Uploaded image for project: 'RESTEasy'
  1. RESTEasy
  2. RESTEASY-2392 Complete Spring integration documentation
  3. RESTEASY-2428

create an example called `resteasy-spring-customized`

XMLWordPrintable

    • Icon: Sub-task Sub-task
    • Resolution: Done
    • Icon: Major Major
    • None
    • None
    • resteasy-examples
    • None

      In our document, the resteasy-spring section, it has described an advanced usage of the resteasy-spring method:

      If you do not use a Spring ContextLoaderListener to create your bean factories, then you can manually register the RESTEasy BeanFactoryPostProcessor by allocating an instance of the RESTEasy SpringBeanProcessor.
      
      You can obtain instances of a ResteasyProviderFactory and Registry from the ServletContext attributes.
      
      There is also a SpringBeanProcessorServletAware, that will automatically inject references to the Registry and ResteasyProviderFactory from the ServletContext. That is, if you have used RestasyBootstrap to bootstrap Resteasy.
      
      Our Spring integration supports both singletons and the "prototype" scope. RESTEasy handles injecting @Context references. Constructor injection is not supported though. Also, with the "prototype" scope, RESTEasy will inject any @*Param annotated fields or setters before the request is dispatched.
      
      NOTE: You can only use auto-proxied beans with our base Spring integration. You will have undesirable affects if you are doing handcoded proxying with Spring, i.e., with ProxyFactoryBean. If you are using auto-proxied beans, you will be ok.
      

      And we need to create an example to match the document.

              weli@redhat.com Weinan Li
              weli@redhat.com Weinan Li
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: