Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 6545 invoked from network); 24 Oct 2003 10:39:03 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 24 Oct 2003 10:39:03 -0000 Received: (qmail 13235 invoked by uid 500); 24 Oct 2003 10:38:59 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 13204 invoked by uid 500); 24 Oct 2003 10:38:59 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: dev@cocoon.apache.org Delivered-To: mailing list dev@cocoon.apache.org Received: (qmail 13191 invoked from network); 24 Oct 2003 10:38:58 -0000 Received: from unknown (HELO mail.s-und-n.de) (212.8.217.2) by daedalus.apache.org with SMTP; 24 Oct 2003 10:38:58 -0000 Received: from notes.sundn.de (ntsrv5.sundn.de [10.10.2.10]) by mail.s-und-n.de (postfix) with ESMTP id 198C5E5662 for ; Fri, 24 Oct 2003 12:38:58 +0200 (CEST) Received: from hw0393 ([10.10.2.35]) by notes.sundn.de (Lotus Domino Release 5.0.8) with SMTP id 2003102412385693:62934 ; Fri, 24 Oct 2003 12:38:56 +0200 Message-ID: <01ce01c39a1b$62627500$23020a0a@hw0393> From: "Guido Casper" To: References: <84F0A43A4248CE45B5C0E20F4C40779C600904@naomi.webworks.nl> Subject: Re: repository block (was Re: [RT] Source extensions) Date: Fri, 24 Oct 2003 12:41:29 +0200 MIME-Version: 1.0 X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 X-MIMETrack: Itemize by SMTP Server on PBSN1/Systeme und Netzwerke(Release 5.0.8 |June 18, 2001) at 24.10.2003 12:38:56, Serialize by Router on PBSN1/Systeme und Netzwerke(Release 5.0.8 |June 18, 2001) at 24.10.2003 12:38:57, Serialize complete at 24.10.2003 12:38:57 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Unico Hommes wrote: >>> A related change I need to make is described here: >>> http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23699 this will >>> not only improve performance of querying for a specific property >>> but is prerequisite for setting properties via the >>> SourceDescriptionManager. >> >> I'm not sure. >> What exactly is the meaning of the returned Strings? >> > > They identify a property type: namespace + "#" + propname. The > previous implementation of the inspector manager's > getSourceProperty() method was looping over all registered inspectors > until it found the property it was looking for. > > In order to make this process more efficient the manager needs to > register the individual inspectors to handle specific properties. The > getExposedPropertyTypes() method enables this. > >> Is it all properties "supported" by a particular SourceInspector >> implementation? > > Yes. > >> What if it supports any within a particular namespace? >> What if it support any within any namespace? >> >> How would that be represented? > > Nothing in place for that yet, but we could add it easily. Just need a > convention. What about using wildcards for this: > > *#myprop > myns#* > *#* > > This way a simple jdbc descriptor that stores properties as key value > pairs in a database can assert it is general enough to handle any > property. The manager then looks for an inspector in order from most > specific (exact match) to least specific (*#*). The way the manager caches the values for lookups looks to me like sacrifying a lot of flexibility. I don't really see a way to avoid the looping (Is it really that costly?). Caching the set of supported properties is ok, but it should be a concern of the individual SourceInspector implementation IMO, since it could change at runtime (think access control for instance). That might also be a reason for the above lookup mechanism to break. Guido