-
Bug
-
Resolution: Done
-
Major
-
6.0.2
-
None
-
Release Notes
-
-
-
-
-
-
CR1
Description of problem:
The free form DRL area is adding semicolon after each line, even if the semicolon should not be there. This can happen for example when you chain method calls and put each method on new line, like this:
new AddressBuilder()
.country("Czech Republic")
.city("Brno")
.street("Purkynova")
.build();
The editor will divide this statement into 5 (one per line) and if you try to validate the rule, it will throw validation errors (because it add the semicolon at the end of each line).
This is a typicall usage of the builder classes and I think should be supported.
Version-Release number of selected component (if applicable):
6.0.2.ER2
How reproducible:
Always
Steps to Reproduce:
1. Download and install the BPMS 6.0.2.ER2. Configure users and roles and start the server.
2. Login, create new Guided Rule. (make sure the org. unit and project are also created)
3. Add free form DRL area and insert (yes, with the new lines):
System
.out
.println("Hello World!");
4. Save the rule. Close the editor and re-open it.
5. Click validate
Actual results:
The statement has been divided into three (one statement per line). This is definitely not ideal. However the real error appears when you try to validate the rule – validation error will appear (see the screenshot), because the editor will add";" at the end of each line, makiung the statements invalid.
Expected results:
The rule should be validated successfully. Ideally IMHO the statement should not be broken into multiple ones.
Additional info:
The "Source" tab will show the rule definition (in DRL) without the semicolons, which makes me wonder if it uses different serialization (into DRL) code?