chemistry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From f...@apache.org
Subject svn commit: r1331566 - in /chemistry/opencmis/trunk: chemistry-opencmis-client/chemistry-opencmis-client-bindings/src/main/java/org/apache/chemistry/opencmis/client/bindings/spi/local/ chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/...
Date Fri, 27 Apr 2012 20:08:44 GMT
Author: fmui
Date: Fri Apr 27 20:08:43 2012
New Revision: 1331566

URL: http://svn.apache.org/viewvc?rev=1331566&view=rev
Log:
renamed maxSize to maxContentSize

Modified:
    chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-bindings/src/main/java/org/apache/chemistry/opencmis/client/bindings/spi/local/AbstractLocalService.java
    chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CallContext.java
    chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CmisServiceFactory.java
    chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/server/AbstractServiceFactory.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/CallContextImpl.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/AtomEntryParser.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/CmisAtomPubServlet.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/MultiFilingService.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/ObjectService.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/PolicyService.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/VersioningService.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/CmisBrowserBindingServlet.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/POSTHttpServletRequestWrapper.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/HttpUtils.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/ThresholdOutputStream.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/ConfigConstants.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/DummyCallContext.java
    chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/server/InMemoryServiceFactoryImpl.java

Modified: chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-bindings/src/main/java/org/apache/chemistry/opencmis/client/bindings/spi/local/AbstractLocalService.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-bindings/src/main/java/org/apache/chemistry/opencmis/client/bindings/spi/local/AbstractLocalService.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-bindings/src/main/java/org/apache/chemistry/opencmis/client/bindings/spi/local/AbstractLocalService.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-client/chemistry-opencmis-client-bindings/src/main/java/org/apache/chemistry/opencmis/client/bindings/spi/local/AbstractLocalService.java
Fri Apr 27 20:08:43 2012
@@ -146,7 +146,7 @@ public abstract class AbstractLocalServi
             return 0;
         }
 
-        public long getMaxSize() {
+        public long getMaxContentSize() {
             return -1;
         }
     }

Modified: chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CallContext.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CallContext.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CallContext.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CallContext.java
Fri Apr 27 20:08:43 2012
@@ -46,7 +46,7 @@ public interface CallContext {
 
     String TEMP_DIR = "tempDir";
     String MEMORY_THRESHOLD = "memoryThreshold";
-    String MAX_SIZE = "maxSize";
+    String MAX_CONTENT_SIZE = "maxContentSize";
 
     /**
      * Returns the binding. Usually it returns
@@ -113,5 +113,5 @@ public interface CallContext {
     /**
      * Returns the may size of content.
      */
-    long getMaxSize();
+    long getMaxContentSize();
 }

Modified: chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CmisServiceFactory.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CmisServiceFactory.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CmisServiceFactory.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-api/src/main/java/org/apache/chemistry/opencmis/commons/server/CmisServiceFactory.java
Fri Apr 27 20:08:43 2012
@@ -72,5 +72,5 @@ public interface CmisServiceFactory {
      * 
      * @return the max size in bytes or -1 to disable the size check
      */
-    long getMaxSize();
+    long getMaxContentSize();
 }

Modified: chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/server/AbstractServiceFactory.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/server/AbstractServiceFactory.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/server/AbstractServiceFactory.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/server/AbstractServiceFactory.java
Fri Apr 27 20:08:43 2012
@@ -53,7 +53,7 @@ public abstract class AbstractServiceFac
     /**
      * Returns a max size of 4 GiB.
      */
-    public long getMaxSize() {
+    public long getMaxContentSize() {
         return (long) 4 * 1024 * 1024 * 1024;
     }
 }

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/CallContextImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/CallContextImpl.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/CallContextImpl.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/CallContextImpl.java
Fri Apr 27 20:08:43 2012
@@ -84,8 +84,8 @@ public class CallContextImpl implements 
         return (Integer) get(MEMORY_THRESHOLD);
     }
 
-    public long getMaxSize() {
-        return (Long) get(MAX_SIZE);
+    public long getMaxContentSize() {
+        return (Long) get(MAX_CONTENT_SIZE);
     }
 
     /**

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/AtomEntryParser.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/AtomEntryParser.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/AtomEntryParser.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/AtomEntryParser.java
Fri Apr 27 20:08:43 2012
@@ -75,7 +75,7 @@ public class AtomEntryParser {
 
     private File tempDir;
     private int memoryThreshold;
-    private long maxSize;
+    private long maxContentSize;
 
     private ObjectData object;
     private ContentStreamImpl atomContentStream;
@@ -84,17 +84,17 @@ public class AtomEntryParser {
     /**
      * Constructor.
      */
-    public AtomEntryParser(File tempDir, int memoryThreshold, long maxSize) {
+    public AtomEntryParser(File tempDir, int memoryThreshold, long maxContentSize) {
         this.tempDir = tempDir;
         this.memoryThreshold = memoryThreshold;
-        this.maxSize = maxSize;
+        this.maxContentSize = maxContentSize;
     }
 
     /**
      * Constructor that immediately parses the given stream.
      */
-    public AtomEntryParser(InputStream stream, File tempDir, int memoryThreshold, long maxSize)
throws Exception {
-        this(tempDir, memoryThreshold, maxSize);
+    public AtomEntryParser(InputStream stream, File tempDir, int memoryThreshold, long maxContentSize)
throws Exception {
+        this(tempDir, memoryThreshold, maxContentSize);
         parse(stream);
     }
 
@@ -385,7 +385,7 @@ public class AtomEntryParser {
      * Parses a tag that contains base64 encoded content.
      */
     private ThresholdOutputStream readBase64(XMLStreamReader parser) throws Exception {
-        ThresholdOutputStream bufferStream = new ThresholdOutputStream(tempDir, memoryThreshold,
maxSize);
+        ThresholdOutputStream bufferStream = new ThresholdOutputStream(tempDir, memoryThreshold,
maxContentSize);
         Base64.OutputStream b64stream = new Base64.OutputStream(bufferStream, Base64.DECODE);
 
         next(parser);

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/CmisAtomPubServlet.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/CmisAtomPubServlet.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/CmisAtomPubServlet.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/CmisAtomPubServlet.java
Fri Apr 27 20:08:43 2012
@@ -94,7 +94,7 @@ public class CmisAtomPubServlet extends 
 
     private File tempDir;
     private int memoryThreshold;
-    private long maxSize;
+    private long maxContentSize;
 
     private Dispatcher dispatcher;
     private CallContextHandler callContextHandler;
@@ -120,7 +120,7 @@ public class CmisAtomPubServlet extends 
 
         tempDir = factory.getTempDirectory();
         memoryThreshold = factory.getMemoryThreshold();
-        maxSize = factory.getMaxSize();
+        maxContentSize = factory.getMaxContentSize();
 
         // initialize the dispatcher
         dispatcher = new Dispatcher();
@@ -176,7 +176,7 @@ public class CmisAtomPubServlet extends 
         CallContext context = null;
         try {
             context = HttpUtils.createContext(request, response, getServletContext(), CallContext.BINDING_ATOMPUB,
-                    callContextHandler, tempDir, memoryThreshold, maxSize);
+                    callContextHandler, tempDir, memoryThreshold, maxContentSize);
             dispatch(context, request, response);
         } catch (Exception e) {
             if (e instanceof CmisPermissionDeniedException) {

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/MultiFilingService.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/MultiFilingService.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/MultiFilingService.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/MultiFilingService.java
Fri Apr 27 20:08:43 2012
@@ -54,7 +54,7 @@ public class MultiFilingService {
         String removeFrom = getStringParameter(request, Constants.PARAM_REMOVE_FROM);
 
         AtomEntryParser parser = new AtomEntryParser(context.getTempDirectory(), context.getMemoryThreshold(),
-                context.getMaxSize());
+                context.getMaxContentSize());
         parser.setIgnoreAtomContentSrc(true); // needed for some clients
         parser.parse(request.getInputStream());
 

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/ObjectService.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/ObjectService.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/ObjectService.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/ObjectService.java
Fri Apr 27 20:08:43 2012
@@ -82,7 +82,7 @@ public final class ObjectService {
                 VersioningState.class);
 
         AtomEntryParser parser = new AtomEntryParser(context.getTempDirectory(), context.getMemoryThreshold(),
-                context.getMaxSize());
+                context.getMaxContentSize());
         parser.setIgnoreAtomContentSrc(true); // needed for some clients
         parser.parse(request.getInputStream());
 
@@ -139,7 +139,7 @@ public final class ObjectService {
             HttpServletRequest request, HttpServletResponse response) throws Exception {
         // get parameters
         AtomEntryParser parser = new AtomEntryParser(request.getInputStream(), context.getTempDirectory(),
-                context.getMemoryThreshold(), context.getMaxSize());
+                context.getMemoryThreshold(), context.getMaxContentSize());
 
         // execute
         String newObjectId = service.createRelationship(repositoryId, parser.getProperties(),
parser.getPolicyIds(),
@@ -450,7 +450,7 @@ public final class ObjectService {
         Boolean major = getBooleanParameter(request, Constants.PARAM_MAJOR);
 
         AtomEntryParser parser = new AtomEntryParser(request.getInputStream(), context.getTempDirectory(),
-                context.getMemoryThreshold(), context.getMaxSize());
+                context.getMemoryThreshold(), context.getMaxContentSize());
 
         // execute
         Holder<String> objectIdHolder = new Holder<String>(objectId);

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/PolicyService.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/PolicyService.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/PolicyService.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/PolicyService.java
Fri Apr 27 20:08:43 2012
@@ -111,7 +111,7 @@ public class PolicyService {
         String objectId = getStringParameter(request, Constants.PARAM_ID);
 
         AtomEntryParser parser = new AtomEntryParser(request.getInputStream(), context.getTempDirectory(),
-                context.getMemoryThreshold(), context.getMaxSize());
+                context.getMemoryThreshold(), context.getMaxContentSize());
 
         // execute
         service.applyPolicy(repositoryId, parser.getId(), objectId, null);

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/VersioningService.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/VersioningService.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/VersioningService.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/atompub/VersioningService.java
Fri Apr 27 20:08:43 2012
@@ -54,7 +54,7 @@ public class VersioningService {
             HttpServletRequest request, HttpServletResponse response) throws Exception {
         // get parameters
         AtomEntryParser parser = new AtomEntryParser(context.getTempDirectory(), context.getMemoryThreshold(),
-                context.getMaxSize());
+                context.getMaxContentSize());
         parser.setIgnoreAtomContentSrc(true); // needed for some clients
         parser.parse(request.getInputStream());
 

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/CmisBrowserBindingServlet.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/CmisBrowserBindingServlet.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/CmisBrowserBindingServlet.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/CmisBrowserBindingServlet.java
Fri Apr 27 20:08:43 2012
@@ -126,7 +126,7 @@ public class CmisBrowserBindingServlet e
 
     private File tempDir;
     private int memoryThreshold;
-    private long maxSize;
+    private long maxContentSize;
 
     private Dispatcher repositoryDispatcher;
     private Dispatcher rootDispatcher;
@@ -153,7 +153,7 @@ public class CmisBrowserBindingServlet e
 
         tempDir = factory.getTempDirectory();
         memoryThreshold = factory.getMemoryThreshold();
-        maxSize = factory.getMaxSize();
+        maxContentSize = factory.getMaxContentSize();
 
         // initialize the dispatchers
         repositoryDispatcher = new Dispatcher(false);
@@ -246,7 +246,7 @@ public class CmisBrowserBindingServlet e
         CallContext context = null;
         try {
             context = HttpUtils.createContext(request, response, getServletContext(), CallContext.BINDING_BROWSER,
-                    callContextHandler, tempDir, memoryThreshold, maxSize);
+                    callContextHandler, tempDir, memoryThreshold, maxContentSize);
             dispatch(context, request, response);
         } catch (Exception e) {
             if (e instanceof CmisPermissionDeniedException) {
@@ -349,7 +349,7 @@ public class CmisBrowserBindingServlet e
                 }
             } else if (METHOD_POST.equals(method)) {
                 POSTHttpServletRequestWrapper postRequest = new POSTHttpServletRequestWrapper(request,
tempDir,
-                        memoryThreshold, maxSize);
+                        memoryThreshold, maxContentSize);
 
                 String cmisaction = getStringParameter(postRequest, Constants.CONTROL_CMISACTION);
                 String objectId = getStringParameter(postRequest, Constants.CONTROL_OBJECT_ID);

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/POSTHttpServletRequestWrapper.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/POSTHttpServletRequestWrapper.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/POSTHttpServletRequestWrapper.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/browser/POSTHttpServletRequestWrapper.java
Fri Apr 27 20:08:43 2012
@@ -47,7 +47,7 @@ public class POSTHttpServletRequestWrapp
     private BigInteger size;
     private InputStream stream;
 
-    public POSTHttpServletRequestWrapper(HttpServletRequest request, File tempDir, int memoryThreshold,
long maxSize)
+    public POSTHttpServletRequestWrapper(HttpServletRequest request, File tempDir, int memoryThreshold,
long maxContentSize)
             throws Exception {
         super(request);
 
@@ -93,7 +93,7 @@ public class POSTHttpServletRequestWrapp
                     contentType = (item.getContentType() == null ? Constants.MEDIATYPE_OCTETSTREAM
: item
                             .getContentType());
 
-                    ThresholdOutputStream os = new ThresholdOutputStream(tempDir, memoryThreshold,
maxSize);
+                    ThresholdOutputStream os = new ThresholdOutputStream(tempDir, memoryThreshold,
maxContentSize);
 
                     try {
                         byte[] buffer = new byte[64 * 1024];

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/HttpUtils.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/HttpUtils.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/HttpUtils.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/HttpUtils.java
Fri Apr 27 20:08:43 2012
@@ -45,7 +45,7 @@ public class HttpUtils {
      */
     public static CallContext createContext(HttpServletRequest request, HttpServletResponse
response,
             ServletContext servletContext, String binding, CallContextHandler callContextHandler,
File tempDir,
-            int memoryThreshold, long maxSize) {
+            int memoryThreshold, long maxContentSize) {
         String[] pathFragments = splitPath(request);
 
         String repositoryId = null;
@@ -73,7 +73,7 @@ public class HttpUtils {
         // content
         context.put(CallContext.TEMP_DIR, tempDir);
         context.put(CallContext.MEMORY_THRESHOLD, memoryThreshold);
-        context.put(CallContext.MAX_SIZE, maxSize);
+        context.put(CallContext.MAX_CONTENT_SIZE, maxContentSize);
 
         // decode range
         String rangeHeader = request.getHeader("Range");

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/ThresholdOutputStream.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/ThresholdOutputStream.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/ThresholdOutputStream.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/shared/ThresholdOutputStream.java
Fri Apr 27 20:08:43 2012
@@ -46,7 +46,7 @@ public class ThresholdOutputStream exten
 
     private File tempDir;
     private int memoryThreshold;
-    private long maxSize;
+    private long maxContentSize;
 
     private byte[] buf = null;
     private int bufSize = 0;
@@ -61,11 +61,11 @@ public class ThresholdOutputStream exten
      *            temp directory
      * @param memoryThreshold
      *            memory threshold in bytes
-     * @param maxSize
+     * @param maxContentSize
      *            max size of the content in bytes (-1 to disable the check)
      */
-    public ThresholdOutputStream(File tempDir, int memoryThreshold, long maxSize) {
-        this(64 * 1024, tempDir, memoryThreshold, maxSize);
+    public ThresholdOutputStream(File tempDir, int memoryThreshold, long maxContentSize)
{
+        this(64 * 1024, tempDir, memoryThreshold, maxContentSize);
     }
 
     /**
@@ -77,17 +77,17 @@ public class ThresholdOutputStream exten
      *            temp directory
      * @param memoryThreshold
      *            memory threshold in bytes
-     * @param maxSize
+     * @param maxContentSize
      *            max size of the content in bytes (-1 to disable the check)
      */
-    public ThresholdOutputStream(int initSize, File tempDir, int memoryThreshold, long maxSize)
{
+    public ThresholdOutputStream(int initSize, File tempDir, int memoryThreshold, long maxContentSize)
{
         if (initSize < 0) {
             throw new IllegalArgumentException("Negative initial size: " + initSize);
         }
 
         this.tempDir = tempDir;
         this.memoryThreshold = (memoryThreshold < 0 ? DEFAULT_THRESHOLD : memoryThreshold);
-        this.maxSize = maxSize;
+        this.maxContentSize = maxContentSize;
 
         buf = new byte[initSize];
     }
@@ -135,7 +135,7 @@ public class ThresholdOutputStream exten
                 return;
             }
 
-            if ((maxSize > -1) && (size + len > maxSize)) {
+            if ((maxContentSize > -1) && (size + len > maxContentSize)) {
                 destroy();
                 throw new CmisConstraintException("Content too big!");
             }
@@ -153,7 +153,7 @@ public class ThresholdOutputStream exten
     @Override
     public void write(int oneByte) throws IOException {
         try {
-            if ((maxSize > -1) && (size + 1 > maxSize)) {
+            if ((maxContentSize > -1) && (size + 1 > maxContentSize)) {
                 destroy();
                 throw new CmisConstraintException("Content too big!");
             }

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/ConfigConstants.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/ConfigConstants.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/ConfigConstants.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/ConfigConstants.java
Fri Apr 27 20:08:43 2012
@@ -27,7 +27,7 @@ public class ConfigConstants {
     public static final String OVERRIDE_CALL_CONTEXT = "InMemoryServer.OverrideCallContext";
     public static final String MEMORY_THRESHOLD = "InMemoryServer.MemoryThreshold";
     public static final String TEMP_DIR = "InMemoryServer.TempDir";
-    public static final String MAX_SIZE = "InMemoryServer.MaxSize";
+    public static final String MAX_CONTENT_SIZE = "InMemoryServer.MaxContentSize";
 
     // Helper constants that allow to fill a repository with data on
     // initialization

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/DummyCallContext.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/DummyCallContext.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/DummyCallContext.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/DummyCallContext.java
Fri Apr 27 20:08:43 2012
@@ -90,7 +90,7 @@ public class DummyCallContext implements
         return 4 * 1024 * 1024;
     }
 
-    public long getMaxSize() {
+    public long getMaxContentSize() {
         return 4 * 1024 * 1024 * 1024;
     }
 }

Modified: chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/server/InMemoryServiceFactoryImpl.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/server/InMemoryServiceFactoryImpl.java?rev=1331566&r1=1331565&r2=1331566&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/server/InMemoryServiceFactoryImpl.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/src/main/java/org/apache/chemistry/opencmis/inmemory/server/InMemoryServiceFactoryImpl.java
Fri Apr 27 20:08:43 2012
@@ -80,7 +80,7 @@ public class InMemoryServiceFactoryImpl 
 
     private File tempDir;
     private int memoryThreshold;
-    private long maxSize;
+    private long maxContentSize;
 
     @Override
     public void init(Map<String, String> parameters) {
@@ -112,12 +112,12 @@ public class InMemoryServiceFactoryImpl 
         memoryThreshold = (memoryThresholdStr == null ? super.getMemoryThreshold() : Integer
                 .parseInt(memoryThresholdStr));
         
-        String maxSizeStr = parameters.get(ConfigConstants.MAX_SIZE);
-        maxSize = (maxSizeStr == null ? super.getMaxSize() : Long.parseLong(maxSizeStr));
+        String maxContentSizeStr = parameters.get(ConfigConstants.MAX_CONTENT_SIZE);
+        maxContentSize = (maxContentSizeStr == null ? super.getMaxContentSize() : Long.parseLong(maxContentSizeStr));
 
-        System.out.println("maxSizeStr > " + maxSizeStr);
-        System.out.println("super.getMaxSize() > " + super.getMaxSize());
-        System.out.println("content > " + tempDir + " / " + memoryThreshold + " / " +
 maxSize);
+        System.out.println("maxSizeStr > " + maxContentSizeStr);
+        System.out.println("super.getMaxSize() > " + super.getMaxContentSize());
+        System.out.println("content > " + tempDir + " / " + memoryThreshold + " / " +
 maxContentSize);
         
         Date deploymentTime = new Date();
         String strDate = new SimpleDateFormat("EEE MMM dd hh:mm:ss a z yyyy", Locale.US).format(deploymentTime);
@@ -178,8 +178,8 @@ public class InMemoryServiceFactoryImpl 
     }
 
     @Override
-    public long getMaxSize() {
-        return maxSize;
+    public long getMaxContentSize() {
+        return maxContentSize;
     }
 
     @Override
@@ -332,8 +332,8 @@ public class InMemoryServiceFactoryImpl 
                 return memoryThreshold;
             }
 
-            public long getMaxSize() {
-                return maxSize;
+            public long getMaxContentSize() {
+                return maxContentSize;
             }
         }
 



Mime
View raw message