You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: plugins/storage/volume/storpool/src/main/java/org/apache/cloudstack/storage/datastore/util/StorPoolUtil.java
+16Lines changed: 16 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -172,6 +172,12 @@ public static class SpConnectionDesc {
172
172
privateStringtemplateName;
173
173
174
174
publicSpConnectionDesc(Stringurl) {
175
+
try {
176
+
extractUriParams(url);
177
+
return;
178
+
} catch (URISyntaxExceptione) {
179
+
log.debug("[ignore] the uri is not valid");
180
+
}
175
181
String[] urlSplit = url.split(";");
176
182
if (urlSplit.length == 1 && !urlSplit[0].contains("=")) {
177
183
this.templateName = url;
@@ -240,6 +246,16 @@ public SpConnectionDesc(String url) {
if (!StringUtils.equalsIgnoreCase(uri.getScheme(), "storpool")) {
252
+
thrownewCloudRuntimeException("The scheme is invalid. The URL should be with a format storpool://{SP_AUTH_TOKEN}@{SP_API_HTTP}:{SP_API_HTTP_PORT}/{SP_TEMPLATE}");
0 commit comments