ovsdb-idl: Remove 'uuid' member of struct ovsdb_idl.
This was used to uniquely identify the monitor, but there's no need for
that.  A fixed monitor name works fine.
Acked-by: Alin Gabriel Serdean
@@ -135,7 +135,6 @@ struct ovsdb_idl {
unsigned int state_seqno; /* See above. */
struct json *request_id; /* JSON ID for request awaiting reply. */
struct json *schema; /* Temporary copy of database schema. */
- struct uuid uuid; /* Identifier for monitor. */
/* Database locking. */
char *lock_name; /* Name of lock we need, NULL if none. */
@@ -344,7 +343,6 @@ ovsdb_idl_create(const char *remote, const struct ovsdb_idl_class *class,
idl->schema = NULL;
hmap_init(&idl->outstanding_txns);
- uuid_generate(&idl->uuid);
return idl;
}
@@ -1211,8 +1209,7 @@ static void
ovsdb_idl_send_cond_change(struct ovsdb_idl *idl)
{
int i;
- char uuid[UUID_LEN + 1];
- struct json *params, *json_uuid;
+ struct json *params;
struct jsonrpc_msg *request;
/* When 'idl-request_id' is not NULL, there is an outstanding
@@ -1244,15 +1241,8 @@ ovsdb_idl_send_cond_change(struct ovsdb_idl *idl)
/* Send request if not empty. */
if (monitor_cond_change_requests) {
- snprintf(uuid, sizeof uuid, UUID_FMT,
- UUID_ARGS(&idl->uuid));
- json_uuid = json_string_create(uuid);
-
- /* Create a new uuid */
- uuid_generate(&idl->uuid);
- snprintf(uuid, sizeof uuid, UUID_FMT,
- UUID_ARGS(&idl->uuid));
- params = json_array_create_3(json_uuid, json_string_create(uuid),
+ params = json_array_create_3(json_string_create("monid"),
+ json_string_create("monid"),
monitor_cond_change_requests);
request = jsonrpc_create_request("monitor_cond_change", params,
@@ -1553,7 +1543,6 @@ ovsdb_idl_send_monitor_request__(struct ovsdb_idl *idl,
struct shash *schema;
struct json *monitor_requests;
struct jsonrpc_msg *msg;
- char uuid[UUID_LEN + 1];
size_t i;
schema = parse_schema(idl->schema);
@@ -1612,11 +1601,10 @@ ovsdb_idl_send_monitor_request__(struct ovsdb_idl *idl,
json_destroy(idl->request_id);
- snprintf(uuid, sizeof uuid, UUID_FMT, UUID_ARGS(&idl->uuid));
msg = jsonrpc_create_request(
method,
json_array_create_3(json_string_create(idl->class_->database),
- json_string_create(uuid), monitor_requests),
+ json_string_create("monid"), monitor_requests),
&idl->request_id);
jsonrpc_session_send(idl->session, msg);
idl->cond_changed = false;
