WE HAVE SUNSET THIS LISTSERV - Join us at collectionspace@lyrasislists.org
View all threadsJoe, (Aron, Glen, all) -
We've just succeeded in adding an extension schema for a new tenant. We ran into several pitfalls along the way. Maybe you just met one, too. The major stumbling point we hit involved actually deploying our changes to the server. Two build.xml files - one in the app layer, another in the services layer, needed to be modified by hand.
• In the app layer, look at war-entry/build.xml. In the <target name="deploy_cspace_config"> element, add a line similar to this:
<copy file="${app_trunk}/tomcat-main/src/main/resources/ucjeps-tenant.xml" tofile="${config_destination}/cspace-config-ucjeps.xml" />.
It basically copies the {tenantname}-tenant.xml file to the server and renames it cspace-config-{tenantname}.xml. (Aron has created CSPACE-4249 to address this.)
• In the services layer, you'll need to add a line in each of three places to services/{recordtype, eg. collectionobject}/nuxeo/3rdparty/build.xml, so that the Ant build process knows about your new tenant. Add the following to the <target name="deploy">, <target name="undeploy"> and <target name="dist"> elements. (I also added the line to the <target name="dist-installer"> tag, though I'm not sure that is needed.) Don't forget to change our tenant name (ucjeps) to yours.
<ant antfile="${nuxeo-platform-collectionobject-ucjeps}/build.xml" target="deploy" inheritall="false"/>It sounds as if you're on the right track, generally. I can't tell from your description, though, exactly what you've done. I'm happy to go over this with you, via this list or direct email (rjaffe@berkeley.edu), irc channel (rjaffeist), phone (510 642-0590), whatever is best. I'll be in a meeting from 11a-noon PDT today, then free from noon-1pm and, again, from 2-3pm.
I've planned to write up documentation on how to add a tenant today and/or tomorrow. Talking you through the task would be helpful.
Hope this helps,
Rick
On Jul 26, 2011, at 8:28 AM, Aron Roberts wrote:
Hi Rick and Glen,
Do you think you have enough info to respond to Joe's query on the
Talk list? Pointing him (and all of us) to a sample of a services
extension schema, with perhaps a few bullet points about how this is
done, would be very welcome.
That'd help me a lot as well, since I haven't done a services schema
extension following Richard's latest changes to make doctypes
tenant-specific.
Thanks!
Aron
---------- Forwarded message ----------
From: Joe Slag joe@slagwerks.com
Date: Mon, Jul 25, 2011 at 3:01 PM
Subject: Re: [Talk] 1.8 schema modification changes
To: CollectionSpace Talk List talk@lists.collectionspace.org
Now that 1.8 is out, I've been taking a look at the
schema-modification related changes.
I'm not entirely clear on whether the example of
services/collectionobject/3rdparty/nuxeo-platform-collectionobject-hearst
indicates the new preferred place to put our schema files (before, we
were extending eg. the collectionobject schema in the
nuxeo-platform-cs-collectionobject tree). Since it appears that a
directory tree such as the nuxeo-platform-collectionobject-hearst
example is the place to put our local core-types-config.xml files, I'm
guessing it's also the proper home for our local .xsd file.
The lifesci example of a local tenant bindings delta seemed pretty
straightforward, so I adapted that to our local changes.
Unfortunately, after running maven & ant and starting up nuxeo and
collectionspace, I'm not seeing a collectionobjects_wac table in
postgres as I did in MySQL:
nuxeo=> \dt wac
No matching relations found.
...and while creating an object via a sample XML payload with our
custom schema returned success, the collectionobjects_wac part is
ignored.
Did I misinterpret any of the changes? Any tips on tracking down what
isn't working?
thanks,
Joe
Talk mailing list
Talk@lists.collectionspace.org
http://lists.collectionspace.org/mailman/listinfo/talk_lists.collectionspace.org
Hi Rick,
I haven't got as far as the app layer yet, but the build.xml changes
got me past the current stumbling block, as nuxeo is now creating the
collectionobjects_wac and related tables.. Will add a note to
http://wiki.collectionspace.org/display/collectionspace/Adding+a+Custom+Field+to+a+CollectionObject.
thanks,
Joe
On Tue, Jul 26, 2011 at 12:53 PM, Rick Jaffe rjaffe@berkeley.edu wrote:
Joe, (Aron, Glen, all) -
We've just succeeded in adding an extension schema for a new tenant. We ran into several pitfalls along the way. Maybe you just met one, too. The major stumbling point we hit involved actually deploying our changes to the server. Two build.xml files - one in the app layer, another in the services layer, needed to be modified by hand.
• In the app layer, look at war-entry/build.xml. In the <target name="deploy_cspace_config"> element, add a line similar to this:
<copy file="${app_trunk}/tomcat-main/src/main/resources/ucjeps-tenant.xml" tofile="${config_destination}/cspace-config-ucjeps.xml" />.
It basically copies the {tenantname}-tenant.xml file to the server and renames it cspace-config-{tenantname}.xml. (Aron has created CSPACE-4249 to address this.)
• In the services layer, you'll need to add a line in each of three places to services/{recordtype, eg. collectionobject}/nuxeo/3rdparty/build.xml, so that the Ant build process knows about your new tenant. Add the following to the <target name="deploy">, <target name="undeploy"> and <target name="dist"> elements. (I also added the line to the <target name="dist-installer"> tag, though I'm not sure that is needed.) Don't forget to change our tenant name (ucjeps) to yours.
<ant antfile="${nuxeo-platform-collectionobject-ucjeps}/build.xml" target="deploy" inheritall="false"/>
It sounds as if you're on the right track, generally. I can't tell from your description, though, exactly what you've done. I'm happy to go over this with you, via this list or direct email (rjaffe@berkeley.edu), irc channel (rjaffeist), phone (510 642-0590), whatever is best. I'll be in a meeting from 11a-noon PDT today, then free from noon-1pm and, again, from 2-3pm.
I've planned to write up documentation on how to add a tenant today and/or tomorrow. Talking you through the task would be helpful.
Hope this helps,
Rick