Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [CDO] Error initializing server for PostgreSQL DB in CDO M6
[CDO] Error initializing server for PostgreSQL DB in CDO M6 [message #1027072] Tue, 26 March 2013 14:25 Go to next message
Marc Gil is currently offline Marc GilFriend
Messages: 81
Registered: July 2009
Member
Hi,

Due to the error posted in this thread (http://www.eclipse.org/forums/index.php/t/464208/), I decided to update CDO version to 4.2-M6, released one week ago.

I try it with my PostgreSQL server 9.1 and also 9.2, using the last drivers (9.2 Build 1002, both jdbc3 and jdbc4), and an exception is raised when starting the server (without having the database created):

!ENTRY org.eclipse.equinox.app 4 0 2013-03-26 15:20:15.676
!MESSAGE DELETE FROM CDO_PROPERTIES WHERE NAME=?
!STACK 0
org.eclipse.net4j.db.DBException: DELETE FROM CDO_PROPERTIES WHERE NAME=?
	at org.eclipse.emf.cdo.server.internal.db.DBStore.setPersistentProperties(DBStore.java:394)
	at org.eclipse.emf.cdo.server.internal.db.DBStore.setCreationTime(DBStore.java:544)
	at org.eclipse.emf.cdo.server.internal.db.DBStore.firstStart(DBStore.java:712)
	at org.eclipse.emf.cdo.server.internal.db.DBStore.doActivate(DBStore.java:645)
	at org.eclipse.net4j.util.lifecycle.Lifecycle.internalActivate(Lifecycle.java:76)
	at org.eclipse.net4j.util.lifecycle.Lifecycle.activate(Lifecycle.java:162)
	at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:114)
	at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:104)
	at org.eclipse.emf.cdo.internal.server.Repository.doActivate(Repository.java:1874)
	at org.eclipse.net4j.util.lifecycle.Lifecycle.internalActivate(Lifecycle.java:76)
	at org.eclipse.net4j.util.lifecycle.ShareableLifecycle.internalActivate(ShareableLifecycle.java:43)
	at org.eclipse.net4j.util.lifecycle.Lifecycle.activate(Lifecycle.java:162)
	at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:114)
	at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:104)
	at org.eclipse.emf.cdo.server.CDOServerUtil.addRepository(CDOServerUtil.java:291)
	at org.eclipse.emf.cdo.spi.server.RepositoryConfigurator.configure(RepositoryConfigurator.java:116)
	at org.eclipse.emf.cdo.internal.server.bundle.CDOServerApplication.doStart(CDOServerApplication.java:61)
	at org.eclipse.net4j.util.om.OSGiApplication.start(OSGiApplication.java:63)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
	at org.eclipse.equinox.internal.app.AnyThreadAppLauncher.run(AnyThreadAppLauncher.java:26)
	at java.lang.Thread.run(Unknown Source)
Caused by: org.postgresql.util.PSQLException: ERROR: no existe la relación «cdo_properties»
  Position: 13
	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2157)
	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1886)
	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:555)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:417)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:363)
	at org.eclipse.net4j.internal.db.DBPreparedStatement.executeUpdate(DBPreparedStatement.java:149)
	at org.eclipse.emf.cdo.server.internal.db.DBStore.setPersistentProperties(DBStore.java:381)
	... 20 more


Any suggestion?

Thanks,
Marc Gil
Re: [CDO] Error initializing server for PostgreSQL DB in CDO M6 [message #1027076 is a reply to message #1027072] Tue, 26 March 2013 14:26 Go to previous messageGo to next message
Marc Gil is currently offline Marc GilFriend
Messages: 81
Registered: July 2009
Member
I tried using a MySQL and it works fine, so maybe it's a Driver problem, but maybe you can check in the CDO code if a table exists or not before executing the sql statement, isn't it?

Thanks,
Marc Gil
Re: [CDO] Error initializing server for PostgreSQL DB in CDO M6 [message #1027099 is a reply to message #1027076] Tue, 26 March 2013 14:53 Go to previous messageGo to next message
Marc Gil is currently offline Marc GilFriend
Messages: 81
Registered: July 2009
Member
Definitely, I think that this problem is inserted in the new version of CDO, cause I tried it using my old PostgreSQL 9.1, with the drivers I was using before, and it works fine if the database has been initialized before, but it fails if the database if created but never initialized by CDO.
Re: [CDO] Error initializing server for PostgreSQL DB in CDO M6 [message #1027734 is a reply to message #1027099] Wed, 27 March 2013 10:49 Go to previous messageGo to next message
Marc Gil is currently offline Marc GilFriend
Messages: 81
Registered: July 2009
Member
In the version of CDO M6, using PostgreSQL, first time a model is created, when the tables of the metamodel don't exist in the DB, it appears another exception. I think it's all related with the same bug, cause it doesn't happen with MySQL.

[ERROR] Rollback in DBStore: org.eclipse.net4j.db.DBException: org.postgresql.util.PSQLException: ERROR: no existe la relación «requirementmanagement_requirementmanagement»
  Position: 13
	at org.eclipse.emf.cdo.server.internal.db.mapping.horizontal.HorizontalNonAuditClassMapping.writeValues(HorizontalNonAuditClassMapping.java:247)
	at org.eclipse.emf.cdo.server.internal.db.mapping.horizontal.AbstractHorizontalClassMapping.writeRevision(AbstractHorizontalClassMapping.java:515)
	at org.eclipse.emf.cdo.server.internal.db.DBStoreAccessor.writeRevision(DBStoreAccessor.java:594)
	at org.eclipse.emf.cdo.server.internal.db.DBStoreAccessor.writeRevisions(DBStoreAccessor.java:574)
	at org.eclipse.emf.cdo.spi.server.StoreAccessor.doWrite(StoreAccessor.java:101)
	at org.eclipse.emf.cdo.spi.server.StoreAccessorBase.write(StoreAccessorBase.java:150)
	at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.write(TransactionCommitContext.java:527)
	at org.eclipse.emf.cdo.spi.server.InternalCommitContext$1.runLoop(InternalCommitContext.java:46)
	at org.eclipse.emf.cdo.spi.server.InternalCommitContext$1.runLoop(InternalCommitContext.java:1)
	at org.eclipse.net4j.util.om.monitor.ProgressDistributor.run(ProgressDistributor.java:96)
	at org.eclipse.emf.cdo.internal.server.Repository.commitUnsynced(Repository.java:911)
	at org.eclipse.emf.cdo.internal.server.Repository.commit(Repository.java:904)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CommitTransactionIndication.indicatingCommit(CommitTransactionIndication.java:295)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CommitTransactionIndication.indicating(CommitTransactionIndication.java:97)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CDOServerIndicationWithMonitoring.indicating(CDOServerIndicationWithMonitoring.java:109)
	at org.eclipse.net4j.signal.IndicationWithMonitoring.indicating(IndicationWithMonitoring.java:86)
	at org.eclipse.net4j.signal.IndicationWithResponse.doExtendedInput(IndicationWithResponse.java:92)
	at org.eclipse.net4j.signal.Signal.doInput(Signal.java:328)
	at org.eclipse.net4j.signal.IndicationWithResponse.execute(IndicationWithResponse.java:65)
	at org.eclipse.net4j.signal.IndicationWithMonitoring.execute(IndicationWithMonitoring.java:65)
	at org.eclipse.net4j.signal.Signal.runSync(Signal.java:253)
	at org.eclipse.net4j.signal.Signal.run(Signal.java:149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:662)
Caused by: org.postgresql.util.PSQLException: ERROR: no existe la relación «requirementmanagement_requirementmanagement»
  Position: 13
	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2157)
	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1886)
	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:555)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:417)
	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:363)
	at org.eclipse.net4j.internal.db.DBPreparedStatement.executeUpdate(DBPreparedStatement.java:149)
	at org.eclipse.net4j.db.DBUtil.update(DBUtil.java:775)
	at org.eclipse.emf.cdo.server.internal.db.mapping.horizontal.HorizontalNonAuditClassMapping.writeValues(HorizontalNonAuditClassMapping.java:243)
	... 24 more
Re: [CDO] Error initializing server for PostgreSQL DB in CDO M6 [message #1028768 is a reply to message #1027734] Thu, 28 March 2013 18:01 Go to previous messageGo to next message
Marc Gil is currently offline Marc GilFriend
Messages: 81
Registered: July 2009
Member
It works completely fine with 4.2 M5.

I opened a bugzilla: https://bugs.eclipse.org/bugs/show_bug.cgi?id=404582
Re: [CDO] Error initializing server for PostgreSQL DB in CDO M6 [message #1031025 is a reply to message #1027072] Mon, 01 April 2013 04:27 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6681
Registered: July 2009
Senior Member
Hi Marc,

Sorry for the late reply, I've just returned from the EclipseCon in Boston.

M6 includes a major redesign of the entire schema handling (compare
http://download.eclipse.org/modeling/emf/cdo/drops/S20130319-1538/relnotes.html ) that could lead to regressions.
Unfortunately I'm not able to install PostgreSQL, so I rely on the community to debug this and provide a patch.

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper



Am 26.03.2013 15:25, schrieb Marc Gil:
> Hi,
>
> Due to the error posted in this thread (http://www.eclipse.org/forums/index.php/t/464208/), I decided to update CDO
> version to 4.2-M6, released one week ago.
>
> I try it with my PostgreSQL server 9.1 and also 9.2, using the last drivers (9.2 Build 1002, both jdbc3 and jdbc4),
> and an exception is raised when starting the server (without having the database created):
>
>
> !ENTRY org.eclipse.equinox.app 4 0 2013-03-26 15:20:15.676
> !MESSAGE DELETE FROM CDO_PROPERTIES WHERE NAME=?
> !STACK 0
> org.eclipse.net4j.db.DBException: DELETE FROM CDO_PROPERTIES WHERE NAME=?
> at org.eclipse.emf.cdo.server.internal.db.DBStore.setPersistentProperties(DBStore.java:394)
> at org.eclipse.emf.cdo.server.internal.db.DBStore.setCreationTime(DBStore.java:544)
> at org.eclipse.emf.cdo.server.internal.db.DBStore.firstStart(DBStore.java:712)
> at org.eclipse.emf.cdo.server.internal.db.DBStore.doActivate(DBStore.java:645)
> at org.eclipse.net4j.util.lifecycle.Lifecycle.internalActivate(Lifecycle.java:76)
> at org.eclipse.net4j.util.lifecycle.Lifecycle.activate(Lifecycle.java:162)
> at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:114)
> at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:104)
> at org.eclipse.emf.cdo.internal.server.Repository.doActivate(Repository.java:1874)
> at org.eclipse.net4j.util.lifecycle.Lifecycle.internalActivate(Lifecycle.java:76)
> at org.eclipse.net4j.util.lifecycle.ShareableLifecycle.internalActivate(ShareableLifecycle.java:43)
> at org.eclipse.net4j.util.lifecycle.Lifecycle.activate(Lifecycle.java:162)
> at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:114)
> at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:104)
> at org.eclipse.emf.cdo.server.CDOServerUtil.addRepository(CDOServerUtil.java:291)
> at org.eclipse.emf.cdo.spi.server.RepositoryConfigurator.configure(RepositoryConfigurator.java:116)
> at org.eclipse.emf.cdo.internal.server.bundle.CDOServerApplication.doStart(CDOServerApplication.java:61)
> at org.eclipse.net4j.util.om.OSGiApplication.start(OSGiApplication.java:63)
> at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
> at org.eclipse.equinox.internal.app.AnyThreadAppLauncher.run(AnyThreadAppLauncher.java:26)
> at java.lang.Thread.run(Unknown Source)
> Caused by: org.postgresql.util.PSQLException: ERROR: no existe la relación «cdo_properties»
> Position: 13
> at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2157)
> at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1886)
> at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
> at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:555)
> at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:417)
> at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:363)
> at org.eclipse.net4j.internal.db.DBPreparedStatement.executeUpdate(DBPreparedStatement.java:149)
> at org.eclipse.emf.cdo.server.internal.db.DBStore.setPersistentProperties(DBStore.java:381)
> ... 20 more
>
>
> Any suggestion?
>
> Thanks,
> Marc Gil


Previous Topic:[CDO/Audtigin] CDORevisionDelta vs. CDORevisionKey
Next Topic:[CDO] Do a rollback only for one resource
Goto Forum:
  


Current Time: Tue Mar 19 02:25:48 GMT 2024

Powered by FUDForum. Page generated in 0.03444 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top