不少朋友都因为CXF的报错信息而苦恼,调试起来很麻烦,昨天突然发现这个玩意还可以用日志配置,直接打印HTTP HEAR信息,所以上BLOG分享下:
配置如下:
配置如下:
<jaxrs:server id="supplyChainMilestoneRest" address="/supplyChain/milestone">
<jaxrs:serviceBeans>
<ref bean="supplyChainMilestoneService"></ref><!-- spring bean name -->
</jaxrs:serviceBeans>
<jaxrs:providers>
<ref bean="jsonProvider"/>
<ref bean="errorHandlerProvider"/>
</jaxrs:providers>
<jaxrs:features>
[b]<bean class="org.apache.cxf.feature.LoggingFeature"></bean>[/b]
</jaxrs:features>
</jaxrs:server>