I successfully tested an RMI invocation through Spring on a weblogic server, like this:
Code:<bean id="roleService" class="org.springframework.remoting.rmi.RmiProxyFactoryBean"> <property name="serviceUrl" value="rmi://someHost:1099/RoleService"/> <property name="serviceInterface" value="com.foo.service.role.RoleService"/> </bean>
Next, I'm wondering if it's possible to do RMI over HTTP with Spring on both server and client. Looking at some old weblogic documentation online, they state you can just change the rmi: to be http:, and weblogic will route the request over HTTP. I tried that out of curiosity by simply editing the serviceUrl property, but got the following MalformedUrlException:
Before I trudge further down that path, does anyone know if it's possible and easy enough to enable RMI over HTTP using Spring and weblogic?Code:ava.net.MalformedURLException: invalid URL scheme: http://PCSHPQL0050537/RoleService at java.rmi.Naming.parseURL(Ljava.lang.String;)Ljava.rmi.Naming$ParsedNamingURL;(Naming.java:233) at java.rmi.Naming.lookup(Ljava.lang.String;)Ljava.rmi.Remote;(Naming.java:79) at org.springframework.remoting.rmi.RmiClientInterceptor.lookupStub()Ljava.rmi.Remote;(RmiClientInterceptor.java:156)
p.s. I know there are other easier options for communication over HTTP, but I'm forced to evaluate RMI for my current problem.
Thanks,
Dan


Reply With Quote