Hi Jakob
On Thu, 18 Nov 2004 21:17:04 +0100, Jakob Braeuchi [EMAIL PROTECTED] wrote:
hi gerhard,
i applied a small fix in addCollectionEdges()
...
else
{
if (col instanceof ManageableCollection)
{
Collection newCol = new ArrayList();
Hi Jakob,
On Fri, 19 Nov 2004 08:20:53 +0100 (MET), Jakob Braeuchi [EMAIL PROTECTED]
wrote:
hi armin,
in the testcase i mentioned the auto-update is set to LINK.
does the scenario you describe also work for odmg ? i was thinking of
something similar in PB: the PB keeps track of the
Hi Tino
this looks like a multi-threading problem. java.util.ConcurrentModification
exception is thrown by the Java runtime when a List is being modified while an
iterator is iterating over it. The list in this case is one of the collections
in your Person object. Is it possible that a second
?
Gerhard
Tino
Gerhard Grosse wrote:
Hi Tino
this looks like a multi-threading problem. java.util.ConcurrentModification
exception is thrown by the Java runtime when a List is being modified while
an
iterator is iterating over it. The list in this case is one of the
collections
in your
of object envelopes and remove the vertices
* and all connected edges from the graph./li
* liIf there are vertices left, repeat steps (1) through (3), otherwise
* we are done.
* /ol
*
* @author Gerhard Grosse
* @version $Id: ObjectEnvelopeOrdering.java,v 1.1 2004/11/18 12:25:28 grosse
Hi Nikolaus,
This is copied from ObjectCacheDefaultImpl:
private Integer buildKey(Identity oid)
{
int key = 0;
switch(cachingKeyType)
{
case 0:
key = oid.hashCode();
break;
case 1:
key = new
On Sun, 14 Nov 2004 17:35:04 +0100, £ukasz Korzybski [EMAIL PROTECTED]
wrote:
Dnia czwartek, 11 listopada 2004 13:49, Gerhard Grosse napisa³:
On Wed, 10 Nov 2004 21:26:22 +0100, Grzegorz Pypec [EMAIL PROTECTED]
wrote:
Instead of tx.checkpoint() you can use ((TransactionExt) tx).flush
old (in OJB1.0.x we moved these classes into
the kernel, but without real refactoring). To answer you question, I
tend to bug.
regards,
Armin
Gerhard Grosse wrote:
Hi,
The following code is copied from
org.apache.ojb.odmg.locking.ReadCommittedStrategy:
/**
* release a lock on Object obj
On Wed, 10 Nov 2004 16:15:16 +0100, £ukasz Korzybski [EMAIL PROTECTED]
wrote:
Dnia ¶roda, 10 listopada 2004 10:02, Gerhard Grosse napisa³:
On Wed, 10 Nov 2004 01:51:59 +0100, £ukasz Korzybski [EMAIL PROTECTED]
wrote:
Thanks for reply,
Dnia ¶roda, 10 listopada 2004 00:19, Justin Stanczak
On Wed, 10 Nov 2004 21:26:22 +0100, Grzegorz Pypec [EMAIL PROTECTED]
wrote:
Hi,
I have two persistent object in my database: 'film' and 'title'.
The object 'film' has reference to object 'title'. (1:1 relation)
When I try delete object 'title' in the following way:
java
(...)
On Thu, 11 Nov 2004 08:33:39 -0600, Robert r. Sanders
[EMAIL PROTECTED] wrote:
I believe you need to do something like:
java.sql.Connection connection =
persistenceBroker.serviceConnectionManager().getConnection();
Statement statement = connection.createStatement();
Hi,
The following code is copied from
org.apache.ojb.odmg.locking.ReadCommittedStrategy:
/**
* release a lock on Object obj for Transaction tx.
* @param tx the transaction releasing the lock
* @param obj the Object to be unlocked
* @return true if successful, else false
*
*/
public boolean
Hi,
we are using a default cache implementation defined in OJB.properties
and for some classes a different cache implementation, which we
declare in the class-descriptor. According to the repository.dtd we
can include an object-cache element only for concrete classes with at
least one
Hi,
When during a query against a DB2 database a statement or lock timeout
occurs, an SQLException is thrown, as expected. However the exception
is not thrown from Statement.executeQuery but rather from
ResultSet.next(), when the cursor moves to the record that could not
be retrieved any more.
Hi,
we are trying to upgrade our OJB version from RC5 to 1.0.1.
We are using the ODMG API.
In RC5, when removing items from a collection of a write-locked
object, the transaction commit deleted the removed items from the
database. This does not seem happen any more in v1.0.1. All that is
sent to
On Fri, 20 Aug 2004 16:30:27 -0400, Jason Mihalick
[EMAIL PROTECTED] wrote:
Gerhard,
Which object cache are you using? ObjectCacheDefaultImpl or
ObjectCachePerBrokerImpl? As the doc states, the ObjectCacheDefaultImpl
does have some drawbacks pertaining to dirty reads. We use OJB in
servlet
On Sat, 21 Aug 2004 15:53:30 +0200, Armin Waibel [EMAIL PROTECTED]
wrote:
Hi Armin,
Hi again,
I think this one happend during lazy loading of a list proxy. So would
this mean that
- we should not use reference and collection proxies when working with
the ODMG API (this would be a
Hi Armin,
some comments below, more in my response to your second post.
On Fri, 20 Aug 2004 19:47:25 +0200, Armin Waibel [EMAIL PROTECTED]
wrote:
Hi Gerhard,
this sounds alarming :-(
Gerhard Grosse wrote:
So my main questions are:
- Have substantial things changed between RC5 and 1.0
hints and help are greatly appreciated.
Gerhard Grosse
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
: Gerhard Grosse [mailto:[EMAIL PROTECTED]
Sent: Tuesday, December 09, 2003 3:58 PM
To: [EMAIL PROTECTED]
Subject: JDK 1.4 dependency in SqlTypeHelper.java
Hi all,
I just checked out CVS Head and I'm getting compile errors in
org.apache.ojb.broker.util.SqlTypeHelper.java: The methods
for now.
Thanks again,
Gerhard
On Tue, 09 Dec 2003 20:24:41 +0100, Armin Waibel
[EMAIL PROTECTED] wrote:
Hi Gerhard,
Gerhard Grosse wrote:
Hi all,
I just checked out CVS Head and I'm getting compile errors in
org.apache.ojb.broker.util.SqlTypeHelper.java: The methods
CallableStatement.getType
Hi all,
I just checked out CVS Head and I'm getting compile errors in
org.apache.ojb.broker.util.SqlTypeHelper.java: The methods
CallableStatement.getType(int) are present only since JDK 1.4.
I hope this does not mean that OJB is dropping JDK 1.3 support? Are
there plans/ideas to fix this?
- checks are postponed till
the end of transaction.
- Original Message -
From: Gerhard Grosse [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 22, 2003 9:52 AM
Subject: Re: Strategies to avoid RI constraint violations?
I just discovered that ((TransactionExt) tx).flush
Hi Edson,
I think with EmptyCache OJB cannot detect loops in your object
relations, because it does not maintain object identity. I'm afraid
you need to use some non-empty cache implementation or remove the
back-reference that causes the loop.
hth
Gerhard
On Wed, 29 Oct 2003 19:36:59 -0300,
2003 14:14:58 +0100, Gunnar Hilling
[EMAIL PROTECTED] wrote:
On Thu, 30 Oct 2003 08:58:33 +0100, Gerhard Grosse wrote:
Hello Gerhard,
Thanks for your Proposal. I think the problem is somewhere where you
pointed out.
But it't not exactly what you proposed. I think there is a problem whith
auto
Hi Vincenz,
I have set up my object model so that A.addB(B) automatically calls
B.setA(A). This takes care of tracking addings without changing the
collection class.
For removals, there are two options:
1) Stay with the default collection class (RemovalAwareCollection) and
just call
Hi Danilo,
On Wed, 29 Oct 2003 08:56:01 +0100, Danilo Tommasina
[EMAIL PROTECTED] wrote:
Hello Jair,
Automatically clearing the cache for the object touched by the aborted
transaction may cause loss of data, let's say it so, if storing data to
db fails due to a temporary db failure, then you
Hi Emmanuel,
AFAIK it shouldn't matter when you acquire a lock for new objects.
(Although it might affect the order of SQL statements during commit).
Btw, for new objects you can also use Database.makePersistent(), which
imo makes the intention of inserting a new object clearer.
For objects to
Hi Brian,
On Thu, 23 Oct 2003 20:51:21 -0400, [EMAIL PROTECTED]
wrote:
(snipped)
1) A Cache implementation that only provides java object identity ( = )
within a single transaction boundary. I am not sure how this would work, may
have to hack around some. Cache might clone the object and
Company and indicate if they are a User and/or a Driver.
Thanks for your help.
Later.
Mitch
-Original Message-
From: Gerhard Grosse [mailto:[EMAIL PROTECTED]
Sent: Wednesday, October 22, 2003 3:17 AM
To: [EMAIL PROTECTED]
Subject: Re: Inheritance mapping, storing new object associated with
pre
Hi Matthias,
I am seeing an AbstractMethodError (partial stack trace below) in my
logs whenever OJB first initializes a JDBC connection from the DB2
JDBC driver. Obviously OJB is checking for batch support even if
batch-mode=false is set in repository.xml. However, in my case the
error is
and Driver.
Cheers,
Gerhard
Later.
Mitch
-Original Message-
From: Gerhard Grosse [mailto:[EMAIL PROTECTED]
Sent: Tuesday, October 21, 2003 9:50 AM
To: [EMAIL PROTECTED]
Subject: Re: Inheritance mapping, storing new object associated with
pre-e xistingsuper object
On Tue, 21 Oct 2003 08:55
Hi Armin,
Your suggestion sounds good to me...
Cheers,
Gerhard
On Wed, 22 Oct 2003 12:12:53 +0200, Armin Waibel
[EMAIL PROTECTED] wrote:
Hi,
On Wed, 22 Oct 2003 09:29:09 +0200, Gerhard Grosse
[EMAIL PROTECTED] wrote:
Hi Matthias,
I am seeing an AbstractMethodError (partial stack trace
As nobody else seems to respond some comments from a user's experience
with OJB's ODMG implementation:
On Fri, 17 Oct 2003 10:26:52 -0400, Weaver, Scott
[EMAIL PROTECTED] wrote:
1. Should collections for 1:n relationships be updated automatically?
Example: I have a class foo which has a
I just discovered that ((TransactionExt) tx).flush() might solve a lot
of my problems...
On Tue, 21 Oct 2003 16:57:30 +0200, Gerhard Grosse
[EMAIL PROTECTED] wrote:
Hi,
I just wonder what strategies others employ to avoid RI constraint
violations. It seems to me that these inevitably occur
that it was a good idea to do so.
Phil
Gerhard Grosse wrote:
I just discovered that ((TransactionExt) tx).flush() might solve a lot
of my problems...
On Tue, 21 Oct 2003 16:57:30 +0200, Gerhard Grosse
[EMAIL PROTECTED] wrote:
Hi,
I just wonder what strategies others employ to avoid RI constraint
.
Cheers,
Gerhard
Thank you for your input.
Matt
Gerhard Grosse wrote:
Hi Matt,
Excuse me to jump in here, but I believe what you have in mind is not
possible in Java and even less with OJB. If your B1 and B2 instance
should 'contain' the same A instance as base class, they are identical
objects
know.
Later.
Mitch
-Original Message-
From: Gerhard Grosse [mailto:[EMAIL PROTECTED]
Sent: Tuesday, October 21, 2003 6:55 AM
To: [EMAIL PROTECTED]
Subject: Re: Inheritance mapping, storing new object associated with
pre-existingsuper object
Hi Matt,
Excuse me to jump in here, but I
Hi,
I just wonder what strategies others employ to avoid RI constraint
violations. It seems to me that these inevitably occur in larger
transactions on complex object models. Any hints other than turning RI
checking off altogether? (I'm short before doing so...)
Thanks,
Gerhard
Does user.addRole(role) call role.addUser(this)? If not maybe that's
something to try to solve your problem?
Gerhard
Hiu Yen Onn [EMAIL PROTECTED]
17.10.2003 02:00
Bitte antworten an OJB Users List
An: [EMAIL PROTECTED], [EMAIL PROTECTED]
Kopie:
Thema: Re:
Hi,
Since I am having problems with referential integrity violations when
deleting objects I tried to understand the reorder() method in
org.apache.ojb.odmg.ObjectEnvelopeTable.
From what I understand, the way this reordering is implemented leads to a
strong bias of the final order towards
Yes, that's what I meant. If you don't do it, you try to persist objects
that are in an inconsistent state, which could easily explain the DELETEs.
Now why this causes an infinite recursion, I have no idea. Sorry.
Gerhard
PS: You are not locking the Role objects, so I assume you left the
Hi Charles,
Thanks for your idea and code snippets. I'll try if this helps in my
cases. I have a feeling it won't, though. In the A-B example reorder()
doesn't change the initial order, so calling it twice won't either. But
now I have a whole weekend ahead to spoil with thinking about this
There may be a better chance that somebody can help you if you post some
snippets of the code you use to persist your objects.
Gerhard
Hiu Yen Onn [EMAIL PROTECTED]
16.10.2003 10:07
Bitte antworten an OJB Users List
An: [EMAIL PROTECTED]
Kopie:
Thema: m:n
Hi Daniel,
I don't know why this would cause a NoClassDefFoundError, but your class
descriptor for Grade definitely needs a field descriptor named jobId for
your reference and collection mappings to work.
Gerhard
Daniel Perry [EMAIL PROTECTED]
16.10.2003 14:06
Bitte antworten an OJB Users
Hi Armin,
Thanks for the info!
Since I'm thinking of using my own ObjectCache implementation anyway (to
use hard rather than soft references), I wonder if it would make sense to
replace the collection attributes in the cache's cache() method. Pseudo
code:
for each
Hi,
If I may add a note:
It's certainly good to avoid primitives for FK fields, but the unnecessary
SELECT statements with WHERE FK=null are
currently generated also when using non-primitives such as Integer. It
would be nice if this could be avoided.
Regards,
Gerhard
[EMAIL PROTECTED]
Hi,
This is somewhat off-topic, but is anyone here successfully using the JDBC
type BIGDECIMAL under WebSphere?
I am getting an AbstractMethodError from the ResultSet.getBigDecimal()
invokation. It's not an OJB issue, but without OJB I was able to work
around this problem by using
Hi Jakob,
I just checked and you are right.
Nevertheless I find a lot of statements like SELECT ... FROM ... WHERE
id='' in my P6Spy logs, where id is a not nullable primary key. I was
assuming these were generated from resolving references with FK=null, but
it turns out this is wrong. Looks
Hi Troy,
You can set the environment variable ANT_OPTS to pass options to the JVM
running Ant.
HTH
Gerhard
Taillefer, Troy (EXP) [EMAIL PROTECTED]
15.10.2003 16:32
Bitte antworten an OJB Users List
An: 'OJB Users List' (E-mail) [EMAIL PROTECTED]
Kopie:
Hi Jakob,
Yes, your patch did the trick! No more selects with id = null. Thanks!
Gerhard
Jakob Braeuchi [EMAIL PROTECTED]
15.10.2003 17:56
An: [EMAIL PROTECTED]
Kopie:
Thema: [Fwd: Re: Antwort: RE: How to map optional 1:1 relationship]
- Nachricht
class-ref=brj.ojb.Person
foreignkey field-ref=idPerson/
/reference-descriptor
hth
jakob
Vincenz Braun wrote:
Hello,
I have the same problem described earlier in this list by
Gerhard Grosse. What is the status of this issue? Is someone
by
Gerhard Grosse. What is the status of this issue? Is someone
working on this or has at least committed a bug report? I queried
scarab and did not find a matching issue, yet.
Any help greatly appreciated.
Vincenz
original post from Gerhard Grosse:
tried to implement a bi-directional 1:n association
Hi,
I ran into a problem with implementing the collection attribute for a 1:n
mapping:
Since I didn't want to polute my persistent objects with any ODMG or
even OJB specific imports, I just initialized my collection attributes (of
type java.util.List) with ArrayLists when needed. This worked
Hi all,
I wonder, is there a way to modify the order of DELETE statements OJB
sends out in response to several Database.deletePersistent() calls.
Somehow the order seems just the opposite of what is needed:
If there is a 1:1 relation with the FK in the parent object, OJB first
deletes the
I posted this question a while ago and got no response so far:
I am using the ODMG API (RC4 and CVS HEAD) with setting
ImplicitLocking=false in OJB.properties.
When I obtain a READ lock on an object that has proxy references, all
proxies are getting materialized. Due to above setting, there
I encountered a problem with class org.apache.ojb.odmg.TransactionImpl: If
a transaction is opened and committed without ever any object being
locked, a NullPointerException is thrown at line 323 (method
doCommitOnObjects):
if(!broker.isInTransaction()) broker.beginTransaction();
I
The problem is that your field descriptor and reference descriptor have
the same name attributes. The name of your field-descriptor must
correspond to an Integer property of your class. The name of the reference
descriptor must correspond to an Object (ThemeSurveurImpl) property of
your class.
A question for the experts:
I am using the ODMG API (RC4) with setting ImplicitLocking=false in
OJB.properties.
When I obtain a READ lock on an object that has proxy references, all
proxies are getting materialized. Due to above setting, there are no READ
locks put on the referenced objects,
In repository.xml you can set the field as read-only. Works for me.
HTH
Gerhard
nntp://news.gmane.org/gmane.group.name; [EMAIL PROTECTED]
Gesendet von: news [EMAIL PROTECTED]
05.09.2003 17:41
Bitte antworten an OJB Users List
An: [EMAIL PROTECTED]
Kopie: [EMAIL
Mike,
If you could send your ZIP to me as well, I would greatly appreciate it:
[EMAIL PROTECTED].
Many thanks,
Gerhard
Michael Becke [EMAIL PROTECTED]
22.08.2003 21:11
Bitte antworten an OJB Users List
An: OJB Users List [EMAIL PROTECTED]
Kopie:
Thema: Re:
transaction?
Thanks for any thoughts on this!
Gerhard Grosse
that does that for me, but I wonder whether this problem
isn't common enough to justify a more general solution?
Cheers,
Gerhard Grosse
[EMAIL PROTECTED]
18.08.2003 11:55
Bitte antworten an OJB Users List
An: [EMAIL PROTECTED]
Kopie:
Thema: RE: How to avoid
Hi Jose,
Using a link table and a programatically controlled M:N relation seems a
reasonable approach. I'll try this out. Thanks for the tip.
Gerhard Grosse
[EMAIL PROTECTED]
18.08.2003 14:39
Bitte antworten an OJB Users List
An: [EMAIL PROTECTED]
Kopie: [EMAIL
against HSQLDB).
Regards,
Gerhard Grosse
Martin Grüneberg [EMAIL PROTECTED]
12.08.2003 10:11
Bitte antworten an OJB Users List
An: [EMAIL PROTECTED]
Kopie:
Thema: Problems rc4 tests on db2 7.2.5
Hello,
i try to test ojb for my next project. I followed
Hi all,
I tried to implement a bi-directional 1:n association between classes User
and UserRole with an anonymous key in UserRole:
class-descriptor
class=de.lexcom.noralinkojb.model.User
table=OJB.USERS
field-descriptor
name=id
column=ID
.
(The
broker tests run fine when using HSQLDB).
Gerhard Grosse
System Info:
JDK 1.3.1_08
OJB 1.0RC4 (with otm classes removed to compile with 1.3)
Client: Windows XP
Server: DB2 7.2 Linux
SQL Log of OneToManyTest.testDeleteWithRemovalAwareCollection() when
running all tests
67 matches
Mail list logo