You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Vassilis Virvilis <v....@biovista.com> on 2018/11/21 13:39:15 UTC

cxf jaxrs Manually configure of ServiceClass

Hi,

I am not using Spring

I am interested in manually configuring individual serviceClasses (i.e. for adding Providers per serviceClass).

This is possible with spring but looks impossible without spring.

Is there a way to do it?

I tried to access the Endpoints/ServiceClasses after they have been loaded as specified in web.xml but failed.

Do I need to launch my own JaxRsFactoryBean?

Vassilis


Re: cxf jaxrs Manually configure of ServiceClass

Posted by Vassilis Virvilis <v....@biovista.com>.
Thanks for the pointer.

Looks like I have to do my own JAXRSServerFactoryBean.

Looks like the objects coming out of this factory are immutable because I cannot find a way to configure a Server(of serviceClass) __after__ it has been created by web.xml parsing. All the options are on the factory and not at the serviceClass server object.

Again thanks for the quick reply.

   Vassilis

On 11/21/18 3:47 PM, James Carman wrote:
> It is indeed possible:
> 
> https://github.com/jaxxy-rs/jaxxy/blob/master/test/src/main/java/org/jaxxy/test/JaxrsTestCase.java
> 
> This should give you enough inspiration for what you're trying to do.
> On Wed, Nov 21, 2018 at 8:39 AM Vassilis Virvilis
> <v....@biovista.com> wrote:
>>
>> Hi,
>>
>> I am not using Spring
>>
>> I am interested in manually configuring individual serviceClasses (i.e. for adding Providers per serviceClass).
>>
>> This is possible with spring but looks impossible without spring.
>>
>> Is there a way to do it?
>>
>> I tried to access the Endpoints/ServiceClasses after they have been loaded as specified in web.xml but failed.
>>
>> Do I need to launch my own JaxRsFactoryBean?
>>
>> Vassilis
>>
> 

Re: cxf jaxrs Manually configure of ServiceClass

Posted by James Carman <ja...@carmanconsulting.com>.
It is indeed possible:

https://github.com/jaxxy-rs/jaxxy/blob/master/test/src/main/java/org/jaxxy/test/JaxrsTestCase.java

This should give you enough inspiration for what you're trying to do.
On Wed, Nov 21, 2018 at 8:39 AM Vassilis Virvilis
<v....@biovista.com> wrote:
>
> Hi,
>
> I am not using Spring
>
> I am interested in manually configuring individual serviceClasses (i.e. for adding Providers per serviceClass).
>
> This is possible with spring but looks impossible without spring.
>
> Is there a way to do it?
>
> I tried to access the Endpoints/ServiceClasses after they have been loaded as specified in web.xml but failed.
>
> Do I need to launch my own JaxRsFactoryBean?
>
> Vassilis
>