Commit 8271c8f5 authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Service component - L3NM gNMI OpenConfig Service Handler:

- Minor logging fix
parent 26d23b3a
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@ import json, logging, netaddr, re
from typing import Dict, List, Optional, Set, Tuple
from common.DeviceTypes import DeviceTypeEnum
from common.proto.context_pb2 import ConfigActionEnum, Device, EndPoint, Service
from common.tools.grpc.Tools import grpc_message_to_json_string
from common.tools.object_factory.ConfigRule import json_config_rule_delete, json_config_rule_set
from service.service.service_handler_api.AnyTreeTools import TreeNode

@@ -94,7 +95,7 @@ class EndpointComposer:
            self.ipv4_address = json_settings['ip_address']
        else:
            MSG = 'IP Address not found. Tried: address_ip and ip_address. endpoint_obj={:s} settings={:s}'
            LOGGER.warning(MSG.format(str(endpoint_obj), str(settings)))
            LOGGER.warning(MSG.format(grpc_message_to_json_string(endpoint_obj), str(settings)))

        if 'address_prefix' in json_settings:
            self.ipv4_prefix_len = json_settings['address_prefix']
@@ -102,7 +103,7 @@ class EndpointComposer:
            self.ipv4_prefix_len = json_settings['prefix_length']
        else:
            MSG = 'IP Address Prefix not found. Tried: address_prefix and prefix_length. endpoint_obj={:s} settings={:s}'
            LOGGER.warning(MSG.format(str(endpoint_obj), str(settings)))
            LOGGER.warning(MSG.format(grpc_message_to_json_string(endpoint_obj), str(settings)))

        self.sub_interface_index = json_settings.get('index', 0)