Skip to content

Commit

Permalink
removed obsolete API ping method
Browse files Browse the repository at this point in the history
Fixes: #790

Breaking change: Removing obsolete API method Ping.
Ping has been added in the beginning for testing purposes.
It is not needed anymore and, therefore, is removed. Since
it was not even documented in the API spec, its impact is
even less.

Signed-off-by: Michael Engel <mengel@redhat.com>
  • Loading branch information
engelmi authored and mwperina committed Mar 8, 2024
1 parent 5b0cddf commit dd889c3
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions src/controller/controller.c
Original file line number Diff line number Diff line change
Expand Up @@ -440,22 +440,6 @@ static bool controller_setup_node_connection_handler(Controller *controller) {
return true;
}

/************************************************************************
****** org.eclipse.bluechi.Controller.Ping ******************
************************************************************************/

/* This is a test method for now, it just returns what you passed */
static int controller_method_ping(sd_bus_message *m, UNUSED void *userdata, UNUSED sd_bus_error *ret_error) {
const char *arg = NULL;

int r = sd_bus_message_read(m, "s", &arg);
if (r < 0) {
return sd_bus_reply_method_errorf(m, SD_BUS_ERROR_INVALID_ARGS, "Invalid arguments");
}
return sd_bus_reply_method_return(m, "s", arg);
}


/************************************************************************
************** org.eclipse.bluechi.Controller.ListUnits *****
************************************************************************/
Expand Down Expand Up @@ -944,7 +928,6 @@ static int controller_property_get_log_target(

static const sd_bus_vtable controller_vtable[] = {
SD_BUS_VTABLE_START(0),
SD_BUS_METHOD("Ping", "s", "s", controller_method_ping, 0),
SD_BUS_METHOD("ListUnits", "", NODE_AND_UNIT_INFO_STRUCT_ARRAY_TYPESTRING, controller_method_list_units, 0),
SD_BUS_METHOD("ListNodes", "", "a(sos)", controller_method_list_nodes, 0),
SD_BUS_METHOD("GetNode", "s", "o", controller_method_get_node, 0),
Expand Down

0 comments on commit dd889c3

Please sign in to comment.