Interface AlarmHistoryRestService

    • Method Detail

      • getStatesForAlarm

        @GET
        @Path("{alarmId}/states")
        @Produces("application/json")
        Collection<AlarmState> getStatesForAlarm​(@PathParam("alarmId")
                                                 String alarmId,
                                                 @QueryParam("matchType")
                                                 String matchType)
        Retrieve the complete set of state changes for the given alarm.
        Parameters:
        alarmId - alarm id to query
        matchType - when set the 'reduction-key', lookup by reduction key instead of alarm id
        Returns:
        state changes
      • getAlarm

        @GET
        @Path("{alarmId}")
        @Produces("application/json")
        AlarmState getAlarm​(@PathParam("alarmId")
                            String alarmId,
                            @QueryParam("matchType")
                            String matchType,
                            @QueryParam("at")
                            Long timestampInMillis)
        Retrieve the last known state of an alarm at the given time.
        Parameters:
        alarmId - alarm id to query
        matchType - when set the 'reduction-key', lookup by reduction key instead of alarm id
        timestampInMillis - timestamp in milliseconds - defaults to "now" when null
        Returns:
        last known state
      • getActiveAlarmsAt

        @GET
        @Produces("application/json")
        Collection<AlarmState> getActiveAlarmsAt​(@QueryParam("at")
                                                 Long timestampInMillis)
        Retrieve the last known state of all alarms which were active at the given time.
        Parameters:
        timestampInMillis - timestamp in milliseconds
        Returns:
        last known state of all alarms which were active at the given time - defaults to "now" when null