hibernate - AMF message error java.io.EOFException implementing graniteDS -
hopefully can me this.
i'm working on project spring mvc + hibernate + tomcat 7 in backend , blazeds + cairngorm in frontend, , need migrate blazeds graniteds have :channel.connect.failed error netconnection.call.failed: http: status 500 when trying connect backend, , in tomcat console:
error amfmessagefilter:160 - amf message error java.io.eofexception @ java.io.datainputstream.readunsignedshort
i don't understand i'm missing here , i've been looking on internet , representative resources found ones: http://www.graniteds.org/public/docs/3.0.0/docs/reference/flex/en-us/html/index.html, http://narup.blogspot.com/2008/08/getting-started-project-graniteds-with.html
thanks in advance!
here web.xml
<?xml version="1.0" encoding="utf-8"?> <web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xsi:schemalocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4"> <context-param> <param-name>contextconfiglocation</param-name> <param-value>/web-inf/applicationcontext.xml</param-value> </context-param> <listener> <listener-class>com.bamboo.common.factory.log4jcontextlistener</listener-class> </listener> <!-- spring listener --> <listener> <listener-class>org.springframework.web.context.contextloaderlistener</listener- class> </listener> <!-- read services-config.xml file @ web application startup --> <listener> <listener-class>org.granite.config.graniteconfiglistener</listener-class> </listener> <!-- spring listener web-scopes (request, session) --> <listener> <listener-class> org.springframework.web.context.request.requestcontextlistener </listener-class> </listener> <!-- handle amf requests ([de]serialization) --> <filter> <filter-name>amfmessagefilter</filter-name> <filter-class>org.granite.messaging.webapp.amfmessagefilter</filter-class> </filter> <filter-mapping> <filter-name>amfmessagefilter</filter-name> <url-pattern>/graniteamf/*</url-pattern> </filter-mapping> <servlet> <servlet-name>dispatcher</servlet-name> <servlet-class> org.springframework.web.servlet.dispatcherservlet </servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>dispatcher</servlet-name> <url-pattern>*.do</url-pattern> </servlet-mapping> <!-- handle amf requests (execution) --> <servlet> <servlet-name>amfmessageservlet</servlet-name> <servlet-class>org.granite.messaging.webapp.amfmessageservlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>amfmessageservlet</servlet-name> <url-pattern>/graniteamf/*</url-pattern> </servlet-mapping> </web-app>
and services-config.xml
<?xml version="1.0" encoding="utf-8"?> <services-config> <services> <service-include file-path="remoting-config.xml" /> </services> <factories> <factory id="springfactory" class="org.granite.spring.springservicefactory" /> </factories> <channels> <channel-definition id="my-amf" class="mx.messaging.channels.amfchannel" > <endpoint url="http://{server.name}:{server.port}/{context.root}/graniteamf/amf" class="flex.messaging.endpoints.amfendpoint"/> </channel-definition> </channels> </services-config>
the remote-config.xml
<?xml version="1.0" encoding="utf-8"?> <service id="remoting-service" class="flex.messaging.services.remotingservice" messagetypes="flex.messaging.messages.remotingmessage" > <destination id="remoteobject-destination"> <channels> <channel ref="my-amf"/> </channels> <properties> <factory>springfactory</factory> <source>catalogfacade</source> <scope>application</scope> </properties> </destination> </service>
it seems have deserialization problem. stack says trying read unsigned short amf , can't stream has no more bytes read. (basically trying read more data amf contains) java classes , as3 classes not synchronised. did modify java classes , forgot regenerate as3 files granite plugin (or maven plugin)? adding field on java side without regenerating reason.
granite serialization system based on iexternalizable on as3 side: explicit (a huge difference blazeds can adapt data @ runtime , can convert type fields instance @ runtime).
check generation of as3 files , granite server configuration.
Comments
Post a Comment