jclouds-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Shoemaker <ryan.shoema...@enterprisedb.com>
Subject warning during BlobStore.getBlobStore()
Date Thu, 13 Apr 2017 22:28:22 GMT

I've been seeing this warning pop out of my code for awhile and have 
finally gotten around to investigating it:


to find key for value http://keystone.domainname.com:5000/v2.0 in 
choosing first: uk

Why is there a mismatch between the uri and what's in the map?  The uri 
is pointing to our keystone service and the map contains our swift 
service.  The actual log message appears to be coming from:


As I was debugging this, I noticed this code on the stack:

    (line 150) @Override
    public T get() {
        try {
           return cache.get("FOO").orNull();
        }catch (UncheckedExecutionException e) {
           throw propagate(e.getCause());
        }catch (ExecutionException e) {
           throw propagate(e.getCause());

What's going on with that key name? Here's the calling code in my app - 
we have a method to get the storage context:

    public BlobStoreContext getStorageContext(@Nullable String tenant) {
         String providerOrApi = ProviderFactory.getSupportedProviderFromId(
         Properties overrides =new Properties();overrides.setProperty(KeystoneProperties.CREDENTIAL_TYPE,
         ContextBuilder builder = ContextBuilder.newBuilder(providerOrApi)
             .credentials(tenant +":" +serviceLogin,servicePassword)
             .modules(ImmutableSet.of(new JDKLoggingModule(),new JschSshClientModule()))

         return builder.buildView(BlobStoreContext.class);

And then code grabs the context and calls getBlobStore() on it - this is 
what causes the warning to be printed:

    BlobStoreContext storageContext = getStorageContext(firstTenant);
    if (storageContext !=null) {
    BlobStore blobStore = storageContext.getBlobStore();

We're running jclouds 2.0.0 on OpenStack.  Despite the warning, 
everything appears to work fine. Thanks! --Ryan

View raw message