PostgreSQL, register custom domains. Closes #14305.

This patch registers custom domains in our OID-type_map.
They will behave exactly as the type specified by `pg_type.typbasetype`.

/cc @matthewd
refactor, use `typtype` instead of `typinput` to segment PG types.
A new trie based router

This commit completely replaces Journey as the router in Rails. The reasoning
being it is a lot less code and also IMO conceptually easier to understand than
NFAs and GTGs. It also performs significantly better than Journey. I wrote a
simple benchmark containing 336 routes that each respective router was required
to match 1000 times, with the averaged time of 5 runs taken as the result.
Journey completed this in 39.97 seconds and this router in 32.61 seconds.

The simple case is a path is split on forward slashes and each segment is a
child of the preceding segment with the route object stored at the terminal
leaf node. The result is tree-like structure with O(log n) runtime
characteristics as the route table grows. In practice with optional segments,
more than one node on the path may point to the same route object. This is so
/:controller matches as well as /:controller/:action does given the path
/:controller(:/action(/:id))(.:format)

The code is straightforward to understand if you seek further details.