Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [CDO] Correctly configuring timeouts
[CDO] Correctly configuring timeouts [message #1817951] Tue, 03 December 2019 14:22 Go to next message
Robert Schulk is currently offline Robert SchulkFriend
Messages: 62
Registered: July 2015
Member
Sometimes, our commits may get quite large and take a couple of seconds to complete.

This leads to occasional exceptions in the net4j communication (see attached example stack).

So what helps in our case is to configure this:
CDONet4jSession#options()#getNet4jProtocol().setTimeout(someHighValue)


But looking around a little, I also found other timeout configurations:

1.) CDONet4jSession#options()#setCommitTimeout(long): this seems to me like it is only a configuration in case a progressmonitor is used for the commit?

2.) CDOTransaction#options()#setCommitInfoTimeout(long) what is this good for? I guess it is there to make sure that the changes are correctly processed by the server? In rare cases, we get a TimeoutRuntimeException on a commit (even though the change seems to always be processed correctly).


Does anyone know more details about the timeouts and how they should be configured?
Thanks!
Re: [CDO] Correctly configuring timeouts [message #1817972 is a reply to message #1817951] Tue, 03 December 2019 17:27 Go to previous messageGo to next message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6469
Registered: July 2009
Senior Member
If I'm not totally misled (the remote progress monitoring is a bit complex) you can use CDONet4jSession#options()#setCommitTimeout(long) even if you don't pass your own progress monitor into the commit() method. Internally there are always progress signals exchanged over the wire and they reset the timeout. In the worst case you could pass a NullProgressMonitor to the commit() method, but I don't think that's required.

CDOTransaction#options()#setCommitInfoTimeout(long) is used to specify how long the transaction must wait after a commit to receive the server's OK notification. It can help when you experience "Did not receive an update" exceptions. A ore liekly cause for these exceptions is a bug in the thread pool which is fixed in recent I-builds and the upcoming 2019-12 release.


Re: [CDO] Correctly configuring timeouts [message #1818009 is a reply to message #1817972] Wed, 04 December 2019 08:09 Go to previous message
Robert Schulk is currently offline Robert SchulkFriend
Messages: 62
Registered: July 2015
Member
Thanks for the answer. Also, that sounds promising with the new release. We will update as soon as possible.
Previous Topic:Export Ecore Metamodel to OWL
Next Topic:[CDO] Schema Locked Exception after update to CDO 4.4
Goto Forum:
  


Current Time: Wed Jan 29 12:50:39 GMT 2020

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

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

Back to the top