Bug 1209949 - Kie projects cannot be built outside business central, because modelers may add annotations, but do not add kie-api dependency to pom.xml of the kjar
Summary: Kie projects cannot be built outside business central, because modelers may a...
Keywords:
Status: CLOSED EOL
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: Data Modeler
Version: 6.1.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: ---
Assignee: Toni Rikkola
QA Contact: Jiri Locker
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-04-08 13:50 UTC by Jiri Svitak
Modified: 2020-03-27 19:02 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-03-27 19:02:02 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1181601 0 medium CLOSED Missing dependency in pom file generated by the workbench 2021-02-22 00:41:40 UTC
Red Hat Bugzilla 1267510 0 high CLOSED Not able to execute rules from guided decision table if we build kjar through mvn command. 2021-02-22 00:41:40 UTC
Red Hat Issue Tracker GUVNOR-2274 0 None None None Never

Internal Links: 1181601 1267510

Description Jiri Svitak 2015-04-08 13:50:38 UTC
Description of problem:
Data modeler adds automatically kie annotations, but does not add kie-api dependency in pom.xml of the kjar project. This means that the kie project cannot be built outside business central.

We found it here [1].
There are two annotations
@org.kie.api.definition.type.Label(value = "Reward recipient")
@org.kie.api.definition.type.Position(value = 0)
added by business-central (the first one is definitely added by data modeler, the second one might be by form modeler). However there is no kie-api dependency added in kie project pom.xml file. So the kie project cannot be built outside business central. I had to fix that manually like this [2].


Version-Release number of selected component (if applicable):
BPM Suite 6.1.0.CR1

Steps to Reproduce:
1. Create a project in business central.
2. Add a new data object. 
3. Fill in id, name and label. Label is important!
4. Click on tab button 'Source'.
5. You can see similar annotation added to an attribute of the data object:
@org.kie.api.definition.type.Label(value = "idcko")
6. Click on wheel and change 'Project View' to 'Repository View'.
7. Open pom.xml. There is no dependency to artifact kie-api defined. Project cannot be built outside business-central.


Actual results:
Business central adds automatically kie annotations, but does not add kie-api dependency in pom.xml of the kjar project. Such kie project cannot be built outside business central.

Expected results:
When business central adds a kie annotation to data model classes, they should also add necessary dependencies to project's pom.xml file, so the kie project can be built without modifications outside business central.

[1] https://github.com/jsvitak/jbpm-6-examples-assets/commit/625dd865e9ff0c2678c04ef08679f5cb2b02c0da#diff-6db57578e3b4faa0d83daa221191f9a6R7
[2] https://github.com/jsvitak/jbpm-6-examples-assets/commit/3862a126872396383225c31399397b2d861bf6dc#diff-0e4ce80139ae74c93022962a42b05de6R20

Comment 1 Kris Verlaenen 2015-04-09 11:10:57 UTC
This is a more generic issue, basically all the core jars are provided when building in the workbench, but they are not declared as such.  It does however require a solution to include dependencies like this without losing the ability to migrate projects from one version to the other (without having to manually update all pom files).

Comment 3 Geoffrey De Smet 2015-09-25 08:23:42 UTC
A release needs to be 100% reproducible, up to the last bit.
That's important when doing a hotfix release (from a release branch) on a mission-critical kjar that's running in production while you're changing it on the master branch. (This only applies when wb supports branching and hotfix releases of course).

Therefore, I would recommend that when a kjar is being released (more specifically during the tagging of all the source code for that release), that a kie-api version is recorded in the wb repository, which is the same as the current workbench version. This way, the release (or a hotfix version of it) can be released again at a later change, even if the workbench version has upgraded, without affecting the kie-api version in the released kjar.


Note You need to log in before you can comment on or make changes to this bug.