299 words

Some technical questions

#1
2011-09-19 19:15

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

andrej
andrej's picture
Joined on 2011-09-19
User Post #1
#2
2011-09-19 20:36

(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
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #611
#3
2011-09-20 07:43

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

 

andrej
andrej's picture
Joined on 2011-09-19
User Post #2
#4
2011-09-20 08:09

> 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
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #614
#5
2011-09-20 13:23

 

That's awesome, thanks.

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

Andrej

andrej
andrej's picture
Joined on 2011-09-19
User Post #3
#6
2011-09-20 16:44

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

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #615

Post Reply

Please read carefully the posting instructions - before posting to the ObjectDB website.

  • You may have to disable pop up blocking in order to use the toolbar (e.g. in Chrome).
  • Use ctrl + right click to open the browser context menu in the editing area (e.g. for using a browser spell checker).
  • To insert formatted lines (e.g. Java code, stack trace) - select a style in the toolbar and then insert the text in the new created block.
  • Avoid overflow of published source code examples by breaking long lines.
  • You may mark in paragraph code words (e.g. class names) with the code style (can be applied by ctrl + D).
  • Long stack traces (> 50 lines) and complex source examples (> 100 lines) should be posted as attachments.
Attachments:
Maximum file size: 32 MB
Cancel