<div dir="ltr"><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">Hi, I found out that nova currently handles list with limit=0 quite different for different objects.</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">Especially when list servers:</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">According to the code:<br><a rel="nofollow" href="http://git.openstack.org/cgit/openstack/nova/tree/nova/api/openstack/common.py#n206" style="color:rgb(0,51,170);text-decoration:none">http://git.openstack.org/cgit/openstack/nova/tree/nova/api/openstack/common.py#n206</a></p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">when limit = 0, it should apply as max_limit, but currently, in:<br><a rel="nofollow" href="http://git.openstack.org/cgit/openstack/nova/tree/nova/db/sqlalchemy/api.py#n1930" style="color:rgb(0,51,170);text-decoration:none">http://git.openstack.org/cgit/openstack/nova/tree/nova/db/sqlalchemy/api.py#n1930</a></p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">we directly return [], this is quite different with comment in the api code.</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px"><br></p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">I checked other objects:</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">when list security groups and server groups, it will return as no limit has been set. And for flavors it returns []. I will continue to try out other APIs if needed.</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">I think maybe we should make a rule for all objects, at least fix the servers to make it same in api and db code.</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">I have reported a bug in launchpad:</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em"><font color="#333333" face="monospace"><span style="font-size:12px;line-height:18px"><a href="https://bugs.launchpad.net/nova/+bug/1494617">https://bugs.launchpad.net/nova/+bug/1494617</a></span></font><br></p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">Any suggestions?</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">Best Regards,</p><p style="margin:0px 0px 1.2em;padding:0px;width:auto;max-width:45em;color:rgb(51,51,51);font-family:monospace;font-size:12px;line-height:18px">Zheng</p></div>