Hi,
after upgrading from 6.2.8 to 6.3.1 I get the warning
HHH90000025: MariaDBDialect does not need to be specified explicitly using 'hibernate.dialect' (remove the property setting and it will be selected by default). I use MariaDB 10.6. If I understood correctly, this warning should only occur if I use a too specific deprecated dialect such as MariaDB106Dialect.
In hibernate.cfg.xml I have the line <property name="dialect">org.hibernate.dialect.MariaDBDialect</property>.
Is this correct? If yes, can I just remove that line and how does Hibernate detect the correct dialect?
PS: I also just experienced a warning from org.hibernate.sql.results.jdbc.internal.DeferredResultSetAccess with MariaDB 10.6: HHH000444: Encountered request for locking however dialect reports that database prefers locking be done in a separate select (follow-on locking); results will be locked after initial query executes. The method useFollowOnLocking() is implemented in org.hibernate.dialect.Dialect (always returns false) and is neither overwritten in MySQLDialect nor MariaDBDialect. The query code looks like this:
CriteriaQuery<Integer> criteria = builder.createQuery(Integer.class);
Root<TestCount> root = criteria.from(TestCount.class);
criteria.select(builder.sum(root.get(TestCount_.timesExecuted)));
criteria.where(builder.and(root.get(TestCount_.test).in(submission.getTask().getTests()), builder.equal(root.get(TestCount_.user), participation.getUser())));
Query<Integer> query = session.createQuery(criteria);
query.setLockMode(LockModeType.PESSIMISTIC_WRITE);
Integer testCount = query.uniqueResult();