diff options
Diffstat (limited to 'adapters/mso-adapter-utils/src/main/java')
-rw-r--r-- | adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/GlanceClientImpl.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/GlanceClientImpl.java b/adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/GlanceClientImpl.java index 740eb778b0..687afeda40 100644 --- a/adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/GlanceClientImpl.java +++ b/adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/GlanceClientImpl.java @@ -74,10 +74,13 @@ public class GlanceClientImpl extends MsoCommonUtils { String encodedName = null; if (name != null) { try { - encodedName = URLEncoder.encode(name, "UTF-8"); + encodedName = + "in:\"" + URLEncoder.encode(name, "UTF-8").replace("+", "%20").replace("%3A", ":") + "\""; } catch (UnsupportedEncodingException e) { - logger.error("error encoding query parameter: {}", encodedName); + logger.error("Error Encoding Image Name", e); + throw new GlanceClientException("Error Endcoding Name", e); } + } Glance glanceClient = getGlanceClient(cloudSiteId, tenantId); // list is set to false, otherwise an invalid URL is appended |