Closed kaihendry closed 5 years ago
https://github.com/unee-t/unit/blob/master/sql/unit_create_new.sql for reference on how we call the SQL procedure.
This is blocking Unit creation in the development environment, making @PicoCreator's UIlicious tests fail and @nbiton from further load testing / performance work.
This is a NON trivial fix ---> BZ periodically restore the core DB schema for BZ to what it think should be. This happens each time the .checksetup.pl script is triggered.
There is a good chance that any change in the DB schema will be overridden at some unpredictable time in the future if we do not make sure that we understand how to make the .checksetup.pl script behave the way we want it to do (i.e keep the core BZ DB schema changes that we need to make).
Until this is taken care of we should delete some of the existing units in the DEV environment to make room for the automated Uilicious tests.
There is a script to remove a unit and all the objects associated to this unit. Input needed is the BZ unit ID and it will take care of the BZ side of things.
@nbiton can you use the script to remove a unit and all the objects associated to this unit and cleanup some of the existing units in Unee-T so we have a spare 100 units that we could create as part of normal tests?
@franck-boullier you suggest I do it one at a time to clean 100 units?
I removed some units, however it would appear there are ids at 32767 on tables flagtypes & groups.
[hendry@t480s db]$ echo "describe flagtypes;" | ./connect.sh 2>/dev/null | grep -m 1 id
id smallint(6) NO PRI NULL auto_increment
[hendry@t480s db]$ echo "describe groups;" | ./connect.sh 2>/dev/null | grep -m 1 id
id mediumint(9) NO PRI NULL auto_increment
It would appear flagtypes is full?
So we're going to make the flagtype id bigger in https://github.com/bugzilla/bugzilla/pull/75.
So assuming the code in bugzilla/bugzilla#75, here's what you need to know, operationally:
Awesome! @dylanwh thanks
Merged @dylanwh's work in https://github.com/bugzilla/bugzilla/pull/75 and tested in {dev,demo}. We should not see this issue again. 🤞
Looks like we have hit the smallint limit on Units in the dev environment.