[jdom-interest] need help with local DTD

jdom-interest at vrolijken.nl jdom-interest at vrolijken.nl
Fri Nov 11 07:28:43 PST 2005


Hi all,

I'm working on WebSphere 5.0 on a project that involves Jakarta Slide. For that
project I needed to change the classloader policy to PARENT_LAST and WAR
classloader policy to APPLICATION so that it would use the JDom provided with
Slide, which is newer that the WSAD one. The problem I'm having now is that the
OJB configuration (which is also needed) is not properly loaded anymore.

The error I'm getting is "no protocol" for the DTD. I would not think the
protocol is needed as it is a local file. I can change the specification of the
DTD into "file:///path/on/my/local/machine/repository.dtd" and that works. The
problem (obviously) is that this won't work in production, as the path is
completely different.

What am I doing wrong here?

--- part of the code where stuff breaks ----
in
org.apache.ojb.broker.metadata.RepositoryPersistor.readMetadataFromXML(InputSource,
Class):

DescriptorRepository repository = new DescriptorRepository();
ContentHandler handler = new RepositoryXmlHandler(repository);
reader.setContentHandler(handler);
reader.parse(source);                 <--- throws a MalformedURLException

--- XML file that is fed to 'source' ---
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE descriptor-repository PUBLIC "-//Apache Software Foundation//DTD OJB
Repository//EN" "repository.dtd"
[
   <!ENTITY database SYSTEM "repository_database.xml">
   <!ENTITY internal SYSTEM "repository_internal.xml">
   <!ENTITY user SYSTEM "intranet_mapping.xml">
]>
...


More information about the jdom-interest mailing list