I'm -1 on going the underscore idea, partly because of the aforementioned confusion issue, but also partly because but I've noticed that in our API, the "underscore" basically has a semantic meeting of "href, [which is] generated on the fly, not stored in the db".
Specifically: - '_href' - '_added_href' - '_removed_href' - '_content_href' So I think if we use a prefix, we should avoid using one that already has a semantic meaning (I don't know whether we actually planned for that to be the case, but I think it's a useful pattern / distinction and I don't think we should mess with it). On Mon, Jun 18, 2018 at 2:01 PM, Brian Bouterse <bbout...@redhat.com> wrote: > Having a user focus made me realize that it would be useful if a user > could easily tell which attributes were common to all content units versus > just that one content unit. When scripting for instance that is really > useful to know. We could document the 5 attributes that platform provides, > but when there are 20+ attributes on a subclassed content unit the > underscores would provide an easy, consistent answer to this question. This > is an additional reason separate from the the issue that our content > attribute names are colliding (id at least for now). The underscore prefix > would make collisions highly unlikely also. This problem is only scoped to > the Content unit since that is the place where we expect a large number of > subclassed attributes. > > For this reason I believe using the _ as the prefix will provide 2 > benefits. I wrote them here on this ticket: https://pulp.plan.io/issues/ > 3704 > > I am still +1 on adopting those changes for those reasons. More feedback > is welcome given the additional problem statements and discussion. > > On Mon, Jun 18, 2018 at 8:43 AM, Ina Panova <ipan...@redhat.com> wrote: > >> uuid sounds like good compromise. >> >> >> >> -------- >> Regards, >> >> Ina Panova >> Software Engineer| Pulp| Red Hat Inc. >> >> "Do not go where the path may lead, >> go instead where there is no path and leave a trail." >> >> On Thu, Jun 14, 2018 at 9:38 PM, Jeff Ortel <jor...@redhat.com> wrote: >> >>> >>> >>> On 06/14/2018 12:19 PM, Jeff Ortel wrote: >>> >>>> >>>> >>>> On 06/14/2018 10:37 AM, Daniel Alley wrote: >>>> >>>>> I will make one more suggestion. What about naming "id" -> "uuid"? >>>>> This carries the clear connotation that it is a unique identifier so it is >>>>> less likely to be confusing a la "id and _id", and is still less likely to >>>>> have a namespace conflict. >>>>> >>>> >>>> Appreciate the suggestion but this would only be marginally less >>>> confusing. >>>> >>> >>> Reconsidering this suggestion for the reasons you outlined. >>> >>> >>> _______________________________________________ >>> Pulp-dev mailing list >>> Pulp-dev@redhat.com >>> https://www.redhat.com/mailman/listinfo/pulp-dev >>> >> >> >> _______________________________________________ >> Pulp-dev mailing list >> Pulp-dev@redhat.com >> https://www.redhat.com/mailman/listinfo/pulp-dev >> >> > > _______________________________________________ > Pulp-dev mailing list > Pulp-dev@redhat.com > https://www.redhat.com/mailman/listinfo/pulp-dev > >
_______________________________________________ Pulp-dev mailing list Pulp-dev@redhat.com https://www.redhat.com/mailman/listinfo/pulp-dev