Hi George, link traversal is O(1) operation because the RID is like a physical pointer to data. Using UUID would mean relying on an index to find the RID corresponding to the UUID. SBTree index you will give you O(logN) performance. HashIndex will give you a near O(1) performance in the average case, but in the worst case you will have O(N)
Luigi 2015-01-06 23:17 GMT+01:00 george chumakov <[email protected]>: > Hi guys. > > I come from DDD and RDBMS background. > Usually when I create my domain model I use UUID as business key to > uniquely distinguish my domain entities. In RDBMS I create surrogate auto > incremented primary key and indexed business key with unique constraint. I > do it to decouple my domain model and business logic from underlying > database, which basically means that PK is used in DB/Joins only and BK is > used in business logic and queries. > > One of OrientDB's most powerful features is O(1) for lookup based on RID. > So the question is: Is it possible to have such fast lookup based on my > business key field? > > P.s. My English is far from perfect so please don't be shy to ask for > clarification. > > Thanks in advance. > > > -- > > --- > You received this message because you are subscribed to the Google Groups > "OrientDB" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- --- You received this message because you are subscribed to the Google Groups "OrientDB" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
