[Zope] ZCatalog and SiteRoot Not Getting Along
Edward Pollard
pollej@uleth.ca
Thu, 13 Feb 2003 15:33:58 -0700
Previously I came to the list with a problem of entries in the ZCatalog
going away when I hit the "Update" button in the Catalog "Advanced" tab
(Subj: [Zope] ZCatalog - Full Update Deletes Valid Entries).
Well, I figured that the problem is caused by the presence of a
SiteRoot. (I develop on a server without a siteroot, thus the problem
did not arise in development.) I'm resubmitting this problem so that
perhaps someone with greater wisdom than I can set me on the right path
--------------
First, "The Preamble". Stuff you need to know to understand the context
of my problem.
Our main website is http://www.blah.ca
We use Apache ProxyPass to redirect certain directories to directories
on our Zope server.
ie, http://www.blah.ca/notice is not redirected, http://www.blah.ca/it
goes to http://zope.blah.ca/www/it
Indeed, all zope pages served this way are in the /www/ directory. We
also proxy pass /manage et al so we can manage the material behind the
site root.
We've developed a system for indexing websites - zClasses that extend
Page Templates and File that are catalog aware. Sitting at the root of
the /www/ heirarchy is the zCatalog that runs this show.
I have webtools to create and manipulate the zClassses mentioned above.
I've also created the correct PropertySheet methods to change the
cataloged information in the ZMI.
-------
Now, "The Problem".
I create some of my zClass objects at http://www.blah.ca/it/. This is,
really, at http://zope.uleth.ca/www/it/. They show in the zCatalog with
Object Identifiers in the style '/it/filenames'. Fantastic. I can
manipulate them every which way from sunday. No trouble. They display in
my zCatalog search tool properly.
I go to http://www.blah.ca/myzCatalog/manage. I look on the Catalog tab
and see all my items as they should be - all with identifiers starting
with '/it/'. I go to advanced. Hit Update. Go back to Catalog. All gone.
I go to Find Objects, and select my zClasses (all items of these classes
should be in the catalog anyway). They all come back, but now their
identifiers are /www/it/filenames.
If I try now to manipulate these files - change titles, for instance -
when they reindex they do not recongize the entry in the zCatalog with
/www/ in the identifier as their own, and create a new entry. The item
is now listed twice.
- once with an identifier beginning with /www/
- once with an identifier beginning with /it/
The /it/ entry will now behave as I would expect it to. The /www/ entry
never gets changed - not when I update with my tools, not when I change
properties in the ZMI. It only becomes accurate when I update the index
again, and all the /it/ entries are deleted.
So, it seems clear that the zCatalog and the SiteRoot are not getting
along.
Anyone with any experience to set me right, or can I not use the
ProxyPass system when a zCatalog is present?
Thanks,
Edward