Re: httpmd

Dan Creswell <[email protected]>
Newsgroups gmane.comp.java.sun.jini
Message-ID <[email protected]>
Hi Patrick,

Logan, Patrick wrote:
> I am converting a working example from using an http codebase url to
> using httpmd instead. After looking around a bit, but probably not in
> the right places, I was hoping all I had to do was replace the codebase
> url with the one for httpmd and put the net.jini.url package on the
> java.protocol.handler.pkgs property.
>

Yep - but you have to do it for everything that needs to use httpmd.

> I have tried this with outrigger as well as blitz, writing an entry to

The trace below appears to be a takeIfExists not a write?

And are you using transactions or not?

> the javaspace. So I did nothing different in the way I started the jini
> services, hoping by default they would understand httpmd, as it wasn't

Nope :)

> clear to me how I would tall them about net.jini.url without
> hand-editing a script somewhere. I believe the traceback below from

Well, of course the issue is we need to teach the JVM about the protocol
so we have to set the property.

Can you post the command-line you are using to start outrigger and/or blitz?

Maybe the script is invoking start.jar?  If it is and the .config you
pass to start.jar contains NonActivatableServiceDescriptors then you
should be able to edit the script and add:

-Djava.protocol.handler.pkgs=net.jini.url

to the command-line for start.jar

> outrigger and a similar one from blitz are telling me that httpmd is not
> understood over on the server side of the javaspaces implementation.
>
> Is that correct?
>
> What am I missing?
>
> Thanks
> -Patrick
>

Hope that helps,

Dan.

>      [java] Trouble with a Worker: java.rmi.ServerException:
> RemoteException in server thread; nested exception is:
>      [java]     java.rmi.UnmarshalException: unmarshalling
> method/arguments; nested exception is:
>      [java]     java.net.MalformedURLException: unknown protocol: httpmd
>      [java] java.rmi.ServerException: RemoteException in server thread;
> nested exception is:
>      [java]     java.rmi.UnmarshalException: unmarshalling
> method/arguments; nested exception is:
>      [java]     java.net.MalformedURLException: unknown protocol: httpmd
>      [java]     at
> net.jini.jeri.BasicInvocationDispatcher.dispatch(BasicInvocationDispatcher.java:644)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$6.run(ObjectTable.java:597)
>      [java]     at
> net.jini.export.ServerContext.doWithServerContext(ServerContext.java:103)
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$Target.dispatch0(ObjectTable.java:595)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$Target.access$700(ObjectTable.java:212)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$5.run(ObjectTable.java:568)
>      [java]     at
> com.sun.jini.start.AggregatePolicyProvider$6.run(AggregatePolicyProvider.java:527)
>
>      [java]     at java.security.AccessController.doPrivileged(Native
> Method)
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$Target.dispatch(ObjectTable.java:565)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$Target.dispatch(ObjectTable.java:540)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$RD.dispatch(ObjectTable.java:778)
>
>      [java]     at
> net.jini.jeri.connection.ServerConnectionManager$Dispatcher.dispatch(ServerConnectionManager.java:148)
>
>      [java]     at
> com.sun.jini.jeri.internal.mux.MuxServer$2.run(MuxServer.java:244)
>      [java]     at
> com.sun.jini.start.AggregatePolicyProvider$5.run(AggregatePolicyProvider.java:513)
>
>      [java]     at java.security.AccessController.doPrivileged(Native
> Method)
>      [java]     at
> com.sun.jini.jeri.internal.mux.MuxServer$1.run(MuxServer.java:241)
>      [java]     at
> com.sun.jini.thread.ThreadPool$Worker.run(ThreadPool.java:136)
>      [java]     at java.lang.Thread.run(Thread.java:595)
>      [java]     at
> com.sun.jini.jeri.internal.runtime.Util.__________EXCEPTION_RECEIVED_FROM_SERVER__________(Util.java:108)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.Util.exceptionReceivedFromServer(Util.java:101)
>
>      [java]     at
> net.jini.jeri.BasicInvocationHandler.unmarshalThrow(BasicInvocationHandler.java:1303)
>
>      [java]     at
> net.jini.jeri.BasicInvocationHandler.invokeRemoteMethodOnce(BasicInvocationHandler.java:832)
>
>      [java]     at
> net.jini.jeri.BasicInvocationHandler.invokeRemoteMethod(BasicInvocationHandler.java:659)
>
>      [java]     at
> net.jini.jeri.BasicInvocationHandler.invoke(BasicInvocationHandler.java:528)
>
>      [java]     at com.sun.jini.outrigger.$Proxy1.takeIfExists(Unknown
> Source)
>      [java]     at
> com.sun.jini.outrigger.SpaceProxy2.takeIfExists(SpaceProxy2.java:462)
>      [java]     at
> com.lmig.pi.webflow.eval.FormSeeder.seedWebFormEntry(FormSeeder.java:47)
>      [java]     at
> com.lmig.pi.webflow.eval.FormSeeder.main(FormSeeder.java:30)
>      [java] Caused by: java.rmi.UnmarshalException: unmarshalling
> method/arguments; nested exception is:
>      [java]     java.net.MalformedURLException: unknown protocol: httpmd
>      [java]     at
> net.jini.jeri.BasicInvocationDispatcher.dispatch(BasicInvocationDispatcher.java:619)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$6.run(ObjectTable.java:597)
>      [java]     at
> net.jini.export.ServerContext.doWithServerContext(ServerContext.java:103)
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$Target.dispatch0(ObjectTable.java:595)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$Target.access$700(ObjectTable.java:212)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$5.run(ObjectTable.java:568)
>      [java]     at
> com.sun.jini.start.AggregatePolicyProvider$6.run(AggregatePolicyProvider.java:527)
>
>      [java]     at java.security.AccessController.doPrivileged(Native
> Method)
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$Target.dispatch(ObjectTable.java:565)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$Target.dispatch(ObjectTable.java:540)
>
>      [java]     at
> com.sun.jini.jeri.internal.runtime.ObjectTable$RD.dispatch(ObjectTable.java:778)
>
>      [java]     at
> net.jini.jeri.connection.ServerConnectionManager$Dispatcher.dispatch(ServerConnectionManager.java:148)
>
>      [java]     at
> com.sun.jini.jeri.internal.mux.MuxServer$2.run(MuxServer.java:244)
>      [java]     at
> com.sun.jini.start.AggregatePolicyProvider$5.run(AggregatePolicyProvider.java:513)
>
>      [java]     at java.security.AccessController.doPrivileged(Native
> Method)
>      [java]     at
> com.sun.jini.jeri.internal.mux.MuxServer$1.run(MuxServer.java:241)
>      [java]     at
> com.sun.jini.thread.ThreadPool$Worker.run(ThreadPool.java:136)
>      [java]     at java.lang.Thread.run(Thread.java:595)
>      [java] Caused by: java.net.MalformedURLException: unknown protocol:
> httpmd
>      [java]     at java.net.URL.<init>(URL.java:574)
>      [java]     at java.net.URL.<init>(URL.java:464)
>      [java]     at java.net.URL.<init>(URL.java:413)
>      [java]     at
> net.jini.loader.pref.PreferredClassProvider.pathToURLs(PreferredClassProvider.java:1409)
>
>      [java]     at
> net.jini.loader.pref.PreferredClassProvider.loadClass(PreferredClassProvider.java:483)
>
>      [java]     at
> java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:247)
>      [java]     at
> net.jini.loader.ClassLoading.loadClass(ClassLoading.java:138)
>      [java]     at
> net.jini.io.MarshalInputStream.resolveClass(MarshalInputStream.java:296)
>      [java]     at
> java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1544)
>      [java]     at
> java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1466)
>      [java]     at
> java.io.ObjectInputStream.readArray(ObjectInputStream.java:1591)
>      [java]     at
> java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1299)
>      [java]     at
> java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1908)
>      [java]     at
> java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:479)
>      [java]     at
> com.sun.jini.outrigger.EntryRep.readObject(EntryRep.java:733)
>      [java]     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)
>      [java]     at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>
>      [java]     at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>
>      [java]     at java.lang.reflect.Method.invoke(Method.java:585)
>      [java]     at
> java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:946)
> [java]     at
> java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1809)
>
>      [java]     at
> java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1719)
>      [java]     at
> java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1305)
>      [java]     at
> java.io.ObjectInputStream.readObject(ObjectInputStream.java:348)
>      [java]     at
> com.sun.jini.jeri.internal.runtime.Util.unmarshalValue(Util.java:221)
>      [java]     at
> net.jini.jeri.BasicInvocationDispatcher.unmarshalArguments(BasicInvocationDispatcher.java:1049)
>
>      [java]     at
> net.jini.jeri.BasicInvocationDispatcher.dispatch(BasicInvocationDispatcher.java:599)
>
>      [java]     ... 17 more
>
>
>
>
>
> Patrick Logan
> Premium Innovation
> Liberty Mutual - Agency Markets IT West
> 650 NE Holladay Street
> PO Box 4555
> Portland, OR   97208-4555
>
> Office: 503.736.7537
> Cell: 503.476.5387
>
>
> --------------------------------------------------------------------------
> Getting Started: http://www.jini.org/wiki/Category:Getting_Started
> Community Web Site: http://jini.org jini-users Archive:
> http://archives.java.sun.com/archives/jini-users.html Unsubscribing:
> email "signoff JINI-USERS" to [email protected]

--------------------------------------------------------------------------
Getting Started:     http://www.jini.org/wiki/Category:Getting_Started
Community Web Site:  http://jini.org
jini-users Archive:  http://archives.java.sun.com/archives/jini-users.html
Unsubscribing:       email "signoff JINI-USERS"  to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.