question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

CodeGen for processes uses unexpected unique id for task names: causes missing endpoints

See original GitHub issue

Consider endpoints such as:

image

image

and config that looks like this:

image image image

(Answer: There are only two task endpoints generated, but there are three unique task definitions)

The Name/TaskNames are not unique and not enforced to be unique during deployment.

In the XML we have the ~true unique name:

<bpmn2:userTask id="_8B9E78DF-5DCE-44D1-B37E-707166B06BC4" name="My Task Name&#10;Row 2">
...
<bpmn2:userTask id="_FFCD0178-2716-4E16-B593-692770BC9E8B" name="Task">
...
<bpmn2:userTask id="_4AD34142-F892-439D-AA0C-6AB8C4B95999" name="Task">

ignoring the ~weird drools extensions that get auto added for a moment:

      <bpmn2:userTask id="_4AD34142-F892-439D-AA0C-6AB8C4B95999" name="Task">
        <bpmn2:extensionElements>
          <drools:metaData name="elementname">
            <drools:metaValue><![CDATA[Task]]></drools:metaValue>
          </drools:metaData>
        </bpmn2:extensionElements>
...

The id for a bpmn element is usually the unique identifier. The ID is not super friendly at the moment, and understandably someone chose something in the BPMN that would be cleaner. Would this suggest that Kogito wants to enforce unique Drools meta values ? IMO would be MUCh cleaner for XML readability if the extension was not used and the id property was used here. makes it much easier to read node execution history events as well.

Either way, the at the moment the problem is endpoints do not get generated as expected. If we are saying that this is expected because the task instance ID would be unique, then why are we generated named endpoints (where the task endpoint has the Task Name in the url)? the answer seems to be so so you could have Schema support for each task, and if that is the case then we seem to be back to the issue described above.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:12 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
fjtiradocommented, Jan 19, 2022

So, maybe we should change TaskName to TaskId and enforce uniquenes, will that avoid confussion?

0reactions
ederigncommented, Apr 20, 2022

For better tracking, we are now following this issue only at https://issues.redhat.com/browse/KOGITO-7013

Read more comments on GitHub >

github_iconTop Results From Across the Web

deepmap/oapi-codegen: Generate Go client and ... - GitHub
We're going to use the OpenAPI example of the Expanded Petstore in the ... Unique id of the pet Id int64 `json:"id"` //...
Read more >
How to use GraphQL Code Generator with React and Apollo
In this blog post, you'll learn how to use the missing piece (GraphQL Code Generator) to unleash the full potential of GraphQL with...
Read more >
Unique ID fields - Microsoft Support
The Unique ID field contains the number that Microsoft Office Project automatically designates whenever a new task, resource, or assignment is created in ......
Read more >
Fix list for IBM WebSphere Application Server V8.5
IBM WebSphere Application Server provides periodic fixes for the base and Network Deployment editions of release V8.5. The following is a complete listing ......
Read more >
OpenAPI Specification v3.1.0 | Introduction, Definitions, & More
In the latter case, Reference Objects and Schema Object $ref keywords are used. It is RECOMMENDED that the root OpenAPI document be named: ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found