Re: OSCPool/EO stack management/relaunch (was: Should ERXEC get sharedEC automagically?)

2018-08-26 Thread Chuck Hill
Finally, an easy question!

Compatible just means that 
modelA.connectionDictionary().equals(modelB.connectionDictionary())

Chuck

From: "ocs@ocs" 
Date: Thursday, August 23, 2018 at 7:03 PM
To: Chuck Hill 
Cc: "webobjects-dev@lists.apple.com" 
Subject: Re: OSCPool/EO stack management/relaunch (was: Should ERXEC get 
sharedEC automagically?)

Chuck,

I guess I have solved the mystery :) Looks like all what's needed is

- to set up freely the OSCPool with any number of coordinators
- at the init time, to use "isolation=serializable/locking=pessimistic" in my 
models
- and switch off the SEC (by setting it to null in my ERXEC)
- when all the init work is done, I simply call

EODatabaseContext.forceConnectionWithModel(model,[URL:"jdbc:FrontBase://$dbhost/$dbname/user=$user/isolation=read_committed/locking=optimistic"],ec)

and that's that, it seems it works all right, for subsequently all 
(session-based) ECs seem to work properly with the (OSC-based) SEC, and the 
connexion indeed is read-committed/optimistic, as need be.

There's just one small thing I am not sure of: forceConnectionWithModel 
re-connects “all compatible models in the model group” too. Alas the 
documentation does not say what a “compatible” model is — what does that mean? 
How does the EOF determine which models are compatible?

Thanks and all the best,
OC


On 22 Aug 2018, at 2:06 PM, ocs@ocs mailto:o...@ocs.cz>> wrote:

Chuck,

hmmm... coudn't I somehow switch off temporarily the OSCPool, so that the 
initialisation code happens precisely as if there was no pool at all, and only 
then, when done, the pool starts behaving as normally? Actually I could benefit 
— if it is possible — from that, not only due to the SEC, but for other reasons 
as well (it would help if I could run the initialisation code against the DB in 
the “isolation=serializable/locking=pessimistic” mode, switching to 
“isolation=read_committed/locking=optimistic” for the normal processing).

The init code just reads some objects from the db (including 
INFORMATION_SCHEMA, which is the reason for the DB mode), checks them, 
potentially updates them, and that's that — if at this moment the application 
quits and immediately runs again without the init code, it would work just as 
well. But for the objects in the shared EC, there's no EO which the init code 
would create/fetch and a later session-based code would use anyhow.

I might switch off the SEC for the initialisation completely: I would run the 
init code using an EC with its SEC explicitly set to null, then somehow trash 
the init EO stack completely and start afresh with a new one (or ones with 
OSCPool) and normal session-based processing.

Can this, i.e.,

- to begin without OSCPool and connecting to DB in the 
“isolation=serializable/locking=pessimistic” mode;
- do some stuff (without SEC), save changes;
- completely trash the EO stack;
- create a new one with OSCPool connecting to DB in the 
“isolation=read_committed/locking=optimistic” mode with SEC, and run happily 
ever after

be done in some cleaner way than, well, restarting the application — which with 
some trickery exploiting Auto Recover in JavaMonitor might even prove possible, 
but would be super-ugly and I would rather do without?

Thanks,
OC


On 22 Aug 2018, at 5:11 AM, Chuck Hill 
mailto:ch...@gevityinc.com>> wrote:

That is a good question.  I’ve not used the combination.   There must be some 
code that uses the default instead of getting the SEC from the 
EOEditingContext.  There is a lot of code in Wonder (and some in WO) that 
assumes the defaultWhatever is the only one that will ever exist.  You would 
have to step into the code to see where this is happening, or enable the 
logging of stack traces of fetches.  It should be a simple fix once you find 
the spot.

Chuck

From: "ocs@ocs" mailto:o...@ocs.cz>>
Date: Tuesday, August 21, 2018 at 1:02 PM
To: Chuck Hill mailto:ch...@gevityinc.com>>
Cc: "webobjects-dev@lists.apple.com" 
mailto:webobjects-dev@lists.apple.com>>
Subject: Re: Should ERXEC get sharedEC automagically?

Indeed! If I switch off the OSCPool, it starts to work properly.

Thanks just again!

Nevertheless, I still must be missing something of grave importance, for with 
OCSPool (I use ), I would presume the SEC for the pool being currently used by 
the ERXEC would load the shared objects?

It does not: the global one does automatically load the shared objects, but the 
SEC-based one of ERXEC remains empty.

Note: the code in question does not run in a session context; it is performed 
at launch, before the first session is created. Might that be important perhaps?

All the best,
OC




On 21 Aug 2018, at 9:42 PM, Chuck Hill 
mailto:ch...@gevityinc.com>> wrote:

Are you using the ERXObjectStoreCoordinatorPool?  It keeps one SEC per pool, 
not one shared globally.  EOSharedEditingContext.defaultSharedEditingContext() 
is the global one.

Chuck

From: "ocs@ocs" mailto:o...@ocs.cz>>
Date: 

WOLips

2018-08-26 Thread Gino Pacitti
No worries - ignore last email - I just downloaded the zip and did it locally…


 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


WOlips Installation problem

2018-08-26 Thread Gino Pacitti
Hi
I am trying to install WOLips in Eclipse Neon and all of the URLs supplied on 
the wiki.community page for WOLips with Update manager don’t seem to work:

https://jenkins.wocommunity.org/job/WOLips46/lastSuccessfulBuild/artifact/temp/dist/


Unable to read repository at 
https://jenkins.wocommunity.org/job/WOLips46/lastSuccessfulBuild/artifact/temp/dist/content.xml.
Unable to read repository at 
https://jenkins.wocommunity.org/job/WOLips46/lastSuccessfulBuild/artifact/temp/dist/content.xml.
sun.security.validator.ValidatorException: PKIX path building failed: 
sun.security.provider.certpath.SunCertPathBuilderException: unable to find 
valid certification path to requested target

Any help with any one else having experienced this?

Best

Gino

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com