cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "JS Bournival (JIRA)" <j...@apache.org>
Subject [jira] Created: (CXF-2202) Deploying REST service on CXF Transport for OSGi
Date Tue, 05 May 2009 13:18:30 GMT
Deploying REST service on CXF Transport for OSGi
------------------------------------------------

                 Key: CXF-2202
                 URL: https://issues.apache.org/jira/browse/CXF-2202
             Project: CXF
          Issue Type: Bug
          Components: OSGi
    Affects Versions: 2.2
         Environment: ServiceMix
  ServiceMix home             /opt/servers/fuse-esb/fuse-esb-4.1.0.0
  ServiceMix base             /opt/servers/fuse-esb/fuse-esb-4.1.0.0
  ServiceMix Kernel version   1.1.0.0-fuse
  ServiceMix version          4.1.0.0-fuse

JVM
  Java Virtual Machine        Java HotSpot(TM) 64-Bit Server VM version 1.6.0_07-b06-57
  Vendor                      Apple Inc.
  Uptime                      4 days 45 hours
  Total compile time          22.997 seconds
Threads
  Live threads                79
  Daemon threads              37
  Peak                        223
  Total started               14328
Memory
  Current heap size           54,440 kbytes
  Maximum heap size           502,464 kbytes
  Committed heap size         125,952 kbytes
  Pending objects             0
  Garbage collector           Name = 'Copy', Collections = 475, Time = 1.654 seconds
  Garbage collector           Name = 'MarkSweepCompact', Collections = 34, Time = 51.343 seconds
Classes
  Current classes loaded      7,442
  Total classes loaded        7,598
  Total classes unloaded      156
Operating system
  Name                        Mac OS X version 10.5.6
  Architecture                x86_64
  Processors                  2

            Reporter: JS Bournival


 have a serious issue that I want to discuss.   

I am developing rest services osgi bundles on fuse4/smx4 using the cxf-osgi transport.  JAX-RS
impl is obviously CXF, which is fine.  But as I learned recently, I have to specify "/cxf"
as part of my implementation @Path annotation, like this: 

<code> 
@Path("/cxf/top10") 
public class TopTenRestService { 
  // methods 
} 
</code> 

I find this somewhat strange because it exposes (shall I say binds) the underlying JAX-RS
implementation to my service class, which is the complete opposite of what the JAX-RS spec
should provide. 

Again, maybe I just don't get it.  Using it this way actually works, but there's something
not right about how to specifiy the @Path. 

As a complement, here is my service configuration in my bundle' spring bean file:

<code> 
<import resource="classpath:META-INF/cxf/cxf.xml" /> 
<import resource="classpath:META-INF/cxf/cxf-extension-http.xml" /> 
<import resource="classpath:META-INF/cxf/cxf-extension-jaxrs-binding.xml"/> 
<import resource="classpath:META-INF/cxf/osgi/cxf-extension-osgi.xml" /> 

<jaxrs:server address="/top10"> 
        <jaxrs:serviceBeans> 
                <ref bean="topTenRestService" /> 
        </jaxrs:serviceBeans> 
</jaxrs:server> 

<bean id="topTenRestService" class="com.company.project.topten.TopTenRestService"></bean>

</code> 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message