<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:Courier;
panose-1:2 7 4 9 2 2 5 2 4 4;}
@font-face
{font-family:Courier;
panose-1:2 7 4 9 2 2 5 2 4 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
{font-family:Consolas;
panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
pre
{mso-style-priority:99;
mso-style-link:"HTML Preformatted Char";
margin:0in;
margin-bottom:.0001pt;
font-size:10.0pt;
font-family:"Courier New";}
span.HTMLPreformattedChar
{mso-style-name:"HTML Preformatted Char";
mso-style-priority:99;
mso-style-link:"HTML Preformatted";
font-family:Consolas;}
span.EmailStyle19
{mso-style-type:personal;
font-family:"Calibri","sans-serif";
color:windowtext;}
p.HTML, li.HTML, div.HTML
{mso-style-name:"HTML \9884\8BBE\683C\5F0F";
mso-style-link:"HTML \9884\8BBE\683C\5F0F Char";
margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
span.HTMLChar
{mso-style-name:"HTML \9884\8BBE\683C\5F0F Char";
mso-style-priority:99;
mso-style-link:"HTML \9884\8BBE\683C\5F0F";
font-family:"Courier New";}
span.line
{mso-style-name:line;}
span.id
{mso-style-name:id;}
span.number
{mso-style-name:number;}
span.string
{mso-style-name:string;}
span.EmailStyle26
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='color:#1F497D'>Hi Leon,<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>You don’t have to map the API operations one-to-one to SQLAlchemy operations. For this call (create a pool), you can in SQLAlchemy first create the “pool” row in a pool table, then create the members rows in the member table (and set their pool_id to the pool you created).<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>If you are worried about updating the DB transactionally, then you can start a transaction before updating both tables and commit it only when both tables have been updated successfully. There will be a lot of operations in the API that will require updating more than one table in the DB, so we have to support transactions anyway.<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>Thanks<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>Youcef<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Leon Cui [mailto:lcui@vmware.com] <br><b>Sent:</b> Monday, November 19, 2012 2:34 AM<br><b>To:</b> Youcef Laribi<br><b>Cc:</b> openstack-dev@lists.openstack.org<br><b>Subject:</b> [quantum][LBaas] Add members to the pool<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Hi Youcef,<o:p></o:p></p><p class=MsoNormal>While I’m coding on SQLAlchemy data model for pool, I found that there is no way to create a pool and specifying its members in a single rest call. The members will only be added to a pool by using member creation/update methods. <o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Therefore, the sample given in API spec in “Creating a pool” should be corrected as below, where “members” is removed.<o:p></o:p></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>POST /v1.</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#0080C0'>0</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>/pools<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>Host: lbaas-service.cloudX.com:</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#0080C0'>8651</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'><o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>Accept: application/json<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>Content-Type: application/json<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>X-Auth-Token:</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#0080C0'>887665443383838</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'><o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>Content-Length: </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#0080C0'>194</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'><o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'><o:p> </o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>{<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'> </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"pool"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'> : {<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'> </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"name"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>: </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"web_pool"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>,<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'> </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"vip_id"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>: </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"db902c0c-d5ff-4753-b465-668ad9656918"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>,<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'> </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"protocol"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>: </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"HTTP"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>,<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'> </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"network_id"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'> : </span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:#004080'>"e2a7a228-8fd1-4aa8-8d0c-4023a68e1c92"</span><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>,<o:p></o:p></span></p><p class=MsoNormal style='line-height:13.5pt;background:#F3F5F7'><span lang=EN style='font-size:10.5pt;font-family:Courier;color:black'>}<o:p></o:p></span></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>What do you think? Correct me if I’m wrong.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Thanks<o:p></o:p></p><p class=MsoNormal>Leon<o:p></o:p></p></div></body></html>