portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Sean Taylor" <da...@bluesunrise.com>
Subject dbpsml
Date Mon, 12 Nov 2001 04:16:41 GMT
Hi Atul,

The dbpsml stuff is all checked in, I also have torque working from within
Jetspeed. Its under the build/torque directory.
The bad news is that I couldn't get the DatabasePsmlManager to work (tried
only with Hypersonic)

I don't think that the DatabaseInitializer is a good idea.
It has a lot of redundant code and dependencies on the CastorPsmlManager.
I wrote a simple PsmlImporter (its in the cvs) instead:

            PsmlManagerService fileService =
            QueryLocator locator = new QueryLocator(QueryLocator.QUERY_ALL);
            Iterator profiles = fileService.query(locator);

            while (profiles.hasNext() )
                Profile profile = (Profile)profiles.next();
                // dumpProfile(profile);
                PsmlManager.store(profile);         <============= new
method on PsmlManagerService interface

I originally tested with the DatabaseInitializer - and I started getting
errors from the DatabaseInitializer.
Then saw that I needed to add some entries in the JRP .
Then it got a little further - 'null pointer' :( Thats when i looked at the
code, saw all the redundancies, and decided to write the code above.

I added another 'service' entry to the JRP - which is the Importer service
which is really the Castor service.


Problem is that it doesnt work - not quite sure why - damn Turbine with its
early and late inits() has me fn confused!!
Looks to me like the DatabasePsmlManager only gets its early init called,
but the CastorPsmlManager only gets its late init.
It just hangs -- one of those service dependency problems. I think the
BaseProfile uses the PsmlManager before everythings is init'd.
So I tried to put the importer call into late init, but then it was never

You can test it from the cvs and then modify the JRP as shown above

-- David

To unsubscribe, e-mail:   <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>

View raw message