Undesirable behaviour from call-map-processor

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Undesirable behaviour from call-map-processor

Ashish Vijaywargiya
Hello,

I was working with <call-map-processor> tag.
When I change the details in the <simple-map-processor> then in case of
first change it reflects the results although don't reflect the changes in
the second,third and so on attempt.
See the CustomerEvents.xml file of ecommerce component for the reference.
Request URI is "newcustomer".

Suppose I was having simple-map-processor entry as shown below :-

            <simple-map-processor name="newPerson">
                <process field="USER_FIRST_NAME">
                    <copy to-field="firstName"/>
                    <not-empty><fail-property resource="EcommerceUiLabels"
property="PartyFirstNameMissing"/></not-empty>
                </process>
                <process field="USER_MIDDLE_NAME"><copy
to-field="middleName"/></process>
                <process field="USER_LAST_NAME">
                    <copy to-field="lastName"/>
                    <not-empty><fail-property resource="EcommerceUiLabels"
property="PartyLastNameMissingError"/></not-empty>
                </process>
                <process field="USER_TITLE"><copy
to-field="personalTitle"/></process>
                <process field="USER_SUFFIX"><copy
to-field="suffix"/></process>
                <process field="USER_BIRTHDATE">
                    <convert type="Date" to-field="birthDate"><fail-property
resource="EcommerceUiLabels"
property="PartyBirthDateMissingError"/></convert>
                </process>
                <process field="USER_GENDER"><copy
to-field="gender"/></process>
            </simple-map-processor>


After first change(See below) it reflect the result on the GUI.
            <simple-map-processor name="newPerson">
                <process field="USER_FIRST_NAME">
                    <copy to-field="firstName"/>
                    <not-empty><fail-message message="===============The
value of First Name is missing==============="/></not-empty>
                </process>
                <process field="USER_MIDDLE_NAME"><copy
to-field="middleName"/></process>
                <process field="USER_LAST_NAME">
                    <copy to-field="lastName"/>
                    <not-empty><fail-property resource="EcommerceUiLabels"
property="PartyLastNameMissingError"/></not-empty>
                </process>
                <process field="USER_TITLE"><copy
to-field="personalTitle"/></process>
                <process field="USER_SUFFIX"><copy
to-field="suffix"/></process>
                <process field="USER_BIRTHDATE">
                    <convert type="Date" to-field="birthDate"><fail-property
resource="EcommerceUiLabels"
property="PartyBirthDateMissingError"/></convert>
                </process>
                <process field="USER_GENDER"><copy
to-field="gender"/></process>
            </simple-map-processor>


After second change(see below) it don't reflect the changes on the GUI.
            <simple-map-processor name="newPerson">
                <process field="USER_FIRST_NAME">
                    <copy to-field="firstName"/>
                    <not-empty><fail-message message="===============The
value of First Name is missing==============="/></not-empty>
                </process>
                <process field="USER_MIDDLE_NAME"><copy
to-field="middleName"/></process>
                <process field="USER_LAST_NAME">
                    <copy to-field="lastName"/>
                    <not-empty><fail-message message="=============== Last
name missing==============="/></not-empty>
                </process>
                <process field="USER_TITLE"><copy
to-field="personalTitle"/></process>
                <process field="USER_SUFFIX"><copy
to-field="suffix"/></process>
                <process field="USER_BIRTHDATE">
                    <convert type="Date" to-field="birthDate"><fail-property
resource="EcommerceUiLabels"
property="PartyBirthDateMissingError"/></convert>
                </process>
                <process field="USER_GENDER"><copy
to-field="gender"/></process>
            </simple-map-processor>


Another scenario is also there that is populating the undesirable behaviour
:-
Suppose I transfered the simple-map-processor entry named "newPerson" from
the call-map-processor to the PartyMapProcs.xml file then calling something
like shown below :-
<call-map-processor in-map-name="parameters" out-map-name="personContext"
processor-name="newPerson"
xml-resource="org/ofbiz/party/party/PartyMapProcs.xml"/>
It works fine.

Now if I change the name of simple-map-processor from "newPerson" to
"newPersonTest" in PartyMapProcs.xml file although it get's the
simple-map-processor entry for processing the data.
I am trunk rev # 648602 and didn't do any changes in cache.properties file.
Same behaviour is occuring on other two development machines.

Thanks in advance for any pointer.

--
Thanks & Regards
Ashish Vijaywargiya
+919893479711