[Pulp-dev] Integer IDs in Pulp 3
amacdona at redhat.com
Thu May 24 15:22:40 UTC 2018
I have a few concerns, but they all may be addressable.
1. URLs and security. If this integer is in the url, it is easy to guess
other urls. Hopefully, our security model won't depend on obscurity, so
maybe this isn't much of a concern.
2. bulk_create. Apparently, bulk_creates would work, but only with
postgreSQL. If we accept this change, any bulk_create would make lock us in
with postgres. 
3. Max size = 2,147,483,647? Is it conceivable that a Pulp would have more
than 2 billion of anything?
On Wed, May 23, 2018 at 2:26 PM, David Davis <daviddavis at redhat.com> wrote:
> Before the release of Pulp 3.0 GA, I think it’s worth just checking in to
> make sure we want to use UUIDs over integer based IDs. Changing from UUIDs
> to ints would be a very easy change at this point (1-2 lines of code) but
> after GA ships, it would be hard if not impossible to switch.
> I think there are a number of reasons why we might want to consider
> integer IDs:
> - Better performance all around for inserts, searches, indexing, etc
> - Less storage required (4 bytes for int vs 16 byes for UUIDs)
> - Hrefs would be shorter (e.g. /pulp/api/v3/repositories/1/)
> - In line with other apps like Katello
> There are some downsides to consider though:
> - Integer ids expose info like how many records there are
> - Can’t support sharding or multiple dbs (are we ever going to need this?)
>  http://kccoder.com/mysql/uuid-vs-int-insert-performance/
> Pulp-dev mailing list
> Pulp-dev at redhat.com
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Pulp-dev