Done
https://issues.apache.org/jira/browse/ARIES-1964

Am So., 12. Jan. 2020 um 00:14 Uhr schrieb Raymond Auge <
raymond.a...@liferay.com>:

> Can you create an issue for this?
>
> - Ray
>
> On Sat, Jan 11, 2020, 16:20 Markus Rathgeb, <maggu2...@gmail.com> wrote:
>
>> Hi,
>> thank you both.
>>
>> It works if I set the component property for the application service that
>> way: servlet.init.hide-service-list-page=true
>>
>> Do you agree that the situation should be improved?
>> The application implementation should not depend on the specific chosen
>> whiteboard implementation (IMHO).
>> If I know I use the Aries JAX-RS Whiteboard implementation I would like
>> to set this setting globally.
>> So, shouldn't  it be possible to set that component property globally for
>> aries jax-rs whiteboard so it is used by all applications wired to that
>> whiteboard implementation?
>> Otherwise everybody need to know about all applications used in the
>> runtime and create a configuration for all of them.
>> If the implementation of the whiteboard service is changed (another one
>> is chosen) the configuration of every application needs to be changed, too.
>>
>>
>>
>> Am Sa., 11. Jan. 2020 um 00:20 Uhr schrieb Carlos Sierra <
>> csie...@gmail.com>:
>>
>>> Hi again,
>>> the whiteboard registers a servlet context per application. The
>>> properties of the application service are passed to the servlet context. So
>>> you can pass any http whiteboard property to the jaxrs application service
>>> and it will end up on the associated servlet context helper service
>>> registration. This way you should be able to pass servlet init properties
>>> using the http whiteboard notation.
>>>
>>> Sent from my phone.
>>>
>>> Carlos.
>>>
>>>
>>> El vie., 10 ene. 2020 23:08, Markus Rathgeb <maggu2...@gmail.com>
>>> escribió:
>>>
>>>> Not yet, will try it later...
>>>>
>>>> Raymond Auge <raymond.a...@liferay.com> schrieb am Fr., 10. Jan. 2020,
>>>> 23:04:
>>>>
>>>>> did you try prefix `servlet.init.`?
>>>>>
>>>>> - Ray
>>>>>
>>>>> On Fri, Jan 10, 2020 at 1:55 PM Markus Rathgeb <maggu2...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> I use an application similar to this one:
>>>>>>
>>>>>> @Component(service = Application.class)
>>>>>> @JaxrsName(RESTConstants.JAX_RS_NAME)
>>>>>> @JaxrsApplicationBase("rest")
>>>>>> public class RESTApplicationImpl extends Application {
>>>>>> }
>>>>>>
>>>>>> The resource looks similar to this one:
>>>>>>
>>>>>> @Component(service = { RESTResource.class })
>>>>>> @JaxrsResource
>>>>>> @JaxrsName("services")
>>>>>> @JaxrsApplicationSelect("(" + JaxrsWhiteboardConstants.JAX_RS_NAME +
>>>>>> "=" + RESTConstants.JAX_RS_NAME + ")")
>>>>>> @JSONRequired
>>>>>> @Path("/services")
>>>>>> public class RESTResource {
>>>>>> ...
>>>>>> }
>>>>>>
>>>>>> I already tried to use configurations for the application component,
>>>>>> but did not succeed.
>>>>>>
>>>>>>
>>>>>> Am Fr., 10. Jan. 2020 um 22:47 Uhr schrieb Raymond Auge <
>>>>>> raymond.a...@liferay.com>:
>>>>>>
>>>>>>> Do you happen to have a custom whiteboard instance with a factory
>>>>>>> pid?
>>>>>>>
>>>>>>> - Ray
>>>>>>>
>>>>>>> On Fri, Jan 10, 2020 at 1:45 PM Markus Rathgeb <maggu2...@gmail.com>
>>>>>>> wrote:
>>>>>>>
>>>>>>>> I already did as I found this mechanism to solve
>>>>>>>> https://issues.apache.org/jira/browse/CXF-8190.
>>>>>>>>
>>>>>>>> I tried "hide-service-list-page" as this does not work I also
>>>>>>>> tried "context.init.hide-service-list-page" as I hoped it will
>>>>>>>> works similar to the HTTP Whiteboard property.
>>>>>>>> But it does not work.
>>>>>>>> I also tried to overwrite the getProperties method of the
>>>>>>>> Application.
>>>>>>>> So, I need a way to set the servlet context init parameter.
>>>>>>>>
>>>>>>>> As it is about migration of an existing code base, I cannot change
>>>>>>>> the endpoints name as a workaround.
>>>>>>>> I need a solution to use "services". :(
>>>>>>>>
>>>>>>>> Am Fr., 10. Jan. 2020 um 22:38 Uhr schrieb Raymond Auge <
>>>>>>>> raymond.a...@liferay.com>:
>>>>>>>>
>>>>>>>>> Did you try creating a configuration with pid
>>>>>>>>> `org.apache.aries.jax.rs.whiteboard.default` and setting the property
>>>>>>>>> there? Those properties of the default whiteboard will be inherited 
>>>>>>>>> by that
>>>>>>>>> servlet.
>>>>>>>>>
>>>>>>>>> (A nice way is with configurator.)
>>>>>>>>>
>>>>>>>>> - Ray
>>>>>>>>>
>>>>>>>>> On Fri, Jan 10, 2020 at 1:15 PM Markus Rathgeb <
>>>>>>>>> maggu2...@gmail.com> wrote:
>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>
>>>>>>>>>> I am currently migrate an existing code base to the JAX-RS
>>>>>>>>>> Whiteboard.
>>>>>>>>>> I did it already a few times but currently I am really stuck.
>>>>>>>>>>
>>>>>>>>>> I already read the involved code base but I cannot find a
>>>>>>>>>> solution...
>>>>>>>>>>
>>>>>>>>>> There is an existing REST endpoint "services" that needs to be
>>>>>>>>>> migrated.
>>>>>>>>>> But I cannot access that REST endpoint.
>>>>>>>>>>
>>>>>>>>>> If I access "/services" CXF provides its own response.
>>>>>>>>>> I identified that class:
>>>>>>>>>> https://github.com/apache/cxf/blob/cxf-3.2.5/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
>>>>>>>>>>
>>>>>>>>>> All I need to do (it sounds such easy) is to set the init
>>>>>>>>>> parameter of the servlet context with name "
>>>>>>>>>> hide-service-list-page" to "false".
>>>>>>>>>> But I did not found any way to to it.
>>>>>>>>>>
>>>>>>>>>> So the question is rather simple:
>>>>>>>>>> How can I use the rest endpoint "services" for a custom
>>>>>>>>>> implementation with Aires' JAX-RS Whiteboard implementation?
>>>>>>>>>>
>>>>>>>>>> Please help
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> *Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
>>>>>>>>>  (@rotty3000)
>>>>>>>>> Senior Software Architect *Liferay, Inc.* <http://www.liferay.com>
>>>>>>>>>  (@Liferay)
>>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> *Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
>>>>>>>  (@rotty3000)
>>>>>>> Senior Software Architect *Liferay, Inc.* <http://www.liferay.com>
>>>>>>>  (@Liferay)
>>>>>>>
>>>>>>
>>>>>
>>>>> --
>>>>> *Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
>>>>>  (@rotty3000)
>>>>> Senior Software Architect *Liferay, Inc.* <http://www.liferay.com>
>>>>>  (@Liferay)
>>>>>
>>>>

Reply via email to