incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bdelacre...@apache.org
Subject svn commit: r603045 - /incubator/sling/trunk/microsling/microsling-core/src/main/java/org/apache/sling/microsling/slingservlets/DefaultSlingServlet.java
Date Mon, 10 Dec 2007 20:55:35 GMT
Author: bdelacretaz
Date: Mon Dec 10 12:55:34 2007
New Revision: 603045

URL: http://svn.apache.org/viewvc?rev=603045&view=rev
Log:
SLING-117 - workaround for resources resolved up the path removed from DefaultSlingServlet

Modified:
    incubator/sling/trunk/microsling/microsling-core/src/main/java/org/apache/sling/microsling/slingservlets/DefaultSlingServlet.java

Modified: incubator/sling/trunk/microsling/microsling-core/src/main/java/org/apache/sling/microsling/slingservlets/DefaultSlingServlet.java
URL: http://svn.apache.org/viewvc/incubator/sling/trunk/microsling/microsling-core/src/main/java/org/apache/sling/microsling/slingservlets/DefaultSlingServlet.java?rev=603045&r1=603044&r2=603045&view=diff
==============================================================================
--- incubator/sling/trunk/microsling/microsling-core/src/main/java/org/apache/sling/microsling/slingservlets/DefaultSlingServlet.java
(original)
+++ incubator/sling/trunk/microsling/microsling-core/src/main/java/org/apache/sling/microsling/slingservlets/DefaultSlingServlet.java
Mon Dec 10 12:55:34 2007
@@ -101,22 +101,6 @@
             }
         } else if(r.adaptTo(Node.class) != null || r.adaptTo(SyntheticResourceData.class)
!= null) {
 
-            if(r.adaptTo(Node.class) != null) {
-                // When rendering Nodes,
-                // make sure we have an Item, and render it via one of our renderingServlets
-                final String suffix = req.getRequestPathInfo().getSuffix();
-                if(suffix != null && suffix.length() > 0) {
-                    // accept exact addressing only for default rendering:
-                    // a non-empty suffix means there was extra stuff after the path
-                    // of the resource
-                    throw new HttpStatusCodeException(
-                            HttpServletResponse.SC_NOT_FOUND,
-                            "Ancestor resource found (" + r.getResourceMetadata().get(ResourceMetadata.RESOLUTION_PATH)
+ ")"
-                            + " but URL suffix must be empty for default rendering (suffix="
+ suffix + ")"
-                    );
-                }
-            }
-            
             final String contentType = req.getResponseContentType();
             final Servlet s = renderingServlets.get(contentType);
             if(s!=null) {



Mime
View raw message