Return-Path: Delivered-To: apmail-xml-forrest-dev-archive@www.apache.org Received: (qmail 35886 invoked from network); 13 Feb 2004 04:48:50 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 13 Feb 2004 04:48:50 -0000 Received: (qmail 35373 invoked by uid 500); 13 Feb 2004 04:48:30 -0000 Delivered-To: apmail-xml-forrest-dev-archive@xml.apache.org Received: (qmail 35207 invoked by uid 500); 13 Feb 2004 04:48:28 -0000 Mailing-List: contact forrest-dev-help@xml.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: forrest-dev@xml.apache.org Delivered-To: mailing list forrest-dev@xml.apache.org Received: (qmail 35191 invoked from network); 13 Feb 2004 04:48:28 -0000 Received: from unknown (HELO www2.kc.aoindustries.com) (65.77.211.84) by daedalus.apache.org with SMTP; 13 Feb 2004 04:48:28 -0000 Received: from dialup-251.147.220.203.acc01-aubu-gou.comindico.com.au (dialup-251.147.220.203.acc01-aubu-gou.comindico.com.au [203.220.147.251]) (authenticated) by www2.kc.aoindustries.com (8.11.6/8.11.6) with ESMTP id i1D4k7C15795 for ; Thu, 12 Feb 2004 22:46:07 -0600 Subject: Re: [Proposal] add DTDs to Apache website From: David Crossley To: forrest-dev@xml.apache.org In-Reply-To: References: <1074056016.5794.13010.camel@ighp> <40058CD0.2000704@gmx.de> <1074139557.5793.17651.camel@ighp> Content-Type: text/plain Organization: Message-Id: <1076647702.12472.3618.camel@ighp> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.2.2 (1.2.2-5) Date: 13 Feb 2004 15:48:24 +1100 Content-Transfer-Encoding: 7bit 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 I started to experiment with Stefano's suggestion to use a .htaccess file and ProxyPass the DTDs via ViewCVS. This approach may not work because the media types will be wrong. Everything will come out as text/plain whereas the DTDs and the associated *.mod need to be application/xml-dtd and *.pen *.ent are a different media type. ViewCVS does let you specify the "content-type". However, we cannot use mod_proxy because query string cannot be passed. So on to mod_rewrite. Here is what i have so far. It is not yet in CVS, but exists at /www/cocoon.apache.org/dtd/ You can experiment with it via http://cocoon.apache.org/dtd/ ask for say document-v12.dtd etc. I have reached a stage where i need help. The Proxy stuff and the Cache stuff need some work. ---------- # See the index.html in this directory. # # The reason for this .htaccess is to deliver DTDs and # associated resources to some impoverished XML tools # that do not use the Catalog Entity Resolver. # Get the content straight out of ViewCVS # and use the appropriate media type: # See http://www.faqs.org/rfcs/rfc3023.html # FIXME: Verify these media types and maybe add charset # RewriteEngine On RewriteRule "(.*)\.dtd$" "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/core/context/resources/schema/dtd/$1.dtd?content-type=application/xml-dtd" [P] RewriteRule "(.*)\.mod$" "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/core/context/resources/schema/dtd/$1.mod?content-type=application/xml-dtd" [P] RewriteRule "(.*)\.pen$" "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/core/context/resources/schema/dtd/$1.pen?content-type=application/xml-external-parsed-entity" [P] RewriteRule "(.*)\.ent$" "http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-forrest/src/core/context/resources/schema/dtd/$1.ent?content-type=application/xml-external-parsed-entity" [P] # FIXME: Cache stuff is not yet working # # Now, since ViewCVS is slow, make sure we cache it #CacheEnable mem # for a day #CacheDefaultExpire 86400 #MCacheSize 4096 #MCacheMaxObjectCount 100 #MCacheMinObjectSize 1 #MCacheMaxObjectSize 2048 # and in case your client is a good web citizen, tell the proxies # to avoid calling us, since we guarantee that the content is fresh # for a day #ExpiresActive On #ExpiresDefault "access plus 1 day" ----------