Verification of LSP instantiation message to PCC for LSP installation

asked 2017-07-31 06:46:06 -0700

purushotham gravatar image

Installed PCEP protocol plugins in the ODL. Post operation response, getting as 404 using RESTCONF in the python script. using below url. url:- /restconf/operations/network-topology-pcep:add-lsp source code:- import os,sys,logging import requests import json,xml import generatelogs, getconfig


ip = getconfig.getsysip()'ip address of the system is.... %s'%ip) url = "http://%s:8080/restconf/operations/network-topology-pcep:add-lsp"%ip

client = requests.Session() client.auth=("admin","admin") client.verify=False headers={'Content-Type':'application/xml','Accept':'application/xml'}

foo=open("PCEPtestCase6LSPinstantiation.xml","r"), headers=headers, data=text)'printing rest-put response... %s'%response)

resp=client.get(url, headers=headers)'printing rest-get response... %s'%resp) data=resp.content'open file to write the result...') fp = open("out.txt",'w') fp.write(data)'closing the opend file.......') fp.close()

please suggest the answers?

edit retag flag offensive close merge delete