You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been trying to create some PTR records for bonjour (b._dns-sd._udp and lb._dns-sd._udp) that use ptrdname to point to a (sub)domain. When I try to create these records with the Python API client, I see that there's no way to distinguish between one record or the other since the initial search looks for ['ptrdname', 'view', 'ipv4addr'], so with both records having the same ptrdname domain value, I get the first created record both times.
Eg. creation of b._dns-sd._udp leads to a search for: {"view": "my_view", "ptrdname": "mydomain.com"}, to decide if the record already exists or not, then when I try to add lb._dns-sd._udp, it once again searches for {"view": "my_view", "ptrdname": "mydomain.com"} which returns the record for b._dns-sd._udp instead of giving no record since lb._dns-sd._udp hasn't been created yet.
If I add name into the _search_for_update_fields in PtrRecordV4, I fix this problem for myself, but I haven't put enough thought into how this'll impact other "normal" PTR record functions to want to create a pull request, but I can if you'll find that helpful.
The text was updated successfully, but these errors were encountered:
There's also a slightly different issue to add to this. As I'm trying to create a local workaround, I'm manually fetching a PTR record (with the name) in order to update it, or create it if the fetch failed. When doing the update on a PTR record where I'm only concerned with the ptrdname field, this Infoblox library sends back a blank ipv4addr field to the Infoblox appliance, which the Infoblox API doesn't like. I worked around this issue locally by manually modifying _updateable_search_fields to not include ipv4addr. It probably needs a fix in the library though.
This issue seems to be a big enhancement as the changes you are suggesting are related to Objects.py which has a lot of backward compatibility with different plugins. Also, we can’t remove the 'ipv4addr' field from '_updateable_search_fields' as this field is a dependent field for multiple Operations like Updating the record, Creating a new record, etc.
We can look into this issue in our future releases. Thanks for your efforts.
Hi,
I've been trying to create some PTR records for bonjour (
b._dns-sd._udp
andlb._dns-sd._udp
) that useptrdname
to point to a (sub)domain. When I try to create these records with the Python API client, I see that there's no way to distinguish between one record or the other since the initial search looks for['ptrdname', 'view', 'ipv4addr']
, so with both records having the sameptrdname
domain value, I get the first created record both times.Eg. creation of
b._dns-sd._udp
leads to a search for:{"view": "my_view", "ptrdname": "mydomain.com"}
, to decide if the record already exists or not, then when I try to addlb._dns-sd._udp
, it once again searches for{"view": "my_view", "ptrdname": "mydomain.com"}
which returns the record forb._dns-sd._udp
instead of giving no record sincelb._dns-sd._udp
hasn't been created yet.If I add
name
into the_search_for_update_fields
in PtrRecordV4, I fix this problem for myself, but I haven't put enough thought into how this'll impact other "normal" PTR record functions to want to create a pull request, but I can if you'll find that helpful.The text was updated successfully, but these errors were encountered: