Uploaded image for project: 'Spring BlazeDS Integration'
  1. Spring BlazeDS Integration
  2. FLEX-129

Support for Message Interceptor for Spring LCDS

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Blocker
    • Resolution: Deferred
    • Affects Version/s: 1.0.2
    • Fix Version/s: None
    • Component/s: LCDS
    • Labels:
      None

      Description

      Hi all,

      We are working to introduce the Message interceptor functionality in an app build with LCDS and Spring. Below are the steps did to achieve this
      1. Added the org.springframework.flex-1.0.2.RELEASE.jar
      2. Replaced the MessageBrokerServlet with DispatcherServlet to handle /messagebroker/*
      3. added <flex:message-broker .. and related interceptor bean to intercept the request in preProcess().

      But i am getting an exception while starting the server as shown below..
      Also tried the dirty solution in the nelow link but not successful

      http://jira.springframework.org/browse/FLEX-28

      -----------------------------------------------------
      [3/16/10 8:54:27:969 EDT] 00000021 ServletWrappe E SRVE0100E: Did not realize init() exception thrown by servlet Spring MVC Dispatcher Servlet: org.springframework.beans.factory.BeanCreationException: Error creating bean with name '_messageBroker': Instantiation of bean failed; nested exception is java.lang.LinkageError: LinkageError while defining class: org.springframework.flex.config.FlexConfigurationManager
      Could not be defined due to: flex.messaging.config.ConfigurationManager
      This is often caused by having a class defined at multiple locations within the classloader hierarchy. Other potential causes include compiling against an older or newer version of the class that has an incompatible method signature.
      Dumping the current context classloader hierarchy:
      ==> indicates defining classloader
      ==>[0]
      [email protected]
      PARENT_FIRST
      [2] [email protected]
      [3] [email protected]
      [4] [email protected]861c8
      [5] [email protected]
      [6] [email protected]
      --Original exception--
      java.lang.IncompatibleClassChangeError: flex.messaging.config.ConfigurationManager
      at java.lang.ClassLoader.defineClassImpl(Native Method)
      at java.lang.ClassLoader.defineClass(ClassLoader.java:222)
      at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:148)
      at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java:526)
      at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java:477)
      at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:373)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:561)
      at java.lang.J9VMInternals.verifyImpl(Native Method)
      at java.lang.J9VMInternals.verify(J9VMInternals.java:59)
      at java.lang.J9VMInternals.initialize(J9VMInternals.java:120)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:67)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:521)
      at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:100)
      at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:61)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:877)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:839)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.getSingletonFactoryBeanForTypeCheck(AbstractAutowireCapableBeanFactory.java:682)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.getTypeForFactoryBean(AbstractAutowireCapableBeanFactory.java:614)
      at org.springframework.beans.factory.support.AbstractBeanFactory.getType(AbstractBeanFactory.java:493)
      at org.springframework.flex.config.RemotingAnnotationPostProcessor.findRemotingDestinations(RemotingAnnotationPostProcessor.java:151)
      at org.springframework.flex.config.RemotingAnnotationPostProcessor.postProcessBeanFactory(RemotingAnnotationPostProcessor.java:79)
      at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:553)
      at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:544)
      at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:362)
      at org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:402)
      at org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext(FrameworkServlet.java:316)
      at org.springframework.web.servlet.FrameworkServlet.initServletBean(FrameworkServlet.java:282)
      at org.springframework.web.servlet.HttpServletBean.init(HttpServletBean.java:126)
      at javax.servlet.GenericServlet.init(GenericServlet.java:256)
      at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:185)
      at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.init(ServletWrapper.java:316

      Any solution to resolve this..

      Thanks in advance.
      Pol User

        Activity

        Hide
        jeremyg484 Jeremy Grelle added a comment -

        Can you provide some more details about your environment? It looks like you're running on Websphere...what version? How have you set up the classloader hierarchy? What version of LCDS, exactly? Have you tried deploying the Test Drive in your environment?

        Show
        jeremyg484 Jeremy Grelle added a comment - Can you provide some more details about your environment? It looks like you're running on Websphere...what version? How have you set up the classloader hierarchy? What version of LCDS, exactly? Have you tried deploying the Test Drive in your environment?
        Hide
        poluser Pol User added a comment -

        Yes we are running the test application on Websphere application server version - 6.1.0.2
        The classloader setup is default - PARENT_FIRST (Classes loaded with parent class loader first)
        We are using LCDS 3 (LCDS - ES) trial version
        We have deployed the test application in our local websphere environment.
        FYI, we are trying to configure a custom message interceptor (org.springframework.flex.core.MessageInterceptor interface) using Spring flex and LCDS. This test drive worked well with BlazeDS classes, but when we used LCDS classes in the place of BlazeDS (with the dirty solution mentioned in http://jira.springframework.org/browse/FLEX-28), we are having issues during application start-up.

        Thank you for looking into it. Let us know if you need more information.

        Show
        poluser Pol User added a comment - Yes we are running the test application on Websphere application server version - 6.1.0.2 The classloader setup is default - PARENT_FIRST (Classes loaded with parent class loader first) We are using LCDS 3 (LCDS - ES) trial version We have deployed the test application in our local websphere environment. FYI, we are trying to configure a custom message interceptor (org.springframework.flex.core.MessageInterceptor interface) using Spring flex and LCDS. This test drive worked well with BlazeDS classes, but when we used LCDS classes in the place of BlazeDS (with the dirty solution mentioned in http://jira.springframework.org/browse/FLEX-28 ), we are having issues during application start-up. Thank you for looking into it. Let us know if you need more information.
        Hide
        jeremyg484 Jeremy Grelle added a comment -

        Ok, can you try removing the workaround from FLEX-28 and using version 1.0.3?

        Show
        jeremyg484 Jeremy Grelle added a comment - Ok, can you try removing the workaround from FLEX-28 and using version 1.0.3?
        Hide
        poluser Pol User added a comment -

        We tried using following jars:
        > Spring2.5.jar
        > org.springframework.flex-1.0.3.RELEASE.jar
        > LCDS 3 (LCDS - ES) trial version
        > Websphere application server version - 6.1.0.2

        but still getting the same issue?

        Show
        poluser Pol User added a comment - We tried using following jars: > Spring2.5.jar > org.springframework.flex-1.0.3.RELEASE.jar > LCDS 3 (LCDS - ES) trial version > Websphere application server version - 6.1.0.2 but still getting the same issue?
        Hide
        jeremyg484 Jeremy Grelle added a comment -

        Deferred in preference for the integration work being done by the Adobe LCDS team.

        Show
        jeremyg484 Jeremy Grelle added a comment - Deferred in preference for the integration work being done by the Adobe LCDS team.

          People

          • Assignee:
            jeremyg484 Jeremy Grelle
            Reporter:
            poluser Pol User
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: