Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dont bind subclasses if they don't support the datasource #43

Merged
merged 1 commit into from
Jun 16, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Check if the sublcass uses the connection source before binding
  • Loading branch information
jameskleeh committed Jun 13, 2017
commit b64ab6c1198f9d63069f94825da745aaa95ee0fe
Original file line number Diff line number Diff line change
Expand Up @@ -1415,7 +1415,7 @@ protected void bindSubClasses(HibernatePersistentEntity domainClass, PersistentC

for (PersistentEntity sub : subClasses) {
final Class javaClass = sub.getJavaClass();
if (javaClass.getSuperclass().equals(domainClass.getJavaClass())) {
if (javaClass.getSuperclass().equals(domainClass.getJavaClass()) && ConnectionSourcesSupport.usesConnectionSource(sub, dataSourceName)) {
bindSubClass((HibernatePersistentEntity)sub, parent, mappings, sessionFactoryBeanName);
}
}
Expand Down