These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: Lazy Load Timeout
PostPosted: Tue Sep 12, 2006 8:32 am 
Newbie

Joined: Fri May 13, 2005 11:14 am
Posts: 18
Is there a place to set the timeout for Lazy-loading?

I see where I can SetTimeout on a Criteria, but haven't seen where I can set the Timeout for Lazy Loading. I'm on Current Code as of last week.

This is the message I'm getting:

Failed to lazily initialize a collection. Inner Exception Message: could not initialize a collection: [Ais.Sentry.Domain.Accounting.Account.FinancialTransactions#1]. Inner Exception Message: Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding.

Thanks,
Jamie


Top
 Profile  
 
 Post subject: 30 Second Timeout
PostPosted: Tue Sep 12, 2006 12:18 pm 
Newbie

Joined: Fri May 13, 2005 11:14 am
Posts: 18
It seems like it times out after 30 seconds - which is the default for a Command.

Is there anyway I can set this Timeout Parameter for Lazy Loading?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 12, 2006 1:36 pm 
Newbie

Joined: Fri May 13, 2005 11:14 am
Posts: 18
For lazy loading, it seems like the command is generated in Loader.cs, in the following method -

protected virtual IDbCommand PrepareQueryCommand(
SqlString sqlString,
QueryParameters parameters,
bool scroll,
ISessionImplementor session )

the command created from

IDbCommand command = session.Batcher.PrepareQueryCommand( sqlString, parameters.CommandType );

doesn't have the correct CommandTimeout set. It is only set if there is a selection.Timeout and I don't see how that is passed via Lazy-Loading.

Is there a way we can set this?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.