On Fri, Mar 10, 2017 at 9:52 PM, Ryan Brady <rbr...@redhat.com> wrote: > > One of the pain points for me as an action developer is the OpenStack > actions[1]. Since they all use the same method name to retrieve the > underlying client, you cannot simply inherit from more than one so you are > forced to rewrite the client access methods. We saw this in creating > actions for TripleO[2]. In the base action in TripleO, we have actions that > make calls to more than one OpenStack client and so we end up re-writing and > maintaining code. IMO the idea of using multiple inheritance there would be > helpful. It may not require the mixin approach here, but rather a design > change in the generator to ensure the method names don't match.
Is there any reason why those methods aren't functions? AFAICT they don't use the instance, they could live top level in the action module and be accessible by all actions. If you can avoid multiple inheritance (or inheritance!) you'll simplify the design. You could also do client = NovaAction().get_client() in your own action (if get_client was a public method). -- Thomas __________________________________________________________________________ OpenStack Development Mailing List (not for usage questions) Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev