Allow Hibernate Types to have access to ServiceRegistry during initialization

Description

HHH-13103 added support for getting access to configuration properties when instantiating a Hibernate Type.

However, there are still two issues I'm facing in the [Hibernate Types project|]:

  • the new TypeBootstrapContext only works from 5.4.13 onwards, so if I add this constructor, any prior Hibernate version will fail with a NoClassDeffFoundError.

  • I need to get access to the underlying Driver Type to adjust how a certain Type handles arrays, for instance.

For this reason, I propose we inject the ServiceRegistry when initializing the Type if there is a matching constructor taking this argument.

Environment

None

Activity

Show:
Vlad Mihalcea
May 15, 2020, 9:55 AM

Pull Request:

Assignee

Vlad Mihalcea

Reporter

Vlad Mihalcea

Fix versions

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

backportDecision

None

Components

Affects versions

Priority

Major
Configure