Hi ,we have below requirement …
for the below yang model .
we have handler using policy-hook to store and update our system params with some conditions. if conditions are not met we errorout.
let us suppose user tried configuring 3 policies and tried for a commit .
out of which first policy is valid and because of first policy 2nd policy is not valid.
cdb error out and wont configure all three .
instead as first policy is valid we should allow first policy to get configured by updating cdb , but from second policy it should error out.
please let us know a way to do the same.
list policy{
key "name";
tailf:info "set policy";
tailf:callpoint policy-hook{
tailf:transaction-hook subtree;
}
leaf name {
tailf:info "Enter name of policy";
type string;
}
list group{
key "id";
tailf:info "set access-group";
leaf id {
tailf:info "Enter id of group";
type uint32;
}
container feature
{
choice work_choice{
case yes{
leaf-list what_work{
tailf:cli-drop-node-name;
type work_type;
}
}
case no{
leaf nowork{
type boolean;
default true;
tailf:cli-boolean-no;
tailf:cli-show-with-default;
}
}
}
}
leaf t_group{
type uint32;
}
leaf t_down{
type pass_type;
}
}
}