|
HI,
we are having
a doctor and department object with every doctor belonging to a department.
there are 2 doctor objects and they will load the their corresponding
departments. when we try a concurrent access we get a Persist.DeadLockException.
there is a bi-directional relationship between doctor and
department.
we've set lazy loading to false and dirty check to
false.
The mapping file is as follows :
<mapping>
<!-- Mapping for
Department-->
<class name="Department" identity="id" key-generator="MAX" access="shared" > <cache-type type="unlimited"
/>
<description>User</description> <map-to table="Department" /> <field name="id" type
="long">
<sql name="pk_department_id" type="bigint"/> </field> <field name="deptName" type="string"> <sql name="deptName" type="varchar" dirty="check"/> </field> <field name="doctors" type="Doctor"
required="false" collection="arraylist" lazy="false"
dirty="ignore">
<sql
many-key="dept_id"/>
</field> </class> <!-- Mapping for Doctor--> <class name="Doctor" identity="id" key-generator="MAX" access="shared" > <cache-type type="unlimited"
/>
<description>Doctor</description> <map-to table="doctor" /> <field name="id" type
="long">
<sql name="pk_doctor_id" type="bigint"/> </field> <field name="userName" type="string"> <sql name="UserName" type="varchar" dirty="check"/> </field> <field name="dept" type="Department"> <sql name="dept_id" /> </field> </class> since its a common day to day scenario and castor fails to work properly,
has it been listed under the castor BUG section> did not find any refernces
to it.
any response in this matter would be appreciated..
thank you..
Arun S
|
