Repository: cxf Updated Branches: refs/heads/master 604167d9f -> 9bb1148e0
Fix problem of new logging with JMS based JAXRS services Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/d655bcb1 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/d655bcb1 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/d655bcb1 Branch: refs/heads/master Commit: d655bcb160e5403f60a8365b2bf41ef07cb0414b Parents: 604167d Author: Daniel Kulp <[email protected]> Authored: Thu Feb 9 11:04:52 2017 -0500 Committer: Daniel Kulp <[email protected]> Committed: Thu Feb 9 11:04:52 2017 -0500 ---------------------------------------------------------------------- .../org/apache/cxf/ext/logging/event/DefaultLogEventMapper.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cxf/blob/d655bcb1/rt/features/logging/src/main/java/org/apache/cxf/ext/logging/event/DefaultLogEventMapper.java ---------------------------------------------------------------------- diff --git a/rt/features/logging/src/main/java/org/apache/cxf/ext/logging/event/DefaultLogEventMapper.java b/rt/features/logging/src/main/java/org/apache/cxf/ext/logging/event/DefaultLogEventMapper.java index f48629f..66082bc 100644 --- a/rt/features/logging/src/main/java/org/apache/cxf/ext/logging/event/DefaultLogEventMapper.java +++ b/rt/features/logging/src/main/java/org/apache/cxf/ext/logging/event/DefaultLogEventMapper.java @@ -258,8 +258,9 @@ public class DefaultLogEventMapper implements LogEventMapper { String requestUri = safeGet(message, Message.REQUEST_URI); if (requestUri != null) { String basePath = safeGet(message, Message.BASE_PATH); - int baseUriLength = (basePath != null) ? basePath.length() : 0; - path = requestUri.substring(baseUriLength); + if (basePath != null && requestUri.startsWith(basePath)) { + path = requestUri.substring(basePath.length()); + } if (path.isEmpty()) { path = "/"; }
