Author: bpapez
Date: Wed Jun 6 17:48:43 2007
New Revision: 17493
URL: https://svndev.jahia.net/websvn/listing.php?sc=3D1&rev=3D17493&repname=
=3Djahia
Log:
* JAHIA-1375: use concurrency API (Latch and Semaphore) instead of own conc=
urrency handling
* [no jira] remove unneeded db_support_embedded_select_statement option
Modified:
branches/JAHIA-5-0-SP-BRANCH/core/src/java/org/jahia/settings/SettingsB=
ean.java
branches/JAHIA-5-0-SP-BRANCH/core/src/webapp/WEB-INF/etc/config/jahia.s=
keleton
Modified: branches/JAHIA-5-0-SP-BRANCH/core/src/java/org/jahia/settings/Set=
tingsBean.java
URL: https://svndev.jahia.net/websvn/diff.php?path=3D/branches/JAHIA-5-0-SP=
-BRANCH/core/src/java/org/jahia/settings/SettingsBean.java&rev=3D17493&repn=
ame=3Djahia
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- branches/JAHIA-5-0-SP-BRANCH/core/src/java/org/jahia/settings/SettingsB=
ean.java (original)
+++ branches/JAHIA-5-0-SP-BRANCH/core/src/java/org/jahia/settings/SettingsB=
ean.java Wed Jun 6 17:48:43 2007
@@ -126,7 +126,6 @@
private boolean db_waitIfBusy;
private boolean db_verbose;
private boolean db_veryVerbose;
- private boolean db_support_embedded_select_statement;
=
// Characters encoding
private boolean utf8Encoding;
@@ -358,8 +357,8 @@
private int searchMaxHitsByPage =3D 10;
=
// Core engine page generation queue configuration parameters
- private int pageGenerationMaxRetryCount =3D 10000;
- private int pageGenerationLoopWaitTime =3D 1000; // in milliseconds
+ private int maxParallelProcessings =3D 10;
+ private long pageGenerationWaitTime =3D 1800000; // in milliseconds =
=
private int editModeSessionTimeout =3D 2*60*60; // 2 hours
=
@@ -505,7 +504,6 @@
db_waitIfBusy =3D getBoolean ("db_waitIfBusy");
db_verbose =3D getBoolean ("db_verbose");
db_veryVerbose =3D getBoolean("db_veryVerbose", false);
- db_support_embedded_select_statement =3D getBoolean("db_suppor=
t_embedded_select_statement", false);
=
// chars encoding
utf8Encoding =3D getBoolean("utf8Encoding");
@@ -766,8 +764,9 @@
searchMaxHitsByPage =3D getInt("searchMaxHitsByPage",searchMax=
HitsByPage);
searchMaxPages =3D getInt("searchMaxPages",searchMaxPages);
=
- pageGenerationMaxRetryCount =3D getInt("pageGenerationMaxRetry=
Count", 10000);
- pageGenerationLoopWaitTime =3D getInt("pageGenerationLoopWaitT=
ime", 1000);
+ // Maximum parallel heavy processing threads
+ maxParallelProcessings =3D getInt("maxParallelProcessings", ma=
xParallelProcessings);
+ pageGenerationWaitTime =3D getLong("pageGenerationWaitTime", p=
ageGenerationWaitTime); =
=
editModeSessionTimeout =3D getInt("editModeSessionTimeout", 2*=
60*60);
=
@@ -1605,10 +1604,6 @@
return db_waitIfBusy;
}
=
- public boolean isDb_support_embedded_select_statement() {
- return db_support_embedded_select_statement;
- }
-
public String getClassDiskPath() {
return classDiskPath;
}
@@ -2026,22 +2021,6 @@
this.searchMaxLuceneDocs =3D searchMaxLuceneDocs;
}
=
- public int getPageGenerationMaxRetryCount() {
- return pageGenerationMaxRetryCount;
- }
-
- public void setPageGenerationMaxRetryCount(int pageGenerationMaxRetryC=
ount) {
- this.pageGenerationMaxRetryCount =3D pageGenerationMaxRetryCount;
- }
-
- public int getPageGenerationLoopWaitTime() {
- return pageGenerationLoopWaitTime;
- }
-
- public void setPageGenerationLoopWaitTime(int pageGenerationLoopWaitTi=
me) {
- this.pageGenerationLoopWaitTime =3D pageGenerationLoopWaitTime;
- }
-
public int getCacheMaxGroups() {
return cacheMaxGroups;
}
@@ -2049,6 +2028,14 @@
public void setCacheMaxGroups(int cacheMaxGroups) {
this.cacheMaxGroups =3D cacheMaxGroups;
}
+ =
+ public long getPageGenerationWaitTime() {
+ return pageGenerationWaitTime;
+ }
+
+ public int getMaxParallelProcessings() {
+ return maxParallelProcessings;
+ } =
=
public boolean isOutputCacheExpirationOnly() {
return outputCacheExpirationOnly;
Modified: branches/JAHIA-5-0-SP-BRANCH/core/src/webapp/WEB-INF/etc/config/j=
ahia.skeleton
URL: https://svndev.jahia.net/websvn/diff.php?path=3D/branches/JAHIA-5-0-SP=
-BRANCH/core/src/webapp/WEB-INF/etc/config/jahia.skeleton&rev=3D17493&repna=
me=3Djahia
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- branches/JAHIA-5-0-SP-BRANCH/core/src/webapp/WEB-INF/etc/config/jahia.s=
keleton (original)
+++ branches/JAHIA-5-0-SP-BRANCH/core/src/webapp/WEB-INF/etc/config/jahia.s=
keleton Wed Jun 6 17:48:43 2007
@@ -122,7 +122,6 @@
db_username =3D sa
db_password =3D
db_transactions =3D false
-db_support_embedded_select_statement =3D true
db_starthsqlserver =3D true
db_min_connections =3D 10
db_max_connections =3D 50
@@ -466,34 +465,6 @@
org.jahia.pages.properties.preload_count =3D 2000
=
######################################################################
-### Page generation properties #######################################
-######################################################################
-# Jahia uses a page generation queue that allows a certain number
-# of threads to generate the same page in parallel, and the others
-# will be put to sleep until the pages have been generated. The
-# waiting threads will then read the page from the cache instead
-# of generating it, unless the page is a non-cacheable page.
-# The first parameter controls the number of threads that are
-# allowed to generate the same page in parallel. Keep this number
-# as low as possible. The default is 10, which should work for most
-# configurations. =
-pageGenerationMaxParallel =3D 10
-# This parameter controls the time each thread waits in a loop before
-# checking if the page has become available. This is a time in
-# milliseconds
-pageGenerationLoopWaitTime =3D 1000
-# The pageGenerationMaxRetryCount allows to control the maximum amount
-# of times Jahia will loop to try loading the page. So the total waiting
-# time will be at the worst case : pageGenerationLoopWaitTime *
-# pageGenerationMaxRetryCount. In the case where the maximum wait
-# time is reached, Jahia will abort the generating the page, and the
-# request will have failed. Keep this value high as this should only
-# happen on server failure, but on some installation we might still
-# want to wait a long time because Jahia might be busy, especially
-# when dealing with large datasets. =
-pageGenerationMaxRetryCount =3D 10000
-
-######################################################################
### Tidy Configuration file ##########################################
######################################################################
# Tidy is an HTML parser that is one of the multiple ones that is
@@ -567,6 +538,17 @@
processPipelineClassName =3D org.jahia.=
pipelines.impl.GenericPipeline
=
######################################################################
+### Concurrent processing options ####################################
+######################################################################
+#
+# This variable controls how many threads are allowed to do heavy weight =
+# processing (page creation not served from the cache)
+maxParallelProcessings =3D 10
+# This variable controls how long threads are waiting to be able to start
+# generating pages (in heavy load situations)
+pageGenerationWaitTime =3D 1800000
+
+######################################################################
### Cookie authentification valve config #############################
######################################################################
#
@@ -719,6 +701,9 @@
# (http://www.iana.org/assignments/multicast-addresses).
# Check out the assignement ranges to see if they may conflict with
# something that might be present on your network.
+
+# Here a default configuration for UDP Clustering
+
cluster.service.multicast.ip_address =3D 231.12.21.130
cluster.service.multicast.port =3D 45000
cluster.idgenerator.multicast.ip_address =3D 231.12.21.150
@@ -729,7 +714,7 @@
cluster.hibernate.multicast.port =3D 45050
=
# Here a default configuration for TCP Clustering
-# You will have to comment the UDP configuration and uncomment the tcp one=
s in the
+# You will have to comment the UDP configuration and uncomment the tcp one=
s int the
# following files :
#../spring/applicationcontext-dao.xml, ../spring/applicationcontext-hibern=
ate.xml,
# ../spring/applicationcontext-services.xml
_______________________________________________
cvs_list mailing list
[email protected]
http://lists.jahia.org/cgi-bin/mailman/listinfo/cvs_list