lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From no...@apache.org
Subject svn commit: r1693434 - in /lucene/dev/trunk/solr: core/src/java/org/apache/solr/request/ core/src/java/org/apache/solr/servlet/ solrj/src/java/org/apache/solr/client/solrj/impl/ solrj/src/java/org/apache/solr/common/util/
Date Thu, 30 Jul 2015 14:39:23 GMT
Author: noble
Date: Thu Jul 30 14:39:23 2015
New Revision: 1693434

URL: http://svn.apache.org/r1693434
Log:
SOLR-6625: formatting fixed

Modified:
    lucene/dev/trunk/solr/core/src/java/org/apache/solr/request/SolrQueryRequestContext.java
    lucene/dev/trunk/solr/core/src/java/org/apache/solr/servlet/SolrDispatchFilter.java
    lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java
    lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/common/util/ExecutorUtil.java

Modified: lucene/dev/trunk/solr/core/src/java/org/apache/solr/request/SolrQueryRequestContext.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/core/src/java/org/apache/solr/request/SolrQueryRequestContext.java?rev=1693434&r1=1693433&r2=1693434&view=diff
==============================================================================
--- lucene/dev/trunk/solr/core/src/java/org/apache/solr/request/SolrQueryRequestContext.java
(original)
+++ lucene/dev/trunk/solr/core/src/java/org/apache/solr/request/SolrQueryRequestContext.java
Thu Jul 30 14:39:23 2015
@@ -26,19 +26,19 @@ import org.apache.solr.client.solrj.impl
  */
 public class SolrQueryRequestContext extends SolrHttpContext {
   final private SolrQueryRequest solrQueryRequest;
-  
+
   public SolrQueryRequestContext(SolrQueryRequest solrQueryRequest) {
     this.solrQueryRequest = solrQueryRequest;
     setAttribute(SolrHttpContext.class.getName(), this);
   }
-  
+
   public SolrQueryRequest getSolrQueryRequest() {
     return solrQueryRequest;
   }
-  
+
   @Override
   public String toString() {
-    return "[SolrQueryRequestContext contains: "+solrQueryRequest+"]";
+    return "[SolrQueryRequestContext contains: " + solrQueryRequest + "]";
   }
 }
 

Modified: lucene/dev/trunk/solr/core/src/java/org/apache/solr/servlet/SolrDispatchFilter.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/core/src/java/org/apache/solr/servlet/SolrDispatchFilter.java?rev=1693434&r1=1693433&r2=1693434&view=diff
==============================================================================
--- lucene/dev/trunk/solr/core/src/java/org/apache/solr/servlet/SolrDispatchFilter.java (original)
+++ lucene/dev/trunk/solr/core/src/java/org/apache/solr/servlet/SolrDispatchFilter.java Thu
Jul 30 14:39:23 2015
@@ -119,7 +119,7 @@ public class SolrDispatchFilter extends
       if (this.cores.getAuthenticationPlugin() != null) {
         HttpClientConfigurer configurer = this.cores.getAuthenticationPlugin().getDefaultConfigurer();
         if (configurer != null) {
-          configurer.configure((DefaultHttpClient)httpClient, new ModifiableSolrParams());
+          configurer.configure((DefaultHttpClient) httpClient, new ModifiableSolrParams());
         }
       }
 

Modified: lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java?rev=1693434&r1=1693433&r2=1693434&view=diff
==============================================================================
--- lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java
(original)
+++ lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java
Thu Jul 30 14:39:23 2015
@@ -388,7 +388,7 @@ public class HttpClientUtil {
       Constructor<? extends SystemDefaultHttpClient> constructor;
       try {
         constructor = systemDefaultHttpClientClass.getDeclaredConstructor();
-          return constructor.newInstance();
+        return constructor.newInstance();
       } catch (NoSuchMethodException | SecurityException | InstantiationException | IllegalAccessException
| IllegalArgumentException | InvocationTargetException e) {
         throw new SolrException(ErrorCode.SERVER_ERROR, "Unable to create HttpClient instance.
", e);
       }
@@ -397,10 +397,10 @@ public class HttpClientUtil {
     public static DefaultHttpClient createHttpClient(ClientConnectionManager cm) {
       Constructor<? extends DefaultHttpClient> productConstructor;
       try {
-        productConstructor = defaultHttpClientClass.getDeclaredConstructor(new Class[] {
ClientConnectionManager.class });
-          return productConstructor.newInstance(new Object[] { cm });
+        productConstructor = defaultHttpClientClass.getDeclaredConstructor(new Class[]{ClientConnectionManager.class});
+        return productConstructor.newInstance(new Object[]{cm});
       } catch (NoSuchMethodException | SecurityException | InstantiationException | IllegalAccessException
| IllegalArgumentException | InvocationTargetException e) {
-        throw new SolrException(ErrorCode.SERVER_ERROR, "Unable to create HttpClient instance,
registered class is: "+defaultHttpClientClass, e);
+        throw new SolrException(ErrorCode.SERVER_ERROR, "Unable to create HttpClient instance,
registered class is: " + defaultHttpClientClass, e);
       }
     }
 

Modified: lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/common/util/ExecutorUtil.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/common/util/ExecutorUtil.java?rev=1693434&r1=1693433&r2=1693434&view=diff
==============================================================================
--- lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/common/util/ExecutorUtil.java (original)
+++ lucene/dev/trunk/solr/solrj/src/java/org/apache/solr/common/util/ExecutorUtil.java Thu
Jul 30 14:39:23 2015
@@ -169,7 +169,7 @@ public class ExecutorUtil {
       StringBuilder contextString = new StringBuilder();
       if (submitterContext != null) {
         Collection<String> values = submitterContext.values();
-        
+
         for (String value : values) {
           contextString.append(value + " ");
         }
@@ -177,13 +177,13 @@ public class ExecutorUtil {
           contextString.setLength(contextString.length() - 1);
         }
       }
-      
+
       String ctxStr = contextString.toString().replace("/", "//");
       final String submitterContextStr = ctxStr.length() <= MAX_THREAD_NAME_LEN ? ctxStr
: ctxStr.substring(0, MAX_THREAD_NAME_LEN);
       final Exception submitterStackTrace = new Exception("Submitter stack trace");
       final List<InheritableThreadLocalProvider> providersCopy = providers;
-      final ArrayList<AtomicReference> ctx = providersCopy.isEmpty()? null: new ArrayList<>(providersCopy.size());
-      if(ctx != null) {
+      final ArrayList<AtomicReference> ctx = providersCopy.isEmpty() ? null : new ArrayList<>(providersCopy.size());
+      if (ctx != null) {
         for (int i = 0; i < providers.size(); i++) {
           AtomicReference reference = new AtomicReference();
           ctx.add(reference);
@@ -193,7 +193,7 @@ public class ExecutorUtil {
       super.execute(new Runnable() {
         @Override
         public void run() {
-          if(ctx != null) {
+          if (ctx != null) {
             for (int i = 0; i < providersCopy.size(); i++) providersCopy.get(i).set(ctx.get(i));
           }
           Map<String, String> threadContext = MDC.getCopyOfContextMap();
@@ -208,7 +208,7 @@ public class ExecutorUtil {
           try {
             command.run();
           } catch (Throwable t) {
-            if (t instanceof OutOfMemoryError)  {
+            if (t instanceof OutOfMemoryError) {
               throw t;
             }
             log.error("Uncaught exception {} thrown by thread: {}", t, currentThread.getName(),
submitterStackTrace);
@@ -219,7 +219,7 @@ public class ExecutorUtil {
             } else {
               MDC.clear();
             }
-            if(ctx != null) {
+            if (ctx != null) {
               for (int i = 0; i < providersCopy.size(); i++) providersCopy.get(i).clean(ctx.get(i));
             }
             currentThread.setName(oldName);



Mime
View raw message