diff --git a/content/post/2017-12.md b/content/post/2017-12.md
index 2ae9a444e..24a2bffb8 100644
--- a/content/post/2017-12.md
+++ b/content/post/2017-12.md
@@ -423,18 +423,18 @@ $ schedtool -D -e ionice -c2 -n7 nice -n19 dspace index-discovery
- Then I create a global `Resource` in the main Tomcat _server.xml_ (inside `GlobalNamingResources`):
```
-
Resource
in the main Tomcat server.xml (inside GlobalNamingResources
): <Resource name="jdbc/dspace" auth="Container" type="javax.sql.DataSource"
- driverClassName="org.postgresql.Driver"
- url="jdbc:postgresql://localhost:5432/dspace"
- username="dspace"
- password="dspace"
- initialSize='5'
- maxActive='50'
- maxIdle='15'
- minIdle='5'
- maxWait='5000'
- validationQuery='SELECT 1'
- testOnBorrow='true' />
+<Resource name="jdbc/dspace" auth="Container" type="javax.sql.DataSource"
+ driverClassName="org.postgresql.Driver"
+ url="jdbc:postgresql://localhost:5432/dspace"
+ username="dspace"
+ password="dspace"
+ initialSize='5'
+ maxActive='50'
+ maxIdle='15'
+ minIdle='5'
+ maxWait='5000'
+ validationQuery='SELECT 1'
+ testOnBorrow='true' />
@@ -811,6 +811,39 @@ javax.naming.NoInitialContextException: Need to specify class name in environmen
- And in the middle of all of this Linode sends an alert that CGSpace has high CPU usage from 2 to 4 PM
+2017-12-20
+
+
+- The database connection pooling is definitely better!
+
+
+
+
+
+- Now there is only one set of idle connections shared among all the web applications, instead of 10+ per application
+- There are short bursts of connections up to 10, but it generally stays around 5
+- Test and import 13 records to CGSpace for Abenet:
+
+
+$ export JAVA_OPTS="-Dfile.encoding=UTF-8 -Xmx512m -XX:+TieredCompilation -XX:TieredStopAtLevel=1"
+$ dspace import -a -e aorth@mjanja.ch -s /home/aorth/cg_system_20Dec/SimpleArchiveFormat -m systemoffice.map &> systemoffice.log
+
+
+
+- The fucking database went from 47 to 72 to 121 connections while I was importing so it stalled.
+- Since I had to restart Tomcat anyways, I decided to just deploy the new JNDI connection pooling stuff on CGSpace
+- There was an initial connection storm of 50 PostgreSQL connections, but then it settled down to 7
+- After that CGSpace came up fine and I was able to import the 13 items just fine:
+
+
+$ dspace import -a -e aorth@mjanja.ch -s /home/aorth/cg_system_20Dec/SimpleArchiveFormat -m systemoffice.map &> systemoffice.log
+$ schedtool -D -e ionice -c2 -n7 nice -n19 dspace filter-media -i 10568/89287
+
+
+
+- The final code for the JNDI work in the Ansible infrastructure scripts is here: https://github.com/ilri/rmg-ansible-public/commit/1959d9cb7a0e7a7318c77f769253e5e029bdfa3b
+
+
diff --git a/public/2017/12/postgres-connections-week-dspacetest.png b/public/2017/12/postgres-connections-week-dspacetest.png
new file mode 100644
index 000000000..a79fffe3d
Binary files /dev/null and b/public/2017/12/postgres-connections-week-dspacetest.png differ
diff --git a/public/sitemap.xml b/public/sitemap.xml
index b1a401675..31e78fbde 100644
--- a/public/sitemap.xml
+++ b/public/sitemap.xml
@@ -4,7 +4,7 @@
https://alanorth.github.io/cgspace-notes/2017-12/
- 2017-12-19T18:33:19+02:00
+ 2017-12-19T19:16:47+02:00
@@ -139,7 +139,7 @@
https://alanorth.github.io/cgspace-notes/
- 2017-12-19T18:33:19+02:00
+ 2017-12-19T19:16:47+02:00
0
@@ -150,7 +150,7 @@
https://alanorth.github.io/cgspace-notes/tags/notes/
- 2017-12-19T18:33:19+02:00
+ 2017-12-19T19:16:47+02:00
0
@@ -162,13 +162,13 @@
https://alanorth.github.io/cgspace-notes/post/
- 2017-12-19T18:33:19+02:00
+ 2017-12-19T19:16:47+02:00
0
https://alanorth.github.io/cgspace-notes/tags/
- 2017-12-19T18:33:19+02:00
+ 2017-12-19T19:16:47+02:00
0
diff --git a/static/2017/12/postgres-connections-week-dspacetest.png b/static/2017/12/postgres-connections-week-dspacetest.png
new file mode 100644
index 000000000..a79fffe3d
Binary files /dev/null and b/static/2017/12/postgres-connections-week-dspacetest.png differ