Mantis - Resin
|
|||||
Viewing Issue Advanced Details | |||||
|
|||||
ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
2118 | feature | always | 10-26-07 09:51 | 11-01-07 15:07 | |
|
|||||
Reporter: | westrupp | Platform: | |||
Assigned To: | ferg | OS: | |||
Priority: | high | OS Version: | |||
Status: | closed | Product Version: | 3.1.3 | ||
Product Build: | Resolution: | fixed | |||
Projection: | none | ||||
ETA: | none | Fixed in Version: | 3.1.4 | ||
|
|||||
Summary: | 0002118: hessian serialization issue: ArrayList declared as Collection | ||||
Description: |
(rep by Daniel Spangler) // Bean to be serialized as a parameter to the service below. @Entity @Table(name="patient") public class Patient implements Serializable { ... @OneToMany(mappedBy="patient", fetch=FetchType.LAZY) private Collection<Order> orders = new ArrayList<Order>(); Serializing a Patient object to an EJB service as a parameter, causes the issue below. // EJB service @Stateless @Local(OrderSubmissionService.class) public class OrderSubmissionServiceBean implements OrderSubmissionService { // service with "Patient" as a parameter public Long createOrder(final Patient patient) throws ServiceException { ... } } In the Patient object the "orders" is an ArrayList and the target is java.util.Collection, which should work, but seems to be confusing Hessian for some reason. [16:19:08.734] FINE com.caucho.hessian.io.SerializerFactory hessian: expected 'java.util.Collection' at '' More info: [16:19:08.718] FINE com.caucho.server.http.HttpRequest Http[6] POST /pathwork-webapp-0.1-SNAPSHOT/hessian/ordersubmission HTTP/1.1 [16:19:08.718] FINE com.caucho.server.http.HttpRequest Http[6] Remote-IP: 127.0.0.1:2369 [16:19:08.718] FINE com.caucho.server.http.HttpRequest Http[6] Content-Type: x-application/hessian [16:19:08.718] FINE com.caucho.server.http.HttpRequest Http[6] User-Agent: Java/1.6.0_02 [16:19:08.718] FINE com.caucho.server.http.HttpRequest Http[6] Host: localhost:8080 [16:19:08.718] FINE com.caucho.server.http.HttpRequest Http[6] Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2 [16:19:08.718] FINE com.caucho.server.http.HttpRequest Http[6] Connection: keep-alive [16:19:08.718] FINE com.caucho.server.http.HttpRequest Http[6] Content-Length: 343 [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet call 1.0 [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet method "createOrder" [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet map com.amirsys.pathwork.entity.Patient(0) [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet "id" => null [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet "clientProvidedPatientId" => "MyId" [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet "firstName" => null [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet "lastName" => null [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet "ssn" => null [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet "nonExistentSSN" => null [16:19:08.718] [16:19:08.718] FINE com.caucho.hessian.server.HessianServlet "sex" => null [16:19:08.718] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "middleInitial" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "homePhone" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "workPhone" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "workExt" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "mobilePhone" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "dob" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "address" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "orders" => list (0000001) [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.io.SerializerFactory hessian: expected 'java.util.Collection' at '' [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet 0: map com.amirsys.pathwork.entity.Order(0000002) [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "id" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "finalDiagnosis" => null [16:19:08.734] [16:19:08.734] FINE com.caucho.hessian.server.HessianServlet "patient" => null [16:19:08.734] |
||||
Steps To Reproduce: | |||||
Additional Information: | |||||
Relationships | |||||
Attached Files: |
Notes | |||||
|
|||||
|
|