ResourceRecord class - Platform - BlueCat Gateway - 20.12.1

Gateway Administration Guide

prodname
BlueCat Gateway
version_custom
20.12.1

class resource_record.ResourceRecord(api, api_entity)

Resource Record.

Bases: bluecat.entity.Entity

Base class for resource records.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

delete_with_options(no_server_update=False, delete_orphaned_ip_address=False)

Deletes objects that have options associated with their removal.
Note: This method currently works only with the deletion of dynamic records from the Address Manager database. When deleted, dynamic records present the option of not dynamically deploying to DNS/DHCP Server.
Parameters Description
no_server_update (boolean, required)

Default value: False

This applies to the dynamic resource records. If set to True, updates the record only in the Address Manager web interface. The change will not be deployed to the DNS server.

delete_orphaned_ip_address (boolean, required)

Default value: False

This applies to the delete operation on Host Records. If set to True, frees IP addresses associated with a host record if no other host records are associated with the IP address.

Returns: None.

Example:

api = g.user.get_api()                              # get api object
host_record_id = 12345                              # host record id
host_record = api.get_entity_by_id(host_record_id)

host_record.delete_with_options(no_server_update=True, 
delete_orphaned_ip_address=True)

get_configuration()

Get the owning configuration.

get_zone()

Get the parent zone.

get_view()

Get the owning view.

get_full_name()

Get the fully qualified domain name of the resource record.

get_absolute_name()

Get absolute name.

get_zone_name()

Get record’s zone name only.

get_specific_ttl()

If there is a specific TTL set for the resource record, return it, otherwise return -1.

get_ttl(server=none)

Find the applicable TTL for the resource record.

This involves walking the entity tree in many cases.

move(resource_record_id, destination_zone)

Move resource record to a new zone.

Parameters Description
resource_record_id The ID of the resource record to move.
destination_zone The FQDN of the destination zone.

class resource_record.MXRecord(api, api_entity)

Bases: resource_record.ResourceRecord.

Instantiate Mail Exchanger MX record.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

get_linked_record_name()

Get the linked record name.

class resource_record.TextRecord(api, api_entity)

Bases: resource_record.ResourceRecord.

Instantiate Text TXT record.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

class resource_record.HostInfoRecord(api, api_entity)

Bases: resource_record.ResourceRecord.

Instantiate Host Info HINFO record.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

class resource_record.SRVRecord(api, api_entity)

Bases: resource_record.ResourceRecord.

Instantiate Service SRV record.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

get_linked_record_name()

Get the linked record name.

class resource_record.NAPTRRecord(api, api_entity)

Bases: resource_record.ResourceRecord.

Instantiate Naming Authority Pointer Record NAPTR record.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

class resource_record.ExternalHostRecord(api, api_entity)

Bases: resource_record.ResourceRecord.

Instantiate External Host record.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

class resource_record.GenericRecord(api, api_entity)

Bases: resource_record.ResourceRecord.

Instantiate Generic record.

The following generic record types are available: A, A6, AAAA, AFSDB, APL, CERT, DHCID, DNAME, DS, IPSECKEY, ISDN, KEY, KX, LOC, MB, MG, MINFO, MR, NS, NSAP, PTR, PX, RP, RT, SINK, SPF, SSHFP, WKS, and X25. These records contain name, type, and value information.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

class resource_record.AliasRecord(*args, **kwargs)

Bases: bluecat.alias_record.AliasRecord.

Instantiate alias CNAME record.

Changed in version 20.6.1: The class AliasRecord has been moved to the module bluecat.alias_record. The one in the current module is provided as a backward compatible proxy.