Skip to content

Commit

Permalink
Change the log level when the rest entity is changed
Browse files Browse the repository at this point in the history
Signed-off-by: crazyhzm <crazyhzm@gmail.com>
  • Loading branch information
CrazyHZM committed Oct 23, 2023
1 parent ad26a69 commit fa9ac98
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -124,9 +124,8 @@ public Type getEntityType() {

@Override
public void setEntity(Object entity) {
//if (entity != null) logger.info("*** setEntity(Object) " + entity.toString());
if (entity != null && jaxrsResponse.getEntity() != null) {
logger.info("Dubbo container response context filter set entity ,before entity is: " + jaxrsResponse.getEntity() + "and after entity is: " + entity);
logger.debug("Dubbo container response context filter set entity ,before entity is: " + jaxrsResponse.getEntity() + "and after entity is: " + entity);

}
jaxrsResponse.setEntity(entity);
Expand All @@ -138,9 +137,8 @@ public void setEntity(Object entity) {

@Override
public void setEntity(Object entity, Annotation[] annotations, MediaType mediaType) {
//if (entity != null) logger.info("*** setEntity(Object, Annotation[], MediaType) " + entity.toString() + ", " + mediaType);
if (entity != null && jaxrsResponse.getEntity() != null) {
logger.info("Dubbo container response context filter set entity ,before entity is: " + jaxrsResponse.getEntity() + "and after entity is: " + entity);
logger.debug("Dubbo container response context filter set entity ,before entity is: " + jaxrsResponse.getEntity() + "and after entity is: " + entity);
}
jaxrsResponse.setEntity(entity);
jaxrsResponse.setAnnotations(annotations);
Expand Down

0 comments on commit fa9ac98

Please sign in to comment.