[java-identity-provider] 02/03: IDP-2108 Work out the Upgrade story

Rod Widdowson rdw at steadingsoftware.com
Sat Jun 3 12:57:16 UTC 2023


This is an automated email from the git hooks/post-receive script.

rdw pushed a commit to branch main
in repository java-identity-provider.

View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=f1d57a194369fa525d17ef11283090a6879fc458

commit f1d57a194369fa525d17ef11283090a6879fc458
Author: Rod Widdowson <rdw at steadingsoftware.com>
AuthorDate: Fri Jun 2 17:12:21 2023 +0100

    IDP-2108 Work out the Upgrade story
    
    https://shibboleth.atlassian.net/browse/IDP-2108
    
    Check for '${idp.home}\system' in web.xml
---
 .../net/shibboleth/idp/installer/impl/V5Install.java    | 17 ++++++++++++-----
 1 file changed, 12 insertions(+), 5 deletions(-)

diff --git a/idp-installer/src/main/java/net/shibboleth/idp/installer/impl/V5Install.java b/idp-installer/src/main/java/net/shibboleth/idp/installer/impl/V5Install.java
index 383f6727f..231efbcb7 100644
--- a/idp-installer/src/main/java/net/shibboleth/idp/installer/impl/V5Install.java
+++ b/idp-installer/src/main/java/net/shibboleth/idp/installer/impl/V5Install.java
@@ -340,14 +340,21 @@ public class V5Install {
         try (final BufferedReader in = new BufferedReader(new FileReader(webXml.toFile()))) {
             final Pattern pat = Pattern.compile(".*net\\.shibboleth\\.ext\\.spring"+
                     "\\.context\\.DeferPlaceholderFileSystemXmlWebApplicationContext.*");
+            final Pattern systemInWebXml = Pattern.compile(".*\\$\\{idp\\.home\\}/system.*");
+            boolean foundPat1 = false, foundSystemInWebXml = false;
             String line = in.readLine();
             while (line != null) {
-                if (pat.matcher(line).matches()) {
-                    log.warn("Your copy of edit-webapp/WEB-INF/web.xml contains a reference to a replaced class, " +
+                if (!foundPat1 && pat.matcher(line).matches()) {
+                    foundPat1=true;
+                    log.warn("Your copy of edit-webapp/WEB-INF/web.xml contains a reference to a replaced class, {}",
                             DeferPlaceholderFileSystemXmlWebApplicationContext.class.getCanonicalName());
-                    log.warn("You MUST update this to " + DelimiterAwareApplicationContext.class.getCanonicalName() +
-                            " and rebuild the war after installation or the IdP will refuse to start.");
-                    break;
+                    log.warn("You MUST update this to {} and rebuild the war after installation or the IdP will refuse to start.",
+                            DelimiterAwareApplicationContext.class.getCanonicalName());
+                }
+                if (!foundSystemInWebXml && systemInWebXml.matcher(line).matches()) {
+                    foundSystemInWebXml=true;
+                    log.warn("Your copy of edit-webapp/WEB-INF/web.xml contains a reference to ${idp.home}/system");
+                    log.warn("This no longer exists.  Make the required changed and rebuild the war after installation or the IdP will refuse to start.");
                 }
                 line = in.readLine();
             }

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list