|
From: <eri...@op...> - 2003-06-28 01:07:00
|
Jon,
I worked with someone at my last client (Leong Dong, who is a subscriber to this list) on implementing a XML parser that permits DTD/Schemas to be read directly from memory, rather than always having to go to disk. I can't recall the exact version, but I think it was the latest version of Xerces that supported this. This might be a slightly more efficient way of loading your DTDs that are already cached. Just a thought. Perhaps Leong can confim?
Erik
----- Original Message -----
From: "Leech, Jonathan" <jl...@vi...>
Date: Friday, June 27, 2003 2:54 pm
Subject: RE: [Babeldoc-devel] retrieving a document from the journal
> For the XML parsing, I prototyped two EntityResolver caches - one
> memory and
> one disk. The memory cache fronts the disk cache wich fronts the
> defaultentity resolving, which is to go to the URL and get the
> document. I have
> already gotten the OK from management here to contribute the
> HttpClientPipelineStage to open source, I most likely could get
> the OK to
> refine the EntityResolverCache and contribute that as well, if
> people are
> interested.
>
> -Jonathan
>
> -----Original Message-----
> From: Bruce McDonald [br...@mc...]
> Sent: Friday, June 27, 2003 12:05 PM
> To: Leech, Jonathan; bab...@li...
> Subject: Re: [Babeldoc-devel] retrieving a document from the journal
>
>
> Jon,
>
> Good - go ahead with the HttpClient one - its way more functional
> than the
> JDK
> UrlConnection code.
>
>
> Processing XML can be very expensive especially with lots of DTDs
> on remote
> machines. I would be very interested to see what can be done
> about making
> this work better. Of course the easy way out is to not verify the
> XML...
> regards,
> Bruce.
>
> On Friday 27 June 2003 10:49 am, Leech, Jonathan wrote:
> > Bruce,
> >
> > I have already prototyped one using the jdk HttpURLConnection,
> but looking
> > at apache HttpClient it seems to be the way to go. If anyone
> else is
> > interested in particular features for this, let me know and I'll
> put them
> > in.
> >
> > Also, I am curious as to what steps other people are taking for
> speedingup
> > XML parsing. Some of the documents I am parsing reference 20
> .dtds on a
> > remote server, which makes parsing take 15 seconds instead of
> .2. I have
> > prototyped some code that is basically an EntityResolver cache,
> but I'm
> > guessing that other people have built similar, more robust ways of
> > accomplising this. Does babeldoc have a way of integrating with
> something> like that?
> >
> > Sincerely,
> > Jonathan Leech
> > Senior Software Engineer
> > Virtela Communications, Inc.
> >
> > -----Original Message-----
> > From: Bruce McDonald [br...@mc...]
> > Sent: Thursday, June 26, 2003 10:05 PM
> > To: Leech, Jonathan; bab...@li...
> > Subject: Re: [Babeldoc-devel] retrieving a document from the journal
> >
> >
> > Jon,
> >
> > Sorry - I was going to do a HttpPostPipelineStage but I never
> got around
> to
> > it
> > - Please go ahead and start this. Writing a pipeline stage is
> not a
> > difficult thing - please do not hesitate to ask for advice, etc.
> >
> > regards,
> > Bruce.
> >
> > On Thursday 26 June 2003 01:02 pm, Leech, Jonathan wrote:
> > > Bruce,
> > >
> > > Thanks for the information on the local configuration.
> > >
> > > I have found the demons causing my No suitable driver error.
> > > java.sql.DriverManager attempts to load the drivers in the
> jdbc.drivers> > system property explicitly using the system class
> loader, whereas the
> > > classes12.jar for oracle was not in my system classpath. What was
> > > confusing was that I could load the class, using
> Class.forName(), or
> call
> > > DriverManager.registerDriver() using a new instance of the oracle
> driver,
> > > which made things work, because the babeldoc classloader is
> loading it.
> >
> > So
> >
> > > the answer is to explicity add it to the classpath.
> > >
> > > Also, the line that's missing from query.properties that makes the
> oracle
> > > journal able to store documents is:
> > > journalSelectBlobForUpdate-oracle=select jrn_data from journal
> where> > jrn_log_id=? and jrn_log_step=? for update
> > >
> > > Dejan mentioned in the Open Discussion forum to me that you
> might have
> > > written a pipeline stage that uses the HttpClient library...
> Is that
> > > true?
> > >
> > > Sincerely,
> > > Jonathan Leech
> > > Senior Software Engineer
> > > Virtela Communications, Inc.
> > >
> > >
> > > -----Original Message-----
> > > From: Bruce McDonald [br...@mc...]
> > > Sent: Wednesday, June 25, 2003 7:27 PM
> > > To: Leech, Jonathan; bab...@li...
> > > Subject: Re: [Babeldoc-devel] retrieving a document from the
> journal> >
> > >
> > > Hmm,
> > >
> > > Yes, that should do it. Are you sure its in the classpath?
> > >
> > > But, what I mean about local configuration path is this:
> > >
> > > You override the babeldoc configurations (as given in the babeldoc
> module
> > > jar
> > > files) by setting the BABELDOC_USER environment variable to a
> >
> > configuration
> >
> > > directory of your own. This is always takes precedence over
> whatever is
> > > built into babeldoc. So, a practical example, in windows:
> > >
> > > 1. Your babeldoc is installed in c:\babeldoc, and therefore the
> > > BABELDOC_HOME=c:\babeldoc
> > > 2. Your configuration data is stored in c:\work, and
> therefore the
> > > BABELDOC_USER=c:\work
> > > 3. Create a subdirectory c:\work\env
> > > 4. Create a file in there called config.properties. Set the
> property> > (or whatever properties) needed for your code to run.
> > >
> > > Try this, let me know.
> > >
> > > regards,
> > > Bruce.
> > >
> > > On Wednesday 25 June 2003 07:20 pm, Leech, Jonathan wrote:
> > > > Bruce,
> > > >
> > > > I'm not sure what you mean by local configuration
> directory... I
> >
> > changed
> >
> > > > the babeldoc/modules/sql/config/env/config.properties to
> have the
> > > > jdbc.drivers=oracle.jdbc.driver.OracleDriver, rebuilt from
> scratch,and
> > > > still
> > > > get the No suitable driver error.
> > > >
> > > > Sincerely,
> > > > Jonathan Leech
> > > > Senior Software Engineer
> > > > Virtela Communications, Inc.
> > > >
> > > > -----Original Message-----
> > > > From: Bruce McDonald [br...@mc...]
> > > > Sent: Wednesday, June 25, 2003 4:43 PM
> > > > To: Leech, Jonathan; bab...@li...
> > > > Subject: Re: [Babeldoc-devel] retrieving a document from the
> journal> > >
> > > >
> > > > Jon,
> > > >
> > > > In the config/env/config.properties (this file contains
> properties> > > which are
> > > >
> > > > added to the system properties) - so in your local configuration
> > >
> > > directory,
> > >
> > > > create an identical env/config.properties and add the line:
> > > >
> > > > jdbc.drivers=oracle.jdbc.driver.OracleDriver
> > > >
> > > > regards,
> > > > Bruce.
> > > >
> > > > On Wednesday 25 June 2003 06:09 pm, Leech, Jonathan wrote:
> > > > > Stefan,
> > > > >
> > > > > I tried the system property approach
> > > > > (-Djdbc.drivers=oracle.jdbc.driver.OracleDriver), on the
> commandline
> > > > > to babeldoc, but that didn't work. Where did you add your JVM
> system
> > > > > property?
> > > > >
> > > > > -Jonathan
> > > > >
> > > > > -----Original Message-----
> > > > > From: Stefan Krieger [ste...@co...]
> > > > > Sent: Wednesday, June 25, 2003 4:55 PM
> > > > > To: bab...@li...
> > > > > Subject: Re: [Babeldoc-devel] retrieving a document from
> the journal
> > > > >
> > > > >
> > > > > Jonathan,
> > > > >
> > > > > we had the same problems with the query.properties und driver.
> > >
> > > Obviously,
> > >
> > > > > the property is missing.
> > > > > A workmate added a statement, but I don't know which. I
> will post
> our
> > > > > query.properties for Oracle tomorrow.
> > > > >
> > > > > We added the driver as system property to the JVM. Anyway, in
> > > > > production
> > > >
> > > > we
> > > >
> > > > > will retrieve a preconfigured datastore from JNDI.
> > > > >
> > > > > Regards,
> > > > > Stefan
> > > > >
> > > > > ----- Original Message -----
> > > > > From: "Leech, Jonathan" <jl...@vi...>
> > > > > To: <bab...@li...>
> > > > > Sent: Wednesday, June 25, 2003 10:35 PM
> > > > > Subject: RE: [Babeldoc-devel] retrieving a document from
> the journal
> > > > >
> > > > > > Thanks Dejan,
> > > > > > That makes sense and I found the spot in the userguide
> that says
> > > > > > that.
> > > >
> > > > I
> > > >
> > > > > > tested it out with the SimpleJournal and I can retrieve
> documents> > > > > just
> > > > >
> > > > > fine.
> > > > >
> > > > > > However, now I'm trying out the Oracle journal and I am
> having> > > > > problems.
> > > > >
> > > > > It
> > > > >
> > > > > > looks to me like the code in CVS isn't quite in sync
> with the
> > > > > > query.properties in CVS, because the
> > > > > > journalSelectBlobForUpdate-oracle property doesn't exist in
> > > > > > query.properties, but OracleJournal.java needs
> > > > >
> > > > > it.
> > > > >
> > > > > > This causes a SQLException. Can somebody tell me what
> the value
> > >
> > > should
> > >
> > > > > > be for this?
> > > > > >
> > > > > > I had another problem with OracleJournal that I got
> past, which
> was
> >
> > a
> >
> > > > > > No Suitable driver exception. I suspect whoever uses the
> > >
> > > OracleJournal
> > >
> > > > > > has
> > > > >
> > > > > the
> > > > >
> > > > > > code that fixes the problem and it just isn't checked
> in, or is
> >
> > using
> >
> > > > > > babeldoc in an environment that registers the Oracle
> driver for
> >
> > them.
> >
> > > > > > I would be happy to check the code in, what do I need to
> do to get
> > > > > > CVS
> > > > >
> > > > > commit
> > > > >
> > > > > > access? Here's the code I would add to OracleJournal.java:
> > > > > >
> > > > > > static {
> > > > > > try {
> > > > > > DriverManager.registerDriver(new
> > > > > > oracle.jdbc.driver.OracleDriver()); }
> > > > > > catch (SQLException sqle) {
> > > > > > throw new RuntimeException(sqle);
> > > > > > }
> > > > > > }
> > > > > >
> > > > > > Sincerely,
> > > > > > Jonathan Leech
> > > > > > Senior Software Engineer
> > > > > > Virtela Communications, Inc.
> > > > > >
> > > > > > -----Original Message-----
> > > > > > From: Dejan Krsmanovic [dej...@ya...]
> > > > > > Sent: Wednesday, June 25, 2003 1:47 PM
> > > > > > To: 'bab...@li...'
> > > > > > Subject: Re: [Babeldoc-devel] retrieving a document from the
> > > > > > journal
> > > > > >
> > > > > >
> > > > > > By default document are NOT stored into jjournal
> > > > > > because it is time-consuming operation. If you want to
> > > > > > store document into journal, you should set tracked
> > > > > > property to true (tracked=true) for pipeline stage in
> > > > > > which you want to store document.
> > > > > >
> > > > > > Dejan
> > > > > >
> > > > > > --- "Leech, Jonathan" <jl...@vi...> wrote:
> > > > > > > Hi,
> > > > > > >
> > > > > > > I am getting started with babeldoc and trying to
> > > > > > > understand the journal
> > > > > > > capabilities. From what I've read in the
> > > > > > > documentation, I should be able to
> > > > > > > retrieve a document from the journal, and even
> > > > > > > replay tickets etc. However,
> > > > > > > if I run the svg-transcode example, and then try
> > > > > > > babeldoc journal -D
> > > > > > > 1056495510901.2, I get a JornalException: No
> > > > > > > document stored at (
> >
> >
> com.babeldoc.core.journal.JournalTicket@763f5d[value=1056495510901],2>
> >
> >
> <com.babeldoc.core.journal.JournalTicket@763f5d[value=1056495510901]
> >
> > > > >,
> > > > >
> > > > > > > 2> ). I added some debug code and rebuilt it, and
> > > > > > > the cause is a
> > > > > > > ClassCastException trying to cast a String into a
> > > > > > > PipelineDocument. I have
> > > > > > > looked through the code to some extent, and I am
> > > > > > > quite confused. I am
> > > > > > > getting the same problem in babeldoc-1.0.1 and the
> > > > > > > current version I checked
> > > > > > > out from CVS yesterday. What am I doing wrong?
> > > > > > >
> > > > > > > Sincerely,
> > > > > > > Jonathan Leech
> > > > > > > Senior Software Engineer
> > > > > > > Virtela Communications, Inc.
> > > > > >
> > > > > > __________________________________
> > > > > > Do you Yahoo!?
> > > > > > SBC Yahoo! DSL - Now only $29.95 per month!
> > > > > > http://sbc.yahoo.com
> > > > > >
> > > > > >
> > > > > > -------------------------------------------------------
> > > > > > This SF.Net email is sponsored by: INetU
> > > > > > Attention Web Developers & Consultants: Become An INetU
> Hosting> > > > > Partner. Refer Dedicated Servers. We Manage Them.
> You Get 10%
> >
> > Monthly
> >
> > > > > > Commission! INetU Dedicated Managed Hosting
> > > > > > http://www.inetu.net/partner/index.php
> > > > > > _______________________________________________
> > > > > > Babeldoc-devel mailing list
> > > > > > Bab...@li...
> > > > > > https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
> > > > > >
> > > > > >
> > > > > > -------------------------------------------------------
> > > > > > This SF.Net email is sponsored by: INetU
> > > > > > Attention Web Developers & Consultants: Become An INetU
> Hosting> > > > > Partner. Refer Dedicated Servers. We Manage Them.
> You Get 10%
> >
> > Monthly
> >
> > > > > > Commission! INetU Dedicated Managed Hosting
> > > > > > http://www.inetu.net/partner/index.php
> > > > > > _______________________________________________
> > > > > > Babeldoc-devel mailing list
> > > > > > Bab...@li...
> > > > > > https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
> > > > >
> > > > > -------------------------------------------------------
> > > > > This SF.Net email is sponsored by: INetU
> > > > > Attention Web Developers & Consultants: Become An INetU
> Hosting> > > > Partner. Refer Dedicated Servers. We Manage Them.
> You Get 10%
> Monthly
> > > > > Commission! INetU Dedicated Managed Hosting
> > > > > http://www.inetu.net/partner/index.php
> > > > > _______________________________________________
> > > > > Babeldoc-devel mailing list
> > > > > Bab...@li...
> > > > > https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
> > > > >
> > > > >
> > > > > -------------------------------------------------------
> > > > > This SF.Net email is sponsored by: INetU
> > > > > Attention Web Developers & Consultants: Become An INetU
> Hosting> > > > Partner. Refer Dedicated Servers. We Manage Them.
> You Get 10%
> Monthly
> > > > > Commission! INetU Dedicated Managed Hosting
> > > > > http://www.inetu.net/partner/index.php
> > > > > _______________________________________________
> > > > > Babeldoc-devel mailing list
> > > > > Bab...@li...
> > > > > https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
> > > >
> > > > -------------------------------------------------------
> > > > This SF.Net email is sponsored by: INetU
> > > > Attention Web Developers & Consultants: Become An INetU Hosting
> > > > Partner. Refer Dedicated Servers. We Manage Them. You Get
> 10% Monthly
> > > > Commission! INetU Dedicated Managed Hosting
> > > > http://www.inetu.net/partner/index.php
> > > > _______________________________________________
> > > > Babeldoc-devel mailing list
> > > > Bab...@li...
> > > > https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
> > > >
> > > >
> > > > -------------------------------------------------------
> > > > This SF.Net email is sponsored by: INetU
> > > > Attention Web Developers & Consultants: Become An INetU Hosting
> > > > Partner. Refer Dedicated Servers. We Manage Them. You Get
> 10% Monthly
> > > > Commission! INetU Dedicated Managed Hosting
> > > > http://www.inetu.net/partner/index.php
> > > > _______________________________________________
> > > > Babeldoc-devel mailing list
> > > > Bab...@li...
> > > > https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
> > >
> > > -------------------------------------------------------
> > > This SF.Net email is sponsored by: INetU
> > > Attention Web Developers & Consultants: Become An INetU
> Hosting Partner.
> > > Refer Dedicated Servers. We Manage Them. You Get 10% Monthly
> Commission!> > INetU Dedicated Managed Hosting
> http://www.inetu.net/partner/index.php> >
> _______________________________________________> > Babeldoc-devel
> mailing list
> > > Bab...@li...
> > > https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
>
>
> -------------------------------------------------------
> This SF.Net email sponsored by: Free pre-built ASP.NET sites including
> Data Reports, E-commerce, Portals, and Forums are available now.
> Download today and enter to win an XBOX or Visual Studio .NET.
> http://aspnet.click-
> url.com/go/psa00100006ave/direct;at.asp_061203_01/01_______________________________________________
> Babeldoc-devel mailing list
> Bab...@li...
> https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
>
>
> -------------------------------------------------------
> This SF.Net email sponsored by: Free pre-built ASP.NET sites including
> Data Reports, E-commerce, Portals, and Forums are available now.
> Download today and enter to win an XBOX or Visual Studio .NET.
> http://aspnet.click-
> url.com/go/psa00100006ave/direct;at.asp_061203_01/01_______________________________________________
> Babeldoc-devel mailing list
> Bab...@li...
> https://lists.sourceforge.net/lists/listinfo/babeldoc-devel
>
|