| Even though the method requiresMultiTenantConnectionProvider exists in MultiTenancyStrategy and as far as I can see is correct instead expressions like MultiTenancyStrategy.NONE == multiTenancyStrategy is used to determine whether ConnectionProvider or MultiTenantConnectionProvider is needed. So with a hibernate.tenant_identifier_resolver supplied and hibernate.multiTenancy=DISCRIMINATOR I get the following error: Caused by: java.lang.NullPointerException at org.hibernate.internal.ContextualJdbcConnectionAccess.obtainConnection(ContextualJdbcConnectionAccess.java:43) ~[hibernate-core-5.2.10.Final.jar:5.2.10.Final] at org.hibernate.resource.jdbc.internal.LogicalConnectionManagedImpl.acquireConnectionIfNeeded(LogicalConnectionManagedImpl.java:115) ~[hibernate-core-5.2.10.Final.jar:5.2.10.Final] at org.hibernate.resource.jdbc.internal.LogicalConnectionManagedImpl.getPhysicalConnection(LogicalConnectionManagedImpl.java:145) ~[hibernate-core-5.2.10.Final.jar:5.2.10.Final] The problem as far as I can see is the if statement in the method org.hibernate.internal.AbstractSharedSessionContract#getJdbcConnectionAccess. |