Description
Describe the bug
Using version 22.1.6 (and older versions) of the plugin it seems to be impossible to unset an attribute like WafPolicyRef or VSDataScripts?
On the AviVirtualService-object I have tried both
vs.setWafPolicyRef(null);
vs.wafPolicyRef = null;
as well as other desperate attempts like setting the attribute to "0", "" (an empty sting), false or even removing the attribute altogether from the object.
But after calling addObject on the AviVroClient-object and passing the vs-object there doesn't seem to be made an attempt to update the object on AVI - there is no entry in the audit log on AVI and the resource is not changed, unlike whenever we make other changes like switching between different WAF-policies.
Reproduction steps
-
Get an exisiting virtualservice:
virtualservice = aviVroClient.getObjectByUUID('virtualservice',vsUuid); -
Unset the WafPolicyRef attribute which is currently not null:
virtualservice.setWafPolicyRef(null); -
Attempt to update the virtualservice-resource on AVI:
aviVroClient.addObject(virtualservice,workflowRuntime.getWorkflowId(),tenant)
This action completes with no error, but does not seem to trigger a PUT to the specified resource, as no change is seen on the resource in AVI, nor is there any entry in the audit log for this update.
Expected behavior
Setting an attribute to null should cause addObject to send a PUT setting the atribute to null.
Additional context
No response