nuagenetworks / vspk-python

A Python library for managing Nuage through its API
http://www.nuagenetworks.net
BSD 3-Clause "New" or "Revised" License
17 stars 19 forks source link

Accessing multiple VSD environments. #14

Closed mainTAP closed 6 years ago

mainTAP commented 7 years ago

Hello,

Can you please advise what is the best way to access two VSD environments at the same time ? Unfortunately it seems only the last NUVSDSession is taken into account : The following code fetches only the entrerprises from last NUVSDSession for both VSD1 and VSD2 objects :

VSD1 = vspk.NUVSDSession(username='admin', password='pass1', enterprise='csp', api_url="https://URL1:8443")
VSD2 = vspk.NUVSDSession(username='admin', password='pass2', enterprise='csp', api_url="https://URL2:8443")

VSD1.start()
VSD2.start()

VSD1.user.enterprises.fetch()
VSD2.user.enterprises.fetch()

Thank you

pdellaert commented 7 years ago

Currently, this is not supported within a single Python environment. We are looking at introducing this, but it will result in a significant redesign of the environment, so we need to handle this carefully.

pdellaert commented 6 years ago

Provided in the bambou 3.0 release, which is the default bambou release used in 5.2.2 and above