jclouds-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremy Daggett <notificati...@github.com>
Subject Re: [jclouds-labs-openstack] OS Ceilometer API support (#166)
Date Wed, 19 Nov 2014 14:47:29 GMT
> +
> +         if (!isNullOrEmptyString(options.getFilter())) {
> +            map.put("filter", options.getFilter());
> +         }
> +
> +         if (options.getLimit() != null) {
> +            map.put("limit", options.getLimit());
> +         }
> +
> +         if (!isNullOrEmptyString(options.getOrderBy())) {
> +            map.put("orderby", options.getOrderBy());
> +         }
> +      }
> +
> +      request.setPayload(gson.toJson(map));
> +      request.getPayload().getContentMetadata().setContentType("application/json");

Prefer: `request.getPayload().getContentMetadata().setContentType(MediaType.APPLICATION_JSON)`

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs-openstack/pull/166/files#r20578458
Mime
View raw message