You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@guacamole.apache.org by 林 政剛 <li...@gmail.com> on 2022/08/22 03:14:17 UTC

Re: Enable RestAPI logging

Hi,

I need to enable logging of the rest api, for example, all of the
requests/responses of HTTP.
I did some research on the Internet. I think I need to set the logging
filter for Jersey like this.
But I don't know how to do it in Guacamole.

    <init-param>
         <param-name>com.sun.jersey.spi.container.ContainerRequestFilters</param-name>
         <param-value>com.sun.jersey.api.container.filter.LoggingFilter</param-value>
     </init-param>
     <init-param>
         <param-name>com.sun.jersey.spi.container.ContainerResponseFilters</param-name>
         <param-value>com.sun.jersey.api.container.filter.LoggingFilter</param-value>
     </init-param>



Please help me, thank you.
Best Regards.
LIN ZHENGGANG


2022年8月22日(月) 12:06 林 政剛 <li...@gmail.com>:

> Hi,
>
> I need to enable logging of the rest api, for example, all of the
> requests/responses of HTTP.
> I did some research on the Internet. I think I need to set the logging
> filter for Jersey like this.
> But I don't know how to do it in Guacamole.
>
>     <init-param>
>          <param-name>com.sun.jersey.spi.container.ContainerRequestFilters</param-name>
>          <param-value>com.sun.jersey.api.container.filter.LoggingFilter</param-value>
>      </init-param>
>      <init-param>
>          <param-name>com.sun.jersey.spi.container.ContainerResponseFilters</param-name>
>          <param-value>com.sun.jersey.api.container.filter.LoggingFilter</param-value>
>      </init-param>
>
>
>
> Please help me, thank you.
> Best Regards.
> LIN ZHENGGANG
>
>

Re: Enable RestAPI logging

Posted by Nick Couchman <vn...@apache.org>.
On Sun, Aug 21, 2022 at 11:14 PM 林 政剛 <li...@gmail.com> wrote:
>
> Hi,
>
> I need to enable logging of the rest api, for example, all of the requests/responses of HTTP.
> I did some research on the Internet. I think I need to set the logging filter for Jersey like this.
> But I don't know how to do it in Guacamole.
>
>     <init-param>
>          <param-name>com.sun.jersey.spi.container.ContainerRequestFilters</param-name>
>          <param-value>com.sun.jersey.api.container.filter.LoggingFilter</param-value>
>      </init-param>
>      <init-param>
>          <param-name>com.sun.jersey.spi.container.ContainerResponseFilters</param-name>
>          <param-value>com.sun.jersey.api.container.filter.LoggingFilter</param-value>
>      </init-param>
>

Logging for Guacamole is controlled by the logback.xml file in the
GUACAMOLE_HOME directory (/etc/guacamole, usually), as documented in
the manual:

https://guacamole.apache.org/doc/gug/configuring-guacamole.html#logging-within-the-web-application

However, perhaps it would be better if you'd explain in more detail
what you're trying to achieve by logging these REST API calls? There
may be other ways to gather the information that you need outside of
enabling this logging.

-Nick

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@guacamole.apache.org
For additional commands, e-mail: user-help@guacamole.apache.org