cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1300530 - in /cxf/trunk: api/src/main/java/org/apache/cxf/staxutils/ rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/ rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/ systests/jaxrs/src/test/resources/jaxrs/WEB-INF/
Date Wed, 14 Mar 2012 12:58:17 GMT
Author: sergeyb
Date: Wed Mar 14 12:58:17 2012
New Revision: 1300530

URL: http://svn.apache.org/viewvc?rev=1300530&view=rev
Log:
[CXF-4172] Making the names of context properties shorter similar to the attachment properties

Modified:
    cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/DocumentDepthProperties.java
    cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/StaxUtils.java
    cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/AbstractJAXBProvider.java
    cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/FormUtils.java
    cxf/trunk/systests/jaxrs/src/test/resources/jaxrs/WEB-INF/beans.xml

Modified: cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/DocumentDepthProperties.java
URL: http://svn.apache.org/viewvc/cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/DocumentDepthProperties.java?rev=1300530&r1=1300529&r2=1300530&view=diff
==============================================================================
--- cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/DocumentDepthProperties.java (original)
+++ cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/DocumentDepthProperties.java Wed
Mar 14 12:58:17 2012
@@ -19,6 +19,11 @@
 package org.apache.cxf.staxutils;
 
 public class DocumentDepthProperties {
+    
+    public static final String TOTAL_ELEMENT_COUNT = "depthTotalElementCountThreshold";
+    public static final String INNER_ELEMENT_COUNT = "depthInnerElementCountThreshold";
+    public static final String INNER_ELEMENT_LEVEL = "depthInnerElementLevelThreshold";
+    
     private int elementCountThreshold = -1;
     private int innerElementLevelThreshold = -1;
     private int innerElementCountThreshold = -1;

Modified: cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/StaxUtils.java
URL: http://svn.apache.org/viewvc/cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/StaxUtils.java?rev=1300530&r1=1300529&r2=1300530&view=diff
==============================================================================
--- cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/StaxUtils.java (original)
+++ cxf/trunk/api/src/main/java/org/apache/cxf/staxutils/StaxUtils.java Wed Mar 14 12:58:17
2012
@@ -82,9 +82,10 @@ import org.apache.cxf.helpers.DOMUtils;
 import org.apache.cxf.helpers.XMLUtils;
 
 public final class StaxUtils {
-    public static final String TOTAL_ELEMENT_COUNT = "org.apache.cxf.staxutils.totalElementCountThreshold";
-    public static final String INNER_ELEMENT_COUNT = "org.apache.cxf.staxutils.innerElementCountThreshold";
-    public static final String INNER_ELEMENT_LEVEL = "org.apache.cxf.staxutils.innerElementLevelThreshold";
+    private static final String INNER_ELEMENT_COUNT_SYSTEM_PROP = 
+        "org.apache.cxf.staxutils.innerElementCountThreshold";
+    private static final String INNER_ELEMENT_LEVEL_SYSTEM_PROP = 
+        "org.apache.cxf.staxutils.innerElementLevelThreshold";
     
     private static final Logger LOG = LogUtils.getL7dLogger(StaxUtils.class);
     
@@ -118,7 +119,7 @@ public final class StaxUtils {
         NS_AWARE_INPUT_FACTORY_POOL = new LinkedBlockingQueue<XMLInputFactory>(i);
         OUTPUT_FACTORY_POOL = new LinkedBlockingQueue<XMLOutputFactory>(i);
         try {
-            String s =  SystemPropertyAction.getProperty(INNER_ELEMENT_LEVEL, "-1");
+            String s =  SystemPropertyAction.getProperty(INNER_ELEMENT_LEVEL_SYSTEM_PROP,
"-1");
             innerElementLevelThreshold = Integer.parseInt(s);
         } catch (Throwable t) {
             innerElementLevelThreshold = -1;
@@ -127,7 +128,7 @@ public final class StaxUtils {
             innerElementLevelThreshold = -1;
         }
         try {
-            String s =  SystemPropertyAction.getProperty(INNER_ELEMENT_COUNT, "-1");
+            String s =  SystemPropertyAction.getProperty(INNER_ELEMENT_COUNT_SYSTEM_PROP,
"-1");
             innerElementCountThreshold = Integer.parseInt(s);
         } catch (Throwable t) {
             innerElementCountThreshold = -1;

Modified: cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/AbstractJAXBProvider.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/AbstractJAXBProvider.java?rev=1300530&r1=1300529&r2=1300530&view=diff
==============================================================================
--- cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/AbstractJAXBProvider.java
(original)
+++ cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/AbstractJAXBProvider.java
Wed Mar 14 12:58:17 2012
@@ -77,7 +77,6 @@ import org.apache.cxf.phase.PhaseInterce
 import org.apache.cxf.staxutils.DepthRestrictingStreamReader;
 import org.apache.cxf.staxutils.DepthXMLStreamReader;
 import org.apache.cxf.staxutils.DocumentDepthProperties;
-import org.apache.cxf.staxutils.StaxUtils;
 import org.apache.cxf.staxutils.transform.TransformUtils;
 
 public abstract class AbstractJAXBProvider<T> extends AbstractConfigurableProvider
@@ -634,11 +633,11 @@ public abstract class AbstractJAXBProvid
         }
         if (getContext() != null) {
             String totalElementCountStr = (String)getContext().getContextualProperty(
-                StaxUtils.TOTAL_ELEMENT_COUNT);
+                DocumentDepthProperties.TOTAL_ELEMENT_COUNT);
             String innerElementCountStr = (String)getContext().getContextualProperty(
-                StaxUtils.INNER_ELEMENT_COUNT);
+                DocumentDepthProperties.INNER_ELEMENT_COUNT);
             String elementLevelStr = (String)getContext().getContextualProperty(
-                StaxUtils.INNER_ELEMENT_LEVEL);
+                DocumentDepthProperties.INNER_ELEMENT_LEVEL);
             if (totalElementCountStr != null || innerElementCountStr != null || elementLevelStr
!= null) {
                 try {
                     int totalElementCount = totalElementCountStr != null 

Modified: cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/FormUtils.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/FormUtils.java?rev=1300530&r1=1300529&r2=1300530&view=diff
==============================================================================
--- cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/FormUtils.java (original)
+++ cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/FormUtils.java Wed
Mar 14 12:58:17 2012
@@ -49,7 +49,7 @@ public final class FormUtils {
     
     private static final Logger LOG = LogUtils.getL7dLogger(FormUtils.class);
     private static final String MULTIPART_FORM_DATA_TYPE = "form-data";  
-    private static final String MAX_FORM_PARAM_COUNT = "org.apache.cxf.form.maxParameterCount";
 
+    private static final String MAX_FORM_PARAM_COUNT = "maxFormParameterCount";  
         
     private FormUtils() {
         

Modified: cxf/trunk/systests/jaxrs/src/test/resources/jaxrs/WEB-INF/beans.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/systests/jaxrs/src/test/resources/jaxrs/WEB-INF/beans.xml?rev=1300530&r1=1300529&r2=1300530&view=diff
==============================================================================
--- cxf/trunk/systests/jaxrs/src/test/resources/jaxrs/WEB-INF/beans.xml (original)
+++ cxf/trunk/systests/jaxrs/src/test/resources/jaxrs/WEB-INF/beans.xml Wed Mar 14 12:58:17
2012
@@ -210,7 +210,7 @@ http://cxf.apache.org/schemas/core.xsd">
       </bean>
     </jaxrs:inInterceptors>
     <jaxrs:properties>
-       <entry key="org.apache.cxf.form.maxParameterCount" value="2"/>
+       <entry key="maxFormParameterCount" value="2"/>
     </jaxrs:properties>
         
   </jaxrs:server>
@@ -221,7 +221,7 @@ http://cxf.apache.org/schemas/core.xsd">
       <ref bean="serviceBean" />
     </jaxrs:serviceBeans>		   
     <jaxrs:properties>
-       <entry key="org.apache.cxf.staxutils.innerElementCountThreshold" value="2"/>
+       <entry key="depthInnerElementCountThreshold" value="2"/>
     </jaxrs:properties>
         
   </jaxrs:server>



Mime
View raw message