Blame SOURCES/maven2-2.2.1-default-resolver-pool-size.patch

ccba2a
From 9c7b1812cbca35f8bd9997e6b5e3ce93f3191840 Mon Sep 17 00:00:00 2001
ccba2a
From: Stanislav Ochotnicky <sochotnicky@redhat.com>
ccba2a
Date: Mon, 28 Jun 2010 15:39:30 +0200
ccba2a
Subject: [PATCH] change default resolver pool size in jpp mode
ccba2a
ccba2a
---
ccba2a
 .../artifact/resolver/DefaultArtifactResolver.java |    9 ++++++++-
ccba2a
 1 files changed, 8 insertions(+), 1 deletions(-)
ccba2a
ccba2a
diff --git a/maven-artifact-manager/src/main/java/org/apache/maven/artifact/resolver/DefaultArtifactResolver.java b/maven-artifact-manager/src/main/java/org/apache/maven/artifact/resolver/DefaultArtifactResolver.java
ccba2a
index d8c3629..0c40881 100644
ccba2a
--- a/maven-artifact-manager/src/main/java/org/apache/maven/artifact/resolver/DefaultArtifactResolver.java
ccba2a
+++ b/maven-artifact-manager/src/main/java/org/apache/maven/artifact/resolver/DefaultArtifactResolver.java
ccba2a
@@ -61,7 +61,14 @@ public class DefaultArtifactResolver
ccba2a
     // Components
ccba2a
     // ----------------------------------------------------------------------
ccba2a
 
ccba2a
-    private static final int DEFAULT_POOL_SIZE = 5;
ccba2a
+    private static final int DEFAULT_POOL_SIZE;
ccba2a
+    static {
ccba2a
+        if (System.getProperty("maven2.jpp.mode") == null) {
ccba2a
+            DEFAULT_POOL_SIZE = 5;
ccba2a
+        } else {
ccba2a
+            DEFAULT_POOL_SIZE = 1;
ccba2a
+        }
ccba2a
+    }
ccba2a
 
ccba2a
     private WagonManager wagonManager;
ccba2a
 
ccba2a
-- 
ccba2a
1.7.0.1
ccba2a