SourceForge.net Logo
Main Overview Wiki Issues Forum Build Fisheye
Issue Details (XML | Word | Printable)

Key: CMP-921
Type: Improvement Improvement
Status: Open Open
Priority: Major Major
Assignee: Shay Banon
Reporter: Kenny MacLeod
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Compass

Allow document IDs to be externalized

Created: 14/Jan/10 08:39 AM   Updated: 14/Jan/10 08:39 AM
Component/s: Compass::Core
Affects Version/s: None
Fix Version/s: None


 Description  « Hide
When writing a Compass mapping, the ID of each mapped type must be declared within the mapping itself, and must be represented by a property of the type. For example, with OSEM, the ID must be represented as a property of the Class being mapped.

What I would very much like to see would be the ability to "externalize" these IDs, so that they do not have to be present in the mapped class. The ID would become a pure meta-data field in the index, with no representation in the original object.

This would then require the addition of methods to CompassSession, with the ID being passed in to the create() method, along with the object:

session.create(alias, object, id);

The use case for this is that I want to be able to persist a legacy class model in Compass, and the properties of this model are not suitable for use as primary keys in Compass. I want to be able to generate them externally to the model, and pass the ID and model to Compass.

This should be equally applicable to XSEM, JSEM, etc

Thoughts?



 All   Comments   Change History      Sort Order: Ascending order - Click to sort in descending order
There are no comments yet on this issue.