-
Notifications
You must be signed in to change notification settings - Fork 188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incorrect handling of the replace op. in edit-config request #49
Comments
found in devel-server branch, not sure about master... |
it seems you do not define xmlns |
Hi, Regards, |
I'm afraid that the original issue still isn't resolved. I'm using devel branches of all libraries (with the libyang fix mentioned above). The edit-config in my first comment (replace operation on
I would expect something like |
Hi, Regards, |
Yes, the debug output looks similar:
|
Hi, Regards, |
Hi,
after the request:
Logs:
|
I am seeing the same issue using replace - the schema does not change - merge works fine. |
Hi, Regards, |
It works now, thanks. |
Hi Michal,
Finding issue for "replace' at container level as shown below.
|
Hi, Regards, |
Hi Michal, =======Existing running config =========================== <?xml version="1.0" encoding="utf-8"?>
<data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<ensemble-config xmlns="http://www.aaa.com/ns/XXX-config">
<rate-profiles xmlns="http://www.aaa.com/ns/XXX-rate-profile">
<rate-profile>
<name>xyz</name>
<cir>0</cir>
<eir>0</eir>
<cbs>163840</cbs>
<ebs>163840</ebs>
<color-enabled>false</color-enabled>
<coupling-enabled>false</coupling-enabled>
</rate-profile>
</rate-profiles>
</ensemble-config>
</data> =============Edit-config with op+replace at container level ====================== <?xml version="1.0" encoding="utf-8"?>
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="">
<edit-config>
<target>
<candidate/>
</target>
<config>
<ensemble-config xmlns="http://www.aaa.com/ns/XXX-config">
<rate-profiles xmlns="http://www.aaa.com/ns/XXX-rate-profile" nc:operation="replace" xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0">
<rate-profile>
<name>xyz</name> ======>> same list with only leaf value updated
<cir>100000</cir>
<eir>100000</eir>
<cbs>1048576</cbs>
<ebs>163840</ebs>
<color-enabled>false</color-enabled>
<coupling-enabled>false</coupling-enabled>
</rate-profile>
</rate-profiles>
</ensemble-config>
</config>
</edit-config>
</rpc> =====================Expected config ===================== <?xml version="1.0" encoding="utf-8"?>
<data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<ensemble-config xmlns="http://www.aaa.com/ns/XXX-config">
<rate-profiles xmlns="http://www.aaa.com/ns/XXX-rate-profile">
<rate-profile>
<name>xyz</name>
<cir>100000</cir>
<eir>100000</eir>
<cbs>1048576</cbs>
<ebs>163840</ebs>
<color-enabled>false</color-enabled>
<coupling-enabled>false</coupling-enabled>
</rate-profile>
</rate-profiles>
</ensemble-config>
</data> Regards, |
Hi Michal, The one I have posted is replace at container level. But we had tried with replace op at leaf level. And found that that also have some issue. But replace op at list level is working fine. Regards, |
Hi Michal, Did you get a chance to look in to this issue ? Regards, |
Hi Rosy, Regards, |
Hi Michal, Sure. So with the latest code now replace will work at the container and leaf level too ? Regards, |
Well, I hope so. Michal |
Use proper size for inet_ntop's buffer
Request to replace
GigabitEthernet0/8/0
config (that already exists in the datastore) with new values:The only edit-like operation that comes to sysrepo is this one set-item:
And nothing actually changes in the datastore...
Full Netopeer2 logs:
The text was updated successfully, but these errors were encountered: