Aled Sage created BROOKLYN-491:
----------------------------------

             Summary: IndexOutOfBoundsException parsing blobstore location 
definition "aws-s3"
                 Key: BROOKLYN-491
                 URL: https://issues.apache.org/jira/browse/BROOKLYN-491
             Project: Brooklyn
          Issue Type: Bug
            Reporter: Aled Sage
            Priority: Minor


With Brooklyn 0.11.0-rc2, in my {{brooklyn.cfg}} I had the following blobstore 
location defined:

{noformat}
brooklyn.location.named.my-s3=aws-s3
brooklyn.location.named.my-s3.region=eu-west-1
brooklyn.location.named.my-s3.identity=********************
brooklyn.location.named.my-s3.credential==********************=******************
{noformat}

And in my {{org.apache.brooklyn.osgilauncher.cfg}} I had 
{{persistenceLocation=my-s3}}.

However, when I started Brooklyn it failed with the error shown below:

{noformat}
Caused by: java.lang.IndexOutOfBoundsException: position (1) must be less than 
the number of elements that remained (1)
        at com.google.common.collect.Iterators.get(Iterators.java:818)
        at com.google.common.collect.Iterables.get(Iterables.java:728)
        at 
org.apache.brooklyn.location.jclouds.JcloudsPropertiesFromBrooklynProperties.getProviderFromDefinition(JcloudsPropertiesFromBrooklynProperties.java:130)
        at 
org.apache.brooklyn.location.jclouds.JcloudsPropertiesFromBrooklynProperties.getProviderName(JcloudsPropertiesFromBrooklynProperties.java:113)
        at 
org.apache.brooklyn.location.jclouds.JcloudsPropertiesFromBrooklynProperties.getJcloudsProperties(JcloudsPropertiesFromBrooklynProperties.java:91)
        at 
org.apache.brooklyn.location.jclouds.JcloudsLocationResolver.newLocationSpecFromString(JcloudsLocationResolver.java:156)
        at 
org.apache.brooklyn.core.location.BasicLocationRegistry.getLocationSpec(BasicLocationRegistry.java:375)[120:org.apache.brooklyn.core:0.11.0.20170316_1432]
        at 
org.apache.brooklyn.core.location.BasicLocationRegistry.getLocationSpec(BasicLocationRegistry.java:350)[120:org.apache.brooklyn.core:0.11.0.20170316_1432]
        at 
org.apache.brooklyn.core.location.NamedLocationResolver.newLocationSpecFromString(NamedLocationResolver.java:85)[120:org.apache.brooklyn.core:0.11.0.20170316_1432]
        at 
org.apache.brooklyn.core.location.BasicLocationRegistry.getLocationSpec(BasicLocationRegistry.java:375)[120:org.apache.brooklyn.core:0.11.0.20170316_1432]
        at 
org.apache.brooklyn.core.location.BasicLocationRegistry.getLocationSpec(BasicLocationRegistry.java:355)[120:org.apache.brooklyn.core:0.11.0.20170316_1432]
        at 
org.apache.brooklyn.core.mgmt.persist.BrooklynPersistenceUtils.newPersistenceObjectStore(BrooklynPersistenceUtils.java:87)
        at 
org.apache.brooklyn.launcher.common.BasicLauncher.initPersistence(BasicLauncher.java:581)
        ... 48 more
{noformat}

---
A workaround is to use {{brooklyn.location.named.my-s3=jclouds:aws-s3}}, or to 
in-line the region like {{brooklyn.location.named.my-s3=aws-s3:eu-west-1}}.




--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to