This removes erroneously defined polymorphic association, because
specifying `belongs_to` relationship with a class that already supports
polymorphic associations works out-of-the-box.
We extracted implementation of build/bridge metadata attributes to a
separate concern, because in EE `Ci::Bridge` also has metadata
attributes, and we want to build abstraction for storing values in build
metadata table.
These are data columns that store runtime configuration
of build needed to execute it on runner and within pipeline.
The definition of this data is that once used, and when no longer
needed (due to retry capability) they can be freely removed.
They use `jsonb` on PostgreSQL, and `text` on MySQL (due to lacking
support for json datatype on old enough version).