You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by nino martinez wael <ni...@gmail.com> on 2017/06/14 12:58:35 UTC

Re: DOSGI 2 prefered documentation technique?

Hi Christian,

I seem to remember that I can get the SWAGGER UI bundled together with the
DOSGI app. But cannot remember the url I have tried with appending api-docs
to my resource url. But it isnt working.

My swagger.json are generated correctly..But does not link to the swagger
ui document.

BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?


On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <sb...@gmail.com>
wrote:

> According to
> https://issues.apache.org/jira/browse/CXF-7347
>
> it is a SwaggerUI 3 refactoring related issue...
> keep working with Swagger 2 UI for the moment
>
> Thanks, Sergey
>
>
> On 24/04/17 05:52, Christian Schneider wrote:
>
>> I also had this problem but was not able to pin it down to the missing
>> host. ( I am not very familiar with swagger).
>> Based on your findings I hope e can find a good solution to this.
>>
>> Can you post your code for the CustomSwagger2Serializers. If you wat you
>> can also create a PR in cxf to fix the issue.
>>
>> Christian
>>
>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>
>> Hi sorry to resurrect this thread but I've a similar problem which was not
>>> completely solved with this approach,
>>>
>>> First I've managed to make dosgi work with swagger with a:
>>>
>>>                 setScan(false);
>>>                 setUsePathBasedConfig(true);
>>>
>>> in the swagger feature. It all works well except the "Try it out" of the
>>> swagger ui. I'm using the latest version (mvn:org.webjars/swagger-ui/3.
>>> 0.5)
>>> and I've noticed that in the swagger.json the host is not filled. This
>>> host
>>> is used to build the url. The cxf feature does not set the host no matter
>>> what I do or change.
>>>
>>> I ended up hammering an ugly solution by setting a custom swagger2
>>> serializer
>>>
>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>
>>> where I'm able to extract the servlet request thus setting the host:port
>>>
>>> I'm I missing something here or this is indeed a problema at least with
>>> the
>>> latest swagger ui version (It seems odd also that the swagger 2 ui does
>>> no
>>> use by default the current url but it didn't work in my tests) ?
>>>
>>> Tnks,
>>> Ivo Leitão
>>>
>>>
>>>
>>> --
>>> View this message in context: http://cxf.547215.n5.nabble.
>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p5779847.html
>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>
>>>
>>
>>
>>
>
> --
> Sergey Beryozkin
>
> Talend Community Coders
> http://coders.talend.com/
>



-- 
Best regards / Med venlig hilsen
Nino Martinez

Re: DOSGI 2 prefered documentation technique?

Posted by Sergey Beryozkin <sb...@gmail.com>.
So why is the root not found ? I can only imagine Swagger Ui is not 
installed...

Sergey
On 22/06/17 13:07, nino martinez wael wrote:
> Sorry I was wrong it is 3.1.11..
> 
> On Wed, Jun 21, 2017 at 4:38 PM, Sergey Beryozkin <sb...@gmail.com>
> wrote:
> 
>> It needs to be CXF 3.1.11 - it is used with the latest DOSGi2 release
>>
>> Sergey
>>
>> On 21/06/17 14:37, nino martinez wael wrote:
>>
>>> IT does look like the project are using CXF-core 3.0.2 , but 3.1.9 of the
>>> swagger cxf module.. would that be a problme?
>>>
>>> On Wed, Jun 21, 2017 at 3:35 PM, nino martinez wael <
>>> nino.martinez.wael@gmail.com> wrote:
>>>
>>> SwaggerUIVersion ends up being null. It goes through all the checks.. Do I
>>>> need to declare that version somewhere?
>>>>
>>>> On Wed, Jun 21, 2017 at 3:18 PM, nino martinez wael <
>>>> nino.martinez.wael@gmail.com> wrote:
>>>>
>>>> Yes I will try so.. ASAP..
>>>>>
>>>>> -Thanks
>>>>>
>>>>> On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <
>>>>> sberyozkin@gmail.com>
>>>>> wrote:
>>>>>
>>>>> Hi
>>>>>>
>>>>>> Can you put a breakpoint here:
>>>>>>
>>>>>> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
>>>>>> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiS
>>>>>> waggerUiResolver.java#L38
>>>>>>
>>>>>> Cheers, Sergey
>>>>>>
>>>>>> On 16/06/17 07:13, nino martinez wael wrote:
>>>>>>
>>>>>> I think I need both..
>>>>>>>
>>>>>>> Problem are that I run into the CORS problem since we have begun to
>>>>>>> host
>>>>>>> our DOSGI service on another port, and the only way to get SWAGGER ui
>>>>>>> to
>>>>>>> function correctly would be to host it alongside the webservice..
>>>>>>>
>>>>>>> Did you try with an older release of swagger..? I just dont know what
>>>>>>> I
>>>>>>> need to add for CXF to activate swager ui, I've put in
>>>>>>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger
>>>>>>> swagger-ui
>>>>>>> activation as far as I can see, combined with supportSwaggerUi=true..
>>>>>>> But
>>>>>>> nothing shows up at my version of "http://host:port/context/services/
>>>>>>> api-docs?/url=/swagger.json"..
>>>>>>>
>>>>>>>
>>>>>>> Place I've looked:
>>>>>>> http://cxf.apache.org/docs/swagger2feature.html
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>>>>>>> chris@die-schneider.net> wrote:
>>>>>>>
>>>>>>> I worked on a better swagger integration a while ago but also failed
>>>>>>> at
>>>>>>>
>>>>>>>> the
>>>>>>>> UI. At that time I think it was an incompatibility of the cxf swagger
>>>>>>>> support with the new swagger versions.
>>>>>>>> There are some interesting enhancements in the current DOSGi master
>>>>>>>> so
>>>>>>>> we
>>>>>>>> could do a release soon.
>>>>>>>> It would be great to also include swagger support but I would also
>>>>>>>> not
>>>>>>>> mind
>>>>>>>> to move swagger support to 2.3.0.
>>>>>>>>
>>>>>>>> Christian
>>>>>>>>
>>>>>>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>>>>>>> nino.martinez.wael@gmail.com>
>>>>>>>> :
>>>>>>>>
>>>>>>>> Hi Christian,
>>>>>>>>
>>>>>>>>>
>>>>>>>>> I seem to remember that I can get the SWAGGER UI bundled together
>>>>>>>>> with
>>>>>>>>>
>>>>>>>>> the
>>>>>>>>
>>>>>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>>>>>>
>>>>>>>>> api-docs
>>>>>>>>
>>>>>>>> to my resource url. But it isnt working.
>>>>>>>>>
>>>>>>>>> My swagger.json are generated correctly..But does not link to the
>>>>>>>>> swagger
>>>>>>>>> ui document.
>>>>>>>>>
>>>>>>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>>>>>>> sberyozkin@gmail.com
>>>>>>>>>
>>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>> According to
>>>>>>>>>
>>>>>>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>>>>>>
>>>>>>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>>>>>>> keep working with Swagger 2 UI for the moment
>>>>>>>>>>
>>>>>>>>>> Thanks, Sergey
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>>>>>>
>>>>>>>>>> I also had this problem but was not able to pin it down to the
>>>>>>>>>>
>>>>>>>>>>> missing
>>>>>>>>>>> host. ( I am not very familiar with swagger).
>>>>>>>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>>>>>>>
>>>>>>>>>>> Can you post your code for the CustomSwagger2Serializers. If you
>>>>>>>>>>> wat
>>>>>>>>>>>
>>>>>>>>>>> you
>>>>>>>>>>
>>>>>>>>>
>>>>>>>> can also create a PR in cxf to fix the issue.
>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>> Christian
>>>>>>>>>>>
>>>>>>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>>>>>>
>>>>>>>>>>> Hi sorry to resurrect this thread but I've a similar problem which
>>>>>>>>>>> was
>>>>>>>>>>>
>>>>>>>>>>> not
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> completely solved with this approach,
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>>>>>>
>>>>>>>>>>>>                    setScan(false);
>>>>>>>>>>>>                    setUsePathBasedConfig(true);
>>>>>>>>>>>>
>>>>>>>>>>>> in the swagger feature. It all works well except the "Try it out"
>>>>>>>>>>>> of
>>>>>>>>>>>>
>>>>>>>>>>>> the
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>> swagger ui. I'm using the latest version
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> 0.5)
>>>>>>>>>
>>>>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>>>>>>
>>>>>>>>>>>> This
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> host
>>>>>>>>>
>>>>>>>>>> is used to build the url. The cxf feature does not set the host no
>>>>>>>>>>>>
>>>>>>>>>>>> matter
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>> what I do or change.
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>> I ended up hammering an ugly solution by setting a custom
>>>>>>>>>>>> swagger2
>>>>>>>>>>>> serializer
>>>>>>>>>>>>
>>>>>>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>>>>>>
>>>>>>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>>>>>>
>>>>>>>>>>>> host:port
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>> I'm I missing something here or this is indeed a problema at least
>>>>>>>>>>>>
>>>>>>>>>>>> with
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> the
>>>>>>>>>
>>>>>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>>>>>>>>>>>>
>>>>>>>>>>>> does
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> no
>>>>>>>>>
>>>>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>>>>>>
>>>>>>>>>>>> Tnks,
>>>>>>>>>>>> Ivo Leitão
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p57798
>>>>>>>>>>>> 47.html
>>>>>>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>> Sergey Beryozkin
>>>>>>>>>>
>>>>>>>>>> Talend Community Coders
>>>>>>>>>> http://coders.talend.com/
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Best regards / Med venlig hilsen
>>>>>>>>> Nino Martinez
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> --
>>>>>>>> Christian Schneider
>>>>>>>> http://www.liquid-reality.de
>>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>>> 2bd062c5a7e
>>>>>>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>>>>>>
>>>>>>>> Open Source Architect
>>>>>>>> http://www.talend.com
>>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>>> 2bd062c5a7e
>>>>>>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>
>>>>> --
>>>>> Best regards / Med venlig hilsen
>>>>> Nino Martinez
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best regards / Med venlig hilsen
>>>> Nino Martinez
>>>>
>>>>
>>>
>>>
>>>
>>
>> --
>> Sergey Beryozkin
>>
>> Talend Community Coders
>> http://coders.talend.com/
>>
> 
> 
> 


-- 
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Re: DOSGI 2 prefered documentation technique?

Posted by nino martinez wael <ni...@gmail.com>.
I got it working, it was because of the old cxf core version...

Thanks for the help :)

On Thu, Jun 22, 2017 at 2:10 PM, Sergey Beryozkin <sb...@gmail.com>
wrote:

> May be it is installed after the checks are done ?
>
>
> On 22/06/17 13:08, nino martinez wael wrote:
>
>> I've put this in my feature file: <bundle>
>> wrap:mvn:org.webjars/swagger-ui/2.2.10</bundle>
>>
>> On Thu, Jun 22, 2017 at 2:07 PM, nino martinez wael <
>> nino.martinez.wael@gmail.com> wrote:
>>
>> Sorry I was wrong it is 3.1.11..
>>>
>>> On Wed, Jun 21, 2017 at 4:38 PM, Sergey Beryozkin <sb...@gmail.com>
>>> wrote:
>>>
>>> It needs to be CXF 3.1.11 - it is used with the latest DOSGi2 release
>>>>
>>>> Sergey
>>>>
>>>> On 21/06/17 14:37, nino martinez wael wrote:
>>>>
>>>> IT does look like the project are using CXF-core 3.0.2 , but 3.1.9 of
>>>>> the
>>>>> swagger cxf module.. would that be a problme?
>>>>>
>>>>> On Wed, Jun 21, 2017 at 3:35 PM, nino martinez wael <
>>>>> nino.martinez.wael@gmail.com> wrote:
>>>>>
>>>>> SwaggerUIVersion ends up being null. It goes through all the checks..
>>>>> Do
>>>>>
>>>>>> I
>>>>>> need to declare that version somewhere?
>>>>>>
>>>>>> On Wed, Jun 21, 2017 at 3:18 PM, nino martinez wael <
>>>>>> nino.martinez.wael@gmail.com> wrote:
>>>>>>
>>>>>> Yes I will try so.. ASAP..
>>>>>>
>>>>>>>
>>>>>>> -Thanks
>>>>>>>
>>>>>>> On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <
>>>>>>> sberyozkin@gmail.com>
>>>>>>> wrote:
>>>>>>>
>>>>>>> Hi
>>>>>>>
>>>>>>>>
>>>>>>>> Can you put a breakpoint here:
>>>>>>>>
>>>>>>>> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
>>>>>>>> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiS
>>>>>>>> waggerUiResolver.java#L38
>>>>>>>>
>>>>>>>> Cheers, Sergey
>>>>>>>>
>>>>>>>> On 16/06/17 07:13, nino martinez wael wrote:
>>>>>>>>
>>>>>>>> I think I need both..
>>>>>>>>
>>>>>>>>>
>>>>>>>>> Problem are that I run into the CORS problem since we have begun to
>>>>>>>>> host
>>>>>>>>> our DOSGI service on another port, and the only way to get SWAGGER
>>>>>>>>> ui to
>>>>>>>>> function correctly would be to host it alongside the webservice..
>>>>>>>>>
>>>>>>>>> Did you try with an older release of swagger..? I just dont know
>>>>>>>>> what I
>>>>>>>>> need to add for CXF to activate swager ui, I've put in
>>>>>>>>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger
>>>>>>>>> swagger-ui
>>>>>>>>> activation as far as I can see, combined with
>>>>>>>>> supportSwaggerUi=true..
>>>>>>>>> But
>>>>>>>>> nothing shows up at my version of "http://host:port/context/serv
>>>>>>>>> ices/
>>>>>>>>> api-docs?/url=/swagger.json"..
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Place I've looked:
>>>>>>>>> http://cxf.apache.org/docs/swagger2feature.html
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>>>>>>>>> chris@die-schneider.net> wrote:
>>>>>>>>>
>>>>>>>>> I worked on a better swagger integration a while ago but also
>>>>>>>>> failed
>>>>>>>>> at
>>>>>>>>>
>>>>>>>>> the
>>>>>>>>>> UI. At that time I think it was an incompatibility of the cxf
>>>>>>>>>> swagger
>>>>>>>>>> support with the new swagger versions.
>>>>>>>>>> There are some interesting enhancements in the current DOSGi
>>>>>>>>>> master
>>>>>>>>>> so
>>>>>>>>>> we
>>>>>>>>>> could do a release soon.
>>>>>>>>>> It would be great to also include swagger support but I would also
>>>>>>>>>> not
>>>>>>>>>> mind
>>>>>>>>>> to move swagger support to 2.3.0.
>>>>>>>>>>
>>>>>>>>>> Christian
>>>>>>>>>>
>>>>>>>>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>>>>>>>>> nino.martinez.wael@gmail.com>
>>>>>>>>>> :
>>>>>>>>>>
>>>>>>>>>> Hi Christian,
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>> I seem to remember that I can get the SWAGGER UI bundled together
>>>>>>>>>>> with
>>>>>>>>>>>
>>>>>>>>>>> the
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> api-docs
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> to my resource url. But it isnt working.
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> My swagger.json are generated correctly..But does not link to the
>>>>>>>>>>> swagger
>>>>>>>>>>> ui document.
>>>>>>>>>>>
>>>>>>>>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>>>>>>>>> sberyozkin@gmail.com
>>>>>>>>>>>
>>>>>>>>>>> wrote:
>>>>>>>>>>>
>>>>>>>>>>> According to
>>>>>>>>>>>
>>>>>>>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>>>>>>>>
>>>>>>>>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>>>>>>>>> keep working with Swagger 2 UI for the moment
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks, Sergey
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> I also had this problem but was not able to pin it down to the
>>>>>>>>>>>>
>>>>>>>>>>>> missing
>>>>>>>>>>>>> host. ( I am not very familiar with swagger).
>>>>>>>>>>>>> Based on your findings I hope e can find a good solution to
>>>>>>>>>>>>> this.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Can you post your code for the CustomSwagger2Serializers. If
>>>>>>>>>>>>> you
>>>>>>>>>>>>> wat
>>>>>>>>>>>>>
>>>>>>>>>>>>> you
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>> can also create a PR in cxf to fix the issue.
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>> Christian
>>>>>>>>>>>>>
>>>>>>>>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>>>>>>>>
>>>>>>>>>>>>> Hi sorry to resurrect this thread but I've a similar problem
>>>>>>>>>>>>> which
>>>>>>>>>>>>> was
>>>>>>>>>>>>>
>>>>>>>>>>>>> not
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>> completely solved with this approach,
>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                    setScan(false);
>>>>>>>>>>>>>>                    setUsePathBasedConfig(true);
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> in the swagger feature. It all works well except the "Try it
>>>>>>>>>>>>>> out"
>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>> swagger ui. I'm using the latest version
>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>> 0.5)
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>> This
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>> host
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> is used to build the url. The cxf feature does not set the host
>>>>>>>>>>>> no
>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>> matter
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>> what I do or change.
>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>> I ended up hammering an ugly solution by setting a custom
>>>>>>>>>>>>>> swagger2
>>>>>>>>>>>>>> serializer
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> host:port
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>> I'm I missing something here or this is indeed a problema at
>>>>>>>>>>>> least
>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>> with
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>> the
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> latest swagger ui version (It seems odd also that the swagger 2
>>>>>>>>>>>> ui
>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>> does
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>> no
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Tnks,
>>>>>>>>>>>>>> Ivo Leitão
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>>>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p57798
>>>>>>>>>>>>>> 47.html
>>>>>>>>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>>
>>>>>>>>>>>> Sergey Beryozkin
>>>>>>>>>>>>
>>>>>>>>>>>> Talend Community Coders
>>>>>>>>>>>> http://coders.talend.com/
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Best regards / Med venlig hilsen
>>>>>>>>>>> Nino Martinez
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> --
>>>>>>>>>> Christian Schneider
>>>>>>>>>> http://www.liquid-reality.de
>>>>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>>>>> 2bd062c5a7e
>>>>>>>>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>>>>>>>>
>>>>>>>>>> Open Source Architect
>>>>>>>>>> http://www.talend.com
>>>>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>>>>> 2bd062c5a7e
>>>>>>>>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> --
>>>>>>> Best regards / Med venlig hilsen
>>>>>>> Nino Martinez
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best regards / Med venlig hilsen
>>>>>> Nino Martinez
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>> --
>>>> Sergey Beryozkin
>>>>
>>>> Talend Community Coders
>>>> http://coders.talend.com/
>>>>
>>>>
>>>
>>>
>>> --
>>> Best regards / Med venlig hilsen
>>> Nino Martinez
>>>
>>>
>>
>>
>>
>
> --
> Sergey Beryozkin
>
> Talend Community Coders
> http://coders.talend.com/
>



-- 
Best regards / Med venlig hilsen
Nino Martinez

Re: DOSGI 2 prefered documentation technique?

Posted by Sergey Beryozkin <sb...@gmail.com>.
May be it is installed after the checks are done ?

On 22/06/17 13:08, nino martinez wael wrote:
> I've put this in my feature file: <bundle>
> wrap:mvn:org.webjars/swagger-ui/2.2.10</bundle>
> 
> On Thu, Jun 22, 2017 at 2:07 PM, nino martinez wael <
> nino.martinez.wael@gmail.com> wrote:
> 
>> Sorry I was wrong it is 3.1.11..
>>
>> On Wed, Jun 21, 2017 at 4:38 PM, Sergey Beryozkin <sb...@gmail.com>
>> wrote:
>>
>>> It needs to be CXF 3.1.11 - it is used with the latest DOSGi2 release
>>>
>>> Sergey
>>>
>>> On 21/06/17 14:37, nino martinez wael wrote:
>>>
>>>> IT does look like the project are using CXF-core 3.0.2 , but 3.1.9 of the
>>>> swagger cxf module.. would that be a problme?
>>>>
>>>> On Wed, Jun 21, 2017 at 3:35 PM, nino martinez wael <
>>>> nino.martinez.wael@gmail.com> wrote:
>>>>
>>>> SwaggerUIVersion ends up being null. It goes through all the checks.. Do
>>>>> I
>>>>> need to declare that version somewhere?
>>>>>
>>>>> On Wed, Jun 21, 2017 at 3:18 PM, nino martinez wael <
>>>>> nino.martinez.wael@gmail.com> wrote:
>>>>>
>>>>> Yes I will try so.. ASAP..
>>>>>>
>>>>>> -Thanks
>>>>>>
>>>>>> On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <
>>>>>> sberyozkin@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>> Hi
>>>>>>>
>>>>>>> Can you put a breakpoint here:
>>>>>>>
>>>>>>> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
>>>>>>> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiS
>>>>>>> waggerUiResolver.java#L38
>>>>>>>
>>>>>>> Cheers, Sergey
>>>>>>>
>>>>>>> On 16/06/17 07:13, nino martinez wael wrote:
>>>>>>>
>>>>>>> I think I need both..
>>>>>>>>
>>>>>>>> Problem are that I run into the CORS problem since we have begun to
>>>>>>>> host
>>>>>>>> our DOSGI service on another port, and the only way to get SWAGGER
>>>>>>>> ui to
>>>>>>>> function correctly would be to host it alongside the webservice..
>>>>>>>>
>>>>>>>> Did you try with an older release of swagger..? I just dont know
>>>>>>>> what I
>>>>>>>> need to add for CXF to activate swager ui, I've put in
>>>>>>>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger
>>>>>>>> swagger-ui
>>>>>>>> activation as far as I can see, combined with supportSwaggerUi=true..
>>>>>>>> But
>>>>>>>> nothing shows up at my version of "http://host:port/context/serv
>>>>>>>> ices/
>>>>>>>> api-docs?/url=/swagger.json"..
>>>>>>>>
>>>>>>>>
>>>>>>>> Place I've looked:
>>>>>>>> http://cxf.apache.org/docs/swagger2feature.html
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>>>>>>>> chris@die-schneider.net> wrote:
>>>>>>>>
>>>>>>>> I worked on a better swagger integration a while ago but also failed
>>>>>>>> at
>>>>>>>>
>>>>>>>>> the
>>>>>>>>> UI. At that time I think it was an incompatibility of the cxf
>>>>>>>>> swagger
>>>>>>>>> support with the new swagger versions.
>>>>>>>>> There are some interesting enhancements in the current DOSGi master
>>>>>>>>> so
>>>>>>>>> we
>>>>>>>>> could do a release soon.
>>>>>>>>> It would be great to also include swagger support but I would also
>>>>>>>>> not
>>>>>>>>> mind
>>>>>>>>> to move swagger support to 2.3.0.
>>>>>>>>>
>>>>>>>>> Christian
>>>>>>>>>
>>>>>>>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>>>>>>>> nino.martinez.wael@gmail.com>
>>>>>>>>> :
>>>>>>>>>
>>>>>>>>> Hi Christian,
>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> I seem to remember that I can get the SWAGGER UI bundled together
>>>>>>>>>> with
>>>>>>>>>>
>>>>>>>>>> the
>>>>>>>>>
>>>>>>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>>>>>>>
>>>>>>>>>> api-docs
>>>>>>>>>
>>>>>>>>> to my resource url. But it isnt working.
>>>>>>>>>>
>>>>>>>>>> My swagger.json are generated correctly..But does not link to the
>>>>>>>>>> swagger
>>>>>>>>>> ui document.
>>>>>>>>>>
>>>>>>>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>>>>>>>> sberyozkin@gmail.com
>>>>>>>>>>
>>>>>>>>>> wrote:
>>>>>>>>>>
>>>>>>>>>> According to
>>>>>>>>>>
>>>>>>>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>>>>>>>
>>>>>>>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>>>>>>>> keep working with Swagger 2 UI for the moment
>>>>>>>>>>>
>>>>>>>>>>> Thanks, Sergey
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>>>>>>>
>>>>>>>>>>> I also had this problem but was not able to pin it down to the
>>>>>>>>>>>
>>>>>>>>>>>> missing
>>>>>>>>>>>> host. ( I am not very familiar with swagger).
>>>>>>>>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>>>>>>>>
>>>>>>>>>>>> Can you post your code for the CustomSwagger2Serializers. If you
>>>>>>>>>>>> wat
>>>>>>>>>>>>
>>>>>>>>>>>> you
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>> can also create a PR in cxf to fix the issue.
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>> Christian
>>>>>>>>>>>>
>>>>>>>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>>>>>>>
>>>>>>>>>>>> Hi sorry to resurrect this thread but I've a similar problem
>>>>>>>>>>>> which
>>>>>>>>>>>> was
>>>>>>>>>>>>
>>>>>>>>>>>> not
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> completely solved with this approach,
>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>>>>>>>
>>>>>>>>>>>>>                    setScan(false);
>>>>>>>>>>>>>                    setUsePathBasedConfig(true);
>>>>>>>>>>>>>
>>>>>>>>>>>>> in the swagger feature. It all works well except the "Try it
>>>>>>>>>>>>> out"
>>>>>>>>>>>>> of
>>>>>>>>>>>>>
>>>>>>>>>>>>> the
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>> swagger ui. I'm using the latest version
>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> 0.5)
>>>>>>>>>>
>>>>>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>>>>>>>
>>>>>>>>>>>>> This
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> host
>>>>>>>>>>
>>>>>>>>>>> is used to build the url. The cxf feature does not set the host no
>>>>>>>>>>>>>
>>>>>>>>>>>>> matter
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>> what I do or change.
>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>> I ended up hammering an ugly solution by setting a custom
>>>>>>>>>>>>> swagger2
>>>>>>>>>>>>> serializer
>>>>>>>>>>>>>
>>>>>>>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>>>>>>>
>>>>>>>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>>>>>>>
>>>>>>>>>>>>> host:port
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>> I'm I missing something here or this is indeed a problema at least
>>>>>>>>>>>>>
>>>>>>>>>>>>> with
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> the
>>>>>>>>>>
>>>>>>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>>>>>>>>>>>>>
>>>>>>>>>>>>> does
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> no
>>>>>>>>>>
>>>>>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>>>>>>>
>>>>>>>>>>>>> Tnks,
>>>>>>>>>>>>> Ivo Leitão
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p57798
>>>>>>>>>>>>> 47.html
>>>>>>>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>> Sergey Beryozkin
>>>>>>>>>>>
>>>>>>>>>>> Talend Community Coders
>>>>>>>>>>> http://coders.talend.com/
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Best regards / Med venlig hilsen
>>>>>>>>>> Nino Martinez
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> --
>>>>>>>>> Christian Schneider
>>>>>>>>> http://www.liquid-reality.de
>>>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>>>> 2bd062c5a7e
>>>>>>>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>>>>>>>
>>>>>>>>> Open Source Architect
>>>>>>>>> http://www.talend.com
>>>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>>>> 2bd062c5a7e
>>>>>>>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best regards / Med venlig hilsen
>>>>>> Nino Martinez
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best regards / Med venlig hilsen
>>>>> Nino Martinez
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>
>>> --
>>> Sergey Beryozkin
>>>
>>> Talend Community Coders
>>> http://coders.talend.com/
>>>
>>
>>
>>
>> --
>> Best regards / Med venlig hilsen
>> Nino Martinez
>>
> 
> 
> 


-- 
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Re: DOSGI 2 prefered documentation technique?

Posted by nino martinez wael <ni...@gmail.com>.
I've put this in my feature file: <bundle>
wrap:mvn:org.webjars/swagger-ui/2.2.10</bundle>

On Thu, Jun 22, 2017 at 2:07 PM, nino martinez wael <
nino.martinez.wael@gmail.com> wrote:

> Sorry I was wrong it is 3.1.11..
>
> On Wed, Jun 21, 2017 at 4:38 PM, Sergey Beryozkin <sb...@gmail.com>
> wrote:
>
>> It needs to be CXF 3.1.11 - it is used with the latest DOSGi2 release
>>
>> Sergey
>>
>> On 21/06/17 14:37, nino martinez wael wrote:
>>
>>> IT does look like the project are using CXF-core 3.0.2 , but 3.1.9 of the
>>> swagger cxf module.. would that be a problme?
>>>
>>> On Wed, Jun 21, 2017 at 3:35 PM, nino martinez wael <
>>> nino.martinez.wael@gmail.com> wrote:
>>>
>>> SwaggerUIVersion ends up being null. It goes through all the checks.. Do
>>>> I
>>>> need to declare that version somewhere?
>>>>
>>>> On Wed, Jun 21, 2017 at 3:18 PM, nino martinez wael <
>>>> nino.martinez.wael@gmail.com> wrote:
>>>>
>>>> Yes I will try so.. ASAP..
>>>>>
>>>>> -Thanks
>>>>>
>>>>> On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <
>>>>> sberyozkin@gmail.com>
>>>>> wrote:
>>>>>
>>>>> Hi
>>>>>>
>>>>>> Can you put a breakpoint here:
>>>>>>
>>>>>> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
>>>>>> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiS
>>>>>> waggerUiResolver.java#L38
>>>>>>
>>>>>> Cheers, Sergey
>>>>>>
>>>>>> On 16/06/17 07:13, nino martinez wael wrote:
>>>>>>
>>>>>> I think I need both..
>>>>>>>
>>>>>>> Problem are that I run into the CORS problem since we have begun to
>>>>>>> host
>>>>>>> our DOSGI service on another port, and the only way to get SWAGGER
>>>>>>> ui to
>>>>>>> function correctly would be to host it alongside the webservice..
>>>>>>>
>>>>>>> Did you try with an older release of swagger..? I just dont know
>>>>>>> what I
>>>>>>> need to add for CXF to activate swager ui, I've put in
>>>>>>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger
>>>>>>> swagger-ui
>>>>>>> activation as far as I can see, combined with supportSwaggerUi=true..
>>>>>>> But
>>>>>>> nothing shows up at my version of "http://host:port/context/serv
>>>>>>> ices/
>>>>>>> api-docs?/url=/swagger.json"..
>>>>>>>
>>>>>>>
>>>>>>> Place I've looked:
>>>>>>> http://cxf.apache.org/docs/swagger2feature.html
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>>>>>>> chris@die-schneider.net> wrote:
>>>>>>>
>>>>>>> I worked on a better swagger integration a while ago but also failed
>>>>>>> at
>>>>>>>
>>>>>>>> the
>>>>>>>> UI. At that time I think it was an incompatibility of the cxf
>>>>>>>> swagger
>>>>>>>> support with the new swagger versions.
>>>>>>>> There are some interesting enhancements in the current DOSGi master
>>>>>>>> so
>>>>>>>> we
>>>>>>>> could do a release soon.
>>>>>>>> It would be great to also include swagger support but I would also
>>>>>>>> not
>>>>>>>> mind
>>>>>>>> to move swagger support to 2.3.0.
>>>>>>>>
>>>>>>>> Christian
>>>>>>>>
>>>>>>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>>>>>>> nino.martinez.wael@gmail.com>
>>>>>>>> :
>>>>>>>>
>>>>>>>> Hi Christian,
>>>>>>>>
>>>>>>>>>
>>>>>>>>> I seem to remember that I can get the SWAGGER UI bundled together
>>>>>>>>> with
>>>>>>>>>
>>>>>>>>> the
>>>>>>>>
>>>>>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>>>>>>
>>>>>>>>> api-docs
>>>>>>>>
>>>>>>>> to my resource url. But it isnt working.
>>>>>>>>>
>>>>>>>>> My swagger.json are generated correctly..But does not link to the
>>>>>>>>> swagger
>>>>>>>>> ui document.
>>>>>>>>>
>>>>>>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>>>>>>> sberyozkin@gmail.com
>>>>>>>>>
>>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>> According to
>>>>>>>>>
>>>>>>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>>>>>>
>>>>>>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>>>>>>> keep working with Swagger 2 UI for the moment
>>>>>>>>>>
>>>>>>>>>> Thanks, Sergey
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>>>>>>
>>>>>>>>>> I also had this problem but was not able to pin it down to the
>>>>>>>>>>
>>>>>>>>>>> missing
>>>>>>>>>>> host. ( I am not very familiar with swagger).
>>>>>>>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>>>>>>>
>>>>>>>>>>> Can you post your code for the CustomSwagger2Serializers. If you
>>>>>>>>>>> wat
>>>>>>>>>>>
>>>>>>>>>>> you
>>>>>>>>>>
>>>>>>>>>
>>>>>>>> can also create a PR in cxf to fix the issue.
>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>> Christian
>>>>>>>>>>>
>>>>>>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>>>>>>
>>>>>>>>>>> Hi sorry to resurrect this thread but I've a similar problem
>>>>>>>>>>> which
>>>>>>>>>>> was
>>>>>>>>>>>
>>>>>>>>>>> not
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> completely solved with this approach,
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>>>>>>
>>>>>>>>>>>>                   setScan(false);
>>>>>>>>>>>>                   setUsePathBasedConfig(true);
>>>>>>>>>>>>
>>>>>>>>>>>> in the swagger feature. It all works well except the "Try it
>>>>>>>>>>>> out"
>>>>>>>>>>>> of
>>>>>>>>>>>>
>>>>>>>>>>>> the
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>> swagger ui. I'm using the latest version
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> 0.5)
>>>>>>>>>
>>>>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>>>>>>
>>>>>>>>>>>> This
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> host
>>>>>>>>>
>>>>>>>>>> is used to build the url. The cxf feature does not set the host no
>>>>>>>>>>>>
>>>>>>>>>>>> matter
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>> what I do or change.
>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>> I ended up hammering an ugly solution by setting a custom
>>>>>>>>>>>> swagger2
>>>>>>>>>>>> serializer
>>>>>>>>>>>>
>>>>>>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>>>>>>
>>>>>>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>>>>>>
>>>>>>>>>>>> host:port
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>> I'm I missing something here or this is indeed a problema at least
>>>>>>>>>>>>
>>>>>>>>>>>> with
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> the
>>>>>>>>>
>>>>>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>>>>>>>>>>>>
>>>>>>>>>>>> does
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> no
>>>>>>>>>
>>>>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>>>>>>
>>>>>>>>>>>> Tnks,
>>>>>>>>>>>> Ivo Leitão
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p57798
>>>>>>>>>>>> 47.html
>>>>>>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>> Sergey Beryozkin
>>>>>>>>>>
>>>>>>>>>> Talend Community Coders
>>>>>>>>>> http://coders.talend.com/
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Best regards / Med venlig hilsen
>>>>>>>>> Nino Martinez
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> --
>>>>>>>> Christian Schneider
>>>>>>>> http://www.liquid-reality.de
>>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>>> 2bd062c5a7e
>>>>>>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>>>>>>
>>>>>>>> Open Source Architect
>>>>>>>> http://www.talend.com
>>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>>> 2bd062c5a7e
>>>>>>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>
>>>>> --
>>>>> Best regards / Med venlig hilsen
>>>>> Nino Martinez
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best regards / Med venlig hilsen
>>>> Nino Martinez
>>>>
>>>>
>>>
>>>
>>>
>>
>> --
>> Sergey Beryozkin
>>
>> Talend Community Coders
>> http://coders.talend.com/
>>
>
>
>
> --
> Best regards / Med venlig hilsen
> Nino Martinez
>



-- 
Best regards / Med venlig hilsen
Nino Martinez

Re: DOSGI 2 prefered documentation technique?

Posted by nino martinez wael <ni...@gmail.com>.
Sorry I was wrong it is 3.1.11..

On Wed, Jun 21, 2017 at 4:38 PM, Sergey Beryozkin <sb...@gmail.com>
wrote:

> It needs to be CXF 3.1.11 - it is used with the latest DOSGi2 release
>
> Sergey
>
> On 21/06/17 14:37, nino martinez wael wrote:
>
>> IT does look like the project are using CXF-core 3.0.2 , but 3.1.9 of the
>> swagger cxf module.. would that be a problme?
>>
>> On Wed, Jun 21, 2017 at 3:35 PM, nino martinez wael <
>> nino.martinez.wael@gmail.com> wrote:
>>
>> SwaggerUIVersion ends up being null. It goes through all the checks.. Do I
>>> need to declare that version somewhere?
>>>
>>> On Wed, Jun 21, 2017 at 3:18 PM, nino martinez wael <
>>> nino.martinez.wael@gmail.com> wrote:
>>>
>>> Yes I will try so.. ASAP..
>>>>
>>>> -Thanks
>>>>
>>>> On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <
>>>> sberyozkin@gmail.com>
>>>> wrote:
>>>>
>>>> Hi
>>>>>
>>>>> Can you put a breakpoint here:
>>>>>
>>>>> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
>>>>> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiS
>>>>> waggerUiResolver.java#L38
>>>>>
>>>>> Cheers, Sergey
>>>>>
>>>>> On 16/06/17 07:13, nino martinez wael wrote:
>>>>>
>>>>> I think I need both..
>>>>>>
>>>>>> Problem are that I run into the CORS problem since we have begun to
>>>>>> host
>>>>>> our DOSGI service on another port, and the only way to get SWAGGER ui
>>>>>> to
>>>>>> function correctly would be to host it alongside the webservice..
>>>>>>
>>>>>> Did you try with an older release of swagger..? I just dont know what
>>>>>> I
>>>>>> need to add for CXF to activate swager ui, I've put in
>>>>>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger
>>>>>> swagger-ui
>>>>>> activation as far as I can see, combined with supportSwaggerUi=true..
>>>>>> But
>>>>>> nothing shows up at my version of "http://host:port/context/services/
>>>>>> api-docs?/url=/swagger.json"..
>>>>>>
>>>>>>
>>>>>> Place I've looked:
>>>>>> http://cxf.apache.org/docs/swagger2feature.html
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>>>>>> chris@die-schneider.net> wrote:
>>>>>>
>>>>>> I worked on a better swagger integration a while ago but also failed
>>>>>> at
>>>>>>
>>>>>>> the
>>>>>>> UI. At that time I think it was an incompatibility of the cxf swagger
>>>>>>> support with the new swagger versions.
>>>>>>> There are some interesting enhancements in the current DOSGi master
>>>>>>> so
>>>>>>> we
>>>>>>> could do a release soon.
>>>>>>> It would be great to also include swagger support but I would also
>>>>>>> not
>>>>>>> mind
>>>>>>> to move swagger support to 2.3.0.
>>>>>>>
>>>>>>> Christian
>>>>>>>
>>>>>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>>>>>> nino.martinez.wael@gmail.com>
>>>>>>> :
>>>>>>>
>>>>>>> Hi Christian,
>>>>>>>
>>>>>>>>
>>>>>>>> I seem to remember that I can get the SWAGGER UI bundled together
>>>>>>>> with
>>>>>>>>
>>>>>>>> the
>>>>>>>
>>>>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>>>>>
>>>>>>>> api-docs
>>>>>>>
>>>>>>> to my resource url. But it isnt working.
>>>>>>>>
>>>>>>>> My swagger.json are generated correctly..But does not link to the
>>>>>>>> swagger
>>>>>>>> ui document.
>>>>>>>>
>>>>>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>>>>>
>>>>>>>>
>>>>>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>>>>>> sberyozkin@gmail.com
>>>>>>>>
>>>>>>>> wrote:
>>>>>>>>
>>>>>>>> According to
>>>>>>>>
>>>>>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>>>>>
>>>>>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>>>>>> keep working with Swagger 2 UI for the moment
>>>>>>>>>
>>>>>>>>> Thanks, Sergey
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>>>>>
>>>>>>>>> I also had this problem but was not able to pin it down to the
>>>>>>>>>
>>>>>>>>>> missing
>>>>>>>>>> host. ( I am not very familiar with swagger).
>>>>>>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>>>>>>
>>>>>>>>>> Can you post your code for the CustomSwagger2Serializers. If you
>>>>>>>>>> wat
>>>>>>>>>>
>>>>>>>>>> you
>>>>>>>>>
>>>>>>>>
>>>>>>> can also create a PR in cxf to fix the issue.
>>>>>>>>
>>>>>>>>>
>>>>>>>>>> Christian
>>>>>>>>>>
>>>>>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>>>>>
>>>>>>>>>> Hi sorry to resurrect this thread but I've a similar problem which
>>>>>>>>>> was
>>>>>>>>>>
>>>>>>>>>> not
>>>>>>>>>
>>>>>>>>
>>>>>>>> completely solved with this approach,
>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>>>>>
>>>>>>>>>>>                   setScan(false);
>>>>>>>>>>>                   setUsePathBasedConfig(true);
>>>>>>>>>>>
>>>>>>>>>>> in the swagger feature. It all works well except the "Try it out"
>>>>>>>>>>> of
>>>>>>>>>>>
>>>>>>>>>>> the
>>>>>>>>>>
>>>>>>>>>
>>>>>>>> swagger ui. I'm using the latest version
>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>>>>>>>>
>>>>>>>>>
>>>>>>> 0.5)
>>>>>>>>
>>>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>>>>>
>>>>>>>>>>> This
>>>>>>>>>>
>>>>>>>>>
>>>>>>> host
>>>>>>>>
>>>>>>>>> is used to build the url. The cxf feature does not set the host no
>>>>>>>>>>>
>>>>>>>>>>> matter
>>>>>>>>>>
>>>>>>>>>
>>>>>>>> what I do or change.
>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>> I ended up hammering an ugly solution by setting a custom
>>>>>>>>>>> swagger2
>>>>>>>>>>> serializer
>>>>>>>>>>>
>>>>>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>>>>>
>>>>>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>>>>>
>>>>>>>>>>> host:port
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>> I'm I missing something here or this is indeed a problema at least
>>>>>>>>>>>
>>>>>>>>>>> with
>>>>>>>>>>
>>>>>>>>>
>>>>>>> the
>>>>>>>>
>>>>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>>>>>>>>>>>
>>>>>>>>>>> does
>>>>>>>>>>
>>>>>>>>>
>>>>>>> no
>>>>>>>>
>>>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>>>>>
>>>>>>>>>>> Tnks,
>>>>>>>>>>> Ivo Leitão
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p57798
>>>>>>>>>>> 47.html
>>>>>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>> Sergey Beryozkin
>>>>>>>>>
>>>>>>>>> Talend Community Coders
>>>>>>>>> http://coders.talend.com/
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Best regards / Med venlig hilsen
>>>>>>>> Nino Martinez
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> --
>>>>>>> Christian Schneider
>>>>>>> http://www.liquid-reality.de
>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>> 2bd062c5a7e
>>>>>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>>>>>
>>>>>>> Open Source Architect
>>>>>>> http://www.talend.com
>>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>>> 2bd062c5a7e
>>>>>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>
>>>> --
>>>> Best regards / Med venlig hilsen
>>>> Nino Martinez
>>>>
>>>>
>>>
>>>
>>> --
>>> Best regards / Med venlig hilsen
>>> Nino Martinez
>>>
>>>
>>
>>
>>
>
> --
> Sergey Beryozkin
>
> Talend Community Coders
> http://coders.talend.com/
>



-- 
Best regards / Med venlig hilsen
Nino Martinez

Re: DOSGI 2 prefered documentation technique?

Posted by Sergey Beryozkin <sb...@gmail.com>.
It needs to be CXF 3.1.11 - it is used with the latest DOSGi2 release

Sergey
On 21/06/17 14:37, nino martinez wael wrote:
> IT does look like the project are using CXF-core 3.0.2 , but 3.1.9 of the
> swagger cxf module.. would that be a problme?
> 
> On Wed, Jun 21, 2017 at 3:35 PM, nino martinez wael <
> nino.martinez.wael@gmail.com> wrote:
> 
>> SwaggerUIVersion ends up being null. It goes through all the checks.. Do I
>> need to declare that version somewhere?
>>
>> On Wed, Jun 21, 2017 at 3:18 PM, nino martinez wael <
>> nino.martinez.wael@gmail.com> wrote:
>>
>>> Yes I will try so.. ASAP..
>>>
>>> -Thanks
>>>
>>> On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <sb...@gmail.com>
>>> wrote:
>>>
>>>> Hi
>>>>
>>>> Can you put a breakpoint here:
>>>>
>>>> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
>>>> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiS
>>>> waggerUiResolver.java#L38
>>>>
>>>> Cheers, Sergey
>>>>
>>>> On 16/06/17 07:13, nino martinez wael wrote:
>>>>
>>>>> I think I need both..
>>>>>
>>>>> Problem are that I run into the CORS problem since we have begun to host
>>>>> our DOSGI service on another port, and the only way to get SWAGGER ui to
>>>>> function correctly would be to host it alongside the webservice..
>>>>>
>>>>> Did you try with an older release of swagger..? I just dont know what I
>>>>> need to add for CXF to activate swager ui, I've put in
>>>>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger swagger-ui
>>>>> activation as far as I can see, combined with supportSwaggerUi=true..
>>>>> But
>>>>> nothing shows up at my version of "http://host:port/context/services/
>>>>> api-docs?/url=/swagger.json"..
>>>>>
>>>>>
>>>>> Place I've looked:
>>>>> http://cxf.apache.org/docs/swagger2feature.html
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>>>>> chris@die-schneider.net> wrote:
>>>>>
>>>>> I worked on a better swagger integration a while ago but also failed at
>>>>>> the
>>>>>> UI. At that time I think it was an incompatibility of the cxf swagger
>>>>>> support with the new swagger versions.
>>>>>> There are some interesting enhancements in the current DOSGi master so
>>>>>> we
>>>>>> could do a release soon.
>>>>>> It would be great to also include swagger support but I would also not
>>>>>> mind
>>>>>> to move swagger support to 2.3.0.
>>>>>>
>>>>>> Christian
>>>>>>
>>>>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>>>>> nino.martinez.wael@gmail.com>
>>>>>> :
>>>>>>
>>>>>> Hi Christian,
>>>>>>>
>>>>>>> I seem to remember that I can get the SWAGGER UI bundled together with
>>>>>>>
>>>>>> the
>>>>>>
>>>>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>>>>
>>>>>> api-docs
>>>>>>
>>>>>>> to my resource url. But it isnt working.
>>>>>>>
>>>>>>> My swagger.json are generated correctly..But does not link to the
>>>>>>> swagger
>>>>>>> ui document.
>>>>>>>
>>>>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>>>>
>>>>>>>
>>>>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>>>>> sberyozkin@gmail.com
>>>>>>>
>>>>>>> wrote:
>>>>>>>
>>>>>>> According to
>>>>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>>>>
>>>>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>>>>> keep working with Swagger 2 UI for the moment
>>>>>>>>
>>>>>>>> Thanks, Sergey
>>>>>>>>
>>>>>>>>
>>>>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>>>>
>>>>>>>> I also had this problem but was not able to pin it down to the
>>>>>>>>> missing
>>>>>>>>> host. ( I am not very familiar with swagger).
>>>>>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>>>>>
>>>>>>>>> Can you post your code for the CustomSwagger2Serializers. If you wat
>>>>>>>>>
>>>>>>>> you
>>>>>>
>>>>>>> can also create a PR in cxf to fix the issue.
>>>>>>>>>
>>>>>>>>> Christian
>>>>>>>>>
>>>>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>>>>
>>>>>>>>> Hi sorry to resurrect this thread but I've a similar problem which
>>>>>>>>> was
>>>>>>>>>
>>>>>>>> not
>>>>>>>
>>>>>>>> completely solved with this approach,
>>>>>>>>>>
>>>>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>>>>
>>>>>>>>>>                   setScan(false);
>>>>>>>>>>                   setUsePathBasedConfig(true);
>>>>>>>>>>
>>>>>>>>>> in the swagger feature. It all works well except the "Try it out"
>>>>>>>>>> of
>>>>>>>>>>
>>>>>>>>> the
>>>>>>>
>>>>>>>> swagger ui. I'm using the latest version
>>>>>>>>>>
>>>>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>>>>
>>>>>>> 0.5)
>>>>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>>>>
>>>>>>>>> This
>>>>>>
>>>>>>> host
>>>>>>>>>> is used to build the url. The cxf feature does not set the host no
>>>>>>>>>>
>>>>>>>>> matter
>>>>>>>
>>>>>>>> what I do or change.
>>>>>>>>>>
>>>>>>>>>> I ended up hammering an ugly solution by setting a custom swagger2
>>>>>>>>>> serializer
>>>>>>>>>>
>>>>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>>>>
>>>>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>>>>
>>>>>>>>> host:port
>>>>>>>
>>>>>>>>
>>>>>>>>>> I'm I missing something here or this is indeed a problema at least
>>>>>>>>>>
>>>>>>>>> with
>>>>>>
>>>>>>> the
>>>>>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>>>>>>>>>>
>>>>>>>>> does
>>>>>>
>>>>>>> no
>>>>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>>>>
>>>>>>>>>> Tnks,
>>>>>>>>>> Ivo Leitão
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p57798
>>>>>>>>>> 47.html
>>>>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>> --
>>>>>>>> Sergey Beryozkin
>>>>>>>>
>>>>>>>> Talend Community Coders
>>>>>>>> http://coders.talend.com/
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best regards / Med venlig hilsen
>>>>>>> Nino Martinez
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> --
>>>>>> Christian Schneider
>>>>>> http://www.liquid-reality.de
>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>> 2bd062c5a7e
>>>>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>>>>
>>>>>> Open Source Architect
>>>>>> http://www.talend.com
>>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>>> 2bd062c5a7e
>>>>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>
>>>
>>> --
>>> Best regards / Med venlig hilsen
>>> Nino Martinez
>>>
>>
>>
>>
>> --
>> Best regards / Med venlig hilsen
>> Nino Martinez
>>
> 
> 
> 


-- 
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Re: DOSGI 2 prefered documentation technique?

Posted by nino martinez wael <ni...@gmail.com>.
IT does look like the project are using CXF-core 3.0.2 , but 3.1.9 of the
swagger cxf module.. would that be a problme?

On Wed, Jun 21, 2017 at 3:35 PM, nino martinez wael <
nino.martinez.wael@gmail.com> wrote:

> SwaggerUIVersion ends up being null. It goes through all the checks.. Do I
> need to declare that version somewhere?
>
> On Wed, Jun 21, 2017 at 3:18 PM, nino martinez wael <
> nino.martinez.wael@gmail.com> wrote:
>
>> Yes I will try so.. ASAP..
>>
>> -Thanks
>>
>> On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <sb...@gmail.com>
>> wrote:
>>
>>> Hi
>>>
>>> Can you put a breakpoint here:
>>>
>>> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
>>> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiS
>>> waggerUiResolver.java#L38
>>>
>>> Cheers, Sergey
>>>
>>> On 16/06/17 07:13, nino martinez wael wrote:
>>>
>>>> I think I need both..
>>>>
>>>> Problem are that I run into the CORS problem since we have begun to host
>>>> our DOSGI service on another port, and the only way to get SWAGGER ui to
>>>> function correctly would be to host it alongside the webservice..
>>>>
>>>> Did you try with an older release of swagger..? I just dont know what I
>>>> need to add for CXF to activate swager ui, I've put in
>>>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger swagger-ui
>>>> activation as far as I can see, combined with supportSwaggerUi=true..
>>>> But
>>>> nothing shows up at my version of "http://host:port/context/services/
>>>> api-docs?/url=/swagger.json"..
>>>>
>>>>
>>>> Place I've looked:
>>>> http://cxf.apache.org/docs/swagger2feature.html
>>>>
>>>>
>>>>
>>>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>>>> chris@die-schneider.net> wrote:
>>>>
>>>> I worked on a better swagger integration a while ago but also failed at
>>>>> the
>>>>> UI. At that time I think it was an incompatibility of the cxf swagger
>>>>> support with the new swagger versions.
>>>>> There are some interesting enhancements in the current DOSGi master so
>>>>> we
>>>>> could do a release soon.
>>>>> It would be great to also include swagger support but I would also not
>>>>> mind
>>>>> to move swagger support to 2.3.0.
>>>>>
>>>>> Christian
>>>>>
>>>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>>>> nino.martinez.wael@gmail.com>
>>>>> :
>>>>>
>>>>> Hi Christian,
>>>>>>
>>>>>> I seem to remember that I can get the SWAGGER UI bundled together with
>>>>>>
>>>>> the
>>>>>
>>>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>>>
>>>>> api-docs
>>>>>
>>>>>> to my resource url. But it isnt working.
>>>>>>
>>>>>> My swagger.json are generated correctly..But does not link to the
>>>>>> swagger
>>>>>> ui document.
>>>>>>
>>>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>>>
>>>>>>
>>>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>>>> sberyozkin@gmail.com
>>>>>>
>>>>>> wrote:
>>>>>>
>>>>>> According to
>>>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>>>
>>>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>>>> keep working with Swagger 2 UI for the moment
>>>>>>>
>>>>>>> Thanks, Sergey
>>>>>>>
>>>>>>>
>>>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>>>
>>>>>>> I also had this problem but was not able to pin it down to the
>>>>>>>> missing
>>>>>>>> host. ( I am not very familiar with swagger).
>>>>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>>>>
>>>>>>>> Can you post your code for the CustomSwagger2Serializers. If you wat
>>>>>>>>
>>>>>>> you
>>>>>
>>>>>> can also create a PR in cxf to fix the issue.
>>>>>>>>
>>>>>>>> Christian
>>>>>>>>
>>>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>>>
>>>>>>>> Hi sorry to resurrect this thread but I've a similar problem which
>>>>>>>> was
>>>>>>>>
>>>>>>> not
>>>>>>
>>>>>>> completely solved with this approach,
>>>>>>>>>
>>>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>>>
>>>>>>>>>                  setScan(false);
>>>>>>>>>                  setUsePathBasedConfig(true);
>>>>>>>>>
>>>>>>>>> in the swagger feature. It all works well except the "Try it out"
>>>>>>>>> of
>>>>>>>>>
>>>>>>>> the
>>>>>>
>>>>>>> swagger ui. I'm using the latest version
>>>>>>>>>
>>>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>>>
>>>>>> 0.5)
>>>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>>>
>>>>>>>> This
>>>>>
>>>>>> host
>>>>>>>>> is used to build the url. The cxf feature does not set the host no
>>>>>>>>>
>>>>>>>> matter
>>>>>>
>>>>>>> what I do or change.
>>>>>>>>>
>>>>>>>>> I ended up hammering an ugly solution by setting a custom swagger2
>>>>>>>>> serializer
>>>>>>>>>
>>>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>>>
>>>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>>>
>>>>>>>> host:port
>>>>>>
>>>>>>>
>>>>>>>>> I'm I missing something here or this is indeed a problema at least
>>>>>>>>>
>>>>>>>> with
>>>>>
>>>>>> the
>>>>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>>>>>>>>>
>>>>>>>> does
>>>>>
>>>>>> no
>>>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>>>
>>>>>>>>> Tnks,
>>>>>>>>> Ivo Leitão
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p57798
>>>>>>>>> 47.html
>>>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>> --
>>>>>>> Sergey Beryozkin
>>>>>>>
>>>>>>> Talend Community Coders
>>>>>>> http://coders.talend.com/
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best regards / Med venlig hilsen
>>>>>> Nino Martinez
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> --
>>>>> Christian Schneider
>>>>> http://www.liquid-reality.de
>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>> 2bd062c5a7e
>>>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>>>
>>>>> Open Source Architect
>>>>> http://www.talend.com
>>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba5
>>>>> 2bd062c5a7e
>>>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>
>>
>> --
>> Best regards / Med venlig hilsen
>> Nino Martinez
>>
>
>
>
> --
> Best regards / Med venlig hilsen
> Nino Martinez
>



-- 
Best regards / Med venlig hilsen
Nino Martinez

Re: DOSGI 2 prefered documentation technique?

Posted by nino martinez wael <ni...@gmail.com>.
SwaggerUIVersion ends up being null. It goes through all the checks.. Do I
need to declare that version somewhere?

On Wed, Jun 21, 2017 at 3:18 PM, nino martinez wael <
nino.martinez.wael@gmail.com> wrote:

> Yes I will try so.. ASAP..
>
> -Thanks
>
> On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <sb...@gmail.com>
> wrote:
>
>> Hi
>>
>> Can you put a breakpoint here:
>>
>> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
>> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiS
>> waggerUiResolver.java#L38
>>
>> Cheers, Sergey
>>
>> On 16/06/17 07:13, nino martinez wael wrote:
>>
>>> I think I need both..
>>>
>>> Problem are that I run into the CORS problem since we have begun to host
>>> our DOSGI service on another port, and the only way to get SWAGGER ui to
>>> function correctly would be to host it alongside the webservice..
>>>
>>> Did you try with an older release of swagger..? I just dont know what I
>>> need to add for CXF to activate swager ui, I've put in
>>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger swagger-ui
>>> activation as far as I can see, combined with supportSwaggerUi=true.. But
>>> nothing shows up at my version of "http://host:port/context/services/
>>> api-docs?/url=/swagger.json"..
>>>
>>>
>>> Place I've looked:
>>> http://cxf.apache.org/docs/swagger2feature.html
>>>
>>>
>>>
>>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>>> chris@die-schneider.net> wrote:
>>>
>>> I worked on a better swagger integration a while ago but also failed at
>>>> the
>>>> UI. At that time I think it was an incompatibility of the cxf swagger
>>>> support with the new swagger versions.
>>>> There are some interesting enhancements in the current DOSGi master so
>>>> we
>>>> could do a release soon.
>>>> It would be great to also include swagger support but I would also not
>>>> mind
>>>> to move swagger support to 2.3.0.
>>>>
>>>> Christian
>>>>
>>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>>> nino.martinez.wael@gmail.com>
>>>> :
>>>>
>>>> Hi Christian,
>>>>>
>>>>> I seem to remember that I can get the SWAGGER UI bundled together with
>>>>>
>>>> the
>>>>
>>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>>
>>>> api-docs
>>>>
>>>>> to my resource url. But it isnt working.
>>>>>
>>>>> My swagger.json are generated correctly..But does not link to the
>>>>> swagger
>>>>> ui document.
>>>>>
>>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>>
>>>>>
>>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>>> sberyozkin@gmail.com
>>>>>
>>>>> wrote:
>>>>>
>>>>> According to
>>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>>
>>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>>> keep working with Swagger 2 UI for the moment
>>>>>>
>>>>>> Thanks, Sergey
>>>>>>
>>>>>>
>>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>>
>>>>>> I also had this problem but was not able to pin it down to the missing
>>>>>>> host. ( I am not very familiar with swagger).
>>>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>>>
>>>>>>> Can you post your code for the CustomSwagger2Serializers. If you wat
>>>>>>>
>>>>>> you
>>>>
>>>>> can also create a PR in cxf to fix the issue.
>>>>>>>
>>>>>>> Christian
>>>>>>>
>>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>>
>>>>>>> Hi sorry to resurrect this thread but I've a similar problem which
>>>>>>> was
>>>>>>>
>>>>>> not
>>>>>
>>>>>> completely solved with this approach,
>>>>>>>>
>>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>>
>>>>>>>>                  setScan(false);
>>>>>>>>                  setUsePathBasedConfig(true);
>>>>>>>>
>>>>>>>> in the swagger feature. It all works well except the "Try it out" of
>>>>>>>>
>>>>>>> the
>>>>>
>>>>>> swagger ui. I'm using the latest version
>>>>>>>>
>>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>>
>>>>> 0.5)
>>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>>
>>>>>>> This
>>>>
>>>>> host
>>>>>>>> is used to build the url. The cxf feature does not set the host no
>>>>>>>>
>>>>>>> matter
>>>>>
>>>>>> what I do or change.
>>>>>>>>
>>>>>>>> I ended up hammering an ugly solution by setting a custom swagger2
>>>>>>>> serializer
>>>>>>>>
>>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>>
>>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>>
>>>>>>> host:port
>>>>>
>>>>>>
>>>>>>>> I'm I missing something here or this is indeed a problema at least
>>>>>>>>
>>>>>>> with
>>>>
>>>>> the
>>>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>>>>>>>>
>>>>>>> does
>>>>
>>>>> no
>>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>>
>>>>>>>> Tnks,
>>>>>>>> Ivo Leitão
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p5779847.html
>>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>> --
>>>>>> Sergey Beryozkin
>>>>>>
>>>>>> Talend Community Coders
>>>>>> http://coders.talend.com/
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best regards / Med venlig hilsen
>>>>> Nino Martinez
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Christian Schneider
>>>> http://www.liquid-reality.de
>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e
>>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>>
>>>> Open Source Architect
>>>> http://www.talend.com
>>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e
>>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>>
>>>>
>>>
>>>
>>>
>
>
> --
> Best regards / Med venlig hilsen
> Nino Martinez
>



-- 
Best regards / Med venlig hilsen
Nino Martinez

Re: DOSGI 2 prefered documentation technique?

Posted by nino martinez wael <ni...@gmail.com>.
Yes I will try so.. ASAP..

-Thanks

On Fri, Jun 16, 2017 at 10:38 AM, Sergey Beryozkin <sb...@gmail.com>
wrote:

> Hi
>
> Can you put a breakpoint here:
>
> https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/descript
> ion-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/
> OsgiSwaggerUiResolver.java#L38
>
> Cheers, Sergey
>
> On 16/06/17 07:13, nino martinez wael wrote:
>
>> I think I need both..
>>
>> Problem are that I run into the CORS problem since we have begun to host
>> our DOSGI service on another port, and the only way to get SWAGGER ui to
>> function correctly would be to host it alongside the webservice..
>>
>> Did you try with an older release of swagger..? I just dont know what I
>> need to add for CXF to activate swager ui, I've put in
>> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger swagger-ui
>> activation as far as I can see, combined with supportSwaggerUi=true.. But
>> nothing shows up at my version of "http://host:port/context/services/
>> api-docs?/url=/swagger.json"..
>>
>>
>> Place I've looked:
>> http://cxf.apache.org/docs/swagger2feature.html
>>
>>
>>
>> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
>> chris@die-schneider.net> wrote:
>>
>> I worked on a better swagger integration a while ago but also failed at
>>> the
>>> UI. At that time I think it was an incompatibility of the cxf swagger
>>> support with the new swagger versions.
>>> There are some interesting enhancements in the current DOSGi master so we
>>> could do a release soon.
>>> It would be great to also include swagger support but I would also not
>>> mind
>>> to move swagger support to 2.3.0.
>>>
>>> Christian
>>>
>>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>>> nino.martinez.wael@gmail.com>
>>> :
>>>
>>> Hi Christian,
>>>>
>>>> I seem to remember that I can get the SWAGGER UI bundled together with
>>>>
>>> the
>>>
>>>> DOSGI app. But cannot remember the url I have tried with appending
>>>>
>>> api-docs
>>>
>>>> to my resource url. But it isnt working.
>>>>
>>>> My swagger.json are generated correctly..But does not link to the
>>>> swagger
>>>> ui document.
>>>>
>>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>>
>>>>
>>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <
>>>> sberyozkin@gmail.com
>>>>
>>>> wrote:
>>>>
>>>> According to
>>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>>
>>>>> it is a SwaggerUI 3 refactoring related issue...
>>>>> keep working with Swagger 2 UI for the moment
>>>>>
>>>>> Thanks, Sergey
>>>>>
>>>>>
>>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>>
>>>>> I also had this problem but was not able to pin it down to the missing
>>>>>> host. ( I am not very familiar with swagger).
>>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>>
>>>>>> Can you post your code for the CustomSwagger2Serializers. If you wat
>>>>>>
>>>>> you
>>>
>>>> can also create a PR in cxf to fix the issue.
>>>>>>
>>>>>> Christian
>>>>>>
>>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>>
>>>>>> Hi sorry to resurrect this thread but I've a similar problem which was
>>>>>>
>>>>> not
>>>>
>>>>> completely solved with this approach,
>>>>>>>
>>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>>
>>>>>>>                  setScan(false);
>>>>>>>                  setUsePathBasedConfig(true);
>>>>>>>
>>>>>>> in the swagger feature. It all works well except the "Try it out" of
>>>>>>>
>>>>>> the
>>>>
>>>>> swagger ui. I'm using the latest version
>>>>>>>
>>>>>> (mvn:org.webjars/swagger-ui/3.
>>>
>>>> 0.5)
>>>>>>> and I've noticed that in the swagger.json the host is not filled.
>>>>>>>
>>>>>> This
>>>
>>>> host
>>>>>>> is used to build the url. The cxf feature does not set the host no
>>>>>>>
>>>>>> matter
>>>>
>>>>> what I do or change.
>>>>>>>
>>>>>>> I ended up hammering an ugly solution by setting a custom swagger2
>>>>>>> serializer
>>>>>>>
>>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>>
>>>>>>> where I'm able to extract the servlet request thus setting the
>>>>>>>
>>>>>> host:port
>>>>
>>>>>
>>>>>>> I'm I missing something here or this is indeed a problema at least
>>>>>>>
>>>>>> with
>>>
>>>> the
>>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>>>>>>>
>>>>>> does
>>>
>>>> no
>>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>>
>>>>>>> Tnks,
>>>>>>> Ivo Leitão
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p5779847.html
>>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>> --
>>>>> Sergey Beryozkin
>>>>>
>>>>> Talend Community Coders
>>>>> http://coders.talend.com/
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best regards / Med venlig hilsen
>>>> Nino Martinez
>>>>
>>>>
>>>
>>>
>>> --
>>> --
>>> Christian Schneider
>>> http://www.liquid-reality.de
>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e
>>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>>
>>> Open Source Architect
>>> http://www.talend.com
>>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e
>>> 46&URL=http%3a%2f%2fwww.talend.com>
>>>
>>>
>>
>>
>>


-- 
Best regards / Med venlig hilsen
Nino Martinez

Re: DOSGI 2 prefered documentation technique?

Posted by Sergey Beryozkin <sb...@gmail.com>.
Hi

Can you put a breakpoint here:

https://github.com/apache/cxf/blob/cxf-3.1.11/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/OsgiSwaggerUiResolver.java#L38

Cheers, Sergey
On 16/06/17 07:13, nino martinez wael wrote:
> I think I need both..
> 
> Problem are that I run into the CORS problem since we have begun to host
> our DOSGI service on another port, and the only way to get SWAGGER ui to
> function correctly would be to host it alongside the webservice..
> 
> Did you try with an older release of swagger..? I just dont know what I
> need to add for CXF to activate swager ui, I've put in
> wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger swagger-ui
> activation as far as I can see, combined with supportSwaggerUi=true.. But
> nothing shows up at my version of "http://host:port/context/services/
> api-docs?/url=/swagger.json"..
> 
> 
> Place I've looked:
> http://cxf.apache.org/docs/swagger2feature.html
> 
> 
> 
> On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
> chris@die-schneider.net> wrote:
> 
>> I worked on a better swagger integration a while ago but also failed at the
>> UI. At that time I think it was an incompatibility of the cxf swagger
>> support with the new swagger versions.
>> There are some interesting enhancements in the current DOSGi master so we
>> could do a release soon.
>> It would be great to also include swagger support but I would also not mind
>> to move swagger support to 2.3.0.
>>
>> Christian
>>
>> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
>> nino.martinez.wael@gmail.com>
>> :
>>
>>> Hi Christian,
>>>
>>> I seem to remember that I can get the SWAGGER UI bundled together with
>> the
>>> DOSGI app. But cannot remember the url I have tried with appending
>> api-docs
>>> to my resource url. But it isnt working.
>>>
>>> My swagger.json are generated correctly..But does not link to the swagger
>>> ui document.
>>>
>>> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>>>
>>>
>>> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <sberyozkin@gmail.com
>>>
>>> wrote:
>>>
>>>> According to
>>>> https://issues.apache.org/jira/browse/CXF-7347
>>>>
>>>> it is a SwaggerUI 3 refactoring related issue...
>>>> keep working with Swagger 2 UI for the moment
>>>>
>>>> Thanks, Sergey
>>>>
>>>>
>>>> On 24/04/17 05:52, Christian Schneider wrote:
>>>>
>>>>> I also had this problem but was not able to pin it down to the missing
>>>>> host. ( I am not very familiar with swagger).
>>>>> Based on your findings I hope e can find a good solution to this.
>>>>>
>>>>> Can you post your code for the CustomSwagger2Serializers. If you wat
>> you
>>>>> can also create a PR in cxf to fix the issue.
>>>>>
>>>>> Christian
>>>>>
>>>>> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
>>>>>
>>>>> Hi sorry to resurrect this thread but I've a similar problem which was
>>> not
>>>>>> completely solved with this approach,
>>>>>>
>>>>>> First I've managed to make dosgi work with swagger with a:
>>>>>>
>>>>>>                  setScan(false);
>>>>>>                  setUsePathBasedConfig(true);
>>>>>>
>>>>>> in the swagger feature. It all works well except the "Try it out" of
>>> the
>>>>>> swagger ui. I'm using the latest version
>> (mvn:org.webjars/swagger-ui/3.
>>>>>> 0.5)
>>>>>> and I've noticed that in the swagger.json the host is not filled.
>> This
>>>>>> host
>>>>>> is used to build the url. The cxf feature does not set the host no
>>> matter
>>>>>> what I do or change.
>>>>>>
>>>>>> I ended up hammering an ugly solution by setting a custom swagger2
>>>>>> serializer
>>>>>>
>>>>>> setSwagger2Serializers(new CustomSwagger2Serializers());
>>>>>>
>>>>>> where I'm able to extract the servlet request thus setting the
>>> host:port
>>>>>>
>>>>>> I'm I missing something here or this is indeed a problema at least
>> with
>>>>>> the
>>>>>> latest swagger ui version (It seems odd also that the swagger 2 ui
>> does
>>>>>> no
>>>>>> use by default the current url but it didn't work in my tests) ?
>>>>>>
>>>>>> Tnks,
>>>>>> Ivo Leitão
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> View this message in context: http://cxf.547215.n5.nabble.
>>>>>> com/DOSGI-2-prefered-documentation-technique-tp5779291p5779847.html
>>>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>> --
>>>> Sergey Beryozkin
>>>>
>>>> Talend Community Coders
>>>> http://coders.talend.com/
>>>>
>>>
>>>
>>>
>>> --
>>> Best regards / Med venlig hilsen
>>> Nino Martinez
>>>
>>
>>
>>
>> --
>> --
>> Christian Schneider
>> http://www.liquid-reality.de
>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e
>> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>>
>> Open Source Architect
>> http://www.talend.com
>> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e
>> 46&URL=http%3a%2f%2fwww.talend.com>
>>
> 
> 
> 

Re: DOSGI 2 prefered documentation technique?

Posted by nino martinez wael <ni...@gmail.com>.
I think I need both..

Problem are that I run into the CORS problem since we have begun to host
our DOSGI service on another port, and the only way to get SWAGGER ui to
function correctly would be to host it alongside the webservice..

Did you try with an older release of swagger..? I just dont know what I
need to add for CXF to activate swager ui, I've put in
wrap:mvn:org.webjars/swagger-ui/2.2.10 which should trigger swagger-ui
activation as far as I can see, combined with supportSwaggerUi=true.. But
nothing shows up at my version of "http://host:port/context/services/
api-docs?/url=/swagger.json"..


Place I've looked:
http://cxf.apache.org/docs/swagger2feature.html



On Wed, Jun 14, 2017 at 9:02 PM, Christian Schneider <
chris@die-schneider.net> wrote:

> I worked on a better swagger integration a while ago but also failed at the
> UI. At that time I think it was an incompatibility of the cxf swagger
> support with the new swagger versions.
> There are some interesting enhancements in the current DOSGi master so we
> could do a release soon.
> It would be great to also include swagger support but I would also not mind
> to move swagger support to 2.3.0.
>
> Christian
>
> 2017-06-14 14:58 GMT+02:00 nino martinez wael <
> nino.martinez.wael@gmail.com>
> :
>
> > Hi Christian,
> >
> > I seem to remember that I can get the SWAGGER UI bundled together with
> the
> > DOSGI app. But cannot remember the url I have tried with appending
> api-docs
> > to my resource url. But it isnt working.
> >
> > My swagger.json are generated correctly..But does not link to the swagger
> > ui document.
> >
> > BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
> >
> >
> > On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <sberyozkin@gmail.com
> >
> > wrote:
> >
> > > According to
> > > https://issues.apache.org/jira/browse/CXF-7347
> > >
> > > it is a SwaggerUI 3 refactoring related issue...
> > > keep working with Swagger 2 UI for the moment
> > >
> > > Thanks, Sergey
> > >
> > >
> > > On 24/04/17 05:52, Christian Schneider wrote:
> > >
> > >> I also had this problem but was not able to pin it down to the missing
> > >> host. ( I am not very familiar with swagger).
> > >> Based on your findings I hope e can find a good solution to this.
> > >>
> > >> Can you post your code for the CustomSwagger2Serializers. If you wat
> you
> > >> can also create a PR in cxf to fix the issue.
> > >>
> > >> Christian
> > >>
> > >> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
> > >>
> > >> Hi sorry to resurrect this thread but I've a similar problem which was
> > not
> > >>> completely solved with this approach,
> > >>>
> > >>> First I've managed to make dosgi work with swagger with a:
> > >>>
> > >>>                 setScan(false);
> > >>>                 setUsePathBasedConfig(true);
> > >>>
> > >>> in the swagger feature. It all works well except the "Try it out" of
> > the
> > >>> swagger ui. I'm using the latest version
> (mvn:org.webjars/swagger-ui/3.
> > >>> 0.5)
> > >>> and I've noticed that in the swagger.json the host is not filled.
> This
> > >>> host
> > >>> is used to build the url. The cxf feature does not set the host no
> > matter
> > >>> what I do or change.
> > >>>
> > >>> I ended up hammering an ugly solution by setting a custom swagger2
> > >>> serializer
> > >>>
> > >>> setSwagger2Serializers(new CustomSwagger2Serializers());
> > >>>
> > >>> where I'm able to extract the servlet request thus setting the
> > host:port
> > >>>
> > >>> I'm I missing something here or this is indeed a problema at least
> with
> > >>> the
> > >>> latest swagger ui version (It seems odd also that the swagger 2 ui
> does
> > >>> no
> > >>> use by default the current url but it didn't work in my tests) ?
> > >>>
> > >>> Tnks,
> > >>> Ivo Leitão
> > >>>
> > >>>
> > >>>
> > >>> --
> > >>> View this message in context: http://cxf.547215.n5.nabble.
> > >>> com/DOSGI-2-prefered-documentation-technique-tp5779291p5779847.html
> > >>> Sent from the cxf-user mailing list archive at Nabble.com.
> > >>>
> > >>>
> > >>
> > >>
> > >>
> > >
> > > --
> > > Sergey Beryozkin
> > >
> > > Talend Community Coders
> > > http://coders.talend.com/
> > >
> >
> >
> >
> > --
> > Best regards / Med venlig hilsen
> > Nino Martinez
> >
>
>
>
> --
> --
> Christian Schneider
> http://www.liquid-reality.de
> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e
> 46&URL=http%3a%2f%2fwww.liquid-reality.de>
>
> Open Source Architect
> http://www.talend.com
> <https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e
> 46&URL=http%3a%2f%2fwww.talend.com>
>



-- 
Best regards / Med venlig hilsen
Nino Martinez

Re: DOSGI 2 prefered documentation technique?

Posted by Christian Schneider <ch...@die-schneider.net>.
I worked on a better swagger integration a while ago but also failed at the
UI. At that time I think it was an incompatibility of the cxf swagger
support with the new swagger versions.
There are some interesting enhancements in the current DOSGi master so we
could do a release soon.
It would be great to also include swagger support but I would also not mind
to move swagger support to 2.3.0.

Christian

2017-06-14 14:58 GMT+02:00 nino martinez wael <ni...@gmail.com>
:

> Hi Christian,
>
> I seem to remember that I can get the SWAGGER UI bundled together with the
> DOSGI app. But cannot remember the url I have tried with appending api-docs
> to my resource url. But it isnt working.
>
> My swagger.json are generated correctly..But does not link to the swagger
> ui document.
>
> BTW it does not work on 2.1.0.. Whats the horizon to release 2.2?
>
>
> On Mon, Apr 24, 2017 at 11:23 AM, Sergey Beryozkin <sb...@gmail.com>
> wrote:
>
> > According to
> > https://issues.apache.org/jira/browse/CXF-7347
> >
> > it is a SwaggerUI 3 refactoring related issue...
> > keep working with Swagger 2 UI for the moment
> >
> > Thanks, Sergey
> >
> >
> > On 24/04/17 05:52, Christian Schneider wrote:
> >
> >> I also had this problem but was not able to pin it down to the missing
> >> host. ( I am not very familiar with swagger).
> >> Based on your findings I hope e can find a good solution to this.
> >>
> >> Can you post your code for the CustomSwagger2Serializers. If you wat you
> >> can also create a PR in cxf to fix the issue.
> >>
> >> Christian
> >>
> >> 2017-04-23 23:49 GMT+02:00 Ivo Leitão <iv...@gmail.com>:
> >>
> >> Hi sorry to resurrect this thread but I've a similar problem which was
> not
> >>> completely solved with this approach,
> >>>
> >>> First I've managed to make dosgi work with swagger with a:
> >>>
> >>>                 setScan(false);
> >>>                 setUsePathBasedConfig(true);
> >>>
> >>> in the swagger feature. It all works well except the "Try it out" of
> the
> >>> swagger ui. I'm using the latest version (mvn:org.webjars/swagger-ui/3.
> >>> 0.5)
> >>> and I've noticed that in the swagger.json the host is not filled. This
> >>> host
> >>> is used to build the url. The cxf feature does not set the host no
> matter
> >>> what I do or change.
> >>>
> >>> I ended up hammering an ugly solution by setting a custom swagger2
> >>> serializer
> >>>
> >>> setSwagger2Serializers(new CustomSwagger2Serializers());
> >>>
> >>> where I'm able to extract the servlet request thus setting the
> host:port
> >>>
> >>> I'm I missing something here or this is indeed a problema at least with
> >>> the
> >>> latest swagger ui version (It seems odd also that the swagger 2 ui does
> >>> no
> >>> use by default the current url but it didn't work in my tests) ?
> >>>
> >>> Tnks,
> >>> Ivo Leitão
> >>>
> >>>
> >>>
> >>> --
> >>> View this message in context: http://cxf.547215.n5.nabble.
> >>> com/DOSGI-2-prefered-documentation-technique-tp5779291p5779847.html
> >>> Sent from the cxf-user mailing list archive at Nabble.com.
> >>>
> >>>
> >>
> >>
> >>
> >
> > --
> > Sergey Beryozkin
> >
> > Talend Community Coders
> > http://coders.talend.com/
> >
>
>
>
> --
> Best regards / Med venlig hilsen
> Nino Martinez
>



-- 
-- 
Christian Schneider
http://www.liquid-reality.de
<https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e46&URL=http%3a%2f%2fwww.liquid-reality.de>

Open Source Architect
http://www.talend.com
<https://owa.talend.com/owa/redir.aspx?C=3aa4083e0c744ae1ba52bd062c5a7e46&URL=http%3a%2f%2fwww.talend.com>