def _create_service_nwk(self, tenant_id, tenant_name, direc):
        """Function to create the service in network in DCNM. """
        net_dict = self.retrieve_dcnm_net_info(tenant_id, direc)
        net = utils.Dict2Obj(net_dict)
        subnet_dict = self.retrieve_dcnm_subnet_info(tenant_id, direc)
        subnet = utils.Dict2Obj(subnet_dict)
        try:
            self.dcnm_obj.create_service_network(tenant_name, net, subnet)
        except dexc.DfaClientRequestFailed:
            LOG.error("Failed to create network in DCNM %s", direc)
            return False
        return True
Function to create the service in network in DCNM.