javajbossrmimalformedurlexception

JBOSS MalformedURLException: unknown protocol: vfs using RMI


I've recently been trying to implement deploy my application as a war on a JBOSS EAP 6.4 environment after getting it fully functioning on Tomcat, but on JBOSS a malformedurlexception seems to arise whenever my application tries to send a file from the client to the server when doing the RMI calls (specifically rmiio).

My error logs are included below

    16:38:31,793 INFO  [stdout] (Thread-89) java.rmi.ServerException: RemoteException occurred in server thread; nested exception is: 
16:38:31,794 INFO  [stdout] (Thread-89)     java.rmi.UnmarshalException: error unmarshalling arguments; nested exception is: 
16:38:31,794 INFO  [stdout] (Thread-89)     java.net.MalformedURLException: unknown protocol: vfs
16:38:31,795 INFO  [stdout] (Thread-89)     at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source) ~[?:?]
16:38:31,795 INFO  [stdout] (Thread-89)     at sun.rmi.transport.Transport$1.run(Unknown Source) ~[?:?]
16:38:31,795 INFO  [stdout] (Thread-89)     at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_92]
16:38:31,795 INFO  [stdout] (Thread-89)     at sun.rmi.transport.Transport.serviceCall(Unknown Source) ~[?:?]
16:38:31,796 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source) ~[?:?]
16:38:31,796 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source) ~[?:?]
16:38:31,796 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source) ~[?:?]
16:38:31,796 INFO  [stdout] (Thread-89)     at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) ~[?:1.8.0_92]
16:38:31,796 INFO  [stdout] (Thread-89)     at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) ~[?:1.8.0_92]
16:38:31,797 INFO  [stdout] (Thread-89)     at java.lang.Thread.run(Unknown Source) ~[?:1.8.0_92]
16:38:31,797 INFO  [stdout] (Thread-89)     at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:276) ~[?:?]
16:38:31,797 INFO  [stdout] (Thread-89)     at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:253) ~[?:?]
16:38:31,797 INFO  [stdout] (Thread-89)     at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:162) ~[?:?]
16:38:31,798 INFO  [stdout] (Thread-89)     at java.rmi.server.RemoteObjectInvocationHandler.invokeRemoteMethod(RemoteObjectInvocationHandler.java:227) ~[?:1.8.0_92]
16:38:31,798 INFO  [stdout] (Thread-89)     at java.rmi.server.RemoteObjectInvocationHandler.invoke(RemoteObjectInvocationHandler.java:179) ~[?:1.8.0_92]
16:38:31,798 INFO  [stdout] (Thread-89)     at com.sun.proxy.$Proxy107.sendFile(Unknown Source) ~[?:?]
16:38:31,798 INFO  [stdout] (Thread-89)     at rmiclient.RmiTaskStarter.sendFile(RmiTaskStarter.java:98) ~[rmiclient-1.0.0.jar:1.0.0]
16:38:31,798 INFO  [stdout] (Thread-89)     at rmiclient.RmiTaskStarter.compute(RmiTaskStarter.java:56) ~[rmiclient-1.0.0.jar:1.0.0]
16:38:31,799 INFO  [stdout] (Thread-89)     at webapp.FrontEnd.Worker.runTask(Worker.java:68) [classes:?]
16:38:31,799 INFO  [stdout] (Thread-89)     at webapp.FrontEnd.Worker.run(Worker.java:52) [classes:?]
16:38:31,799 INFO  [stdout] (Thread-89)     at java.lang.Thread.run(Thread.java:745) [?:1.8.0_92]
16:38:31,799 INFO  [stdout] (Thread-89) Caused by: java.rmi.UnmarshalException: error unmarshalling arguments; nested exception is: 
16:38:31,799 INFO  [stdout] (Thread-89)     java.net.MalformedURLException: unknown protocol: vfs
16:38:31,800 INFO  [stdout] (Thread-89)     at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source) ~[?:?]
16:38:31,800 INFO  [stdout] (Thread-89)     at sun.rmi.transport.Transport$1.run(Unknown Source) ~[?:?]
16:38:31,800 INFO  [stdout] (Thread-89)     at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_92]
16:38:31,800 INFO  [stdout] (Thread-89)     at sun.rmi.transport.Transport.serviceCall(Unknown Source) ~[?:?]
16:38:31,801 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source) ~[?:?]
16:38:31,801 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source) ~[?:?]
16:38:31,802 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source) ~[?:?]
16:38:31,802 INFO  [stdout] (Thread-89)     at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) ~[?:1.8.0_92]
16:38:31,802 INFO  [stdout] (Thread-89)     at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) ~[?:1.8.0_92]
16:38:31,802 INFO  [stdout] (Thread-89)     at java.lang.Thread.run(Unknown Source) ~[?:1.8.0_92]
16:38:31,802 INFO  [stdout] (Thread-89) Caused by: java.net.MalformedURLException: unknown protocol: vfs
16:38:31,803 INFO  [stdout] (Thread-89)     at java.net.URL.<init>(Unknown Source) ~[?:1.8.0_92]
16:38:31,803 INFO  [stdout] (Thread-89)     at java.net.URL.<init>(Unknown Source) ~[?:1.8.0_92]
16:38:31,803 INFO  [stdout] (Thread-89)     at java.net.URL.<init>(Unknown Source) ~[?:1.8.0_92]
16:38:31,803 INFO  [stdout] (Thread-89)     at sun.rmi.server.LoaderHandler.pathToURLs(Unknown Source) ~[?:?]
16:38:31,804 INFO  [stdout] (Thread-89)     at sun.rmi.server.LoaderHandler.loadProxyClass(Unknown Source) ~[?:?]
16:38:31,804 INFO  [stdout] (Thread-89)     at java.rmi.server.RMIClassLoader$2.loadProxyClass(Unknown Source) ~[?:1.8.0_92]
16:38:31,804 INFO  [stdout] (Thread-89)     at java.rmi.server.RMIClassLoader.loadProxyClass(Unknown Source) ~[?:1.8.0_92]
16:38:31,805 INFO  [stdout] (Thread-89)     at sun.rmi.server.MarshalInputStream.resolveProxyClass(Unknown Source) ~[?:?]
16:38:31,805 INFO  [stdout] (Thread-89)     at java.io.ObjectInputStream.readProxyDesc(Unknown Source) ~[?:1.8.0_92]
16:38:31,805 INFO  [stdout] (Thread-89)     at java.io.ObjectInputStream.readClassDesc(Unknown Source) ~[?:1.8.0_92]
16:38:31,805 INFO  [stdout] (Thread-89)     at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source) ~[?:1.8.0_92]
16:38:31,805 INFO  [stdout] (Thread-89)     at java.io.ObjectInputStream.readObject0(Unknown Source) ~[?:1.8.0_92]
16:38:31,806 INFO  [stdout] (Thread-89)     at java.io.ObjectInputStream.readObject(Unknown Source) ~[?:1.8.0_92]
16:38:31,806 INFO  [stdout] (Thread-89)     at sun.rmi.server.UnicastRef.unmarshalValue(Unknown Source) ~[?:?]
16:38:31,806 INFO  [stdout] (Thread-89)     at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source) ~[?:?]
16:38:31,806 INFO  [stdout] (Thread-89)     at sun.rmi.transport.Transport$1.run(Unknown Source) ~[?:?]
16:38:31,806 INFO  [stdout] (Thread-89)     at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_92]
16:38:31,807 INFO  [stdout] (Thread-89)     at sun.rmi.transport.Transport.serviceCall(Unknown Source) ~[?:?]
16:38:31,807 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source) ~[?:?]
16:38:31,807 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source) ~[?:?]
16:38:31,807 INFO  [stdout] (Thread-89)     at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source) ~[?:?]
16:38:31,808 INFO  [stdout] (Thread-89)     at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) ~[?:1.8.0_92]
16:38:31,808 INFO  [stdout] (Thread-89)     at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) ~[?:1.8.0_92]
16:38:31,808 INFO  [stdout] (Thread-89)     at java.lang.Thread.run(Unknown Source) ~[?:1.8.0_92]

From looking through other examples, I've noticed that other malformedurlexceptions either consist of no protocol or unknown exception c but the majority of them seem to arise from codebase setting issues, which I don't believe I have. Furthermore, I can't seem to find any mentions of vfs even being used with RMI. Any suggestions would be appreciated, thanks!


Solution

  • You are using vfs: somewhere in a java.rmi.server.codebase setting. You can only use protocols recognized by Java. Codebase URLs are almost invariably HTTP.