Skip to Content.
Sympa Menu

grouper-users - [grouper-users] Grouper patching I don't fully understand

Subject: Grouper Users - Open Discussion List

List archive

[grouper-users] Grouper patching I don't fully understand


Chronological Thread 
  • From: Olivier Salaün <>
  • To: "" <>
  • Subject: [grouper-users] Grouper patching I don't fully understand
  • Date: Wed, 22 Jan 2020 15:09:20 +0100

Hello,

We are moving to Grouper 2.4.0 on a Linux server and while applying latest patches I got troubles applying patches to the grouper API. I think I understand the process now, but I want to make sure I apply patches the right way. Also since the documentation was confusing (for me), maybe this email might be helpful for others.

We run the grouper installer for patching as follows :

java -cp .:grouper.installer-2.4.0/grouperInstaller.jar edu.internet2.middleware.grouperInstaller.GrouperInstaller

The grouper.installer.properties file includes the following entries :

  • grouperInstaller.default.installOrUpgrade = patch
  • grouperInstaller.default.appToUpgrade = api
  • grouperInstaller.autorun.grouperWhereInstalled = /data/webapps/grouper-test.univ-rennes1.fr/application/grouper.ui-2.4.0/dist/grouper

https://spaces.at.internet2.edu/display/Grouper/Grouper+patching states that:

Note, if you are patching the UI or WS for example, you do not need to patch the API for the UI/WS, you just need to run the patcher for the UI or WS.  It will apply and manage the API patches as well.

Therefore I assumed running Grouper installer in patch mode on grouper.ui-2.4.0/dist/grouper/ would also patch the Grouper API used by gsh.sh (GROUPER_HOME=/data/webapps/grouper-test.univ-rennes1.fr/application/grouper.apiBinary-2.4.0), but it didn't.

################ Checking patch grouper_v2_4_0_api_patch_89
...
Applying file: /data/webapps/grouper-test.univ-rennes1.fr/application/grouper.ui-2.4.0/dist/grouper/WEB-INF/classes/edu/internet2/middleware/grouper/app/deprovisioning/GrouperDeprovisioningOverallConfiguration.class
Applying file: /data/webapps/grouper-test.univ-rennes1.fr/application/grouper.ui-2.4.0/dist/grouper/WEB-INF/classes/edu/internet2/middleware/grouper/app/deprovisioning/GrouperDeprovisioningOverallConfiguration.java
Patch successfully applied: grouper_v2_4_0_api_patch_89
 - added to end of property file: grouper_v2_4_0_api_patch_89.state = applied

The Grouper installer patched code in the grouper.ui-2.4.0/dist/grouper/WEB-INF/classes/ hierarchy, which is a copy of the grouper.apiBinary-2.4.0/conf/edu/ hierarchy.

I indeed realized $GROUPER_HOME/bin/gsh.sh did not have the latest patches applied :

gsh.sh
Detected Grouper directory structure 'api' (valid is api or webapp)
Using GROUPER_HOME:           /data/webapps/grouper-test.univ-rennes1.fr/application/grouper.apiBinary-2.4.0
Using GROUPER_CONF:           /data/webapps/grouper-test.univ-rennes1.fr/application/grouper.apiBinary-2.4.0/conf
...
api patches installed:        0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72

I found out I have 5 versions of gsh.sh in my Grouper hierarchy:

  1. grouper.apiBinary-2.4.0/bin/gsh.sh : the gsh.sh version used by our GSH scripts,
  2. grouper.ui-2.4.0/dist/grouper/WEB-INF/bin/gsh.sh : associated with API code used by Grouper UI
  3. grouper.ui-2.4.0/webapp/WEB-INF/bin/gsh.sh : source code for (2)
  4. grouper.ws-2.4.0/grouper-ws/build/dist/grouper-ws/WEB-INF/bin/gsh.sh : associated with API code used by Grouper WS
  5. grouper.ws-2.4.0/grouper-ws/webapp/WEB-INF/bin/gsh.sh : source code for (4)

I had to run the grouper installer again to patch the API located in the grouper.apiBinary-2.4.0/ hierarchy and now gsh.sh is up to patch 89 :-)

Can you confirm that I need to run the patching process twice to update both UI and API code?

Any way to make Grouper install a single version of the Grouper API code (for the sake of maintenability and comprehensibility)?

-- 
Olivier Salaün
DSI / pôle SI / équipe SNUM
Tel : 02 23 23 74 54



Archive powered by MHonArc 2.6.19.

Top of Page