#369 increase the 50 character limit of Koji tag names
Closed: Fixed 5 years ago Opened 5 years ago by mikeb.

Koji tag names are limited to 50 characters. This is causing issues for the Modularity, which is programatically generating tag names, see:


Also, 50 characters seems arbitrarily low. Any reason not to increase it, or remove the limit altogether?

Agreed 50 is too low. I think we've generally just switched VARCHARS to TEXT when they became a problem.

I'm guessing target names too?

Alternately maybe 255 (like filenames)? Less someone accidentally type the wrong command and create a tag whose name is the content of a large file.

I'd be in favor of turning VARCHARs to TEXT fields. If we want to limit the length, maybe we do it in code, to make it easier to change later if necessary.

There shouldn't be any significant speed slowdown for TEXT compared to fixed-length fields.
Length check could be done also in db.

aiui, varchar is implemented as text plus a length check, so text is very slighly faster

As far as I know, there is no way to set a UNIQUE constraint for TEXT fields. Tag names need to be unique, so unless there is another way to resolve this, I don't think changing the tag name field to TEXT is a valid solution here.

What we could do is change the VARCHAR character limit. Right now it's set to 50. We could change it to 256, allow for longer tags, and still keep the UNIQUE constraint.

As far as I know, there is no way to set a UNIQUE constraint for TEXT fields

We have several unique TEXT fields already in the schema. I'm unaware of this being an issue in postgres.

Ah, thanks. TEXT fields it is then.

Would it make sense to make max_name_length configurable? I don't think so, but asking if anyone else find it beneficial.

Metadata Update from @tkopecek:
- Issue set to the milestone: 1.13

4 years ago

Login to comment on this ticket.