title: REST service not being registered in Apache wink with Spring and Maven
body: <p>I have a Maven project with the dependencies listed below:</p>
  
  <p><img src="https://i.stack.imgur.com/ZTtSM.png" alt="enter image description here"></p>
  
  <p>wink.version = 1.1.3-incubating and spring.version = 3.0.5.RELEASE</p>
  
  <p>Application Context in Spring includes:</p>
  
  <pre><code>    &lt;bean class="org.apache.wink.spring.Registrar"&gt;
      &lt;property name="classes"&gt;
          &lt;set value-type="java.lang.Class"&gt;
          &lt;/set&gt;
      &lt;/property&gt;
      &lt;property name="instances"&gt;
          &lt;set&gt;
              &lt;ref local="restexample" /&gt;
          &lt;/set&gt;
      &lt;/property&gt;
      &lt;/bean&gt;
      &lt;bean id="restexample" class="com.example.rest.ExampleRest"&gt;&lt;/bean&gt;
  </code></pre>
  
  <p>web.xml includes:</p>
  
  <pre><code>&lt;context-param&gt;
      &lt;param-name&gt;contextConfigLocation&lt;/param-name&gt;
      &lt;param-value&gt;
          classpath:META-INF/wink/wink-core-context.xml
          classpath:applicationContext.xml
      &lt;/param-value&gt;
  &lt;/context-param&gt;
  
  &lt;listener&gt;
      &lt;listener-class&gt;org.springframework.web.context.ContextLoaderListener&lt;/listener-class&gt;
  &lt;/listener&gt;
  
  &lt;servlet&gt;
      &lt;servlet-name&gt;restServlet&lt;/servlet-name&gt;
      &lt;servlet-class&gt;org.apache.wink.server.internal.servlet.RestServlet&lt;/servlet-class&gt;
  &lt;/servlet&gt;
  
  &lt;servlet-mapping&gt;
      &lt;servlet-name&gt;restServlet&lt;/servlet-name&gt;
      &lt;url-pattern&gt;/rest/*&lt;/url-pattern&gt;
  &lt;/servlet-mapping&gt;
  </code></pre>
  
  <p>Rest Java Class includes:</p>
  
  <pre><code>@Path("/ex")
  public class ExampleRest {
  
      @GET
      @Produces(MediaType.APPLICATION_JSON)
      public String example() throws IOException {
          return "{ 'id':'test' }";
      }
  }
  </code></pre>
  
  <hr>
  
  <p>Looking at the logs I don't see any exception or problem, the 'restexample' bean is being created but... I get a <strong>404</strong> when I try to call the REST service.</p>
  
  <p>I think <strong>ExampleRest</strong> is not being registered by Apache Wink.</p>
  
  <p>Any idea ?</p>
  
  <p><strong>UPDATE 02/14</strong>:
  Loking at the logs, I noticed that ExampleRest is not being registered by Apache Wink. Maybe, the problem is within the beans declaration or maybe the dependencies that I'm using.
  I also set-up another project without spring and it works there. I really need Spring to use his IoD for daos and services.</p>