class AutoScalingSpringResource {

    @ApiOperation("Create or Update scaling policy")
    @PostMapping(path = "/scalingPolicy")
    public ScalingPolicyID setScalingPolicy(@RequestBody PutPolicyRequest putPolicyRequest, CallMetadataAuthentication authentication) {
        Observable<ScalingPolicyID> putPolicyResult = autoScalingService.setAutoScalingPolicy(putPolicyRequest, authentication.getCallMetadata());
        ScalingPolicyID policyId = Responses.fromSingleValueObservable(putPolicyResult);
        log.info("New policy created {}", policyId);
        return policyId;
    }

    @Inject public  AutoScalingSpringResource(AutoScalingService autoScalingService);

}