On Wed, Feb 26, 2014 at 3:34 PM, Sylvain Bauza <[email protected]>wrote:
> > > > 2014-02-26 19:40 GMT+01:00 Doug Hellmann <[email protected]>: > > >> So you're not segregating the dynamic part of the API at all from the >> static part? >> >> Doug >> >> > No, you're right, at least with API V1 (Flask). As per our discussion, it > seems our use-case hasn't yet been implemented in WSME, so I'll provide a > different way to add extra attributes with API V2 (Pecan/WSME) by using a > single key with JSON-serialized extra attributes as value. > > Something like this: > { 'name': 'foo', > 'extra_capabilities': "{u'fruits':u'bananas',u'vgpus':u'2'}"} > > Using that body will allow us to keep WSME validation for extra > attributes, but I would really like having the logic I mentioned within > WSME in the next releases. Do you think this is something manageable some > way, or is it a tricky feature ? > It's probably something we can do, but it will take some thought. When receiving data we can stick the attributes on the model, but model will have no way to know what extra attributes need to be serialized, so returning the data may be a little challenging. Doug > > Thanks for your support Doug, > -Sylvain > > _______________________________________________ > OpenStack-dev mailing list > [email protected] > http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev > >
_______________________________________________ OpenStack-dev mailing list [email protected] http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
