Thread: AW: Re[2]: [OJB-developers] Re: OJB-ODMG does[n't] support implic it locking
Brought to you by:
thma
From: Mahler T. <tho...@it...> - 2002-02-04 07:46:30
|
Hi Doug, > -----Urspr=FCngliche Nachricht----- > Von: Doug Currie [mailto:de...@fl...] > Gesendet: Samstag, 2. Februar 2002 18:52 > An: Thomas Mahler > Cc: ojb > Betreff: Re[2]: [OJB-developers] Re: OJB-ODMG does[n't]=20 > support implicit > locking >=20 >=20 > Hello Thomas, >=20 > Saturday, February 02, 2002, 6:35:51 AM, you wrote: > <snip> > TM> Hmm. If you are NOT using "read-uncommited" and there is no > TM> READ-lock in the LockMap it must be a bug! Which isolation level > TM> are you using for class Article ? >=20 > In two tests I used: <MappingRepository = isolation=3D"repeatable-read"> Hmm, is this a typo? isolation must be declared per ClassDescriptor? > as well as the usual repository.xml; both gave the same results. So > yes, I think there's a bug. >=20 > TM> Maybe we need different semantics for the isolation=20 > levels? Did you have=20 > TM> a look at my doc concerning the LockManager? It contains a table=20 > TM> demonstrating the behaviour of all isolation levels=20 > currently implemented. >=20 > I will look at it more closely. I've hestitated to use the default > read-uncommited isolation level because I don't understand the > implications of the semantics. It's one thing to have transactions > overlap; it's quite another to read a partially modified object. I am > not that brave! >=20 As a consequence of our discussion I placed a note on the feature list = and on the roadmap page stating that implicit locking is not fully = implemented and that users must use explicit lock to have proper tx isolation. I assume we really need object clones per ODMG transaction to have a = clean optimistic locking. Apropos: Jakob implemented locking and it is already integrated into = the latest 0.7.325 release! Thomas > Regards, >=20 > e >=20 >=20 > _______________________________________________ > Objectbridge-developers mailing list > Obj...@li... > https://lists.sourceforge.net/lists/listinfo/objectbridge-developers >=20 |
From: Doug C. <de...@fl...> - 2002-02-04 08:27:41
|
>> In two tests I used: <MappingRepository isolation="repeatable-read"> > Hmm, is this a typo? isolation must be declared per ClassDescriptor? I thought this construction changed the default isolation for all classes. I overlooked the fact that Article's isolation level is set explicitly. (I was looking at test.ojb.broker.Article instead of test.ojb.odmg.Article). So, I ran the tests with the <MappingRepository isolation="repeatable-read"> but otherwise unmodifed repository using LockStrategyFactory.getStrategyFor() to see the isolation level... run_odmg_example: [junit] .[BOOT] INFO: OJB.properties: file:/D:/ejava/ojb-0.7.315/build/test/ojb/OJB.properties [junit] ....[ODMG] ERROR: !!! L: ojb.odmg.locking.RepeatableReadStrategy@406199 [junit] [ODMG] ERROR: !!! L: not read locked! [junit] .[ODMG] ERROR: !!! L: ojb.odmg.locking.ReadUncommittedStrategy@61f24 [junit] [ODMG] ERROR: !!! not read locked !!! [junit] [ODMG] ERROR: !!! dirty cache !!! the RepeatableReadStrategy object is the result of a query on a named DList (remember my ealier bug report). You are right, the Article is ReadUncommittedStrategy. So I changed the Article class isolation... run_odmg_example: [junit] .[BOOT] INFO: OJB.properties: file:/D:/ejava/ojb-0.7.315/build/test/ojb/OJB.properties [junit] ....[ODMG] ERROR: !!! L: ojb.odmg.locking.RepeatableReadStrategy@406199 [junit] [ODMG] ERROR: !!! L: not read locked! [junit] .[ODMG] ERROR: !!! L: ojb.odmg.locking.RepeatableReadStrategy@406199 [junit] [ODMG] ERROR: !!! dirty cache !!! and now we do have a read lock after the query, but still have the implicit write lock "bug." Er, feature. <snip> > As a consequence of our discussion I placed a note on the feature list and > on the roadmap page stating that implicit locking is not fully implemented > and that users must use explicit lock to have proper tx isolation. Very good. That's all we really need. > I assume we really need object clones per ODMG transaction to have a clean > optimistic locking. > Apropos: Jakob implemented locking and it is already integrated into the > latest 0.7.325 release! I meant to write about this. It looks very nice. It is everything we'd need at the broker level for optimistic locking, but as you say, unless we have multiple clones of objects (in the simplest case one per transaction) it won't provide transaction isolation. e |
From: <ri...@ya...> - 2002-03-01 23:47:41
|
Hello, Because of the performance problems I've had with MySQL (maybe it's a = mm.mysql JDBC driver issue, but I have no time to make more tests! My = users are gonna kill me!), I'll try to import my tables to a MS SQL = Server 2000 here in my office. I downloaded the free JDBC drivers here: http://www.microsoft.com/sql/downloads/2000/jdbc.asp (Note: the .exe installer doesn't work, just download the .tar version, = and use the 3 jars from the lib directory) Question: How can I specify the MS driver in the repository.xml file? There is no <dbms.name>MSSQL</dbms.name> entry in the documentation. Does anybody has experience using OJB + MSSQL 2k? Thanks in advance, Ricardo Arguello |
From: Darren S. <dsy...@ci...> - 2002-03-02 12:47:55
|
Here's how to configure the MS drivers within the repository: <JdbcConnectionDescriptor id=3D"default"> <dbms.name>Testdb</dbms.name> <driver.name>com.microsoft.jdbc.sqlserver.SQLServerDriver</driver.nam= e> <url.protocol>jdbc</url.protocol> <url.subprotocol>microsoft:sqlserver</url.subprotocol> <url.dbalias>//DEV-IRIS:1433;DatabaseName=3DTestdb</url.dbalias> <user.name>SQLAuth</user.name> <user.passwd>password</user.passwd> </JdbcConnectionDescriptor> --> The url alias format is: //host:port;DatabaseName=3DTestdb host =3D the database server machine name. Port is typically the default= and finally the database name. You may also need the SelectMethod=3Dcursor - this allows multiple object= s to be opened on the connection - i.e. you can perform both a select and upda= te within a transaction on the same connection. You can specify this option= on the url.dbalias element: <url.dbalias>//DEV-IRIS:1433;DatabaseName=3DTestdb;SelectMethod=3Dcursor<= /url.db alias> Darren ----- Original Message ----- From: "Ricardo Arg=FCello" <ri...@ya...> To: "Objectbridge (E-Mail)" <obj...@li...= t> Sent: Friday, March 01, 2002 11:48 PM Subject: [OJB-developers] OJB + M$ JDBC drivers ? Hello, Because of the performance problems I've had with MySQL (maybe it's a mm.mysql JDBC driver issue, but I have no time to make more tests! My use= rs are gonna kill me!), I'll try to import my tables to a MS SQL Server 2000 here in my office. I downloaded the free JDBC drivers here: http://www.microsoft.com/sql/downloads/2000/jdbc.asp (Note: the .exe installer doesn't work, just download the .tar version, a= nd use the 3 jars from the lib directory) Question: How can I specify the MS driver in the repository.xml file? There is no <dbms.name>MSSQL</dbms.name> entry in the documentation. Does anybody has experience using OJB + MSSQL 2k? Thanks in advance, Ricardo Arguello _______________________________________________ Objectbridge-developers mailing list Obj...@li... https://lists.sourceforge.net/lists/listinfo/objectbridge-developers |
From: Thomas M. <tho...@ho...> - 2002-03-02 15:11:08
|
Hi Ricardo, OJB ships with support for SQL Server 2000. Just enable the flag MSSQLSERVER2000 in build.xml. (Follow the=20 documentation in http://objectbridge.sf.net/rdbms-support.html) Then edit the SQL Server url entries in db-setup.sql an repository.xml hth, Thomas Ricardo Arg=FCello wrote: > Hello, >=20 > Because of the performance problems I've had with MySQL (maybe it's a m= m.mysql JDBC driver issue, but I have no time to make more tests! My user= s are gonna kill me!), I'll try to import my tables to a MS SQL Server 20= 00 here in my office. >=20 > I downloaded the free JDBC drivers here: > http://www.microsoft.com/sql/downloads/2000/jdbc.asp >=20 > (Note: the .exe installer doesn't work, just download the .tar version,= and use the 3 jars from the lib directory) >=20 > Question: > How can I specify the MS driver in the repository.xml file? > There is no <dbms.name>MSSQL</dbms.name> entry in the documentation. > > Does anybody has experience using OJB + MSSQL 2k? >=20 > Thanks in advance, >=20 > Ricardo Arguello >=20 >=20 >=20 >=20 > _______________________________________________ > Objectbridge-developers mailing list > Obj...@li... > https://lists.sourceforge.net/lists/listinfo/objectbridge-developers >=20 >=20 >=20 >=20 |