On Mon, Jun 03, 2019 at 09:11:07AM -0400, David Davis wrote: > @Simon I like the idea behind the repo_key solution you came up with. > Can you be more specific around cases you think that it couldn't > handle? I imagine that plugin writers could use properties or > denormailzation (ie additional database columns) to solve cases where > they need uniqueness across data that isn't in the database. In a worst > case scenario, they can't use the pulpcore solution and just have to > roll their own.
What I wrote probably sounded too pessimistic. You are right, in most cases that should be doable. I agree that we could have a simple default solution that just requires to specify a couple of field names in the easiest case. As you say, it should be possible use custom logic in a plugin if required. Here is the case I was thinking of that it can't handle: In pulp_file, a uniqueness constraint on "relative_path" would allow content units "a" and "a/b" to be in a repo version. However, we may want file repos to be representable on an actual file system (e.g. when exporting them as tar files). For the repo above, this does not work, as "a" can't be a file and a directory at the same time on a standard Unix file system. _______________________________________________ Pulp-dev mailing list Pulp-dev@redhat.com https://www.redhat.com/mailman/listinfo/pulp-dev