[ http://jira.jboss.com/jira/browse/JBPM-103?page=history ]
Mark LaFond updated JBPM-103:
-----------------------------
Attachment: Script.hbm.xml
attached hibernate config for Script object.
> in variables on Script uses same DB table as out variables, causes evaluation
> errors.
> -------------------------------------------------------------------------------------
>
> Key: JBPM-103
> URL: http://jira.jboss.com/jira/browse/JBPM-103
> Project: JBoss jBPM
> Type: Bug
> Components: Core Engine
> Versions: jBPM 3.0 alpha 2
> Environment: J2SE 1.4.2_07, Windows XP
> Reporter: Mark LaFond
> Assignee: Tom Baeyens
> Priority: Blocker
> Attachments: Script.hbm.xml
>
>
> The following script was failing for me.
> " <script>" +
> " <expression>" +
> " outParm = response.getTestOutputParm();" +
> " </expression>" +
> " <out variable='outParm' />" +
> " </script>" +
> The problem was traced back to Script.hbm.xml which was mapping the in
> variables to the same table as the out variables. This caused
> Script.createInterpreter() to load all of the out variables as in variables
> which caused my "response" variable to NOT be loaded into the Interpreter
> which then caused the script to fail. I've attached the fix below, I've
> tested it in the core project as well as in the db project that generates the
> SQL.
> **********
> <?xml version="1.0"?>
> <!DOCTYPE hibernate-mapping PUBLIC
> "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
> "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
> <hibernate-mapping default-access="field" >
> <subclass name="org.jbpm.jpdl.def.Script"
> discriminator-value="S"
> extends="org.jbpm.graph.def.Action">
> <property name="expression" column="EXPRESSION_" />
> <property name="resultVariableName" column="RESULTVARIABLENAME_" />
> <set name="inVariables" table="JBPM_SCRIPTVARIABLES_IN">
> <key column="SCRIPT_" foreign-key="FK_VARIABLE_SCRIPT_IN" />
> <element type="string" />
> </set>
> <set name="outVariables" table="JBPM_SCRIPTVARIABLES_OUT">
> <key column="SCRIPT_" foreign-key="FK_VARIABLE_SCRIPT_OUT"/>
> <element type="string" />
> </set>
> </subclass>
> </hibernate-mapping>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
JBoss-Development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-development