Some technical questions

#1

Hi,

ObjectDB looks interesting. Have two technical questions...

(1) what locking model does ObjectDB use? I.e. 2PL or MVCC? Do writers block readers? Do readers block writers?

(2) what's the recommended usage for SAAS? One ObjectDB database per customer, or one ObjectDB database for all?

Thank you,

Andrej

#2

(1) what locking model does ObjectDB use? I.e. 2PL or MVCC? Do writers block readers? Do readers block writers?

ObjectDB implements the standard JPA locking model - see this manual page.

(2) what's the recommended usage for SAAS? One ObjectDB database per customer, or one ObjectDB database for all?

It depends, but one database for all provides better capabilities (e.g cross customer queries).

ObjectDB Support
#3

Thank you.

I understand JPA locking, as described in the manual. But what locking mechanism does ObjectDB use internally. E.g. in one transaction I change an attribute of an object, but don't commit yet. Can another transaction fetch this object without blocking, and will it see the old attribute? Or will the second transaction block until the first transaction either commits or rolls back? Since ObjectDB implements online backups, does it implement something like MVCC, so it can see the data at the time the backup was started (to have consistent backup data)? 

Thanks

Andrej

 

#4

> E.g. in one transaction I change an attribute of an object, but don't commit yet. Can another transaction fetch this object without blocking?

Yes, if it has not been locked with pessimistic WRITE.

> , and will it see the old attribute?

Yes, changes before commit are invisible to other users.

> Since ObjectDB implements online backups, does it implement something like MVCC, so it can see the data at the time the backup was started (to have consistent backup data)?

Yes.

ObjectDB Support
#5

 

That's awesome, thanks.

EclipseLink 2.3 and Hibernate 4 have support for multi-tenancy with JPA. Is that on your road-map? 

Andrej

#6

It could be. Fill a feature request if you are interested.

ObjectDB Support

Reply