From 2b46f76d9a688acf326424659ec9672a2614fdcf Mon Sep 17 00:00:00 2001 From: Instrumental Date: Wed, 20 Feb 2019 11:14:41 -0600 Subject: fix new openssl, data, etc Issue-ID: AAF-667 Change-Id: Ic87c5159c453c293d845abea6be0c4cfb3164fc1 Signed-off-by: Instrumental --- .../main/java/org/onap/aaf/auth/direct/DirectAAFLocator.java | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'auth/auth-cass/src/main/java/org') diff --git a/auth/auth-cass/src/main/java/org/onap/aaf/auth/direct/DirectAAFLocator.java b/auth/auth-cass/src/main/java/org/onap/aaf/auth/direct/DirectAAFLocator.java index 93fab977..cc9ee66c 100644 --- a/auth/auth-cass/src/main/java/org/onap/aaf/auth/direct/DirectAAFLocator.java +++ b/auth/auth-cass/src/main/java/org/onap/aaf/auth/direct/DirectAAFLocator.java @@ -23,6 +23,7 @@ package org.onap.aaf.auth.direct; import java.net.URI; import java.net.URISyntaxException; +import java.net.UnknownHostException; import java.util.Collections; import java.util.LinkedList; import java.util.List; @@ -34,8 +35,10 @@ import org.onap.aaf.auth.env.AuthzTrans; import org.onap.aaf.auth.layer.Result; import org.onap.aaf.cadi.LocatorException; import org.onap.aaf.cadi.Access.Level; +import org.onap.aaf.cadi.CadiException; import org.onap.aaf.cadi.aaf.v2_0.AbsAAFLocator; import org.onap.aaf.cadi.config.Config; +import org.onap.aaf.cadi.config.RegistrationPropHolder; import org.onap.aaf.misc.env.util.Split; import locate.v1_0.Endpoint; @@ -70,8 +73,12 @@ public class DirectAAFLocator extends AbsAAFLocator { } try { - uri = new URI(access.getProperty(Config.AAF_LOCATE_URL, "localhost")+"/locate/"+name+':'+version); - } catch (URISyntaxException e) { + RegistrationPropHolder rph = new RegistrationPropHolder(access,0); + String aaf_url = rph.replacements("https://"+Config.AAF_LOCATE_URL_TAG+"/%CNS."+name, null,null); + //access.getProperty("/locate/"+name+':'+version; + access.printf(Level.INIT,"Creating DirectAAFLocator to %s",aaf_url); + uri = new URI(aaf_url); + } catch (URISyntaxException | UnknownHostException | CadiException e) { throw new LocatorException(e); } myhostname=null; -- cgit 1.2.3-korg