You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Gerardo Arroyo <ge...@flecharoja.com> on 2003/02/17 18:30:03 UTC
Problem with HighLowSequence under 0.9.9 and 0.9.8
Hi,
I am having some problems with OJB 0.9.8 and 0.9.9.
The problems is a
[org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can not get next org.apache.ojb.broker.util.sequence.HighLowSequence for next scope of keys
null
everytime that I attempt to insert a new record on a table, I am using SybaseASE 11.9.2 under Linux. The extract of the repository user is:
<class-descriptor
class="com.unify.webcenter.data.teamsData"
table="teams"
>
<field-descriptor id="1"
name="authorized"
column="authorized"
jdbc-type="CHAR"
/>
<field-descriptor id="2"
name="members"
column="members"
jdbc-type="INTEGER"
/>
<field-descriptor id="3"
name="projects"
column="projects"
jdbc-type="INTEGER"
/>
<field-descriptor id="4"
name="published"
column="published"
jdbc-type="CHAR"
/>
<field-descriptor id="5"
name="id"
column="id"
jdbc-type="INTEGER"
primarykey="true"
autoincrement="true"
/>
<reference-descriptor name="parentMember"
class-ref="com.unify.webcenter.data.membersData"
refresh="true">
<foreignkey field-id-ref = "2"/>
</reference-descriptor>
</class-descriptor>
And the stack trace is below. Any idea or suggestion???
Thanks in advance!
[org.apache.ojb.broker.accesslayer.ConnectionFactoryPooledImpl] INFO: Create new connection pool:org.apache.ojb.broker.metadata.JdbcConnectionDescriptor@1014e21[
jcd-alias=default
default-connection=true
dbms=SybaseASE
jdbc-level=1.0
driver=com.sybase.jdbc2.jdbc.SybDriver
protocol=jdbc
sub-protocol=sybase
db-alias=Tds:10.1.1.137:5000/unifycenter
user=sa
password=*****
eager-release=false
ConnectionPoolDescriptor={whenExhaustedAction=0, maxIdle=-1, maxActive=21, maxWait=5000, removeAbandoned=false, numTestsPerEvictionRun=10, testWhileIdle=false, minEvictableIdleTimeMillis=600000, testOnReturn=false, logAbandoned=false, removeAbandonedTimeout=300, timeBetweenEvictionRunsMillis=-1, testOnBorrow=true}
batchMode=false
sequenceDescriptor=org.apache.ojb.broker.metadata.SequenceDescriptor@1c297a3[
sequenceManagerClass=class org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl
Properties={grabSize=5}
]
]
[org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can not get next org.apache.ojb.broker.util.sequence.HighLowSequence for next scope of keys
null
org.apache.ojb.broker.TransactionInProgressException
at org.apache.ojb.broker.singlevm.PersistenceBrokerImpl.beginTransaction(Unknown Source)
at org.apache.ojb.broker.singlevm.DelegatingPersistenceBroker.beginTransaction(Unknown Source)
at org.apache.ojb.broker.util.sequence.SequenceGenerator.getNextSequence(Unknown Source)
at org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl.getUniqueId(Unknown Source)
at org.apache.ojb.broker.util.BrokerHelper.getAutoIncrementValue(Unknown Source)
at org.apache.ojb.broker.util.BrokerHelper.getKeyValues(Unknown Source)
at org.apache.ojb.broker.Identity.init(Unknown Source)
at org.apache.ojb.broker.Identity.<init>(Unknown Source)
at org.apache.ojb.broker.singlevm.PersistenceBrokerImpl.store(Unknown Source)
at org.apache.ojb.broker.singlevm.DelegatingPersistenceBroker.store(Unknown Source)
at com.unify.webcenter.broker.MainBroker.add(MainBroker.java:37)
at com.unify.webcenter.action.teamsAction.perform(teamsAction.java:156)
at org.apache.struts.action.ActionServlet.processActionPerform(ActionServlet.java:1720)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1519)
at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:505)
at javax.servlet.http.HttpServlet.service(HttpServlet.java)
at javax.servlet.http.HttpServlet.service(HttpServlet.java)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Unknown Source)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(Unknown Source)
at org.apache.catalina.core.StandardWrapperValve.invoke(Unknown Source)
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
at org.apache.catalina.core.StandardContextValve.invoke(Unknown Source)
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
at org.apache.catalina.core.StandardContext.invoke(Unknown Source)
at org.apache.catalina.core.StandardHostValve.invoke(Unknown Source)
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
at org.apache.catalina.valves.ErrorDispatcherValve.invoke(Unknown Source)
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
at org.apache.catalina.valves.ErrorReportValve.invoke(Unknown Source)
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
at org.apache.catalina.valves.AccessLogValve.invoke(Unknown Source)
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
at org.apache.catalina.core.StandardEngineValve.invoke(Unknown Source)
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
at org.apache.catalina.connector.http.HttpProcessor.process(Unknown Source)
at org.apache.catalina.connector.http.HttpProcessor.run(Unknown Source)
at java.lang.Thread.run(Thread.java:536)
[org.apache.ojb.broker.accesslayer.ConnectionManagerImpl] INFO: Rollback was called, do rollback on current connection com.sybase.jdbc2.jdbc.SybConnection@1f195fc
Ing. Gerardo Arroyo Arce
Flecha Roja Technologies
Doubt about the setStartAtIndex - setEndAtIndex
Posted by Gerardo Arroyo <ge...@flecharoja.com>.
Good day!
I've a doubt about the semantics of the setStartAtIndex - setEndAtIndex methods of the Query Class.
In the most simply case, without a orderBy clause, this methods return all the rows in the range specified.
But, in a more complex case with the use of the addOrderByDescending() or addOrderByAscending() the result is not consistent. Let me explain the results:
I had 13 records on the DBMS, named: 1,2,3...until 13
If I use the setStartAtIndex and setEndAtIndex in blocks of 5 elements without order I got:
1 to 5
6 to 10
11 to 13 -> PERFECT!!
but I use the orderByClause I got:
1 to 5
6 to 10
1 to 2 (?????!!!!! WHY? )
Is that the expected behavior? Am I missing something??
Thanks in advance!!!
Ing. Gerardo Arroyo Arce
Flecha Roja Technologies
Re: Problem with HighLowSequence under 0.9.9 and 0.9.8
Posted by Armin Waibel <ar...@code-au-lait.de>.
OK, the problem is that the PB used in the SequenceGenerator
seems to be in a transaction.
Do you direct use a ConnectionManager instance in your
code base?
Do you use the PB in the standard way: Per thread a PB. Close PB
after work is done?
Could you post the code snip where the error
occurred.
regards,
Armin
----- Original Message -----
From: "Gerardo Arroyo" <ge...@flecharoja.com>
To: "Armin Waibel" <ar...@code-au-lait.de>
Cc: "OJB Users List" <oj...@db.apache.org>
Sent: Monday, February 17, 2003 10:20 PM
Subject: Re: Problem with HighLowSequence under 0.9.9 and 0.9.8
> Hi Armin,
>
> I checked all the new configuration files (OJB.properties,
> repository_internal.xml, etc). I already had all the files up to date.
>
> So, I follow your advice and try to use the
SequenceManagerInMemoryImpl.
> With this new SequenceManager I don't have any problem, and everything
> work smoothly.
>
> However, if I try to use the SequenceManagerHighLowImpl I got the same
> exception.
>
> [org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can not
> get next org.apache.ojb.broker.util.sequence.HighLowSequence for next
> scope of keys null
>
> Any idea or suggestion?
>
> Thanks in advance!
> Gerardo
>
>
>
> On Mon, 2003-02-17 at 12:06, Armin Waibel wrote:
>
> > Hi Gerardo,
> >
> > between 0.9.8 and 0.9.9 many changes were made.
> > Now field descriptor id was no longer used, see examples in
> > repository files (in particular reference-descriptor, use
> > foreignkey field-ref).
> > Do you really update all configuration files (OJB.properties,
> > repository_internal.xml, ...)?
> >
> > If this doesn't help, try to use another SequenceManager
> > for testing e.g. SequenceManagerInMemoryImpl (this
> > implementation does not store any data to database)
> > and post the stack trace again.
> >
> > regards,
> > Armin
> >
> >
> > ----- Original Message -----
> > From: "Gerardo Arroyo" <ge...@flecharoja.com>
> > To: "OJB Users List" <oj...@db.apache.org>
> > Sent: Monday, February 17, 2003 6:30 PM
> > Subject: Problem with HighLowSequence under 0.9.9 and 0.9.8
> >
> >
> > > Hi,
> > >
> > > I am having some problems with OJB 0.9.8 and 0.9.9.
> > >
> > > The problems is a
> > > [org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can
not
> > get next org.apache.ojb.broker.util.sequence.HighLowSequence for
next
> > scope of keys
> > > null
> > >
> > > everytime that I attempt to insert a new record on a table, I am
using
> > SybaseASE 11.9.2 under Linux. The extract of the repository user
is:
> > >
> > > <class-descriptor
> > > class="com.unify.webcenter.data.teamsData"
> > > table="teams"
> > > >
> > > <field-descriptor id="1"
> > > name="authorized"
> > > column="authorized"
> > > jdbc-type="CHAR"
> > > />
> > > <field-descriptor id="2"
> > > name="members"
> > > column="members"
> > > jdbc-type="INTEGER"
> > > />
> > > <field-descriptor id="3"
> > > name="projects"
> > > column="projects"
> > > jdbc-type="INTEGER"
> > > />
> > > <field-descriptor id="4"
> > > name="published"
> > > column="published"
> > > jdbc-type="CHAR"
> > > />
> > > <field-descriptor id="5"
> > > name="id"
> > > column="id"
> > > jdbc-type="INTEGER"
> > > primarykey="true"
> > > autoincrement="true"
> > > />
> > > <reference-descriptor name="parentMember"
> > > class-ref="com.unify.webcenter.data.membersData"
> > > refresh="true">
> > > <foreignkey field-id-ref = "2"/>
> > > </reference-descriptor>
> > > </class-descriptor>
> > >
> > >
> > > And the stack trace is below. Any idea or suggestion???
> > >
> > > Thanks in advance!
> > >
> > >
> > > [org.apache.ojb.broker.accesslayer.ConnectionFactoryPooledImpl]
INFO:
> > Create new connection
> >
pool:org.apache.ojb.broker.metadata.JdbcConnectionDescriptor@1014e21[
> > > jcd-alias=default
> > > default-connection=true
> > > dbms=SybaseASE
> > > jdbc-level=1.0
> > > driver=com.sybase.jdbc2.jdbc.SybDriver
> > > protocol=jdbc
> > > sub-protocol=sybase
> > > db-alias=Tds:10.1.1.137:5000/unifycenter
> > > user=sa
> > > password=*****
> > > eager-release=false
> > > ConnectionPoolDescriptor={whenExhaustedAction=0, maxIdle=-1,
> > maxActive=21, maxWait=5000, removeAbandoned=false,
> > numTestsPerEvictionRun=10, testWhileIdle=false,
> > minEvictableIdleTimeMillis=600000, testOnReturn=false,
> > logAbandoned=false, removeAbandonedTimeout=300,
> > timeBetweenEvictionRunsMillis=-1, testOnBorrow=true}
> > > batchMode=false
> > >
> >
sequenceDescriptor=org.apache.ojb.broker.metadata.SequenceDescriptor@1c2
> > 97a3[
> > > sequenceManagerClass=class
> > org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl
> > > Properties={grabSize=5}
> > > ]
> > > ]
> > > [org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can
not
> > get next org.apache.ojb.broker.util.sequence.HighLowSequence for
next
> > scope of keys
> > > null
> > > org.apache.ojb.broker.TransactionInProgressException
> > > at
> >
org.apache.ojb.broker.singlevm.PersistenceBrokerImpl.beginTransaction(Un
> > known Source)
> > > at
> >
org.apache.ojb.broker.singlevm.DelegatingPersistenceBroker.beginTransact
> > ion(Unknown Source)
> > > at
> >
org.apache.ojb.broker.util.sequence.SequenceGenerator.getNextSequence(Un
> > known Source)
> > > at
> >
org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl.getUnique
> > Id(Unknown Source)
> > > at
> >
org.apache.ojb.broker.util.BrokerHelper.getAutoIncrementValue(Unknown
> > Source)
> > > at
> > org.apache.ojb.broker.util.BrokerHelper.getKeyValues(Unknown Source)
> > > at org.apache.ojb.broker.Identity.init(Unknown Source)
> > > at org.apache.ojb.broker.Identity.<init>(Unknown Source)
> > > at
> > org.apache.ojb.broker.singlevm.PersistenceBrokerImpl.store(Unknown
> > Source)
> > > at
> >
org.apache.ojb.broker.singlevm.DelegatingPersistenceBroker.store(Unknown
> > Source)
> > > at
> > com.unify.webcenter.broker.MainBroker.add(MainBroker.java:37)
> > > at
> > com.unify.webcenter.action.teamsAction.perform(teamsAction.java:156)
> > > at
> >
org.apache.struts.action.ActionServlet.processActionPerform(ActionServle
> > t.java:1720)
> > > at
> >
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1519)
> > > at
> >
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:505)
> > > at
javax.servlet.http.HttpServlet.service(HttpServlet.java)
> > > at
javax.servlet.http.HttpServlet.service(HttpServlet.java)
> > > at
> >
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Unknown
> > Source)
> > > at
> > org.apache.catalina.core.ApplicationFilterChain.doFilter(Unknown
Source)
> > > at
> > org.apache.catalina.core.StandardWrapperValve.invoke(Unknown Source)
> > > at
> >
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> > nvokeNext(Unknown Source)
> > > at
org.apache.catalina.core.StandardPipeline.invoke(Unknown
> > Source)
> > > at org.apache.catalina.core.ContainerBase.invoke(Unknown
> > Source)
> > > at
> > org.apache.catalina.core.StandardContextValve.invoke(Unknown Source)
> > > at
> >
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> > nvokeNext(Unknown Source)
> > > at
org.apache.catalina.core.StandardPipeline.invoke(Unknown
> > Source)
> > > at org.apache.catalina.core.ContainerBase.invoke(Unknown
> > Source)
> > > at org.apache.catalina.core.StandardContext.invoke(Unknown
> > Source)
> > > at
org.apache.catalina.core.StandardHostValve.invoke(Unknown
> > Source)
> > > at
> >
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> > nvokeNext(Unknown Source)
> > > at
> > org.apache.catalina.valves.ErrorDispatcherValve.invoke(Unknown Sourc
e)
> > > at
> >
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> > nvokeNext(Unknown Source)
> > > at
org.apache.catalina.valves.ErrorReportValve.invoke(Unknown
> > Source)
> > > at
> >
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> > nvokeNext(Unknown Source)
> > > at
org.apache.catalina.valves.AccessLogValve.invoke(Unknown
> > Source)
> > > at
> >
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> > nvokeNext(Unknown Source)
> > > at
org.apache.catalina.core.StandardPipeline.invoke(Unknown
> > Source)
> > > at org.apache.catalina.core.ContainerBase.invoke(Unknown
> > Source)
> > > at
org.apache.catalina.core.StandardEngineValve.invoke(Unknown
> > Source)
> > > at
> >
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> > nvokeNext(Unknown Source)
> > > at
org.apache.catalina.core.StandardPipeline.invoke(Unknown
> > Source)
> > > at org.apache.catalina.core.ContainerBase.invoke(Unknown
> > Source)
> > > at
> > org.apache.catalina.connector.http.HttpProcessor.process(Unknown
Source)
> > > at
> > org.apache.catalina.connector.http.HttpProcessor.run(Unknown Source)
> > > at java.lang.Thread.run(Thread.java:536)
> > > [org.apache.ojb.broker.accesslayer.ConnectionManagerImpl] INFO:
> > Rollback was called, do rollback on current connection
> > com.sybase.jdbc2.jdbc.SybConnection@1f195fc
> > >
> > >
> > >
> > > Ing. Gerardo Arroyo Arce
> > > Flecha Roja Technologies
> > >
> >
> >
>
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> > For additional commands, e-mail: ojb-user-help@db.apache.org
>
Re: Problem with HighLowSequence under 0.9.9 and 0.9.8
Posted by Gerardo Arroyo <ge...@flecharoja.com>.
Hi Armin,
I checked all the new configuration files (OJB.properties,
repository_internal.xml, etc). I already had all the files up to date.
So, I follow your advice and try to use the SequenceManagerInMemoryImpl.
With this new SequenceManager I don't have any problem, and everything
work smoothly.
However, if I try to use the SequenceManagerHighLowImpl I got the same
exception.
[org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can not
get next org.apache.ojb.broker.util.sequence.HighLowSequence for next
scope of keys null
Any idea or suggestion?
Thanks in advance!
Gerardo
On Mon, 2003-02-17 at 12:06, Armin Waibel wrote:
> Hi Gerardo,
>
> between 0.9.8 and 0.9.9 many changes were made.
> Now field descriptor id was no longer used, see examples in
> repository files (in particular reference-descriptor, use
> foreignkey field-ref).
> Do you really update all configuration files (OJB.properties,
> repository_internal.xml, ...)?
>
> If this doesn't help, try to use another SequenceManager
> for testing e.g. SequenceManagerInMemoryImpl (this
> implementation does not store any data to database)
> and post the stack trace again.
>
> regards,
> Armin
>
>
> ----- Original Message -----
> From: "Gerardo Arroyo" <ge...@flecharoja.com>
> To: "OJB Users List" <oj...@db.apache.org>
> Sent: Monday, February 17, 2003 6:30 PM
> Subject: Problem with HighLowSequence under 0.9.9 and 0.9.8
>
>
> > Hi,
> >
> > I am having some problems with OJB 0.9.8 and 0.9.9.
> >
> > The problems is a
> > [org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can not
> get next org.apache.ojb.broker.util.sequence.HighLowSequence for next
> scope of keys
> > null
> >
> > everytime that I attempt to insert a new record on a table, I am using
> SybaseASE 11.9.2 under Linux. The extract of the repository user is:
> >
> > <class-descriptor
> > class="com.unify.webcenter.data.teamsData"
> > table="teams"
> > >
> > <field-descriptor id="1"
> > name="authorized"
> > column="authorized"
> > jdbc-type="CHAR"
> > />
> > <field-descriptor id="2"
> > name="members"
> > column="members"
> > jdbc-type="INTEGER"
> > />
> > <field-descriptor id="3"
> > name="projects"
> > column="projects"
> > jdbc-type="INTEGER"
> > />
> > <field-descriptor id="4"
> > name="published"
> > column="published"
> > jdbc-type="CHAR"
> > />
> > <field-descriptor id="5"
> > name="id"
> > column="id"
> > jdbc-type="INTEGER"
> > primarykey="true"
> > autoincrement="true"
> > />
> > <reference-descriptor name="parentMember"
> > class-ref="com.unify.webcenter.data.membersData"
> > refresh="true">
> > <foreignkey field-id-ref = "2"/>
> > </reference-descriptor>
> > </class-descriptor>
> >
> >
> > And the stack trace is below. Any idea or suggestion???
> >
> > Thanks in advance!
> >
> >
> > [org.apache.ojb.broker.accesslayer.ConnectionFactoryPooledImpl] INFO:
> Create new connection
> pool:org.apache.ojb.broker.metadata.JdbcConnectionDescriptor@1014e21[
> > jcd-alias=default
> > default-connection=true
> > dbms=SybaseASE
> > jdbc-level=1.0
> > driver=com.sybase.jdbc2.jdbc.SybDriver
> > protocol=jdbc
> > sub-protocol=sybase
> > db-alias=Tds:10.1.1.137:5000/unifycenter
> > user=sa
> > password=*****
> > eager-release=false
> > ConnectionPoolDescriptor={whenExhaustedAction=0, maxIdle=-1,
> maxActive=21, maxWait=5000, removeAbandoned=false,
> numTestsPerEvictionRun=10, testWhileIdle=false,
> minEvictableIdleTimeMillis=600000, testOnReturn=false,
> logAbandoned=false, removeAbandonedTimeout=300,
> timeBetweenEvictionRunsMillis=-1, testOnBorrow=true}
> > batchMode=false
> >
> sequenceDescriptor=org.apache.ojb.broker.metadata.SequenceDescriptor@1c2
> 97a3[
> > sequenceManagerClass=class
> org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl
> > Properties={grabSize=5}
> > ]
> > ]
> > [org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can not
> get next org.apache.ojb.broker.util.sequence.HighLowSequence for next
> scope of keys
> > null
> > org.apache.ojb.broker.TransactionInProgressException
> > at
> org.apache.ojb.broker.singlevm.PersistenceBrokerImpl.beginTransaction(Un
> known Source)
> > at
> org.apache.ojb.broker.singlevm.DelegatingPersistenceBroker.beginTransact
> ion(Unknown Source)
> > at
> org.apache.ojb.broker.util.sequence.SequenceGenerator.getNextSequence(Un
> known Source)
> > at
> org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl.getUnique
> Id(Unknown Source)
> > at
> org.apache.ojb.broker.util.BrokerHelper.getAutoIncrementValue(Unknown
> Source)
> > at
> org.apache.ojb.broker.util.BrokerHelper.getKeyValues(Unknown Source)
> > at org.apache.ojb.broker.Identity.init(Unknown Source)
> > at org.apache.ojb.broker.Identity.<init>(Unknown Source)
> > at
> org.apache.ojb.broker.singlevm.PersistenceBrokerImpl.store(Unknown
> Source)
> > at
> org.apache.ojb.broker.singlevm.DelegatingPersistenceBroker.store(Unknown
> Source)
> > at
> com.unify.webcenter.broker.MainBroker.add(MainBroker.java:37)
> > at
> com.unify.webcenter.action.teamsAction.perform(teamsAction.java:156)
> > at
> org.apache.struts.action.ActionServlet.processActionPerform(ActionServle
> t.java:1720)
> > at
> org.apache.struts.action.ActionServlet.process(ActionServlet.java:1519)
> > at
> org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:505)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java)
> > at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Unknown
> Source)
> > at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(Unknown Source)
> > at
> org.apache.catalina.core.StandardWrapperValve.invoke(Unknown Source)
> > at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvokeNext(Unknown Source)
> > at org.apache.catalina.core.StandardPipeline.invoke(Unknown
> Source)
> > at org.apache.catalina.core.ContainerBase.invoke(Unknown
> Source)
> > at
> org.apache.catalina.core.StandardContextValve.invoke(Unknown Source)
> > at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvokeNext(Unknown Source)
> > at org.apache.catalina.core.StandardPipeline.invoke(Unknown
> Source)
> > at org.apache.catalina.core.ContainerBase.invoke(Unknown
> Source)
> > at org.apache.catalina.core.StandardContext.invoke(Unknown
> Source)
> > at org.apache.catalina.core.StandardHostValve.invoke(Unknown
> Source)
> > at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvokeNext(Unknown Source)
> > at
> org.apache.catalina.valves.ErrorDispatcherValve.invoke(Unknown Source)
> > at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvokeNext(Unknown Source)
> > at org.apache.catalina.valves.ErrorReportValve.invoke(Unknown
> Source)
> > at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvokeNext(Unknown Source)
> > at org.apache.catalina.valves.AccessLogValve.invoke(Unknown
> Source)
> > at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvokeNext(Unknown Source)
> > at org.apache.catalina.core.StandardPipeline.invoke(Unknown
> Source)
> > at org.apache.catalina.core.ContainerBase.invoke(Unknown
> Source)
> > at org.apache.catalina.core.StandardEngineValve.invoke(Unknown
> Source)
> > at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvokeNext(Unknown Source)
> > at org.apache.catalina.core.StandardPipeline.invoke(Unknown
> Source)
> > at org.apache.catalina.core.ContainerBase.invoke(Unknown
> Source)
> > at
> org.apache.catalina.connector.http.HttpProcessor.process(Unknown Source)
> > at
> org.apache.catalina.connector.http.HttpProcessor.run(Unknown Source)
> > at java.lang.Thread.run(Thread.java:536)
> > [org.apache.ojb.broker.accesslayer.ConnectionManagerImpl] INFO:
> Rollback was called, do rollback on current connection
> com.sybase.jdbc2.jdbc.SybConnection@1f195fc
> >
> >
> >
> > Ing. Gerardo Arroyo Arce
> > Flecha Roja Technologies
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
Re: Problem with HighLowSequence under 0.9.9 and 0.9.8
Posted by Armin Waibel <ar...@code-au-lait.de>.
Hi Gerardo,
between 0.9.8 and 0.9.9 many changes were made.
Now field descriptor id was no longer used, see examples in
repository files (in particular reference-descriptor, use
foreignkey field-ref).
Do you really update all configuration files (OJB.properties,
repository_internal.xml, ...)?
If this doesn't help, try to use another SequenceManager
for testing e.g. SequenceManagerInMemoryImpl (this
implementation does not store any data to database)
and post the stack trace again.
regards,
Armin
----- Original Message -----
From: "Gerardo Arroyo" <ge...@flecharoja.com>
To: "OJB Users List" <oj...@db.apache.org>
Sent: Monday, February 17, 2003 6:30 PM
Subject: Problem with HighLowSequence under 0.9.9 and 0.9.8
> Hi,
>
> I am having some problems with OJB 0.9.8 and 0.9.9.
>
> The problems is a
> [org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can not
get next org.apache.ojb.broker.util.sequence.HighLowSequence for next
scope of keys
> null
>
> everytime that I attempt to insert a new record on a table, I am using
SybaseASE 11.9.2 under Linux. The extract of the repository user is:
>
> <class-descriptor
> class="com.unify.webcenter.data.teamsData"
> table="teams"
> >
> <field-descriptor id="1"
> name="authorized"
> column="authorized"
> jdbc-type="CHAR"
> />
> <field-descriptor id="2"
> name="members"
> column="members"
> jdbc-type="INTEGER"
> />
> <field-descriptor id="3"
> name="projects"
> column="projects"
> jdbc-type="INTEGER"
> />
> <field-descriptor id="4"
> name="published"
> column="published"
> jdbc-type="CHAR"
> />
> <field-descriptor id="5"
> name="id"
> column="id"
> jdbc-type="INTEGER"
> primarykey="true"
> autoincrement="true"
> />
> <reference-descriptor name="parentMember"
> class-ref="com.unify.webcenter.data.membersData"
> refresh="true">
> <foreignkey field-id-ref = "2"/>
> </reference-descriptor>
> </class-descriptor>
>
>
> And the stack trace is below. Any idea or suggestion???
>
> Thanks in advance!
>
>
> [org.apache.ojb.broker.accesslayer.ConnectionFactoryPooledImpl] INFO:
Create new connection
pool:org.apache.ojb.broker.metadata.JdbcConnectionDescriptor@1014e21[
> jcd-alias=default
> default-connection=true
> dbms=SybaseASE
> jdbc-level=1.0
> driver=com.sybase.jdbc2.jdbc.SybDriver
> protocol=jdbc
> sub-protocol=sybase
> db-alias=Tds:10.1.1.137:5000/unifycenter
> user=sa
> password=*****
> eager-release=false
> ConnectionPoolDescriptor={whenExhaustedAction=0, maxIdle=-1,
maxActive=21, maxWait=5000, removeAbandoned=false,
numTestsPerEvictionRun=10, testWhileIdle=false,
minEvictableIdleTimeMillis=600000, testOnReturn=false,
logAbandoned=false, removeAbandonedTimeout=300,
timeBetweenEvictionRunsMillis=-1, testOnBorrow=true}
> batchMode=false
>
sequenceDescriptor=org.apache.ojb.broker.metadata.SequenceDescriptor@1c2
97a3[
> sequenceManagerClass=class
org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl
> Properties={grabSize=5}
> ]
> ]
> [org.apache.ojb.broker.util.sequence.SequenceGenerator] ERROR: Can not
get next org.apache.ojb.broker.util.sequence.HighLowSequence for next
scope of keys
> null
> org.apache.ojb.broker.TransactionInProgressException
> at
org.apache.ojb.broker.singlevm.PersistenceBrokerImpl.beginTransaction(Un
known Source)
> at
org.apache.ojb.broker.singlevm.DelegatingPersistenceBroker.beginTransact
ion(Unknown Source)
> at
org.apache.ojb.broker.util.sequence.SequenceGenerator.getNextSequence(Un
known Source)
> at
org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl.getUnique
Id(Unknown Source)
> at
org.apache.ojb.broker.util.BrokerHelper.getAutoIncrementValue(Unknown
Source)
> at
org.apache.ojb.broker.util.BrokerHelper.getKeyValues(Unknown Source)
> at org.apache.ojb.broker.Identity.init(Unknown Source)
> at org.apache.ojb.broker.Identity.<init>(Unknown Source)
> at
org.apache.ojb.broker.singlevm.PersistenceBrokerImpl.store(Unknown
Source)
> at
org.apache.ojb.broker.singlevm.DelegatingPersistenceBroker.store(Unknown
Source)
> at
com.unify.webcenter.broker.MainBroker.add(MainBroker.java:37)
> at
com.unify.webcenter.action.teamsAction.perform(teamsAction.java:156)
> at
org.apache.struts.action.ActionServlet.processActionPerform(ActionServle
t.java:1720)
> at
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1519)
> at
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:505)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java)
> at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Unknown
Source)
> at
org.apache.catalina.core.ApplicationFilterChain.doFilter(Unknown Source)
> at
org.apache.catalina.core.StandardWrapperValve.invoke(Unknown Source)
> at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvokeNext(Unknown Source)
> at org.apache.catalina.core.StandardPipeline.invoke(Unknown
Source)
> at org.apache.catalina.core.ContainerBase.invoke(Unknown
Source)
> at
org.apache.catalina.core.StandardContextValve.invoke(Unknown Source)
> at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvokeNext(Unknown Source)
> at org.apache.catalina.core.StandardPipeline.invoke(Unknown
Source)
> at org.apache.catalina.core.ContainerBase.invoke(Unknown
Source)
> at org.apache.catalina.core.StandardContext.invoke(Unknown
Source)
> at org.apache.catalina.core.StandardHostValve.invoke(Unknown
Source)
> at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvokeNext(Unknown Source)
> at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(Unknown Source)
> at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvokeNext(Unknown Source)
> at org.apache.catalina.valves.ErrorReportValve.invoke(Unknown
Source)
> at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvokeNext(Unknown Source)
> at org.apache.catalina.valves.AccessLogValve.invoke(Unknown
Source)
> at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvokeNext(Unknown Source)
> at org.apache.catalina.core.StandardPipeline.invoke(Unknown
Source)
> at org.apache.catalina.core.ContainerBase.invoke(Unknown
Source)
> at org.apache.catalina.core.StandardEngineValve.invoke(Unknown
Source)
> at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvokeNext(Unknown Source)
> at org.apache.catalina.core.StandardPipeline.invoke(Unknown
Source)
> at org.apache.catalina.core.ContainerBase.invoke(Unknown
Source)
> at
org.apache.catalina.connector.http.HttpProcessor.process(Unknown Source)
> at
org.apache.catalina.connector.http.HttpProcessor.run(Unknown Source)
> at java.lang.Thread.run(Thread.java:536)
> [org.apache.ojb.broker.accesslayer.ConnectionManagerImpl] INFO:
Rollback was called, do rollback on current connection
com.sybase.jdbc2.jdbc.SybConnection@1f195fc
>
>
>
> Ing. Gerardo Arroyo Arce
> Flecha Roja Technologies
>