将 ClientFilter 从 Jersey 移动到 Jersey 2
Moving ClientFilter from Jersey to Jersey 2
我正在尝试将我的代码库中 Jersey Client 的使用从 com.sun.jersey.client
迁移到 org.glassfish.jersey.client
。
在代码库的多个部分,我正在创建 类 继承自 ClientFilter
并覆盖 handle
方法。
Jersey 2 中 ClientFilter
的替代品是什么?我应该如何更改我使用它的地方?
有关流程的详细信息,请参阅 Jersey 文档部分 Client Filters. Basically there are ClientRequestFilter
and ClientResponseFilter
. The former is called before the request goes out and the latter is called on the incoming response. See also this post。
我正在尝试将我的代码库中 Jersey Client 的使用从 com.sun.jersey.client
迁移到 org.glassfish.jersey.client
。
在代码库的多个部分,我正在创建 类 继承自 ClientFilter
并覆盖 handle
方法。
Jersey 2 中 ClientFilter
的替代品是什么?我应该如何更改我使用它的地方?
有关流程的详细信息,请参阅 Jersey 文档部分 Client Filters. Basically there are ClientRequestFilter
and ClientResponseFilter
. The former is called before the request goes out and the latter is called on the incoming response. See also this post。