1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

state: use new C++ function stateToString()

This commit is contained in:
Steffen Vogel 2021-10-04 21:30:53 +02:00
parent ec66348ef3
commit f8f8405b05
4 changed files with 4 additions and 4 deletions

2
common

@ -1 +1 @@
Subproject commit 59eaf21fc8cd57eba035baa128f9d21743747eed
Subproject commit 06bd16a965a494ccfd4d69ab74a5737c8cb1328c

View file

@ -98,7 +98,7 @@ public:
json_error_t err;
json_t *json_status = json_pack_ex(&err, 0, "{ s: s, s: s, s: s, s: s, s: s, s: s, s: s, s: f, s: f, s: { s: s, s: I, s: b }, s: { s: s, s: s, s: s, s: s, s: s, s: s}, s: { s: i, s: i, s: I, s: I, s: [ f, f, f ], s: { s: I, s, I, s: I, s: I }, s: { s: I, s: I }, s: { s: I, s: I } } }",
"state", state_print(sn->getState()),
"state", stateToString(sn->getState()).c_str(),
"version", PROJECT_VERSION_STR,
"release", PROJECT_RELEASE,
"build_id", PROJECT_BUILD_ID,

View file

@ -713,7 +713,7 @@ json_t * node_to_json(struct vnode *n)
json_node = json_pack("{ s: s, s: s, s: s, s: i, s: { s: i, s: o? }, s: { s: i, s: o? } }",
"name", node_name_short(n),
"uuid", uuid,
"state", state_print(n->state),
"state", stateToString(n->state).c_str(),
"affinity", n->affinity,
"in",
"vectorize", n->in.vectorize,

View file

@ -833,7 +833,7 @@ json_t * path_to_json(struct vpath *p)
json_t *json_path = json_pack("{ s: s, s: s, s: s, s: b, s: b s: b, s: b, s: b, s: b s: i, s: o, s: o, s: o, s: o }",
"uuid", uuid,
"state", state_print(p->state),
"state", stateToString(p->state).c_str(),
"mode", p->mode == PathMode::ANY ? "any" : "all",
"enabled", p->enabled,
"builtin", p->builtin,