I created custom work item for jBPM 7.74.1.Final. It is based on "core" Rest Work Item (https://github.com/kiegroup/jbpm/tree/main/jbpm-workitems/jbpm-workitems-rest). I added OAuth2 authentication there. It works when I use it in Eclipse jBPM plugin. But it does not work in Business Central. There is an error in log:
11:41:04,021 ERROR [org.kie.workbench.common.stunner.bpmn.backend.workitem.WorkItemDefinitionParser] (default task-49) The work item has an invalid name [ Rest2].It must contain words only, skipping it.
Any idea what is the cause of this error?
The way how I add it to the Business Central:
- BC homepage, click Admin (upper right corner)
- Custom Task Administration
- Click Add Custom Task and upload the *.jar with the work item
- Wtich toggle to "ON"
- Go to my project
- Go to "Settings" tab
- Go to "Custom Task" part and click on "Install"
- Create a new business process in my project
- BUG: I can not see my work item
Rest2.wid file (generated automatically during maven build):
[
[
"name" : "Rest2",
"displayName" : "Rest2",
"category" : "jbpm-workitem-rest2",
"description" : "",
"defaultHandler" : "mvel: new com.cross_ni.cross.jbpm.workitem.rest2.REST2WorkItemHandler()",
"documentation" : "jbpm-workitem-rest2/index.html",
"parameters" : [
"Cookie" : new StringDataType()
,"ConnectTimeout" : new StringDataType()
,"ResultClass" : new StringDataType()
,"ContentType" : new StringDataType()
,"AcceptCharset" : new StringDataType()
,"Headers" : new StringDataType()
,"AuthUrl" : new StringDataType()
,"CookiePath" : new StringDataType()
,"Method" : new StringDataType()
,"ReadTimeout" : new StringDataType()
,"Url" : new StringDataType()
,"ContentTypeCharset" : new StringDataType()
,"HandleResponseErrors" : new StringDataType()
,"ContentData" : new StringDataType()
,"Username" : new StringDataType()
,"Content" : new StringDataType()
,"AcceptHeader" : new StringDataType()
,"AuthType" : new StringDataType()
,"Password" : new StringDataType()
],
"results" : [
"Result" : new StringDataType()
],
"mavenDependencies" : [
"com.cross_ni.cross:jbpm-workitem-rest2:1.0.0-SNAPSHOT"
],
"icon" : "defaultresticon.png"
]
]
Thank you.