Hi, Markku
ofctl_rest.py receives "dpid" as integer, so you have to use "GET /stats/desc/10". However, ofctl_rest.py is an example application, so you can modify ofctl_rest.py as you want. I suppose you may modify: https://github.com/osrg/ryu/blob/master/ryu/app/ofctl_rest.py#L199 The second argument is the base, so modifying here will work with "dpid" specified as 16 hex digits. Thanks, Fujimoto On 2017年04月21日 19:41, Markku Savela wrote: > Hi, > > In some places "dpid" is defined to be string of 16 hex digits. However in > > http://ryu.readthedocs.io/en/latest/app/ofctl_rest.html > > <dpid> is described as "integer", and all examples use either 1 or "1" > as value. > > If value is truly integer, then am I supposed to convert the hex string > acquired from somewhere else into decimal integer? Or, does the url hold > dpid as hex string, eg. should I use > > GET /stats/desc/a > > or > > GET /stats/desc/10 > > ??? > > Doing decimal conversion correctly in javascript is also tricky, because > converting hex string into decimal integer will give bad result, if dpid > uses more than 53 bits... > > > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > Ryu-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/ryu-devel ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Ryu-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ryu-devel
