<div dir="ltr">This is a bug, as tenant and user is maintained by keystone and quota are stored in nova db, so it has the cleanup problems.</div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jan 19, 2016 at 8:12 PM, jialiang_song517 <span dir="ltr"><<a href="mailto:jialiang_song517@163.com" target="_blank">jialiang_song517@163.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><u></u>
<div style="BORDER-LEFT-WIDTH:0px;FONT-SIZE:10.5pt;FONT-FAMILY:微软雅黑;BORDER-RIGHT-WIDTH:0px;BORDER-BOTTOM-WIDTH:0px;COLOR:#000000;MARGIN:12px;LINE-HEIGHT:1.5;BORDER-TOP-WIDTH:0px" marginheight="0" marginwidth="0"><u></u>
<div>Hi guys,</div>
<div> </div>
<div style="FONT-SIZE:10.5pt">I am working on bug <span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px">#<span style="FONT-SIZE:10.5pt;COLOR:#000000">1449498, <<span style="FONT-SIZE:12pt;MAX-WIDTH:95%"><span style="FONT-SIZE:10.5pt">the
command “nova quota-show” Should not display the quota of a user has been
deleted</span></span>>.</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000"></span></span> </div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">Reproduction steps w/ devstack and
Liberty:</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">1) create a tenant
bug_test</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">2) create a user test1 in tenant
bug_test</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">3) update the quota instances of
test1 as 5 (the default instances value is 10)</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">4) delete user
test1</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">5) query the quota information for
user test1 in tenant bug_test</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">in step5, the expected result should
indicate user test1 doesn't exist, while nova returned the deleted user test1's
quota infomation with instances as 5.</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000"></span></span> </div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">After investigation, it is found that
quota_get_all_by_project_and_user() and quota_get_all_by_project() will invoke
model_query(context,
model,<br>
args=None,<br>
session=None,<br>
use_slave=False,<br>
<strong>read_deleted=None</strong>,<br>
project_only=False)</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">to query the quota information
specified by project or project & user. While the model_query() doesnot work
as expected, that is, in case a user was deleted, even <strong>read_deleted
</strong>is set as <strong>no</strong>, the quota information associated with
the deleted user will also be returned.</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000"></span></span> </div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">I am not sure if this is a design
behavior or this could be problem in oslo_db? Could you give some instruction on
the further direction? Thanks.</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000"></span></span> </div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">Any other comments are
welcome.</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000"></span></span> </div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">Best Regards,</span></span></div>
<div style="FONT-SIZE:10.5pt"><span style="WHITE-SPACE:normal;WORD-SPACING:0px;TEXT-TRANSFORM:none;FLOAT:none;COLOR:#000000;TEXT-ALIGN:left;FONT:10.5pt/18px Ubuntu,'Bitstream Vera Sans','DejaVu Sans',Tahoma,sans-serif;DISPLAY:inline!important;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255);TEXT-INDENT:0px"><span style="FONT-SIZE:10.5pt;COLOR:#000000">Jialiang</span></span></div>
<div> </div>
<div style="FONT-SIZE:10pt;FONT-FAMILY:Verdana;COLOR:#c0c0c0">
<hr style="BORDER-TOP:#c0c0c0 1px solid;min-height:1px;BORDER-RIGHT:0px;WIDTH:122px;BORDER-BOTTOM:0px;BORDER-LEFT:0px" align="left"><span class="HOEnZb"><font color="#888888">
<span>jialiang_song517</span>
</font></span></div><u></u></div><br>__________________________________________________________________________<br>
OpenStack Development Mailing List (not for usage questions)<br>
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" target="_blank">OpenStack-dev-request@lists.openstack.org?subject:unsubscribe</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
<br></blockquote></div><br></div>