[
http://opensource.atlassian.com/projects/hibernate/browse/HHH-4358?page=c...
]
Steve Ebersole commented on HHH-4358:
-------------------------------------
I *know* you did not attach a pull request. That was in fact my point. You say it is
something so important, so why not fix it?
The consensus on the relate developer mailing list discussion was that because this would
break the way existing applications worked we would only change this *as the default
behavior* if this actually violated the spec. As it does not appear to violate the spec,
this will not change as the default behavior. Now, we could discuss having this work with
a configuration setting (something like {{hibernate.force_discriminators_by_default}})
that (1) keeps the current behavior as default and (2) allows specifying that forcing
discriminator should be the default when enabled.
I had only initially assigned a fix version because I assumed someone involved in this
issue or the person that started the dev list discussion was going to follow up. That
never happened. So I'll just un-assign a fix version. That way we dont have to keep
"pushing it on and on"...
Having to use @ForceDiscriminator kind of breaks JPA compatibility
------------------------------------------------------------------
Key: HHH-4358
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-4358
Project: Hibernate Core
Issue Type: Improvement
Components: annotations
Environment: JPA
Reporter: Steve Ebersole
Assignee: Steve Ebersole
Labels: jpa2
Fix For: 4.0.1
According to
http://opensource.atlassian.com/projects/hibernate/browse/ANN-36
@ForceDiscriminator was created as a quick workaround to a problem.
Yes, it solves the problem, but it creates a new problem:
the source code which previously had only JPA annotations, now need to be annotated by a
Hibernate annotation,
causing that the the source code is now unable to use just any JPA provider.
Major portability issue!
Everyone who likes Open Source, hates Lock-Ins!
My proposal: change the default to a more sane force=true, so that @ForceDiscriminator
will not be needed for general JPA projects.
(And create a @DisableDiscriminator Hibernate annotation, for those who like to brake
their code).
If changing default behavior is risky, don't fix this on older versions, but lets
change this from 3.5.0-Beta2.
--
This message is automatically generated by JIRA.
For more information on JIRA, see:
http://www.atlassian.com/software/jira