<div dir="ltr">Hi All,<br><br>As we are using fedora-21-atomic-2 image and that has Kubernetes
v0.11.0, I tried to run v1beta3 APIs on it. Some of the APIs failed.<br>The
Kubernetes developer said "v1beta3 wasn't fully supported until the
0.15.0 release". Hence this is causing some APIs to fail.<br><br>Below are the failures:<br><br>1. service-create API fail(422 status) with v1beta3 request format.<br> The request format has changed from v1beta1 to v1beta3.<br> <a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/api.md#v1beta3-conversion-tips" target="_blank">https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/api.md#v1beta3-conversion-tips</a><br><br> I have logged an issue for the same at GoogleCloudPlatform/Kubernetes:<br> <a href="https://github.com/GoogleCloudPlatform/kubernetes/issues/7157">https://github.com/GoogleCloudPlatform/kubernetes/issues/7157</a><br><br>2. pod-create API fail(500 status) with invalid request format.<br> While doing negative testing, I found that pod-create API fails with 500 status. It should actually fail with 400 status.<br><br> I have logged an issue for the same at GoogleCloudPlatform/Kubernetes:<br> <a href="https://github.com/GoogleCloudPlatform/kubernetes/issues/7087" target="_blank">https://github.com/GoogleCloudPlatform/kubernetes/issues/7087</a><br><br>3. pod-update API fail(404).<br> While trying to update a pod<b>, </b>it failed with status 404 even if the pod exists. This is due to duplicate replacePod API in Kubernetes Client code.<br><br> I have logged an issue for the same at GoogleCloudPlatform/Kubernetes:<br> <a href="https://github.com/GoogleCloudPlatform/kubernetes/issues/7100" target="_blank">https://github.com/GoogleCloudPlatform/kubernetes/issues/7100</a><br><br>4. All APIs fail with json manifest.<br>
All Kubernetes resources(pod, rc, service) now fails with json format
manifest due to issue in swagger-codegen generated Kubernetes Client
code.<br> It doesn't support unicode string.<br><br>After all this
issues, can we really switch to Kubernetes Client in this release or
should we wait for the Fedora image with Kubernetes 0.15.0 release that
has full support of v1beta3?<br><br>Please provide your suggestions on this so that I can proceed further.<br><br>
<div>
<div><font face="Arial" size="2" color="000000">Thanks & Regards<br>
Madhuri Kumari<br>
</font><font color="000000"><b><font face="Arial" size="2"><br>
</font></b></font></div>
</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Mar 24, 2015 at 10:37 AM, Madhuri Rai <span dir="ltr"><<a href="mailto:madhuri.rai07@gmail.com" target="_blank">madhuri.rai07@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">Hi Hongbin,<br><br><div><div class="gmail_extra"><br><div class="gmail_quote"><span class="">On Tue, Mar 24, 2015 at 12:37 AM, Hongbin Lu <span dir="ltr"><<a href="mailto:hongbin034@gmail.com" target="_blank">hongbin034@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi Madhuri,<div><br></div><div>Amazing work! I wouldn't concern the code duplication and modularity issue since the codes are generated. However, there is another concern here: if we find a bug/improvement of the generated code, we probably need to modify the generator. The question is if the upstream will accept the modifications? If yes, how fast the patch will go through.</div><div><br></div><div>I would prefer to maintain a folk of the generator. By this way, we would have full control of the generated code. Thoughts?</div></div></blockquote><div><br></div></span><div>I agree that's a concern. I will try to fix the pep8 error upstream to look how it take to push a change upstream.<br><br></div><div><div class="h5"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><br></div><div>Thanks,</div><div>Hongbin</div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div>On Mon, Mar 23, 2015 at 10:11 AM, Steven Dake (stdake) <span dir="ltr"><<a href="mailto:stdake@cisco.com" target="_blank">stdake@cisco.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div>
<div style="word-wrap:break-word;color:rgb(0,0,0);font-size:14px;font-family:Calibri,sans-serif">
<div><br>
</div>
<div><br>
</div>
<span>
<div style="font-family:Calibri;font-size:11pt;text-align:left;color:black;border-width:1pt medium medium;border-style:solid none none;border-color:rgb(181,196,223) -moz-use-text-color -moz-use-text-color;padding:3pt 0in 0in">
<span style="font-weight:bold">From: </span>Madhuri Rai <<a href="mailto:madhuri.rai07@gmail.com" target="_blank">madhuri.rai07@gmail.com</a>><br>
<span style="font-weight:bold">Reply-To: </span>"OpenStack Development Mailing List (not for usage questions)" <<a href="mailto:openstack-dev@lists.openstack.org" target="_blank">openstack-dev@lists.openstack.org</a>><br>
<span style="font-weight:bold">Date: </span>Monday, March 23, 2015 at 1:53 AM<br>
<span style="font-weight:bold">To: </span>"<a href="mailto:openstack-dev@lists.openstack.org" target="_blank">openstack-dev@lists.openstack.org</a>" <<a href="mailto:openstack-dev@lists.openstack.org" target="_blank">openstack-dev@lists.openstack.org</a>><br>
<span style="font-weight:bold">Subject: </span>[openstack-dev] [magnum] swagger-codegen generated code for python-k8sclient<br>
</div><div><div>
<div><br>
</div>
<blockquote style="BORDER-LEFT:#b5c4df 5 solid;PADDING:0 0 0 5;MARGIN:0 0 0 5">
<div>
<div>
<div dir="ltr">Hi All,<br>
<br>
This is to have a discussion on the blueprint for implementing python-k8client for magnum.<br>
<br>
<a href="https://blueprints.launchpad.net/magnum/+spec/python-k8sclient" target="_blank">
https://blueprints.launchpad.net/magnum/+spec/python-k8sclient</a><br>
<br>
I have committed the code generated by swagger-codegen at <a href="https://review.openstack.org/#/c/166720/" target="_blank">
https://review.openstack.org/#/c/166720/</a>.<br>
But I feel the quality of the code generated by swagger-codegen is not good.<br>
<br>
Some of the points:<br>
1) There is lot of code duplication. If we want to generate code for two or more versions, same code is duplicated for each API version.<br>
2) There is no modularity. CLI code for all the APIs are written in same file.<br>
<br>
So, I would like your opinion on this. How should we proceed further?<br>
</div>
</div>
</div>
</blockquote>
</div></div></span>
<div><br>
</div>
<div>Madhuri,</div>
<div><br>
</div>
<div>First off, spectacular that you figured out how to do this! Great great job! I suspected the swagger code would be a bunch of garbage. Just looking over the review, the output isn’t too terribly bad. It has some serious pep8 problems.</div>
<div><br>
</div>
<div>Now that we have seen the swagger code generator works, we need to see if it produces useable output. In other words, can the API be used by the magnum backend. Google is “all-in” on swagger for their API model. Realistically maintaining a python binding
would be a huge job. If we could just use swagger for the short term, even though its less then ideal, that would be my preference. Even if its suboptimal. We can put a readme in the TLD saying the code was generated by a a code generator and explain how
to generate the API.</div>
<div><br>
</div>
<div>One last question. I didn’t see immediately by looking at the api, but does it support TLS auth? We will need that.</div>
<div><br>
</div>
<div>Super impressed!</div>
<div><br>
</div>
<div>Regards</div>
<div>-steve</div>
<div><br>
</div>
<div><br>
</div>
<span>
<blockquote style="BORDER-LEFT:#b5c4df 5 solid;PADDING:0 0 0 5;MARGIN:0 0 0 5">
<div>
<div>
<div dir="ltr"><br>
Regards,<br>
Madhuri Kumari</div>
</div>
</div>
</blockquote>
</span>
</div>
<br></div></div>__________________________________________________________________________<span><br>
OpenStack Development Mailing List (not for usage questions)<br></span>
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" target="_blank">OpenStack-dev-request@lists.openstack.org?subject:unsubscribe</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>
<br>__________________________________________________________________________<br>
OpenStack Development Mailing List (not for usage questions)<br>
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" target="_blank">OpenStack-dev-request@lists.openstack.org?subject:unsubscribe</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></div></div>Regards,<br></div><div class="gmail_extra">Madhuri Kumari<br></div></div></div>
</blockquote></div><br></div>