cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sergey Beryozkin <sberyoz...@gmail.com>
Subject Re: How to generate WADL on "root" of controller, not just with "?_wadl"?
Date Tue, 07 Nov 2017 23:07:25 GMT
Can you try a breakpoint at

https://github.com/apache/cxf/blob/master/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/impl/RequestPreprocessor.java#L111

?

I'll try to get a test done (unless it's already there) in the next few days

Sergey

On 07/11/17 17:52, KARR, DAVID wrote:
>> -----Original Message-----
>> From: Sergey Beryozkin [mailto:sberyozkin@gmail.com]
>> Sent: Tuesday, November 07, 2017 9:17 AM
>> To: users@cxf.apache.org
>> Subject: Re: How to generate WADL on "root" of controller, not just with
>> "?_wadl"?
>>
>> Try
>> application/vnd.sun.wadl+xml
>> please.
> 
> Changed the entry to:
> -------
>      <entry key="wadl" value="application/vnd.sun.wadl+xml" />
> --------
> 
> Still doesn't work.  'http://localhost:8080/combinedAtgUslMonitorService.wadl' still
gets 404.  Changing ".wadl" to "?_wadl" works.
> 
>> On 07/11/17 16:43, KARR, DAVID wrote:
>>>> -----Original Message-----
>>>> From: Sergey Beryozkin [mailto:sberyozkin@gmail.com]
>>>> Sent: Tuesday, November 07, 2017 3:16 AM
>>>> To: users@cxf.apache.org
>>>> Subject: Re: How to generate WADL on "root" of controller, not just
>>>> with "?_wadl"?
>>>>
>>>> Hi David
>>>>
>>>> I looked at the code, I think you can add a '.wadl' to the path
>>>> instead
>>>> - and for this to work at the server it requires an extensionMappings
>>>> map property to have a "wadl":"application/wadl" pair
>>>
>>> If that could work, it's still not quite what I'm looking for, but it
>> would be marginally better.  However, it doesn't appear to work.
>>>
>>> I changed my extensionMappings block to this:
>>> -------------
>>> 	   <jaxrs:extensionMappings>
>>>               <entry key="json" value="application/json" />
>>>               <entry key="xml" value="application/xml" />
>>>               <entry key="wadl" value="application/wadl" />
>>> 	   </jaxrs:extensionMappings>
>>> -------------
>>>
>>> I restarted the app.
>>>
>>> I ran "curl
>> 'http://localhost:8080/combinedAtgUslMonitorService.wadl'", which
>> returned a 404.
>>>
>>> I retested the normal "curl
>> 'http://localhost:8080/combinedAtgUslMonitorService/?_wadl&_type=json'",
>> and that worked fine.
>>>
>>>> On 06/11/17 22:54, KARR, DAVID wrote:
>>>>> I managed to add the 'cxf-rt-rs-service-description' artifact to my
>>>> build, so that I get the WADL when I add "?_wadl" to my URL.  I'd
>>>> actually like to make it return the WADL when I just try to access
>>>> the "root" of the controller, without having to add the "?_wadl"
>> string.
>>>> This feels like a more natural way of exploring the service, like
>>>> running a Linux command in bash without any parameters to have it
>>>> tell me what the options are.
>>>>>

Mime
View raw message