db-ojb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oleg Nitz" ...@ukr.net>
Subject Re[2]: Proxy prefetching limit in Collection and Reference descriptors.
Date Thu, 15 Jan 2004 13:20:22 GMT
Hi Tadeus,

It's my stuff, I shall look at this. 

Oleg

-----Original Message-----
From: Tadeus Garsva <tadeusg@takas.lt>
To: OJB Users List <ojb-user@db.apache.org>
Date: Thu, 15 Jan 2004 14:53:46 +0200
Subject: Re: Proxy prefetching limit in Collection and Reference descriptors.

> hi Jakob,
> Thanks for answer. But I think there is other logic.
> In ojb.properties I have SqlInLimit set to 200, but when prefetching of 
> proxy collection is performed I found that field _limit in class 
> PBCollectionProxyListener (inner of class QueryReferenceBroker) field 
> m_ProxyPrefetchingLimit in CollectionDescriptor is =50 and method  
> CollectionDescriptor.getProxyPrefetchingLimit() returns, of course, 50 - 
> the default value for proxy-prefetching-limit. I tried to change 
> attribute "proxy-prefetching-limit" in descriptor-repository and in 
> collection-descriptor - no results.
> More. If I have in owners collection more objects than 
> proxy-prefetching-limit, I get a ClassCastException in class in 
> PBCollectionProxyListener  in method :
> 
> protected void addThisListenerTo(Object listenedObject)
>        {
>            _listenedCollection = (CollectionProxy) listenedObject;
>            _listenedCollection.addListener(this);
>        }
> because reference to this method is
>        addThisListenerTo(owners.get(0));
> This reference is in abstract class PBPrefetchingListener. 
> PBCollectionProxyListener extends PBPrefetchingListener.
> So I would like to change proxy-prefetching-limit or  to find some 
> solution not to get ClassCastException.
> Of course, I can change constant 50 in source code of  
> ObjectReferenceDescriptor, but I think this is not the best solution.
> 
> Thanks for any answer.
> Best regards
> Tadeus Garsva
> 
> P.S. I am sorry for my english.
> 
> 
> 
> Jakob Braeuchi wrote:
> 
> > hi tadeus,
> >
> > this limit is defined in ojb.properties. the parameter is called 
> > SqlInLimit.
> >
> > hth
> > jakob
> >
> > Tadeus Garsva wrote:
> >
> >> Hi,
> >>
> >> I don't find any reference to method setProxyPrefetchungLimit in 
> >> ObjectReferenceDescriptor class. Does it mean that 
> >> proxy-prefetching-attribute in reference and collection descriptor 
> >> can be changed only by calling this method and not by attribute in 
> >> repository.xml?
> >>
> >> Thanks in advance for answer.
> >> Best regards
> >> Tadeus Garsva
> >>
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> >> For additional commands, e-mail: ojb-user-help@db.apache.org
> >>
> >>
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> > For additional commands, e-mail: ojb-user-help@db.apache.org
> >
> >
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 
> 
> 



Mime
View raw message