How to configure a restful service into fuse.
himanshu.sinha Apr 13, 2015 4:09 AMHi Everyone!!
I'm following below link to develop a restful webservices into fuse-
http://www.jboss.org/quickstarts/fuse/rest/#system-requirements
I've created one package inside /rest folder which contains my service and doing mvn clean install,
but while -features:install quickstart-rest ,I'm getting below error.
JBossFuse:karaf@root> features:install quickstart-rest
Error executing command: Can not resolve feature:
Unsatisfied requirement(s):
---------------------------
package:(&(package=com.comcast.demo.service))
JBoss Fuse :: Examples :: RESTful WebService
Please note-My blueprint.xml and feature.xml are as follows --
<?xml version="1.0" encoding="UTF-8"?>
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:jaxrs="http://cxf.apache.org/blueprint/jaxrs"
xmlns:cxf="http://cxf.apache.org/blueprint/core"
xsi:schemaLocation="
http://www.osgi.org/xmlns/blueprint/v1.0.0 http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
http://cxf.apache.org/blueprint/jaxrs http://cxf.apache.org/schemas/blueprint/jaxrs.xsd
http://cxf.apache.org/blueprint/core http://cxf.apache.org/schemas/blueprint/core.xsd">
<jaxrs:server id="customerService" address="/crm">
<jaxrs:serviceBeans>
<ref component-id="customerSvc"/>
</jaxrs:serviceBeans>
<jaxrs:features>
<bean class="org.apache.cxf.jaxrs.swagger.SwaggerFeature"/>
</jaxrs:features>
<jaxrs:providers>
<bean class="com.fasterxml.jackson.jaxrs.json.JacksonJsonProvider"/>
</jaxrs:providers>
</jaxrs:server>
<jaxrs:server id="fuseServiceIntegration" address="/crm">
<jaxrs:serviceBeans>
<ref component-id="fuseService"/>
</jaxrs:serviceBeans>
<jaxrs:features>
<bean class="org.apache.cxf.jaxrs.swagger.SwaggerFeature"/>
</jaxrs:features>
<jaxrs:providers>
<bean class="com.fasterxml.jackson.jaxrs.json.JacksonJsonProvider"/>
</jaxrs:providers>
</jaxrs:server>
<cxf:bus>
<cxf:features>
<cxf:logging />
</cxf:features>
</cxf:bus>
<bean id="customerSvc" class="org.jboss.quickstarts.fuse.rest.CustomerService"/>
<bean id="fuseService" class="com.comcast.demo.service.Controller"/>
</blueprint>
<?xml version="1.0" encoding="UTF-8"?>
<features name="quickstart-rest-6.1.0.redhat-379"
xmlns="http://karaf.apache.org/xmlns/features/v1.0.0">
<repository>mvn:org.apache.cxf.karaf/apache-cxf/2.7.0.redhat-610379/xml/features</repository>
<repository>mvn:io.fabric8/fabric8-karaf/1.0.0.redhat-379/xml/features</repository>
<feature name="quickstart-rest" version="6.1.0.redhat-379" resolver="(obr)">
<feature version="1.0.0.redhat-379">swagger</feature>
<feature version="${cxf-version-range}">cxf-jaxrs</feature>
<bundle>mvn:org.jboss.quickstarts.fuse/rest/6.1.0.redhat-379</bundle>
</feature>
</features>