> @@ -270,9 +275,31 @@ public CloudStackComputeServiceAdapter(CloudStackApi
> client, Predicate<String> j
>
> @Override
> public Iterable<Template> listImages() {
> - // TODO: we may need to filter these further
> - // we may also want to see if we can work with ssh keys
> - return filter(client.getTemplateApi().listTemplates(), isReady());
> + Set<String> projects =
> ImmutableSet.copyOf(transform(projectSupplier.get().values(),
> + new Function<Project, String>() {
> +
> + @Override
> + public String apply(Project project) {
> + return project.getId();
> + }
> + }));
> +
> + return filter(concat(transform(ImmutableSet.<String>
> builder().addAll(projects).add("").build(),
fwiw, my brain farted - the keys are actually the IDs we need. d'oh!
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/215/files#r7931014