diff --git a/README.md b/README.md index 0066f89..cf4b941 100644 --- a/README.md +++ b/README.md @@ -90,7 +90,7 @@ if __name__ == "__main__": * [Cluster](./docs/entities.md#cluster) * [Virtual Machine](./docs/entities.md#virtual-machine) * [Virtual Disk](./docs/entities.md#virtual-disk) -* [Virtual Interface](./docs/entities.md#virtual-interface) +* [VM Interface](./docs/entities.md#vm-interface) ## Development notes diff --git a/docs/entities.md b/docs/entities.md index 61f8162..3bd2361 100644 --- a/docs/entities.md +++ b/docs/entities.md @@ -1255,7 +1255,7 @@ if __name__ == "__main__": ``` -## Virtual Interface +## VM Interface Attributes: @@ -1273,7 +1273,7 @@ Attributes: from netboxlabs.diode.sdk import DiodeClient from netboxlabs.diode.sdk.ingester import ( Entity, - VirtualInterface, + VMInterface, VirtualMachine, Cluster, ClusterGroup, @@ -1296,20 +1296,20 @@ def main(): entities = [] """ - VirtualInterface entity with only a name provided will attempt to create or update a name + VMInterface entity with only a name provided will attempt to create or update a name with the given name and placeholders (i.e. "undefined") for other nested objects types (e.g. VirtualMachine) required by NetBox. """ - virtual_interface = VirtualInterface(name="Interface A") + vminterface = VMInterface(name="Interface A") - entities.append(Entity(virtual_interface=virtual_interface)) + entities.append(Entity(vminterface=vminterface)) """ - VirtualInterface entity using flat data structure. + VMInterface entity using flat data structure. """ - virtual_interface_flat = VirtualInterface( + vminterface_flat = VMInterface( name="Interface A", virtual_machine="VM A", enabled=True, @@ -1319,13 +1319,13 @@ def main(): tags=["tag 1", "tag 2"], ) - entities.append(Entity(virtual_interface=virtual_interface_flat)) + entities.append(Entity(vminterface=vminterface_flat)) """ - VirtualInterface entity using explicit data structure. + VMInterface entity using explicit data structure. """ - virtual_interface_explicit = VirtualInterface( + vminterface_explicit = VMInterface( name="Interface A", virtual_machine=VirtualMachine( name="VM A", @@ -1399,7 +1399,7 @@ def main(): tags=["tag 1", "tag 2"], ) - entities.append(Entity(virtual_interface=virtual_interface_explicit)) + entities.append(Entity(vminterface=vminterface_explicit)) response = client.ingest(entities=entities) if response.errors: diff --git a/netboxlabs/diode/sdk/diode/v1/ingester_pb2.py b/netboxlabs/diode/sdk/diode/v1/ingester_pb2.py index 0ddfb67..4897938 100644 --- a/netboxlabs/diode/sdk/diode/v1/ingester_pb2.py +++ b/netboxlabs/diode/sdk/diode/v1/ingester_pb2.py @@ -16,7 +16,7 @@ from netboxlabs.diode.sdk.validate import validate_pb2 as validate_dot_validate__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x17\x64iode/v1/ingester.proto\x12\x08\x64iode.v1\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x17validate/validate.proto\"\xe4\x05\n\x06\x44\x65vice\x12\x1b\n\x04name\x18\x01 \x01(\tB\x07\xfa\x42\x04r\x02\x18@R\x04name\x12\x30\n\x0b\x64\x65vice_fqdn\x18\x02 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01H\x00R\ndeviceFqdn\x88\x01\x01\x12\x35\n\x0b\x64\x65vice_type\x18\x03 \x01(\x0b\x32\x14.diode.v1.DeviceTypeR\ndeviceType\x12\"\n\x04role\x18\x04 \x01(\x0b\x32\x0e.diode.v1.RoleR\x04role\x12.\n\x08platform\x18\x05 \x01(\x0b\x32\x12.diode.v1.PlatformR\x08platform\x12$\n\x06serial\x18\x06 \x01(\tB\x07\xfa\x42\x04r\x02\x18\x32H\x01R\x06serial\x88\x01\x01\x12\"\n\x04site\x18\x07 \x01(\x0b\x32\x0e.diode.v1.SiteR\x04site\x12*\n\tasset_tag\x18\x08 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x02R\x08\x61ssetTag\x88\x01\x01\x12\x63\n\x06status\x18\t \x01(\tBK\xfa\x42HrFR\x07offlineR\x06\x61\x63tiveR\x07plannedR\x06stagedR\x06\x66\x61iledR\tinventoryR\x0f\x64\x65\x63ommissioningR\x06status\x12/\n\x0b\x64\x65scription\x18\n \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x03R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x0b \x01(\tH\x04R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x0c \x03(\x0b\x32\r.diode.v1.TagR\x04tags\x12\x34\n\x0bprimary_ip4\x18\r \x01(\x0b\x32\x13.diode.v1.IPAddressR\nprimaryIp4\x12\x34\n\x0bprimary_ip6\x18\x0e \x01(\x0b\x32\x13.diode.v1.IPAddressR\nprimaryIp6B\x0e\n\x0c_device_fqdnB\t\n\x07_serialB\x0c\n\n_asset_tagB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\xef\x11\n\tInterface\x12\x32\n\x06\x64\x65vice\x18\x01 \x01(\x0b\x32\x10.diode.v1.DeviceB\x08\xfa\x42\x05\xa2\x01\x02\x08\x01R\x06\x64\x65vice\x12\x1d\n\x04name\x18\x02 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18@R\x04name\x12$\n\x05label\x18\x03 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18@H\x00R\x05label\x88\x01\x01\x12\xfa\x0c\n\x04type\x18\x04 \x01(\tB\xe5\x0c\xfa\x42\xe1\x0cr\xde\x0cR\x07virtualR\x06\x62ridgeR\x03lagR\n100base-fxR\x0b\x31\x30\x30\x62\x61se-lfxR\n100base-txR\n100base-t1R\n1000base-tR\x0f\x31\x30\x30\x30\x62\x61se-x-gbicR\x0e\x31\x30\x30\x30\x62\x61se-x-sfpR\n2.5gbase-tR\x08\x35gbase-tR\t10gbase-tR\x0b\x31\x30gbase-cx4R\x0e\x31\x30gbase-x-sfppR\r10gbase-x-xfpR\x10\x31\x30gbase-x-xenpakR\x0c\x31\x30gbase-x-x2R\x0f\x32\x35gbase-x-sfp28R\x0f\x35\x30gbase-x-sfp56R\x0f\x34\x30gbase-x-qsfppR\x0f\x35\x30gbase-x-sfp28R\x0e\x31\x30\x30gbase-x-cfpR\x0f\x31\x30\x30gbase-x-cfp2R\x0f\x31\x30\x30gbase-x-cfp4R\x0e\x31\x30\x30gbase-x-cxpR\x0f\x31\x30\x30gbase-x-cpakR\x0f\x31\x30\x30gbase-x-dsfpR\x10\x31\x30\x30gbase-x-sfpddR\x11\x31\x30\x30gbase-x-qsfp28R\x11\x31\x30\x30gbase-x-qsfpddR\x0f\x32\x30\x30gbase-x-cfp2R\x11\x32\x30\x30gbase-x-qsfp56R\x11\x32\x30\x30gbase-x-qsfpddR\x0f\x34\x30\x30gbase-x-cfp2R\x12\x34\x30\x30gbase-x-qsfp112R\x11\x34\x30\x30gbase-x-qsfpddR\x0f\x34\x30\x30gbase-x-osfpR\x13\x34\x30\x30gbase-x-osfp-rhsR\x0f\x34\x30\x30gbase-x-cdfpR\x0f\x34\x30\x30gbase-x-cfp8R\x11\x38\x30\x30gbase-x-qsfpddR\x0f\x38\x30\x30gbase-x-osfpR\x0b\x31\x30\x30\x30\x62\x61se-kxR\n10gbase-krR\x0b\x31\x30gbase-kx4R\n25gbase-krR\x0b\x34\x30gbase-kr4R\n50gbase-krR\x0c\x31\x30\x30gbase-kp4R\x0c\x31\x30\x30gbase-kr2R\x0c\x31\x30\x30gbase-kr4R\x0bieee802.11aR\x0bieee802.11gR\x0bieee802.11nR\x0cieee802.11acR\x0cieee802.11adR\x0cieee802.11axR\x0cieee802.11ayR\x0cieee802.15.1R\x0eother-wirelessR\x03gsmR\x04\x63\x64maR\x03lteR\tsonet-oc3R\nsonet-oc12R\nsonet-oc48R\x0bsonet-oc192R\x0bsonet-oc768R\x0csonet-oc1920R\x0csonet-oc3840R\x08\x31gfc-sfpR\x08\x32gfc-sfpR\x08\x34gfc-sfpR\t8gfc-sfppR\n16gfc-sfppR\x0b\x33\x32gfc-sfp28R\x0b\x36\x34gfc-qsfppR\r128gfc-qsfp28R\x0einfiniband-sdrR\x0einfiniband-ddrR\x0einfiniband-qdrR\x10infiniband-fdr10R\x0einfiniband-fdrR\x0einfiniband-edrR\x0einfiniband-hdrR\x0einfiniband-ndrR\x0einfiniband-xdrR\x02t1R\x02\x65\x31R\x02t3R\x02\x65\x33R\x04xdslR\x06\x64ocsisR\x04gponR\x06xg-ponR\x07xgs-ponR\x07ng-pon2R\x04\x65ponR\x08\x31\x30g-eponR\x0f\x63isco-stackwiseR\x14\x63isco-stackwise-plusR\x0f\x63isco-flexstackR\x14\x63isco-flexstack-plusR\x12\x63isco-stackwise-80R\x13\x63isco-stackwise-160R\x13\x63isco-stackwise-320R\x13\x63isco-stackwise-480R\x12\x63isco-stackwise-1tR\x0bjuniper-vcpR\x13\x65xtreme-summitstackR\x17\x65xtreme-summitstack-128R\x17\x65xtreme-summitstack-256R\x17\x65xtreme-summitstack-512R\x05otherR\x04type\x12\x1d\n\x07\x65nabled\x18\x05 \x01(\x08H\x01R\x07\x65nabled\x88\x01\x01\x12\"\n\x03mtu\x18\x06 \x01(\x05\x42\x0b\xfa\x42\x08\x1a\x06\x18\x80\x80\x04(\x01H\x02R\x03mtu\x88\x01\x01\x12$\n\x0bmac_address\x18\x07 \x01(\tH\x03R\nmacAddress\x88\x01\x01\x12\"\n\x05speed\x18\x08 \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00H\x04R\x05speed\x88\x01\x01\x12\x15\n\x03wwn\x18\t \x01(\tH\x05R\x03wwn\x88\x01\x01\x12 \n\tmgmt_only\x18\n \x01(\x08H\x06R\x08mgmtOnly\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x0b \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x07R\x0b\x64\x65scription\x88\x01\x01\x12*\n\x0emark_connected\x18\x0c \x01(\x08H\x08R\rmarkConnected\x88\x01\x01\x12\x35\n\x04mode\x18\r \x01(\tB!\xfa\x42\x1er\x1cR\x06\x61\x63\x63\x65ssR\x06taggedR\ntagged-allR\x04mode\x12!\n\x04tags\x18\x0e \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x08\n\x06_labelB\n\n\x08_enabledB\x06\n\x04_mtuB\x0e\n\x0c_mac_addressB\x08\n\x06_speedB\x06\n\x04_wwnB\x0c\n\n_mgmt_onlyB\x0e\n\x0c_descriptionB\x11\n\x0f_mark_connected\"\xe3\x02\n\x07\x43luster\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12)\n\x04type\x18\x02 \x01(\x0b\x32\x15.diode.v1.ClusterTypeR\x04type\x12,\n\x05group\x18\x03 \x01(\x0b\x32\x16.diode.v1.ClusterGroupR\x05group\x12\"\n\x04site\x18\x04 \x01(\x0b\x32\x0e.diode.v1.SiteR\x04site\x12X\n\x06status\x18\x05 \x01(\tB@\xfa\x42=r;R\x07offlineR\x06\x61\x63tiveR\x07plannedR\x06stagedR\x06\x66\x61iledR\x0f\x64\x65\x63ommissioningR\x06status\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x07 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xc1\x01\n\x0b\x43lusterType\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12/\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x04 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xc2\x01\n\x0c\x43lusterGroup\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12/\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x04 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xde\x05\n\x0eVirtualMachine\x12\x1b\n\x04name\x18\x01 \x01(\tB\x07\xfa\x42\x04r\x02\x18@R\x04name\x12X\n\x06status\x18\x02 \x01(\tB@\xfa\x42=r;R\x07offlineR\x06\x61\x63tiveR\x07plannedR\x06stagedR\x06\x66\x61iledR\x0f\x64\x65\x63ommissioningR\x06status\x12\"\n\x04site\x18\x03 \x01(\x0b\x32\x0e.diode.v1.SiteR\x04site\x12+\n\x07\x63luster\x18\x04 \x01(\x0b\x32\x11.diode.v1.ClusterR\x07\x63luster\x12\"\n\x04role\x18\x05 \x01(\x0b\x32\x0e.diode.v1.RoleR\x04role\x12(\n\x06\x64\x65vice\x18\x06 \x01(\x0b\x32\x10.diode.v1.DeviceR\x06\x64\x65vice\x12.\n\x08platform\x18\x07 \x01(\x0b\x32\x12.diode.v1.PlatformR\x08platform\x12\x34\n\x0bprimary_ip4\x18\x08 \x01(\x0b\x32\x13.diode.v1.IPAddressR\nprimaryIp4\x12\x34\n\x0bprimary_ip6\x18\t \x01(\x0b\x32\x13.diode.v1.IPAddressR\nprimaryIp6\x12\"\n\x05vcpus\x18\n \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00H\x00R\x05vcpus\x88\x01\x01\x12$\n\x06memory\x18\x0b \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00H\x01R\x06memory\x88\x01\x01\x12 \n\x04\x64isk\x18\x0c \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00H\x02R\x04\x64isk\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\r \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x03R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x0e \x01(\tH\x04R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x0f \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x08\n\x06_vcpusB\t\n\x07_memoryB\x07\n\x05_diskB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\xef\x02\n\x10VirtualInterface\x12K\n\x0fvirtual_machine\x18\x01 \x01(\x0b\x32\x18.diode.v1.VirtualMachineB\x08\xfa\x42\x05\xa2\x01\x02\x08\x01R\x0evirtualMachine\x12\x1d\n\x04name\x18\x02 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18@R\x04name\x12\x1d\n\x07\x65nabled\x18\x03 \x01(\x08H\x00R\x07\x65nabled\x88\x01\x01\x12\"\n\x03mtu\x18\x04 \x01(\x05\x42\x0b\xfa\x42\x08\x1a\x06\x18\x80\x80\x04(\x01H\x01R\x03mtu\x88\x01\x01\x12$\n\x0bmac_address\x18\x05 \x01(\tH\x02R\nmacAddress\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x03R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x07 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\n\n\x08_enabledB\x06\n\x04_mtuB\x0e\n\x0c_mac_addressB\x0e\n\x0c_description\"\xfa\x01\n\x0bVirtualDisk\x12K\n\x0fvirtual_machine\x18\x01 \x01(\x0b\x32\x18.diode.v1.VirtualMachineB\x08\xfa\x42\x05\xa2\x01\x02\x08\x01R\x0evirtualMachine\x12\x1d\n\x04name\x18\x02 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12\x1b\n\x04size\x18\x03 \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00R\x04size\x12/\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x05 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\x8c\x04\n\tIPAddress\x12!\n\x07\x61\x64\x64ress\x18\x01 \x01(\tB\x07\xfa\x42\x04r\x02p\x01R\x07\x61\x64\x64ress\x12\x33\n\tinterface\x18\x02 \x01(\x0b\x32\x13.diode.v1.InterfaceH\x00R\tinterface\x12H\n\x06status\x18\x03 \x01(\tB0\xfa\x42-r+R\x06\x61\x63tiveR\x08reservedR\ndeprecatedR\x04\x64hcpR\x05slaacR\x06status\x12T\n\x04role\x18\x04 \x01(\tB@\xfa\x42=r;R\x08loopbackR\tsecondaryR\x07\x61nycastR\x03vipR\x04vrrpR\x04hsrpR\x04glbpR\x04\x63\x61rpR\x04role\x12U\n\x08\x64ns_name\x18\x05 \x01(\tB5\xfa\x42\x32r0\x18\xff\x01\x32+^([0-9A-Za-z_-]+|\\*)(\\.[0-9A-Za-z_-]+)*\\.?$H\x01R\x07\x64nsName\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x02R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x07 \x01(\tH\x03R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x08 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x11\n\x0f\x61ssigned_objectB\x0b\n\t_dns_nameB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\xeb\x02\n\nDeviceType\x12\x1f\n\x05model\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x05model\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12:\n\x0cmanufacturer\x18\x03 \x01(\x0b\x32\x16.diode.v1.ManufacturerR\x0cmanufacturer\x12/\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x05 \x01(\tH\x01R\x08\x63omments\x88\x01\x01\x12-\n\x0bpart_number\x18\x06 \x01(\tB\x07\xfa\x42\x04r\x02\x18\x32H\x02R\npartNumber\x88\x01\x01\x12!\n\x04tags\x18\x07 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_descriptionB\x0b\n\t_commentsB\x0e\n\x0c_part_number\"\xc2\x01\n\x0cManufacturer\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12/\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x04 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xfa\x01\n\x08Platform\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12:\n\x0cmanufacturer\x18\x03 \x01(\x0b\x32\x16.diode.v1.ManufacturerR\x0cmanufacturer\x12/\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x05 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\x8d\x03\n\x06Prefix\x12\x1f\n\x06prefix\x18\x01 \x01(\tB\x07\xfa\x42\x04r\x02p\x01R\x06prefix\x12\"\n\x04site\x18\x02 \x01(\x0b\x32\x0e.diode.v1.SiteR\x04site\x12\x46\n\x06status\x18\x03 \x01(\tB.\xfa\x42+r)R\x06\x61\x63tiveR\tcontainerR\x08reservedR\ndeprecatedR\x06status\x12\x1c\n\x07is_pool\x18\x04 \x01(\x08H\x00R\x06isPool\x88\x01\x01\x12(\n\rmark_utilized\x18\x05 \x01(\x08H\x01R\x0cmarkUtilized\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x02R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x07 \x01(\tH\x03R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x08 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\n\n\x08_is_poolB\x10\n\x0e_mark_utilizedB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\xea\x01\n\x04Role\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12.\n\x05\x63olor\x18\x03 \x01(\tB\x18\xfa\x42\x15r\x13\x10\x06\x18\x06\x32\r^[0-9a-f]{6}$R\x05\x63olor\x12/\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x05 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xa2\x03\n\x04Site\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12Q\n\x06status\x18\x03 \x01(\tB9\xfa\x42\x36r4R\x07plannedR\x07stagingR\x06\x61\x63tiveR\x0f\x64\x65\x63ommissioningR\x07retiredR\x06status\x12(\n\x08\x66\x61\x63ility\x18\x04 \x01(\tB\x07\xfa\x42\x04r\x02\x18\x32H\x00R\x08\x66\x61\x63ility\x88\x01\x01\x12 \n\ttime_zone\x18\x05 \x01(\tH\x01R\x08timeZone\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x02R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x07 \x01(\tH\x03R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x08 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0b\n\t_facilityB\x0c\n\n_time_zoneB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\x85\x01\n\x03Tag\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12.\n\x05\x63olor\x18\x03 \x01(\tB\x18\xfa\x42\x15r\x13\x10\x06\x18\x06\x32\r^[0-9a-f]{6}$R\x05\x63olor\"\x93\x07\n\x06\x45ntity\x12$\n\x04site\x18\x01 \x01(\x0b\x32\x0e.diode.v1.SiteH\x00R\x04site\x12\x30\n\x08platform\x18\x02 \x01(\x0b\x32\x12.diode.v1.PlatformH\x00R\x08platform\x12<\n\x0cmanufacturer\x18\x03 \x01(\x0b\x32\x16.diode.v1.ManufacturerH\x00R\x0cmanufacturer\x12*\n\x06\x64\x65vice\x18\x04 \x01(\x0b\x32\x10.diode.v1.DeviceH\x00R\x06\x64\x65vice\x12\x31\n\x0b\x64\x65vice_role\x18\x05 \x01(\x0b\x32\x0e.diode.v1.RoleH\x00R\ndeviceRole\x12\x37\n\x0b\x64\x65vice_type\x18\x06 \x01(\x0b\x32\x14.diode.v1.DeviceTypeH\x00R\ndeviceType\x12\x33\n\tinterface\x18\x07 \x01(\x0b\x32\x13.diode.v1.InterfaceH\x00R\tinterface\x12\x34\n\nip_address\x18\t \x01(\x0b\x32\x13.diode.v1.IPAddressH\x00R\tipAddress\x12*\n\x06prefix\x18\n \x01(\x0b\x32\x10.diode.v1.PrefixH\x00R\x06prefix\x12=\n\rcluster_group\x18\x0b \x01(\x0b\x32\x16.diode.v1.ClusterGroupH\x00R\x0c\x63lusterGroup\x12:\n\x0c\x63luster_type\x18\x0c \x01(\x0b\x32\x15.diode.v1.ClusterTypeH\x00R\x0b\x63lusterType\x12-\n\x07\x63luster\x18\r \x01(\x0b\x32\x11.diode.v1.ClusterH\x00R\x07\x63luster\x12\x43\n\x0fvirtual_machine\x18\x0e \x01(\x0b\x32\x18.diode.v1.VirtualMachineH\x00R\x0evirtualMachine\x12I\n\x11virtual_interface\x18\x0f \x01(\x0b\x32\x1a.diode.v1.VirtualInterfaceH\x00R\x10virtualInterface\x12:\n\x0cvirtual_disk\x18\x10 \x01(\x0b\x32\x15.diode.v1.VirtualDiskH\x00R\x0bvirtualDisk\x12\x44\n\ttimestamp\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\n\xfa\x42\x07\xb2\x01\x04\x08\x01\x38\x01R\ttimestampB\x08\n\x06\x65ntity\"\xe4\x02\n\rIngestRequest\x12\"\n\x06stream\x18\x01 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01R\x06stream\x12\x39\n\x08\x65ntities\x18\x02 \x03(\x0b\x32\x10.diode.v1.EntityB\x0b\xfa\x42\x08\x92\x01\x05\x08\x01\x10\xe8\x07R\x08\x65ntities\x12\x18\n\x02id\x18\x03 \x01(\tB\x08\xfa\x42\x05r\x03\xb0\x01\x01R\x02id\x12\x36\n\x11producer_app_name\x18\x04 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01R\x0fproducerAppName\x12<\n\x14producer_app_version\x18\x05 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01R\x12producerAppVersion\x12%\n\x08sdk_name\x18\x06 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01R\x07sdkName\x12=\n\x0bsdk_version\x18\x07 \x01(\tB\x1c\xfa\x42\x19r\x17\x32\x15^(\\d)+\\.(\\d)+\\.(\\d)+$R\nsdkVersion\"(\n\x0eIngestResponse\x12\x16\n\x06\x65rrors\x18\x01 \x03(\tR\x06\x65rrors2P\n\x0fIngesterService\x12=\n\x06Ingest\x12\x17.diode.v1.IngestRequest\x1a\x18.diode.v1.IngestResponse\"\x00\x42\x35Z3github.com/netboxlabs/diode-sdk-go/diode/v1/diodepbb\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x17\x64iode/v1/ingester.proto\x12\x08\x64iode.v1\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x17validate/validate.proto\"\xe4\x05\n\x06\x44\x65vice\x12\x1b\n\x04name\x18\x01 \x01(\tB\x07\xfa\x42\x04r\x02\x18@R\x04name\x12\x30\n\x0b\x64\x65vice_fqdn\x18\x02 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01H\x00R\ndeviceFqdn\x88\x01\x01\x12\x35\n\x0b\x64\x65vice_type\x18\x03 \x01(\x0b\x32\x14.diode.v1.DeviceTypeR\ndeviceType\x12\"\n\x04role\x18\x04 \x01(\x0b\x32\x0e.diode.v1.RoleR\x04role\x12.\n\x08platform\x18\x05 \x01(\x0b\x32\x12.diode.v1.PlatformR\x08platform\x12$\n\x06serial\x18\x06 \x01(\tB\x07\xfa\x42\x04r\x02\x18\x32H\x01R\x06serial\x88\x01\x01\x12\"\n\x04site\x18\x07 \x01(\x0b\x32\x0e.diode.v1.SiteR\x04site\x12*\n\tasset_tag\x18\x08 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x02R\x08\x61ssetTag\x88\x01\x01\x12\x63\n\x06status\x18\t \x01(\tBK\xfa\x42HrFR\x07offlineR\x06\x61\x63tiveR\x07plannedR\x06stagedR\x06\x66\x61iledR\tinventoryR\x0f\x64\x65\x63ommissioningR\x06status\x12/\n\x0b\x64\x65scription\x18\n \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x03R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x0b \x01(\tH\x04R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x0c \x03(\x0b\x32\r.diode.v1.TagR\x04tags\x12\x34\n\x0bprimary_ip4\x18\r \x01(\x0b\x32\x13.diode.v1.IPAddressR\nprimaryIp4\x12\x34\n\x0bprimary_ip6\x18\x0e \x01(\x0b\x32\x13.diode.v1.IPAddressR\nprimaryIp6B\x0e\n\x0c_device_fqdnB\t\n\x07_serialB\x0c\n\n_asset_tagB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\xef\x11\n\tInterface\x12\x32\n\x06\x64\x65vice\x18\x01 \x01(\x0b\x32\x10.diode.v1.DeviceB\x08\xfa\x42\x05\xa2\x01\x02\x08\x01R\x06\x64\x65vice\x12\x1d\n\x04name\x18\x02 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18@R\x04name\x12$\n\x05label\x18\x03 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18@H\x00R\x05label\x88\x01\x01\x12\xfa\x0c\n\x04type\x18\x04 \x01(\tB\xe5\x0c\xfa\x42\xe1\x0cr\xde\x0cR\x07virtualR\x06\x62ridgeR\x03lagR\n100base-fxR\x0b\x31\x30\x30\x62\x61se-lfxR\n100base-txR\n100base-t1R\n1000base-tR\x0f\x31\x30\x30\x30\x62\x61se-x-gbicR\x0e\x31\x30\x30\x30\x62\x61se-x-sfpR\n2.5gbase-tR\x08\x35gbase-tR\t10gbase-tR\x0b\x31\x30gbase-cx4R\x0e\x31\x30gbase-x-sfppR\r10gbase-x-xfpR\x10\x31\x30gbase-x-xenpakR\x0c\x31\x30gbase-x-x2R\x0f\x32\x35gbase-x-sfp28R\x0f\x35\x30gbase-x-sfp56R\x0f\x34\x30gbase-x-qsfppR\x0f\x35\x30gbase-x-sfp28R\x0e\x31\x30\x30gbase-x-cfpR\x0f\x31\x30\x30gbase-x-cfp2R\x0f\x31\x30\x30gbase-x-cfp4R\x0e\x31\x30\x30gbase-x-cxpR\x0f\x31\x30\x30gbase-x-cpakR\x0f\x31\x30\x30gbase-x-dsfpR\x10\x31\x30\x30gbase-x-sfpddR\x11\x31\x30\x30gbase-x-qsfp28R\x11\x31\x30\x30gbase-x-qsfpddR\x0f\x32\x30\x30gbase-x-cfp2R\x11\x32\x30\x30gbase-x-qsfp56R\x11\x32\x30\x30gbase-x-qsfpddR\x0f\x34\x30\x30gbase-x-cfp2R\x12\x34\x30\x30gbase-x-qsfp112R\x11\x34\x30\x30gbase-x-qsfpddR\x0f\x34\x30\x30gbase-x-osfpR\x13\x34\x30\x30gbase-x-osfp-rhsR\x0f\x34\x30\x30gbase-x-cdfpR\x0f\x34\x30\x30gbase-x-cfp8R\x11\x38\x30\x30gbase-x-qsfpddR\x0f\x38\x30\x30gbase-x-osfpR\x0b\x31\x30\x30\x30\x62\x61se-kxR\n10gbase-krR\x0b\x31\x30gbase-kx4R\n25gbase-krR\x0b\x34\x30gbase-kr4R\n50gbase-krR\x0c\x31\x30\x30gbase-kp4R\x0c\x31\x30\x30gbase-kr2R\x0c\x31\x30\x30gbase-kr4R\x0bieee802.11aR\x0bieee802.11gR\x0bieee802.11nR\x0cieee802.11acR\x0cieee802.11adR\x0cieee802.11axR\x0cieee802.11ayR\x0cieee802.15.1R\x0eother-wirelessR\x03gsmR\x04\x63\x64maR\x03lteR\tsonet-oc3R\nsonet-oc12R\nsonet-oc48R\x0bsonet-oc192R\x0bsonet-oc768R\x0csonet-oc1920R\x0csonet-oc3840R\x08\x31gfc-sfpR\x08\x32gfc-sfpR\x08\x34gfc-sfpR\t8gfc-sfppR\n16gfc-sfppR\x0b\x33\x32gfc-sfp28R\x0b\x36\x34gfc-qsfppR\r128gfc-qsfp28R\x0einfiniband-sdrR\x0einfiniband-ddrR\x0einfiniband-qdrR\x10infiniband-fdr10R\x0einfiniband-fdrR\x0einfiniband-edrR\x0einfiniband-hdrR\x0einfiniband-ndrR\x0einfiniband-xdrR\x02t1R\x02\x65\x31R\x02t3R\x02\x65\x33R\x04xdslR\x06\x64ocsisR\x04gponR\x06xg-ponR\x07xgs-ponR\x07ng-pon2R\x04\x65ponR\x08\x31\x30g-eponR\x0f\x63isco-stackwiseR\x14\x63isco-stackwise-plusR\x0f\x63isco-flexstackR\x14\x63isco-flexstack-plusR\x12\x63isco-stackwise-80R\x13\x63isco-stackwise-160R\x13\x63isco-stackwise-320R\x13\x63isco-stackwise-480R\x12\x63isco-stackwise-1tR\x0bjuniper-vcpR\x13\x65xtreme-summitstackR\x17\x65xtreme-summitstack-128R\x17\x65xtreme-summitstack-256R\x17\x65xtreme-summitstack-512R\x05otherR\x04type\x12\x1d\n\x07\x65nabled\x18\x05 \x01(\x08H\x01R\x07\x65nabled\x88\x01\x01\x12\"\n\x03mtu\x18\x06 \x01(\x05\x42\x0b\xfa\x42\x08\x1a\x06\x18\x80\x80\x04(\x01H\x02R\x03mtu\x88\x01\x01\x12$\n\x0bmac_address\x18\x07 \x01(\tH\x03R\nmacAddress\x88\x01\x01\x12\"\n\x05speed\x18\x08 \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00H\x04R\x05speed\x88\x01\x01\x12\x15\n\x03wwn\x18\t \x01(\tH\x05R\x03wwn\x88\x01\x01\x12 \n\tmgmt_only\x18\n \x01(\x08H\x06R\x08mgmtOnly\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x0b \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x07R\x0b\x64\x65scription\x88\x01\x01\x12*\n\x0emark_connected\x18\x0c \x01(\x08H\x08R\rmarkConnected\x88\x01\x01\x12\x35\n\x04mode\x18\r \x01(\tB!\xfa\x42\x1er\x1cR\x06\x61\x63\x63\x65ssR\x06taggedR\ntagged-allR\x04mode\x12!\n\x04tags\x18\x0e \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x08\n\x06_labelB\n\n\x08_enabledB\x06\n\x04_mtuB\x0e\n\x0c_mac_addressB\x08\n\x06_speedB\x06\n\x04_wwnB\x0c\n\n_mgmt_onlyB\x0e\n\x0c_descriptionB\x11\n\x0f_mark_connected\"\xe3\x02\n\x07\x43luster\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12)\n\x04type\x18\x02 \x01(\x0b\x32\x15.diode.v1.ClusterTypeR\x04type\x12,\n\x05group\x18\x03 \x01(\x0b\x32\x16.diode.v1.ClusterGroupR\x05group\x12\"\n\x04site\x18\x04 \x01(\x0b\x32\x0e.diode.v1.SiteR\x04site\x12X\n\x06status\x18\x05 \x01(\tB@\xfa\x42=r;R\x07offlineR\x06\x61\x63tiveR\x07plannedR\x06stagedR\x06\x66\x61iledR\x0f\x64\x65\x63ommissioningR\x06status\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x07 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xc1\x01\n\x0b\x43lusterType\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12/\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x04 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xc2\x01\n\x0c\x43lusterGroup\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12/\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x04 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xde\x05\n\x0eVirtualMachine\x12\x1b\n\x04name\x18\x01 \x01(\tB\x07\xfa\x42\x04r\x02\x18@R\x04name\x12X\n\x06status\x18\x02 \x01(\tB@\xfa\x42=r;R\x07offlineR\x06\x61\x63tiveR\x07plannedR\x06stagedR\x06\x66\x61iledR\x0f\x64\x65\x63ommissioningR\x06status\x12\"\n\x04site\x18\x03 \x01(\x0b\x32\x0e.diode.v1.SiteR\x04site\x12+\n\x07\x63luster\x18\x04 \x01(\x0b\x32\x11.diode.v1.ClusterR\x07\x63luster\x12\"\n\x04role\x18\x05 \x01(\x0b\x32\x0e.diode.v1.RoleR\x04role\x12(\n\x06\x64\x65vice\x18\x06 \x01(\x0b\x32\x10.diode.v1.DeviceR\x06\x64\x65vice\x12.\n\x08platform\x18\x07 \x01(\x0b\x32\x12.diode.v1.PlatformR\x08platform\x12\x34\n\x0bprimary_ip4\x18\x08 \x01(\x0b\x32\x13.diode.v1.IPAddressR\nprimaryIp4\x12\x34\n\x0bprimary_ip6\x18\t \x01(\x0b\x32\x13.diode.v1.IPAddressR\nprimaryIp6\x12\"\n\x05vcpus\x18\n \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00H\x00R\x05vcpus\x88\x01\x01\x12$\n\x06memory\x18\x0b \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00H\x01R\x06memory\x88\x01\x01\x12 \n\x04\x64isk\x18\x0c \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00H\x02R\x04\x64isk\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\r \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x03R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x0e \x01(\tH\x04R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x0f \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x08\n\x06_vcpusB\t\n\x07_memoryB\x07\n\x05_diskB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\xea\x02\n\x0bVMInterface\x12K\n\x0fvirtual_machine\x18\x01 \x01(\x0b\x32\x18.diode.v1.VirtualMachineB\x08\xfa\x42\x05\xa2\x01\x02\x08\x01R\x0evirtualMachine\x12\x1d\n\x04name\x18\x02 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18@R\x04name\x12\x1d\n\x07\x65nabled\x18\x03 \x01(\x08H\x00R\x07\x65nabled\x88\x01\x01\x12\"\n\x03mtu\x18\x04 \x01(\x05\x42\x0b\xfa\x42\x08\x1a\x06\x18\x80\x80\x04(\x01H\x01R\x03mtu\x88\x01\x01\x12$\n\x0bmac_address\x18\x05 \x01(\tH\x02R\nmacAddress\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x03R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x07 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\n\n\x08_enabledB\x06\n\x04_mtuB\x0e\n\x0c_mac_addressB\x0e\n\x0c_description\"\xfa\x01\n\x0bVirtualDisk\x12K\n\x0fvirtual_machine\x18\x01 \x01(\x0b\x32\x18.diode.v1.VirtualMachineB\x08\xfa\x42\x05\xa2\x01\x02\x08\x01R\x0evirtualMachine\x12\x1d\n\x04name\x18\x02 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12\x1b\n\x04size\x18\x03 \x01(\x05\x42\x07\xfa\x42\x04\x1a\x02(\x00R\x04size\x12/\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x05 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\x8c\x04\n\tIPAddress\x12!\n\x07\x61\x64\x64ress\x18\x01 \x01(\tB\x07\xfa\x42\x04r\x02p\x01R\x07\x61\x64\x64ress\x12\x33\n\tinterface\x18\x02 \x01(\x0b\x32\x13.diode.v1.InterfaceH\x00R\tinterface\x12H\n\x06status\x18\x03 \x01(\tB0\xfa\x42-r+R\x06\x61\x63tiveR\x08reservedR\ndeprecatedR\x04\x64hcpR\x05slaacR\x06status\x12T\n\x04role\x18\x04 \x01(\tB@\xfa\x42=r;R\x08loopbackR\tsecondaryR\x07\x61nycastR\x03vipR\x04vrrpR\x04hsrpR\x04glbpR\x04\x63\x61rpR\x04role\x12U\n\x08\x64ns_name\x18\x05 \x01(\tB5\xfa\x42\x32r0\x18\xff\x01\x32+^([0-9A-Za-z_-]+|\\*)(\\.[0-9A-Za-z_-]+)*\\.?$H\x01R\x07\x64nsName\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x02R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x07 \x01(\tH\x03R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x08 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x11\n\x0f\x61ssigned_objectB\x0b\n\t_dns_nameB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\xeb\x02\n\nDeviceType\x12\x1f\n\x05model\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x05model\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12:\n\x0cmanufacturer\x18\x03 \x01(\x0b\x32\x16.diode.v1.ManufacturerR\x0cmanufacturer\x12/\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x05 \x01(\tH\x01R\x08\x63omments\x88\x01\x01\x12-\n\x0bpart_number\x18\x06 \x01(\tB\x07\xfa\x42\x04r\x02\x18\x32H\x02R\npartNumber\x88\x01\x01\x12!\n\x04tags\x18\x07 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_descriptionB\x0b\n\t_commentsB\x0e\n\x0c_part_number\"\xc2\x01\n\x0cManufacturer\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12/\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x04 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xfa\x01\n\x08Platform\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12:\n\x0cmanufacturer\x18\x03 \x01(\x0b\x32\x16.diode.v1.ManufacturerR\x0cmanufacturer\x12/\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x05 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\x8d\x03\n\x06Prefix\x12\x1f\n\x06prefix\x18\x01 \x01(\tB\x07\xfa\x42\x04r\x02p\x01R\x06prefix\x12\"\n\x04site\x18\x02 \x01(\x0b\x32\x0e.diode.v1.SiteR\x04site\x12\x46\n\x06status\x18\x03 \x01(\tB.\xfa\x42+r)R\x06\x61\x63tiveR\tcontainerR\x08reservedR\ndeprecatedR\x06status\x12\x1c\n\x07is_pool\x18\x04 \x01(\x08H\x00R\x06isPool\x88\x01\x01\x12(\n\rmark_utilized\x18\x05 \x01(\x08H\x01R\x0cmarkUtilized\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x02R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x07 \x01(\tH\x03R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x08 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\n\n\x08_is_poolB\x10\n\x0e_mark_utilizedB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\xea\x01\n\x04Role\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12.\n\x05\x63olor\x18\x03 \x01(\tB\x18\xfa\x42\x15r\x13\x10\x06\x18\x06\x32\r^[0-9a-f]{6}$R\x05\x63olor\x12/\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x00R\x0b\x64\x65scription\x88\x01\x01\x12!\n\x04tags\x18\x05 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0e\n\x0c_description\"\xa2\x03\n\x04Site\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12Q\n\x06status\x18\x03 \x01(\tB9\xfa\x42\x36r4R\x07plannedR\x07stagingR\x06\x61\x63tiveR\x0f\x64\x65\x63ommissioningR\x07retiredR\x06status\x12(\n\x08\x66\x61\x63ility\x18\x04 \x01(\tB\x07\xfa\x42\x04r\x02\x18\x32H\x00R\x08\x66\x61\x63ility\x88\x01\x01\x12 \n\ttime_zone\x18\x05 \x01(\tH\x01R\x08timeZone\x88\x01\x01\x12/\n\x0b\x64\x65scription\x18\x06 \x01(\tB\x08\xfa\x42\x05r\x03\x18\xc8\x01H\x02R\x0b\x64\x65scription\x88\x01\x01\x12\x1f\n\x08\x63omments\x18\x07 \x01(\tH\x03R\x08\x63omments\x88\x01\x01\x12!\n\x04tags\x18\x08 \x03(\x0b\x32\r.diode.v1.TagR\x04tagsB\x0b\n\t_facilityB\x0c\n\n_time_zoneB\x0e\n\x0c_descriptionB\x0b\n\t_comments\"\x85\x01\n\x03Tag\x12\x1d\n\x04name\x18\x01 \x01(\tB\t\xfa\x42\x06r\x04\x10\x01\x18\x64R\x04name\x12/\n\x04slug\x18\x02 \x01(\tB\x1b\xfa\x42\x18r\x16\x10\x01\x18\x64\x32\x10^[-a-zA-Z0-9_]+$R\x04slug\x12.\n\x05\x63olor\x18\x03 \x01(\tB\x18\xfa\x42\x15r\x13\x10\x06\x18\x06\x32\r^[0-9a-f]{6}$R\x05\x63olor\"\x83\x07\n\x06\x45ntity\x12$\n\x04site\x18\x01 \x01(\x0b\x32\x0e.diode.v1.SiteH\x00R\x04site\x12\x30\n\x08platform\x18\x02 \x01(\x0b\x32\x12.diode.v1.PlatformH\x00R\x08platform\x12<\n\x0cmanufacturer\x18\x03 \x01(\x0b\x32\x16.diode.v1.ManufacturerH\x00R\x0cmanufacturer\x12*\n\x06\x64\x65vice\x18\x04 \x01(\x0b\x32\x10.diode.v1.DeviceH\x00R\x06\x64\x65vice\x12\x31\n\x0b\x64\x65vice_role\x18\x05 \x01(\x0b\x32\x0e.diode.v1.RoleH\x00R\ndeviceRole\x12\x37\n\x0b\x64\x65vice_type\x18\x06 \x01(\x0b\x32\x14.diode.v1.DeviceTypeH\x00R\ndeviceType\x12\x33\n\tinterface\x18\x07 \x01(\x0b\x32\x13.diode.v1.InterfaceH\x00R\tinterface\x12\x34\n\nip_address\x18\t \x01(\x0b\x32\x13.diode.v1.IPAddressH\x00R\tipAddress\x12*\n\x06prefix\x18\n \x01(\x0b\x32\x10.diode.v1.PrefixH\x00R\x06prefix\x12=\n\rcluster_group\x18\x0b \x01(\x0b\x32\x16.diode.v1.ClusterGroupH\x00R\x0c\x63lusterGroup\x12:\n\x0c\x63luster_type\x18\x0c \x01(\x0b\x32\x15.diode.v1.ClusterTypeH\x00R\x0b\x63lusterType\x12-\n\x07\x63luster\x18\r \x01(\x0b\x32\x11.diode.v1.ClusterH\x00R\x07\x63luster\x12\x43\n\x0fvirtual_machine\x18\x0e \x01(\x0b\x32\x18.diode.v1.VirtualMachineH\x00R\x0evirtualMachine\x12\x39\n\x0bvminterface\x18\x0f \x01(\x0b\x32\x15.diode.v1.VMInterfaceH\x00R\x0bvminterface\x12:\n\x0cvirtual_disk\x18\x10 \x01(\x0b\x32\x15.diode.v1.VirtualDiskH\x00R\x0bvirtualDisk\x12\x44\n\ttimestamp\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\n\xfa\x42\x07\xb2\x01\x04\x08\x01\x38\x01R\ttimestampB\x08\n\x06\x65ntity\"\xe4\x02\n\rIngestRequest\x12\"\n\x06stream\x18\x01 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01R\x06stream\x12\x39\n\x08\x65ntities\x18\x02 \x03(\x0b\x32\x10.diode.v1.EntityB\x0b\xfa\x42\x08\x92\x01\x05\x08\x01\x10\xe8\x07R\x08\x65ntities\x12\x18\n\x02id\x18\x03 \x01(\tB\x08\xfa\x42\x05r\x03\xb0\x01\x01R\x02id\x12\x36\n\x11producer_app_name\x18\x04 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01R\x0fproducerAppName\x12<\n\x14producer_app_version\x18\x05 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01R\x12producerAppVersion\x12%\n\x08sdk_name\x18\x06 \x01(\tB\n\xfa\x42\x07r\x05\x10\x01\x18\xff\x01R\x07sdkName\x12=\n\x0bsdk_version\x18\x07 \x01(\tB\x1c\xfa\x42\x19r\x17\x32\x15^(\\d)+\\.(\\d)+\\.(\\d)+$R\nsdkVersion\"(\n\x0eIngestResponse\x12\x16\n\x06\x65rrors\x18\x01 \x03(\tR\x06\x65rrors2P\n\x0fIngesterService\x12=\n\x06Ingest\x12\x17.diode.v1.IngestRequest\x1a\x18.diode.v1.IngestResponse\"\x00\x42\x35Z3github.com/netboxlabs/diode-sdk-go/diode/v1/diodepbb\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -82,14 +82,14 @@ _globals['_VIRTUALMACHINE'].fields_by_name['disk']._serialized_options = b'\372B\004\032\002(\000' _globals['_VIRTUALMACHINE'].fields_by_name['description']._loaded_options = None _globals['_VIRTUALMACHINE'].fields_by_name['description']._serialized_options = b'\372B\005r\003\030\310\001' - _globals['_VIRTUALINTERFACE'].fields_by_name['virtual_machine']._loaded_options = None - _globals['_VIRTUALINTERFACE'].fields_by_name['virtual_machine']._serialized_options = b'\372B\005\242\001\002\010\001' - _globals['_VIRTUALINTERFACE'].fields_by_name['name']._loaded_options = None - _globals['_VIRTUALINTERFACE'].fields_by_name['name']._serialized_options = b'\372B\006r\004\020\001\030@' - _globals['_VIRTUALINTERFACE'].fields_by_name['mtu']._loaded_options = None - _globals['_VIRTUALINTERFACE'].fields_by_name['mtu']._serialized_options = b'\372B\010\032\006\030\200\200\004(\001' - _globals['_VIRTUALINTERFACE'].fields_by_name['description']._loaded_options = None - _globals['_VIRTUALINTERFACE'].fields_by_name['description']._serialized_options = b'\372B\005r\003\030\310\001' + _globals['_VMINTERFACE'].fields_by_name['virtual_machine']._loaded_options = None + _globals['_VMINTERFACE'].fields_by_name['virtual_machine']._serialized_options = b'\372B\005\242\001\002\010\001' + _globals['_VMINTERFACE'].fields_by_name['name']._loaded_options = None + _globals['_VMINTERFACE'].fields_by_name['name']._serialized_options = b'\372B\006r\004\020\001\030@' + _globals['_VMINTERFACE'].fields_by_name['mtu']._loaded_options = None + _globals['_VMINTERFACE'].fields_by_name['mtu']._serialized_options = b'\372B\010\032\006\030\200\200\004(\001' + _globals['_VMINTERFACE'].fields_by_name['description']._loaded_options = None + _globals['_VMINTERFACE'].fields_by_name['description']._serialized_options = b'\372B\005r\003\030\310\001' _globals['_VIRTUALDISK'].fields_by_name['virtual_machine']._loaded_options = None _globals['_VIRTUALDISK'].fields_by_name['virtual_machine']._serialized_options = b'\372B\005\242\001\002\010\001' _globals['_VIRTUALDISK'].fields_by_name['name']._loaded_options = None @@ -186,32 +186,32 @@ _globals['_CLUSTERGROUP']._serialized_end=3877 _globals['_VIRTUALMACHINE']._serialized_start=3880 _globals['_VIRTUALMACHINE']._serialized_end=4614 - _globals['_VIRTUALINTERFACE']._serialized_start=4617 - _globals['_VIRTUALINTERFACE']._serialized_end=4984 - _globals['_VIRTUALDISK']._serialized_start=4987 - _globals['_VIRTUALDISK']._serialized_end=5237 - _globals['_IPADDRESS']._serialized_start=5240 - _globals['_IPADDRESS']._serialized_end=5764 - _globals['_DEVICETYPE']._serialized_start=5767 - _globals['_DEVICETYPE']._serialized_end=6130 - _globals['_MANUFACTURER']._serialized_start=6133 - _globals['_MANUFACTURER']._serialized_end=6327 - _globals['_PLATFORM']._serialized_start=6330 - _globals['_PLATFORM']._serialized_end=6580 - _globals['_PREFIX']._serialized_start=6583 - _globals['_PREFIX']._serialized_end=6980 - _globals['_ROLE']._serialized_start=6983 - _globals['_ROLE']._serialized_end=7217 - _globals['_SITE']._serialized_start=7220 - _globals['_SITE']._serialized_end=7638 - _globals['_TAG']._serialized_start=7641 - _globals['_TAG']._serialized_end=7774 - _globals['_ENTITY']._serialized_start=7777 - _globals['_ENTITY']._serialized_end=8692 - _globals['_INGESTREQUEST']._serialized_start=8695 - _globals['_INGESTREQUEST']._serialized_end=9051 - _globals['_INGESTRESPONSE']._serialized_start=9053 - _globals['_INGESTRESPONSE']._serialized_end=9093 - _globals['_INGESTERSERVICE']._serialized_start=9095 - _globals['_INGESTERSERVICE']._serialized_end=9175 + _globals['_VMINTERFACE']._serialized_start=4617 + _globals['_VMINTERFACE']._serialized_end=4979 + _globals['_VIRTUALDISK']._serialized_start=4982 + _globals['_VIRTUALDISK']._serialized_end=5232 + _globals['_IPADDRESS']._serialized_start=5235 + _globals['_IPADDRESS']._serialized_end=5759 + _globals['_DEVICETYPE']._serialized_start=5762 + _globals['_DEVICETYPE']._serialized_end=6125 + _globals['_MANUFACTURER']._serialized_start=6128 + _globals['_MANUFACTURER']._serialized_end=6322 + _globals['_PLATFORM']._serialized_start=6325 + _globals['_PLATFORM']._serialized_end=6575 + _globals['_PREFIX']._serialized_start=6578 + _globals['_PREFIX']._serialized_end=6975 + _globals['_ROLE']._serialized_start=6978 + _globals['_ROLE']._serialized_end=7212 + _globals['_SITE']._serialized_start=7215 + _globals['_SITE']._serialized_end=7633 + _globals['_TAG']._serialized_start=7636 + _globals['_TAG']._serialized_end=7769 + _globals['_ENTITY']._serialized_start=7772 + _globals['_ENTITY']._serialized_end=8671 + _globals['_INGESTREQUEST']._serialized_start=8674 + _globals['_INGESTREQUEST']._serialized_end=9030 + _globals['_INGESTRESPONSE']._serialized_start=9032 + _globals['_INGESTRESPONSE']._serialized_end=9072 + _globals['_INGESTERSERVICE']._serialized_start=9074 + _globals['_INGESTERSERVICE']._serialized_end=9154 # @@protoc_insertion_point(module_scope) diff --git a/netboxlabs/diode/sdk/diode/v1/ingester_pb2.pyi b/netboxlabs/diode/sdk/diode/v1/ingester_pb2.pyi index 4ee89d0..3d4ffe0 100644 --- a/netboxlabs/diode/sdk/diode/v1/ingester_pb2.pyi +++ b/netboxlabs/diode/sdk/diode/v1/ingester_pb2.pyi @@ -147,7 +147,7 @@ class VirtualMachine(_message.Message): tags: _containers.RepeatedCompositeFieldContainer[Tag] def __init__(self, name: _Optional[str] = ..., status: _Optional[str] = ..., site: _Optional[_Union[Site, _Mapping]] = ..., cluster: _Optional[_Union[Cluster, _Mapping]] = ..., role: _Optional[_Union[Role, _Mapping]] = ..., device: _Optional[_Union[Device, _Mapping]] = ..., platform: _Optional[_Union[Platform, _Mapping]] = ..., primary_ip4: _Optional[_Union[IPAddress, _Mapping]] = ..., primary_ip6: _Optional[_Union[IPAddress, _Mapping]] = ..., vcpus: _Optional[int] = ..., memory: _Optional[int] = ..., disk: _Optional[int] = ..., description: _Optional[str] = ..., comments: _Optional[str] = ..., tags: _Optional[_Iterable[_Union[Tag, _Mapping]]] = ...) -> None: ... -class VirtualInterface(_message.Message): +class VMInterface(_message.Message): __slots__ = ("virtual_machine", "name", "enabled", "mtu", "mac_address", "description", "tags") VIRTUAL_MACHINE_FIELD_NUMBER: _ClassVar[int] NAME_FIELD_NUMBER: _ClassVar[int] @@ -308,7 +308,7 @@ class Tag(_message.Message): def __init__(self, name: _Optional[str] = ..., slug: _Optional[str] = ..., color: _Optional[str] = ...) -> None: ... class Entity(_message.Message): - __slots__ = ("site", "platform", "manufacturer", "device", "device_role", "device_type", "interface", "ip_address", "prefix", "cluster_group", "cluster_type", "cluster", "virtual_machine", "virtual_interface", "virtual_disk", "timestamp") + __slots__ = ("site", "platform", "manufacturer", "device", "device_role", "device_type", "interface", "ip_address", "prefix", "cluster_group", "cluster_type", "cluster", "virtual_machine", "vminterface", "virtual_disk", "timestamp") SITE_FIELD_NUMBER: _ClassVar[int] PLATFORM_FIELD_NUMBER: _ClassVar[int] MANUFACTURER_FIELD_NUMBER: _ClassVar[int] @@ -322,7 +322,7 @@ class Entity(_message.Message): CLUSTER_TYPE_FIELD_NUMBER: _ClassVar[int] CLUSTER_FIELD_NUMBER: _ClassVar[int] VIRTUAL_MACHINE_FIELD_NUMBER: _ClassVar[int] - VIRTUAL_INTERFACE_FIELD_NUMBER: _ClassVar[int] + VMINTERFACE_FIELD_NUMBER: _ClassVar[int] VIRTUAL_DISK_FIELD_NUMBER: _ClassVar[int] TIMESTAMP_FIELD_NUMBER: _ClassVar[int] site: Site @@ -338,10 +338,10 @@ class Entity(_message.Message): cluster_type: ClusterType cluster: Cluster virtual_machine: VirtualMachine - virtual_interface: VirtualInterface + vminterface: VMInterface virtual_disk: VirtualDisk timestamp: _timestamp_pb2.Timestamp - def __init__(self, site: _Optional[_Union[Site, _Mapping]] = ..., platform: _Optional[_Union[Platform, _Mapping]] = ..., manufacturer: _Optional[_Union[Manufacturer, _Mapping]] = ..., device: _Optional[_Union[Device, _Mapping]] = ..., device_role: _Optional[_Union[Role, _Mapping]] = ..., device_type: _Optional[_Union[DeviceType, _Mapping]] = ..., interface: _Optional[_Union[Interface, _Mapping]] = ..., ip_address: _Optional[_Union[IPAddress, _Mapping]] = ..., prefix: _Optional[_Union[Prefix, _Mapping]] = ..., cluster_group: _Optional[_Union[ClusterGroup, _Mapping]] = ..., cluster_type: _Optional[_Union[ClusterType, _Mapping]] = ..., cluster: _Optional[_Union[Cluster, _Mapping]] = ..., virtual_machine: _Optional[_Union[VirtualMachine, _Mapping]] = ..., virtual_interface: _Optional[_Union[VirtualInterface, _Mapping]] = ..., virtual_disk: _Optional[_Union[VirtualDisk, _Mapping]] = ..., timestamp: _Optional[_Union[_timestamp_pb2.Timestamp, _Mapping]] = ...) -> None: ... + def __init__(self, site: _Optional[_Union[Site, _Mapping]] = ..., platform: _Optional[_Union[Platform, _Mapping]] = ..., manufacturer: _Optional[_Union[Manufacturer, _Mapping]] = ..., device: _Optional[_Union[Device, _Mapping]] = ..., device_role: _Optional[_Union[Role, _Mapping]] = ..., device_type: _Optional[_Union[DeviceType, _Mapping]] = ..., interface: _Optional[_Union[Interface, _Mapping]] = ..., ip_address: _Optional[_Union[IPAddress, _Mapping]] = ..., prefix: _Optional[_Union[Prefix, _Mapping]] = ..., cluster_group: _Optional[_Union[ClusterGroup, _Mapping]] = ..., cluster_type: _Optional[_Union[ClusterType, _Mapping]] = ..., cluster: _Optional[_Union[Cluster, _Mapping]] = ..., virtual_machine: _Optional[_Union[VirtualMachine, _Mapping]] = ..., vminterface: _Optional[_Union[VMInterface, _Mapping]] = ..., virtual_disk: _Optional[_Union[VirtualDisk, _Mapping]] = ..., timestamp: _Optional[_Union[_timestamp_pb2.Timestamp, _Mapping]] = ...) -> None: ... class IngestRequest(_message.Message): __slots__ = ("stream", "entities", "id", "producer_app_name", "producer_app_version", "sdk_name", "sdk_version") diff --git a/netboxlabs/diode/sdk/ingester.py b/netboxlabs/diode/sdk/ingester.py index aa4ad6c..a2b5318 100644 --- a/netboxlabs/diode/sdk/ingester.py +++ b/netboxlabs/diode/sdk/ingester.py @@ -22,7 +22,7 @@ Site as SitePb, Tag as TagPb, VirtualDisk as VirtualDiskPb, - VirtualInterface as VirtualInterfacePb, + VMInterface as VMInterfacePb, VirtualMachine as VirtualMachinePb, ) @@ -621,8 +621,8 @@ def __new__( ) -class VirtualInterface: - """VirtualInterface message wrapper.""" +class VMInterface: + """VMInterface message wrapper.""" def __new__( cls, @@ -633,7 +633,7 @@ def __new__( mac_address: str | None = None, description: str | None = None, tags: list[str | Tag | TagPb] | None = None, - ) -> VirtualInterfacePb: + ) -> VMInterfacePb: """Create a new virtual interface protobuf message.""" virtual_machine = convert_to_protobuf( virtual_machine, VirtualMachinePb, name=virtual_machine @@ -642,7 +642,7 @@ def __new__( if isinstance(tags, list) and all(isinstance(t, str) for t in tags): tags = [TagPb(name=tag) for tag in tags] - return VirtualInterfacePb( + return VMInterfacePb( name=name, virtual_machine=virtual_machine, enabled=enabled, @@ -671,7 +671,7 @@ def __new__( cluster_type: str | ClusterType | ClusterTypePb | None = None, cluster: str | Cluster | ClusterPb | None = None, virtual_disk: str | VirtualDisk | VirtualDiskPb | None = None, - virtual_interface: str | VirtualInterface | VirtualInterfacePb | None = None, + vminterface: str | VMInterface | VMInterfacePb | None = None, virtual_machine: str | VirtualMachine | VirtualMachinePb | None = None, timestamp: _timestamp_pb2.Timestamp | None = None, ): @@ -697,8 +697,8 @@ def __new__( virtual_disk = convert_to_protobuf( virtual_disk, VirtualDiskPb, name=virtual_disk ) - virtual_interface = convert_to_protobuf( - virtual_interface, VirtualInterfacePb, name=virtual_interface + vminterface = convert_to_protobuf( + vminterface, VMInterfacePb, name=vminterface ) virtual_machine = convert_to_protobuf( virtual_machine, VirtualMachinePb, name=virtual_machine @@ -718,7 +718,7 @@ def __new__( cluster_type=cluster_type, cluster=cluster, virtual_disk=virtual_disk, - virtual_interface=virtual_interface, + vminterface=vminterface, virtual_machine=virtual_machine, timestamp=timestamp, ) diff --git a/tests/test_ingester.py b/tests/test_ingester.py index 1afb1e7..c7be42f 100644 --- a/tests/test_ingester.py +++ b/tests/test_ingester.py @@ -19,7 +19,7 @@ Site as SitePb, Tag as TagPb, VirtualDisk as VirtualDiskPb, - VirtualInterface as VirtualInterfacePb, + VMInterface as VMInterfacePb, VirtualMachine as VirtualMachinePb, ) from netboxlabs.diode.sdk.ingester import ( @@ -38,7 +38,7 @@ Site, Tag, VirtualDisk, - VirtualInterface, + VMInterface, VirtualMachine, convert_to_protobuf, ) @@ -597,9 +597,9 @@ def test_virtual_disk_instantiation_with_all_fields(): assert isinstance(tag, TagPb) -def test_virtual_interface_instantiation_with_all_fields(): - """Check VirtualInterface instantiation with all fields.""" - virtual_interface = VirtualInterface( +def test_vminterface_instantiation_with_all_fields(): + """Check VMInterface instantiation with all fields.""" + vminterface = VMInterface( name="eth01", virtual_machine="vm1", enabled=True, @@ -608,15 +608,15 @@ def test_virtual_interface_instantiation_with_all_fields(): description="Virtual interface", tags=["vm", "ifce"], ) - assert isinstance(virtual_interface, VirtualInterfacePb) - assert isinstance(virtual_interface.virtual_machine, VirtualMachinePb) - assert virtual_interface.name == "eth01" - assert virtual_interface.virtual_machine.name == "vm1" - assert virtual_interface.mtu == 1500 - assert virtual_interface.mac_address == "00:00:00:00:00:00" - assert virtual_interface.description == "Virtual interface" - assert len(virtual_interface.tags) == 2 - for tag in virtual_interface.tags: + assert isinstance(vminterface, VMInterfacePb) + assert isinstance(vminterface.virtual_machine, VirtualMachinePb) + assert vminterface.name == "eth01" + assert vminterface.virtual_machine.name == "vm1" + assert vminterface.mtu == 1500 + assert vminterface.mac_address == "00:00:00:00:00:00" + assert vminterface.description == "Virtual interface" + assert len(vminterface.tags) == 2 + for tag in vminterface.tags: assert isinstance(tag, TagPb) @@ -779,11 +779,11 @@ def test_entity_instantiation_with_virtual_disk(): assert entity.virtual_disk.name == "VirtualDisk1" -def test_entity_instantiation_with_virtual_interface(): +def test_entity_instantiation_with_vminterface(): """Check Entity instantiation with virtual interface.""" entity = Entity( - virtual_interface="VirtualInterface1", + vminterface="VMInterface1", ) assert isinstance(entity, EntityPb) - assert isinstance(entity.virtual_interface, VirtualInterfacePb) - assert entity.virtual_interface.name == "VirtualInterface1" + assert isinstance(entity.vminterface, VMInterfacePb) + assert entity.vminterface.name == "VMInterface1"