grnet / synnefo

Synnefo is open source cloud software, used to create massively scalable IaaS clouds.
GNU General Public License v3.0
133 stars 45 forks source link

Make Plankton backend modular #386

Closed cstavr closed 2 years ago

cstavr commented 7 years ago

Hello!

This PR makes Cyclades more modular and extendable, by implementing support for external backend drivers on the Image Service of Cyclades (Plankton).

Until now, Plankton was directly creating and using an instance of the Pithos backend, which has the following downsides:

The goal of this PR is to decouple those components and make Cyclades able to use a different backing store for Plankton by means of external drivers. The current implementation that is using the Pithos backend is provided as the default driver implementation. An alternative implementation based on Pithos could use the Pithos public HTTP API instead of directly importing the client.

The first commits of this PR make some minor modifications to the PlanktonBackend and how it is used throughout the code to make it more modular.

The last commit, adds the PLANKTON_BACKEND_DRIVER setting that can be used to define the driver class that will be used and moves the existing backend implementation to synnefo.plankton.drivers.pithos_driver.PithosPlanktonDriver.

This PR does not modify the functionality of Plankton in any way, and it maintains full compatibility with the previous code path. User-wise, there are no visible changes. Hopefully, the flexibility to implement custom drivers will prove useful.

cstavr commented 7 years ago

Hello guys,

Any new on this PR? Has anyone had a chance to take a look at this? Please let me know your plans and whether I need to update this PR.