From 39596f5b6d2c67d8c2b357243ecfb2dd6d746796 Mon Sep 17 00:00:00 2001 From: Instrumental Date: Thu, 7 Feb 2019 18:53:11 -0600 Subject: Minor fixes starting from Scratch Issue-ID: AAF-698 Change-Id: Ie279c11f9f385e9cb179cbe3e16de35cbfa33ecf Signed-off-by: Instrumental --- .../src/main/java/org/onap/aaf/auth/org/OrganizationFactory.java | 2 +- .../src/main/java/org/onap/aaf/auth/server/AbsServiceStarter.java | 7 ++----- .../main/java/org/onap/aaf/auth/server/JettyServiceStarter.java | 2 +- 3 files changed, 4 insertions(+), 7 deletions(-) (limited to 'auth/auth-core/src/main') diff --git a/auth/auth-core/src/main/java/org/onap/aaf/auth/org/OrganizationFactory.java b/auth/auth-core/src/main/java/org/onap/aaf/auth/org/OrganizationFactory.java index 40c8c2d3..f4e6d14e 100644 --- a/auth/auth-core/src/main/java/org/onap/aaf/auth/org/OrganizationFactory.java +++ b/auth/auth-core/src/main/java/org/onap/aaf/auth/org/OrganizationFactory.java @@ -71,7 +71,7 @@ public class OrganizationFactory { String realm = env.getProperty(Config.AAF_DEFAULT_REALM,"people.osaaf.org"); defaultOrg = cnst.newInstance(env,realm); } catch (ClassNotFoundException | InstantiationException | IllegalAccessException | NoSuchMethodException | SecurityException | IllegalArgumentException | InvocationTargetException e) { - throw new OrganizationException("At least one Organization must be defined",e); + env.warn().log("Not Organization Moduled linked in",e); } } if (defaultOrg == null) { diff --git a/auth/auth-core/src/main/java/org/onap/aaf/auth/server/AbsServiceStarter.java b/auth/auth-core/src/main/java/org/onap/aaf/auth/server/AbsServiceStarter.java index 1bc367e6..fe610e57 100644 --- a/auth/auth-core/src/main/java/org/onap/aaf/auth/server/AbsServiceStarter.java +++ b/auth/auth-core/src/main/java/org/onap/aaf/auth/server/AbsServiceStarter.java @@ -23,7 +23,6 @@ import java.io.IOException; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.Future; -import java.util.concurrent.TimeUnit; import org.onap.aaf.auth.org.OrganizationException; import org.onap.aaf.auth.org.OrganizationFactory; @@ -41,15 +40,13 @@ public abstract class AbsServiceStarter service; - public AbsServiceStarter(final AbsService service, boolean noexit) { + public AbsServiceStarter(final AbsService service) { this.service = service; try { OrganizationFactory.init(service.env); } catch (OrganizationException e) { service.access.log(e, "Missing defined Organization Plugins"); - if(!noexit) { - System.exit(3); - } + System.exit(3); } // do_register - this is used for specialty Debug Situations. Developer can create an Instance for a remote system // for Debugging purposes without fear that real clients will start to call your debug instance diff --git a/auth/auth-core/src/main/java/org/onap/aaf/auth/server/JettyServiceStarter.java b/auth/auth-core/src/main/java/org/onap/aaf/auth/server/JettyServiceStarter.java index 98503d11..413b7919 100644 --- a/auth/auth-core/src/main/java/org/onap/aaf/auth/server/JettyServiceStarter.java +++ b/auth/auth-core/src/main/java/org/onap/aaf/auth/server/JettyServiceStarter.java @@ -59,7 +59,7 @@ public class JettyServiceStarter ex private boolean secure; public JettyServiceStarter(final AbsService service) throws OrganizationException { - super(service,false); + super(service); secure = true; } -- cgit 1.2.3-korg