Need to provide a better naming scheme for relationships
--------------------------------------------------------
Key: TUSCANY-144
URL: http://issues.apache.org/jira/browse/TUSCANY-144
Project: Tuscany
Type: Improvement
Components: Java DAS RDB
Reporter: Kevin Williams
Priority: Minor
The current naming scheme allows users to specify a "relationship name" in the
relationship defintion section of the config file. Users tend to name this in
terms of their view of the relationship. For example, if I am trying to
describe a relationship between Company and EmployeeOfTheMonth then I might
logically name the relationship Company->EOM. Then I would expect to be able
to use the dynamic SDO apis to traverse this relationship like this:
DataObject empOfTheMonth = aCompany.getDataObject("Company->EOM")
Currently, the situation is such that the name really applies to the path on
the relationship from the "parent" to the "child". That is , the name refers
to the direction from the parent row (row holding the PK) to the child (row
holding the FK). The DAS then generates a name for the other side of the
relationship by taking "name" and adding "_opposite".
The reult for the example above is that the name for the side of the
relationship from Company to Employee of the month is actually
"Company->EOM_opposite" which is very confusing.
The current convention works well for mostof the time but we may want to allow
the user to name both sides of the relationship and provide documentaiton about
what is actually being named.
OneToOneRelationshipTests.test3 illustrates this issue.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira