+ else if (unformat (line_input, "session-scope-local"))
+ {
+ vcl_cfg->session_scope_local = 1;
+ if (VPPCOM_DEBUG > 0)
+ clib_warning ("[%d] configured session_scope_local (%d)",
+ vcm->my_pid, vcl_cfg->session_scope_local);
+ }
+ else if (unformat (line_input, "session-scope-global"))
+ {
+ vcl_cfg->session_scope_global = 1;
+ if (VPPCOM_DEBUG > 0)
+ clib_warning ("[%d] configured session_scope_global (%d)",
+ vcm->my_pid, vcl_cfg->session_scope_global);
+ }
+ else if (unformat (line_input, "namespace-secret 0x%lx",
+ &vcl_cfg->namespace_secret))
+ {
+ if (VPPCOM_DEBUG > 0)
+ clib_warning
+ ("[%d] configured namespace_secret 0x%lx (%lu)",
+ vcm->my_pid, vcl_cfg->namespace_secret,
+ vcl_cfg->namespace_secret);
+ }
+ else if (unformat (line_input, "namespace-secret %lu",
+ &vcl_cfg->namespace_secret))
+ {
+ if (VPPCOM_DEBUG > 0)
+ clib_warning
+ ("[%d] configured namespace_secret %lu (0x%lx)",
+ vcm->my_pid, vcl_cfg->namespace_secret,
+ vcl_cfg->namespace_secret);
+ }
+ else if (unformat (line_input, "namespace-id %v",
+ &vcl_cfg->namespace_id))
+ {
+ vl_api_application_attach_t *mp;
+ u32 max_nsid_vec_len = sizeof (mp->namespace_id) - 1;
+ u32 nsid_vec_len = vec_len (vcl_cfg->namespace_id);
+ if (nsid_vec_len > max_nsid_vec_len)
+ {
+ _vec_len (vcl_cfg->namespace_id) = max_nsid_vec_len;
+ if (VPPCOM_DEBUG > 0)
+ clib_warning ("[%d] configured namespace_id is too long,"
+ " truncated to %d characters!", vcm->my_pid,
+ max_nsid_vec_len);
+ }
+
+ if (VPPCOM_DEBUG > 0)
+ clib_warning ("[%d] configured namespace_id %v",
+ vcm->my_pid, vcl_cfg->namespace_id);
+ }