<div dir="ltr"><div>Jeff, can you elaborate more on your -1. I want to understand it. I'm struggling to appreciate an "it's a convention" argument without sources like an RFC or similar. I don't believe internet articles are credible sources because any viewpoint can be validated by an internet post.<br></div><div><br></div><div>To recap my interests here, it's about being responsive to the community. We ask plugin writers for feedback and from two independent plugin writers (not me) we received feedback that this name wasn't ideal. I want us to be responsive to that. It's not only because I think their technical feedback is legit (albeit small), but also because it's our strategy during the beta/RC of Pulp3 core is to make adjustments based on plugin writer feedback. To receive feedback and choose to not follow the recommendation they suggested feels like not the way I want to interact with plugin writers. This is my main concern with not making a change in this area.<br></div><div><br></div><div>All the best,</div><div>Brian</div><div><br></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jun 13, 2018 at 10:26 AM, Jeff Ortel <span dir="ltr"><<a href="mailto:jortel@redhat.com" target="_blank">jortel@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 text="#000000" bgcolor="#FFFFFF"><span>
<br>
<br>
<div class="m_4039839811345622941m_672728314250338745moz-cite-prefix">On 06/12/2018 05:03 PM, David Davis
wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">I do think the most compelling case for renaming
the field is having feedback from plugin writers to do so and
also the desire to reduce complexity for plugin writers.
Honestly, I am on the fence about renaming the field.
<div><br>
</div>
<div>Just to clarify, is anyone a hard -1 on renaming id?</div>
</div>
</blockquote>
<br></span>
-1<div><div class="m_4039839811345622941h5"><br>
<br>
<blockquote type="cite">
<div class="gmail_extra"><br clear="all">
<div>
<div class="m_4039839811345622941m_672728314250338745gmail_signature" data-smartmail="gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div><br>
</div>
<div>David<br>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
<div class="gmail_quote">On Tue, Jun 12, 2018 at 5:32 PM, Brian
Bouterse <span dir="ltr"><<a href="mailto:bbouters@redhat.com" target="_blank">bbouters@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"><br>
<div class="gmail_extra"><br>
<div class="gmail_quote"><span>On Tue, Jun 12,
2018 at 5:11 PM, David Davis <span dir="ltr"><<a href="mailto:daviddavis@redhat.com" target="_blank">daviddavis@redhat.com</a>></span>
wrote:<br>
</span><span>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr"><span>On Tue, Jun 12, 2018 at 4:50
PM, Brian Bouterse <span dir="ltr"><<a href="mailto:bbouters@redhat.com" target="_blank">bbouters@redhat.com</a>></span>
wrote:<br>
</span>
<div class="gmail_extra">
<div class="gmail_quote"><span>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">Silly question, but could
we just call our 'id' 'pk' instead?
Since that is a fully reserved value
in Django for the primary key it seems
clearest to just use that? What about
that?<br>
</div>
</blockquote>
<div><br>
</div>
</span>
<div>Are you recommending we rename the id
field to pk in the database? I’m not sure
if that would work.</div>
</div>
</div>
</div>
</blockquote>
<div><br>
</div>
</span>
<div>I'm wondering if its possible yes. #django says
it is but they've been wrong before. I haven't had a
chance to test it.<br>
</div>
<span>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote"><span>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div>
<div>
<div class="gmail_extra"><br>
<div class="gmail_quote"><span>On
Tue, Jun 12, 2018 at 3:44
PM, Jeff Ortel <span dir="ltr"><<a href="mailto:jortel@redhat.com" target="_blank">jortel@redhat.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>On
06/08/2018 02:57 PM,
Brian Bouterse wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
@jortel: We're blocked
on your -1 vote
expressed for 3704. We
have practical plugin
writer issues with the
current state. Can you
elaborate on why we
shouldn't go forward
with <a href="https://pulp.plan.io/issues/3704" rel="noreferrer" target="_blank">https://pulp.plan.io/issues/37<wbr>04</a><br>
</blockquote>
<br>
</span>
The 'ID' column is
reserved for the primary
key and is inappropriate
for natural keys. This is
well establish convention
and best practice. </blockquote>
<div><br>
</div>
</span>
<div>I don't understand this
reasoning. Earlier in the
thread we discussed how the
sources recommending these
conventions also mention
that if we have a practical
reason or problem with that
convention to do something
differently. We received
complaints on this name
about collisions so I don't
follow how we should still
follow the convention.<br>
</div>
<span>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Plugin writers specify
natural keys. Also, by
introducing '_' prefix (or
any prefix) means a table
could have both 'ID' and
'_ID' columns which is
especially confusing since
the 'ID' column would not
be the primary key.<br>
</blockquote>
<div><br>
</div>
</span>
<div>We have two concepts here
that are similar, so I think
that problem is mostly
unrelated to this decision.
For example, if we leave the
names as-is we have this
problem only now it's named
id and errata_id and in
addition we'll have the
problems listed below.<br>
</div>
<span>
<div><br>
</div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
How does naming the
natural key for an rpm as
'rpm_id' cause a
significant problem for
plugin writers?<br>
</blockquote>
<div><br>
</div>
</span>
<div>It's a good question
because it's the whole
motivation for this change.
It's not an rpm, it's an
erratum which doesn't have
nevra like a package. It's
also the problem from
another content type I heard
about at Config Management
Camp.<br>
</div>
<div><br>
</div>
<div>It causes problems in two
ways:</div>
<div><br>
</div>
<div>* plugin users (not
writers) who are familiar
with 'id' as part of the
erratum data type would then
have to also understand this
field name renaming that
Pulp arbitrarily introduces.
This could get confusing
when the user submit a
filter with id='ID-2115858'
and they find nothing
because 'id' is matching on
the primary key not on the
'id' attribute of the errata
like they expect. Those
users would also be Pulp
users so they'll understand
that _id means the pk.</div>
</div>
</div>
</div>
</div>
</div>
</blockquote>
<div><br>
</div>
</span>
<div>By the same logic, if Pulp users know
that id means pk, wouldn’t they therefore
understand that the id is not the erratum
id?</div>
</div>
</div>
</div>
</blockquote>
<div><br>
</div>
</span>
<div>Yes by that logic they probably would know, but
the actual errata field is named 'id' so my it's
more about a correctness problem than confusion. A
correctness problem that passes along to users. If
we're going to have confusing names, let's pick
names that allow for alignment with the names
already chosen by content types which commonly do
use 'id'. Plugin writer's aren't in control of those
names; they already are chosen by content types.<br>
</div>
<span>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote"><span>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div>
<div>
<div class="gmail_extra">
<div class="gmail_quote">
<div><br>
</div>
<div>* plugins specifically
may wrap other tools and now
they have to maintain
mappings as well. This is
specifically the case with
errata which the data model
is design to be
name-for-name identical to
the createrepo_c interface</div>
<span>
<div><br>
</div>
</span></div>
</div>
</div>
</div>
</div>
</blockquote>
<div><br>
</div>
</span>
<div>Mapping one field to another seems
rather minor. Or am I missing something?</div>
</div>
</div>
</div>
</blockquote>
<div><br>
</div>
</span>
<div>After 22 emails on this thread it feels like a
mountain out of a molehill. I don't mean to waste
people's time and energy. The reason I continue to
advocate for it is because when two, independent
plugin writers give feedback suggesting change, even
small change, we should adopt it. The complexity is
minor, but it's there. I've always believed
minimizing complexity has been our goal.<br>
</div>
<span>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote"><span>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div>
<div>
<div class="gmail_extra">
<div class="gmail_quote"><span>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
@bmbouters: just curious,
where does the rpm 'id'
come from and how is it
used differently than the
NEVREA composite natural
key.
<div class="m_4039839811345622941m_672728314250338745m_-3272269538306778365m_-4618410301101877854m_-5047181755300947594m_-5542100025370726035HOEnZb">
<div class="m_4039839811345622941m_672728314250338745m_-3272269538306778365m_-4618410301101877854m_-5047181755300947594m_-5542100025370726035h5"><br>
<br>
______________________________<wbr>_________________<br>
Pulp-dev mailing list<br>
<a href="mailto:Pulp-dev@redhat.com" target="_blank">Pulp-dev@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-dev" rel="noreferrer" target="_blank">https://www.redhat.com/mailman<wbr>/listinfo/pulp-dev</a><br>
</div>
</div>
</blockquote>
</span></div>
<br>
</div>
</div>
</div>
</div>
<br>
______________________________<wbr>_________________<br>
Pulp-dev mailing list<br>
<a href="mailto:Pulp-dev@redhat.com" target="_blank">Pulp-dev@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-dev" rel="noreferrer" target="_blank">https://www.redhat.com/mailman<wbr>/listinfo/pulp-dev</a><br>
<br>
</blockquote>
</span></div>
<br>
</div>
</div>
</blockquote>
</span></div>
<br>
</div>
</div>
</blockquote>
</div>
<br>
</div>
</blockquote>
<br>
</div></div></div>
<br>______________________________<wbr>_________________<br>
Pulp-dev mailing list<br>
<a href="mailto:Pulp-dev@redhat.com" target="_blank">Pulp-dev@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-dev" rel="noreferrer" target="_blank">https://www.redhat.com/mailman<wbr>/listinfo/pulp-dev</a><br>
<br></blockquote></div><br></div></div></div></div>