File tree 1 file changed +4
-1
lines changed
1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 8
8
import radix
9
9
import websocket
10
10
11
- url = "wss://ris-live.ripe.net/v1/ws/?client=username_at_example_com"
11
+ ## Uncomment and update this with a unique identifier for the RIPE team
12
+ #url = "wss://ris-live.ripe.net/v1/ws/?client=username_at_example_com"
12
13
13
14
tree = radix .Radix ()
14
15
32
33
while True :
33
34
ws = websocket .WebSocket ()
34
35
ws .connect (url )
36
+ # subscribe to all BGP Updates
35
37
ws .send (json .dumps ({"type" : "ris_subscribe" , "data" : {"type" : "UPDATE" }}))
36
38
try :
37
39
for data in ws :
48
50
print ("search_best: %s returned " % prefix , e )
49
51
if rnode is not None and rnode .data ['metadata' ] is not None :
50
52
as_path = ' ' .join (str (x ) for x in parsed_data .get ('path' , None ))
53
+ # Is it a more specific?
51
54
if prefix != rnode .prefix :
52
55
sub_prefix = "Yes"
53
56
else :
You can’t perform that action at this time.
0 commit comments