Anonymous | Login | Signup for a new account | 12-09-2024 14:41 PST |
Main | My View | View Issues | Change Log | Docs |
Viewing Issue Simple Details [ Jump to Notes ] | [ View Advanced ] [ Issue History ] [ Print ] | |||||||||||
ID | Category | Severity | Reproducibility | Date Submitted | Last Update | |||||||
0003341 | [Hessian] | major | always | 02-13-09 11:45 | 03-01-09 13:47 | |||||||
Reporter | everflux | View Status | public | |||||||||
Assigned To | ||||||||||||
Priority | normal | Resolution | open | |||||||||
Status | new | Product Version | 3.2.1 | |||||||||
Summary | 0003341: hessian 3.2.1 does not work with phphessian while hessian 3.1.6 does | |||||||||||
Description |
Using phphessian to create a hessian service in php and calling from java (groovy) it does not work using hessian-3.2.1.jar If using hessian-3.1.6.jar the very same application works. |
|||||||||||
Additional Information |
using phphessian this is the sample service <?php include_once 'HessianPHP/dist/HessianService.php'; $wrapper = &new HessianService(); //enable method browsing with http get $wrapper->setDisplayInfo(true); $wrapper->registerObject(new Demo()); $wrapper->service(); class Demo { function run($n1,$n2) { $result = ""; $result .= "hello $n1 $n2"; return $result; } function arrayResult($n1, $n2) { $result = array(); $result[0] = $n1; $result[1] = strlen($n1); $result[2] = $n2; $result[3] = strlen($n1); return $result; } function objectResult($n1, $n2) { $result; $result->nameOne = $n1; $result->nameTwo = $n2; return $result; } } ?> this is the call in groovy import com.caucho.hessian.client.HessianProxyFactory; def n1='tkruse' def n2='muenster' url ="http://localhost/~tkruse/hessianRules/server.php" [^] HessianProxyFactory factory = new HessianProxyFactory(); //factory.setDebug(true); factory.setChunkedPost(false); service = factory.create(DemoInterface.class, url); println (service.run(n1, n2)) service.arrayResult(n1, n2).each{println "entry: " + it} When having the debug mode on, it looks like there is something swallowing the first byte containing "r", so hessian does not recognize the response correctly: Exception in thread "main" com.caucho.hessian.client.HessianRuntimeException: com.caucho.hessian.io.HessianProtocolException: expected hessian reply at 0x1 () at com.caucho.hessian.client.HessianProxy.invoke(HessianProxy.java:258) at $Proxy0.run(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) Having a look on a tcpdump everything looks correctly. Since changeing just the hessian jar solves this issue there seems something changed between them. |
|||||||||||
Attached Files | ||||||||||||
|
Mantis 1.0.0rc3[^]
Copyright © 2000 - 2005 Mantis Group
33 total queries executed. 27 unique queries executed. |