Search code examples
javaxodus

Is it possible to set custom generated String ID for a Entity?


Is it possible to set custom generated String ID for a Entity?

i.e jetbrains.exodus.entitystore.Entity

Say application generates a alerady unique key using Java UUID or some kind of Object ID can it be used as value of EntityId.toString()


Solution

  • EntityId is an internal id used for managing links under the hood. If it doesn't meet your requirements just use your own app-level id as a property assigned to an entity. You can easily find entities by property values (searching by property value).