2

I was trying to use openstack4j V3.0.1 to create alarm in openstack:

    Alarm alarm = projectClient
            .telemetry()
            .alarms()
            .create(Builders.alarm().name(alarmName + "@" + serverId).description(alarmName + " high")
                    .type(Alarm.Type.THRESHOLD).thresholeRule(rule).alarmActions(actions).isEnabled(true).build());

but the server fails to respond and throws me an exception:

Exception in thread "main" org.jboss.resteasy.client.ClientResponseFailure: Unable to find a MessageBodyReader of content-type text/plain;charset="UTF-8" and type null

after i track the network traffic on the server side, it seems that the request is sent to 8777 port, which is telemetry metering service. in fact it should be sent to 8042 port, where the telemetry alarming service is running.

anybody knows if I'm using the openstack4j correctly. thanks!

0 Answers0