diff --git a/compute/src/main/java/org/jclouds/compute/util/ComputeServiceUtils.java b/compute/src/main/java/org/jclouds/compute/util/ComputeServiceUtils.java index fd48387b21..0f4fc19171 100644 --- a/compute/src/main/java/org/jclouds/compute/util/ComputeServiceUtils.java +++ b/compute/src/main/java/org/jclouds/compute/util/ComputeServiceUtils.java @@ -193,7 +193,7 @@ public class ComputeServiceUtils { Builder builder = ImmutableMap. builder(); builder.putAll(options.getUserMetadata()); if (options.getTags().size() > 0) - builder.put("jclouds.tags", Joiner.on(',').join(options.getTags())); + builder.put("jclouds_tags", Joiner.on(',').join(options.getTags())); return builder.build(); } @@ -202,10 +202,10 @@ public class ComputeServiceUtils { */ public static NodeMetadataBuilder addMetadataAndParseTagsFromCommaDelimitedValue(NodeMetadataBuilder builder, Map map) { - String tagString = map.get("jclouds.tags"); + String tagString = map.get("jclouds_tags"); if (tagString != null) builder.tags(Splitter.on(',').split(tagString)); - builder.userMetadata(filterKeys(map, not(equalTo("jclouds.tags")))); + builder.userMetadata(filterKeys(map, not(equalTo("jclouds_tags")))); return builder; } diff --git a/compute/src/test/java/org/jclouds/compute/util/ComputeServiceUtilsTest.java b/compute/src/test/java/org/jclouds/compute/util/ComputeServiceUtilsTest.java index 68bdcb8055..9a6c1e7015 100644 --- a/compute/src/test/java/org/jclouds/compute/util/ComputeServiceUtilsTest.java +++ b/compute/src/test/java/org/jclouds/compute/util/ComputeServiceUtilsTest.java @@ -60,7 +60,7 @@ public class ComputeServiceUtilsTest { @Test public void testMetadataAndTagsAsCommaDelimitedValue() { TemplateOptions options = TemplateOptions.Builder.tags(ImmutableSet.of("tag")).userMetadata(ImmutableMap.of("foo", "bar")); - assertEquals(metadataAndTagsAsCommaDelimitedValue(options), ImmutableMap.of("foo", "bar", "jclouds.tags", "tag")); + assertEquals(metadataAndTagsAsCommaDelimitedValue(options), ImmutableMap.of("foo", "bar", "jclouds_tags", "tag")); } @Test