Hi,

I've been checking the example that interacts with an ofbiz service.
I disabled ssl by commenting out lines in ofbiz-containers.xml.
(Would be great to have comments about it in the xml. My opinion is
that for using the demo service for the first time its probably not a
good idea to get the whole ssl burden. Or is it already documented
somewhere?)

However I kept getting the following error using jdk1.5.0_09 with
ofbiz rev# 496747 (around January 16th) on a Win2003 server:

java.rmi.UnmarshalException: error unmarshalling return; nested exception is:
java.net.MalformedURLException: no protocol: 
Files/Java/jdk1.5.0_09/lib/tools.jar

Note that only the JDK is installed to Program Files folder,
ofbiz_home does not have any spaces in its path.
I tried changing the 'Program Files' sequence to 'Progra~1' in both
JAVA_HOME env var and the Java section of Windows registry, all to no
avail.

I was told that the most common way of solution is to use a JDK
which is installed into a directory that has no spaces in its path.

Since I like to avoid reinstalling JDK and reconfiguring everything
based on it at all cost, I came up with a solution of a quick fix
of Classpath.java based on a relevant issue in the Sun bug database:
http://bugs.sun.com/bugdatabase/view_bug.do;jsessionid=a6a5e6c13fadf9ffffffffc85adbe8a70f6aa:WuuT?bug_id=4273532

In the getUrls() method I changed
  urls[i] = ((File) (_elements.get(i))).toURL()
to this
  urls[i] = ((File) (_elements.get(i))).toURI().toURL()

After this the demo service runs ok for me.

It would be great if someone could be looking at it in details.
(I'm far from seeing the whole picture, and this kind of modification may
apply to other places as well where the toURL() method is used. Also it
might turn out that this has downsides elsewhere.)

This way this simple demo would work out-of-the-box on Windows as well.
And keep up the good work guys, ofbiz is great.


Thanks,
  András


Reply via email to