mirror of https://github.com/apache/cloudstack.git
Skip null or missing URLs for S3
This commit is contained in:
parent
387f958df1
commit
dd39393400
|
|
@ -1247,6 +1247,10 @@ public class SecondaryStorageManagerImpl extends ManagerBase implements Secondar
|
|||
protected void addSecondaryStorageServerAddressToBuffer(StringBuilder buffer, List<DataStore> dataStores, String vmName) {
|
||||
List<String> addresses = new ArrayList<>();
|
||||
for (DataStore dataStore: dataStores) {
|
||||
// S3 and other object stores may not have a URL, so better to skip them
|
||||
if (dataStore == null || dataStore.getTO() == null || dataStore.getTO().getUrl() == null) {
|
||||
continue;
|
||||
}
|
||||
String url = dataStore.getTO().getUrl();
|
||||
String[] urlArray = url.split("/");
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue