diff --git a/src/main/java/com/mongodb/hibernate/jdbc/MongoConnectionProvider.java b/src/main/java/com/mongodb/hibernate/jdbc/MongoConnectionProvider.java index 90b9c5d..83e569a 100644 --- a/src/main/java/com/mongodb/hibernate/jdbc/MongoConnectionProvider.java +++ b/src/main/java/com/mongodb/hibernate/jdbc/MongoConnectionProvider.java @@ -16,7 +16,9 @@ package com.mongodb.hibernate.jdbc; -import static org.hibernate.cfg.JdbcSettings.*; +import static org.hibernate.cfg.JdbcSettings.JAKARTA_JDBC_PASSWORD; +import static org.hibernate.cfg.JdbcSettings.JAKARTA_JDBC_URL; +import static org.hibernate.cfg.JdbcSettings.JAKARTA_JDBC_USER; import com.mongodb.ConnectionString; import com.mongodb.MongoClientSettings; @@ -42,12 +44,31 @@ *
{@link MongoConnectionProvider} uses the following Hibernate properties: * *
{@value org.hibernate.cfg.JdbcSettings#JAKARTA_JDBC_URL} property is mandatory and it maps to MongoDB's
+ * as follows:
+ *
+ *
Property | Description |
---|---|
{@linkplain JdbcSettings#JAKARTA_JDBC_URL jakarta.persistence.jdbc.url} | + *MongoDB + * connection string | + *
{@linkplain JdbcSettings#JAKARTA_JDBC_USER jakarta.persistence.jdbc.user} | + *{@code userName} for {@link com.mongodb.MongoCredential#createCredential(String, String, char[])} | + *
{@linkplain JdbcSettings#JAKARTA_JDBC_PASSWORD jakarta.persistence.jdbc.password} | + *{@code password} for {@link com.mongodb.MongoCredential#createCredential(String, String, char[])} | + *
+ * {@value JdbcSettings#JAKARTA_JDBC_URL} property is mandatory and it maps to MongoDB's connection string, in which database name
* must be provided to align with JDBC URL's convention. The other two JDBC properties are optional.
*
@@ -100,7 +121,7 @@ public void configure(Map