<div dir="ltr">Sounds great. It's valuable to have reasonable default behaviors in the core.</div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Sep 26, 2017 at 7:54 AM, Dennis Kliban <span dir="ltr"><<a href="mailto:dkliban@redhat.com" target="_blank">dkliban@redhat.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"><div><div>The Content model in pulpcore defines a 'natural_key_fields' tuple that models inheriting from it need to populate with field names that make that content type unique. At the same time each model defines database uniqueness constraints in the Class Meta of the model. <br><br></div>In pulp_example[0] I've demonstrated how the database uniqueness constraint can be used to get a list of all of the unique fields for content. As part of this task I'd like to move this code out of pulp_example and into pulpcore so all plugins can use it. I will also remove the 'natural_key_fields' tuple.<br><br></div>Thoughts? Objections?<br><div><br><br><br>[0] <a href="https://github.com/pulp/pulp_example/blob/master/pulp_example/app/models.py#L111" target="_blank">https://github.com/pulp/pulp_<wbr>example/blob/master/pulp_<wbr>example/app/models.py#L111</a><br></div></div>
<br>______________________________<wbr>_________________<br>
Pulp-dev mailing list<br>
<a href="mailto:Pulp-dev@redhat.com">Pulp-dev@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-dev" rel="noreferrer" target="_blank">https://www.redhat.com/<wbr>mailman/listinfo/pulp-dev</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><p style="color:rgb(0,0,0);font-family:overpass-mono,monospace;font-size:10px;margin:0px!important;padding:0px!important"><span style="margin:0px!important;padding:0px!important">Michael</span> <span style="margin:0px!important;padding:0px!important">Hrivnak</span></p><p style="color:rgb(0,0,0);font-family:overpass-mono,monospace;font-size:10px;margin:0px!important;padding:0px!important"></p><span style="color:rgb(0,0,0);font-family:overpass-mono,monospace;font-size:10px;margin:0px!important;padding:0px!important"><span style="margin:0px!important;padding:0px!important">Principal Software Engineer</span><span style="margin:0px!important;padding:0px!important">, <span style="margin:0px!important;padding:0px!important">RHCE</span></span> </span><span style="color:rgb(0,0,0);font-family:overpass-mono,monospace;font-size:10px"></span><br style="color:rgb(0,0,0);font-family:overpass-mono,monospace;font-size:10px;margin:0px!important;padding:0px!important"><p style="color:rgb(0,0,0);font-family:overpass-mono,monospace;font-size:10px;margin:0px!important;padding:0px!important">Red Hat</p></div></div>
</div>