Skip to content

NH-3975 - Synchronize some features dialect support properties #591

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

Merged
merged 2 commits into from
Apr 6, 2017

Conversation

fredericDelaporte
Copy link
Member

@fredericDelaporte fredericDelaporte commented Apr 5, 2017

NH-3975 - Synchronize some features dialect support properties (Informational metadata).

A bunch of "Informational metadata" properties are defined on the base dialect class, and allow tests to ignore dialects which do not support the tested feature. Unfortunately, some of them are not up-to-date and causes such tests to fail instead of ignoring the dialect.

This PR aims at updating those properties according to their current value in Hibernate Java dialects implementation.

This has been done in a very conservative manner: each such property have been checked for not having any usage inside NHibernate (being purely informational), otherwise I have left them untouched. Some NHibernate dialect are overriding some of those properties while their Java counterpart do not, I have kept NHibernate overrides.

It would be probably nice to do a complete dialect sync, but this would have heavy transverse impacts. By example, the SupportsTemporaryTable seems gone in Java, while in NHibernate it enables updates and deletes on classes having joined table (subclasses notably). This is why I have limited the scope of this Jira to purely informational properties.

@@ -14,7 +14,7 @@ protected override IList Mappings

protected override bool AppliesTo(Dialect.Dialect dialect)
{
return dialect is MySQL5Dialect || dialect is MySQLDialect;
return dialect is MySQLDialect;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MySQL5Dialect inherits MySQLDialect, so I have just simplified this.


public override bool SupportsEmptyInList
{
get { return false; }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can these one-line properties be written with expression syntax? I know that it'll make an inconsistency, but I'm ok with it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed and done.

@fredericDelaporte fredericDelaporte merged commit 8e71d6a into nhibernate:master Apr 6, 2017
@fredericDelaporte fredericDelaporte deleted the NH-3975 branch April 6, 2017 12:39
@fredericDelaporte fredericDelaporte added this to the 5.0.0 milestone Apr 6, 2017
@hazzik hazzik added r: Fixed and removed r: Fixed labels Aug 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants