<div dir="ltr"><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Feb 26, 2014 at 3:34 PM, Sylvain Bauza <span dir="ltr"><<a href="mailto:sylvain.bauza@gmail.com" target="_blank">sylvain.bauza@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">2014-02-26 19:40 GMT+01:00 Doug Hellmann <span dir="ltr"><<a href="mailto:doug.hellmann@dreamhost.com" target="_blank">doug.hellmann@dreamhost.com</a>></span>:<div class="">
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div style="font-size:small"><br></div><div class="gmail_extra"><div class="gmail_quote"><div><div style="font-size:small">

So you're not segregating the dynamic part of the API at all from the static part?</div><span><font color="#888888"><div style="font-size:small">
<br></div><div style="font-size:small">Doug</div><br></font></span></div><div><div></div></div></div></div></div></blockquote><div><br></div></div><div>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.</div>

<div><br></div><div>Something like this:</div><div>{ 'name': 'foo',</div><div>  'extra_capabilities': "{u'fruits':u'bananas',u'vgpus':u'2'}"}</div><div><br>

</div><div>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 ?</div>
</div></div></div></blockquote><div><br></div><div><div class="gmail_default" style="font-size:small">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.</div>
<div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Doug</div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">
<div><br></div><div>Thanks for your support Doug,</div><div>-Sylvain</div></div></div></div>
<br>_______________________________________________<br>
OpenStack-dev mailing list<br>
<a href="mailto:OpenStack-dev@lists.openstack.org">OpenStack-dev@lists.openstack.org</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
<br></blockquote></div><br></div></div>