You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@jclouds.apache.org by "Alex Heneveld (JIRA)" <ji...@apache.org> on 2015/08/29 04:18:45 UTC

[jira] [Commented] (JCLOUDS-908) BaseComputeService#listNodes throwing an exception

    [ https://issues.apache.org/jira/browse/JCLOUDS-908?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14720919#comment-14720919 ] 

Alex Heneveld commented on JCLOUDS-908:
---------------------------------------

This is not entirely fixed in 1.9.1.  The call to:

    firewallTagNamingConvention.get(group).isFirewallTag()

can throw an NPE if the `group` could not be inferred from the instance name.

But the commit 465a62aa2767427018d83c2711fd427e90e97ef4 -- Remove firewall-tag filtering -- in jclouds master looks okay as the offending lines have been entirely removed.

> BaseComputeService#listNodes throwing an exception
> --------------------------------------------------
>
>                 Key: JCLOUDS-908
>                 URL: https://issues.apache.org/jira/browse/JCLOUDS-908
>             Project: jclouds
>          Issue Type: Sub-task
>          Components: jclouds-compute, jclouds-labs-google
>    Affects Versions: 1.8.1, 1.9.0
>            Reporter: Pedro Ribeiro
>             Fix For: 1.9.1, 2.0.0
>
>
> If I have an instance named "j-t2", then when I call BaseComputeService#listNodes, I get the following error. The 'j' in the exception seems to result from some manipulation of the instance name.
> {code}
> Caused by: java.lang.IllegalArgumentException: Object 'j' doesn't match dns naming constraints. Reason: Can't be null or empty. Length must be 3 to 63 symbols..
> 	at org.jclouds.predicates.validators.DnsNameValidator.exception(DnsNameValidator.java:74)
> 	at org.jclouds.predicates.validators.DnsNameValidator.validate(DnsNameValidator.java:51)
> 	at org.jclouds.predicates.validators.DnsNameValidator.validate(DnsNameValidator.java:36)
> 	at org.jclouds.compute.internal.FormatSharedNamesAndAppendUniqueStringToThoseWhichRepeat.checkGroup(FormatSharedNamesAndAppendUniqueStringToThoseWhichRepeat.java:124)
> 	at org.jclouds.compute.internal.FormatSharedNamesAndAppendUniqueStringToThoseWhichRepeat.sharedNameForGroup(FormatSharedNamesAndAppendUniqueStringToThoseWhichRepeat.java:120)
> 	at org.jclouds.googlecomputeengine.compute.functions.FirewallTagNamingConvention$Factory.get(FirewallTagNamingConvention.java:39)
> 	at org.jclouds.googlecomputeengine.compute.functions.InstanceInZoneToNodeMetadata.apply(InstanceInZoneToNodeMetadata.java:89)
> 	at org.jclouds.googlecomputeengine.compute.functions.InstanceInZoneToNodeMetadata.apply(InstanceInZoneToNodeMetadata.java:51)
> 	at shaded.com.google.common.base.Functions$FunctionComposition.apply(Functions.java:216)
> 	at shaded.com.google.common.collect.Iterators$8.transform(Iterators.java:799)
> 	at shaded.com.google.common.collect.TransformedIterator.next(TransformedIterator.java:48)
> 	at shaded.com.google.common.collect.Iterators$7.computeNext(Iterators.java:651)
> 	at shaded.com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:143)
> 	at shaded.com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:138)
> 	at shaded.com.google.common.collect.Iterators.addAll(Iterators.java:361)
> 	at shaded.com.google.common.collect.Iterables.addAll(Iterables.java:354)
> 	at shaded.com.google.common.collect.Sets.newLinkedHashSet(Sets.java:328)
> 	at org.jclouds.compute.internal.BaseComputeService.listNodes(BaseComputeService.java:335)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:606)
> 	at com.google.inject.internal.DelegatingInvocationHandler.invoke(DelegatingInvocationHandler.java:40)
> 	at com.sun.proxy.$Proxy107.listNodes(Unknown Source)
> 	at jenkins.plugins.jclouds.compute.JCloudsCloud.getRunningNodesCount(JCloudsCloud.java:389)
> 	at jenkins.plugins.jclouds.compute.JCloudsCloud.doProvision(JCloudsCloud.java:372)
> 	... 73 more
> {code}
> *Note*: I have only tested this with version 1.8.1 and I am calling jclouds from inside a jenkins plugin.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)