From: Adam R. <ad...@ex...> - 2013-02-28 17:19:56
|
I dont like the master triggers approach - user choice is important On 28 February 2013 16:17, Dmitriy Shabanov <sha...@gm...> wrote: > Adam, > > You can register RestXQ trigger as master trigger. Positives - it's will not > depend on collection.xconf, but negative that all files will go to that > trigger. Fast filter at RestXQ trigger can compensate possible negative > affects. > > > On Thu, Feb 28, 2013 at 6:31 PM, Adam Retter <ad...@ex...> wrote: >> >> >> I will take a look and see if I cant improve the logging - I should at >> least add a line that declares when a RestXqTrigger is registered... >> In general we should probably log Trigger registrations in eXist. >> >> On 27 February 2013 18:40, Joe Wicentowski <jo...@gm...> wrote: >> > Just to update everyone, I figured out the problem. I had added a few >> > range indexes and a lucene index to my app, but didn't include the >> > RestXQ rigger in the new collection.xconf. Thus, the RestXQ trigger >> > was no longer operating on my app. >> > >> > RestXQ Troubleshooting Tip of the Day: If you start working on a >> > RestXQ app and you add a collection.xconf file at the level of the >> > collection hierarchy that includes your RestXQ modules, make sure you >> > add the RestXQ trigger to the collection.xconf file. Otherwise, the >> > next time you update your RestXQ module or restart the database, your >> > app will break. You will know it's broken because (1) you'll get >> > errors like: "HTTP ERROR 405 Problem accessing /exist/restxq/myapp. >> > Reason: HTTP method GET is not supported by this URL" and (2) you'll >> > see no evidence of this error anywhere in exist.log or restxq.log, >> > even with logging set to trace. After all, eXist-db has no idea >> > you're trying to use RestXQ, so why should it notify you of an error? >> > >> > RestXQ Troubleshooting Tip of the Day #2: To avoid the situation above >> > completely, put your data and correspoding index definitions deeper in >> > your app's collection hierarchy than at the level of your RestXQ >> > modules. This way the default collection.xconf (stored in >> > /system/config/db/collection.xconf), which contains the RestXQ >> > trigger, will apply to your app: >> > >> > <collection xmlns="http://exist-db.org/collection-config/1.0"> >> > <triggers> >> > <trigger >> > class="org.exist.extensions.exquery.restxq.impl.RestXqTrigger"/> >> > </triggers> >> > </collection> >> > >> > Otherwise, be sure to add the trigger in your app's collection.xconf. > > > -- > Dmitriy Shabanov -- Adam Retter eXist Developer { United Kingdom } ad...@ex... irc://irc.freenode.net/existdb |