残り-server.xml:
<jaxrs:server id="baseApi" address="http://localhost:8080/myfashions/catalog">
<jaxrs:serviceBeans>
<bean class="com.myfashions.api.service.rest.implementation.CatalogServiceImpl"/>
</jaxrs:serviceBeans>
<jaxrs:providers>
<ref bean="customRequestHandler"/>
<ref bean="customResponseHandler"/>
<ref bean="restExceptionMapper"/>
<bean class="org.codehaus.jackson.jaxrs.JacksonJaxbJsonProvider"/>
</jaxrs:providers>
</jaxrs:server>
インターフェース:
public interface CatalogService {
@Path("/categories")
@GET
@Produces({MediaType.APPLICATION_JSON})
SelectCategoryBeanList getMyfashionCategories();
}
クラス:
@Service
@Path("/myfashions/catalog")
public class CatalogServiceImpl implements CatalogService {
@Override
public SelectCategoryBeanList getMyfashionCategories() {
...
...
}
}
を呼び出したhttp://localhost:8080/myfashions/catalog/categories
ところ、No root resource matching request path /myfashions/catalog/categories
has been found, Relative Path: /categories
exception. というメッセージが表示されました。誰でもこれについて私を助けることができますか?