cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1426549 - in /cxf/branches/2.5.x-fixes: ./ rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/RequestDispatcherProvider.java
Date Fri, 28 Dec 2012 15:41:39 GMT
Author: sergeyb
Date: Fri Dec 28 15:41:39 2012
New Revision: 1426549

URL: http://svn.apache.org/viewvc?rev=1426549&view=rev
Log:
Merged revisions 1426548 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/branches/2.6.x-fixes

................
  r1426548 | sergeyb | 2012-12-28 15:35:02 +0000 (Fri, 28 Dec 2012) | 9 lines
  
  Merged revisions 1426547 via svnmerge from 
  https://svn.apache.org/repos/asf/cxf/trunk
  
  ........
    r1426547 | sergeyb | 2012-12-28 15:30:11 +0000 (Fri, 28 Dec 2012) | 1 line
    
    Minor update to ResponseDispatcherProvider to get redirections paths from the output message
  ........
................

Modified:
    cxf/branches/2.5.x-fixes/   (props changed)
    cxf/branches/2.5.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/RequestDispatcherProvider.java

Propchange: cxf/branches/2.5.x-fixes/
------------------------------------------------------------------------------
  Merged /cxf/trunk:r1426547
  Merged /cxf/branches/2.6.x-fixes:r1426548

Propchange: cxf/branches/2.5.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.5.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/RequestDispatcherProvider.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/RequestDispatcherProvider.java?rev=1426549&r1=1426548&r2=1426549&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/RequestDispatcherProvider.java
(original)
+++ cxf/branches/2.5.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/RequestDispatcherProvider.java
Fri Dec 28 15:41:39 2012
@@ -68,6 +68,8 @@ public class RequestDispatcherProvider e
     private static final String REQUEST_SCOPE = "request";
     private static final String SESSION_SCOPE = "session";
     
+    private static final String MESSAGE_RESOURCE_PATH_PROPERTY = "redirect.resource.path";
+    
     private static final String DEFAULT_RESOURCE_EXTENSION = ".jsp";
     private static final String DEFAULT_LOCATION_PREFIX = "/WEB-INF/";
     
@@ -136,6 +138,9 @@ public class RequestDispatcherProvider e
                 }
             }
         }
+        if (mc != null && mc.get(MESSAGE_RESOURCE_PATH_PROPERTY) != null) {
+            return true;
+        }
         return false;
     }
 
@@ -226,8 +231,10 @@ public class RequestDispatcherProvider e
                 return resourcePaths.get(requestPath);
             }
         }
-        // won't happen given that isWriteable() returned true
-        return null;
+        
+        Object resourcePathProp = (String)mc.get(MESSAGE_RESOURCE_PATH_PROPERTY);
+        return resourcePathProp != null ? resourcePathProp.toString() : null;
+        
     }
     
     private String getRequestPath() {



Mime
View raw message