[jboss-dev-forums] [Design the new POJO MicroContainer] - JBoss with spaces in the directory name

adrian@jboss.org do-not-reply at jboss.com
Wed Jul 23 13:14:37 EDT 2008


https://jira.jboss.org/jira/browse/JBAS-5796

The initial problem is in the main class,
which needs the file converting to a URI before creating the URL
for jboss.home.url
otherwise it doesn't encode the URL properly


  | [ejort at warjort main]$ svn diff
  | Index: src/main/org/jboss/Main.java
  | ===================================================================
  | --- src/main/org/jboss/Main.java        (revision 76000)
  | +++ src/main/org/jboss/Main.java        (working copy)
  | @@ -138,7 +138,7 @@
  |        if (homeURL == null)
  |        {
  |           File file = new File(homeDir);
  | -         homeURL = file.toURL().toString();
  | +         homeURL = file.toURI().toURL().toString();
  |           props.setProperty(ServerConfig.HOME_URL, homeURL);
  |        }
  | 

The next problem is that the property editors aren't handling encoded
URLs/URIs properly:

https://jira.jboss.org/jira/browse/JBCOMMON-60

After that there some problem in the VFS:

  | Caused by: org.jboss.mx.util.JBossNotCompliantMBeanException: Error parsing the XML file, from XMLMetaData: 
  |         at org.jboss.mx.metadata.XMLMetaData.build(XMLMetaData.java:292)
  |         at org.jboss.mx.modelmbean.XMBean.<init>(XMBean.java:253)
  |         at org.jboss.mx.modelmbean.XMBean.<init>(XMBean.java:282)
  |         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
  |         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
  |         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
  |         at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
  |         at org.jboss.mx.server.MBeanServerImpl.instantiate(MBeanServerImpl.java:1242)
  |         at org.jboss.mx.server.MBeanServerImpl.instantiate(MBeanServerImpl.java:286)
  |         at org.jboss.mx.server.MBeanServerImpl.createMBean(MBeanServerImpl.java:344)
  |         at org.jboss.system.ServiceCreator.installExternalXMBean(ServiceCreator.java:286)
  |         at org.jboss.system.ServiceCreator.install(ServiceCreator.java:122)
  |         ... 38 more
  | Caused by: org.dom4j.DocumentException: Child not found jboss-5.0.0.CR2%20test/server/default/conf/xmdesc/AttributePersistenceService-xmbean.xml for FileHandler at 166961
  | 1[path= context=file:/home/ejort/jboss-head/build/output/ real=file:/home/ejort/jboss-head/build/output/] Nested exception: Child not found jboss-5.0.0.CR2%20test/serv
  | er/default/conf/xmdesc/AttributePersistenceService-xmbean.xml for FileHandler at 1669611[path= context=file:/home/ejort/jboss-head/build/output/ real=file:/home/ejort/jbo
  | ss-head/build/output/]
  |         at org.dom4j.io.SAXReader.read(SAXReader.java:484)
  |         at org.dom4j.io.SAXReader.read(SAXReader.java:291)
  |         at org.jboss.mx.metadata.XMLMetaData.build(XMLMetaData.java:255)
  |         ... 49 more
  | 

Probably because the FileHandler is looking for a directory called?
boss-5.0.0.CR2%20test

I'm fixing the first two problems. Ales, I'll let you look at the VFS issue. ;-)

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4166220#4166220

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4166220



More information about the jboss-dev-forums mailing list