SessionFactory xFactory = new SessionFactory();Sessionsession1 = xFactory.getSession("mysqlx://[user1[:pwd1]@]host1[:port1]/db");Sessionsession2 = xFactory.getSession("mysqlx://host2[:port2]/db?user=user2&password=pwd2");Sessionsession3 = xFactory.getSession("mysqlx+srv://[user1[:pwd1]@]service_name/db");
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected Session | Returns: aSession instance.the session connUrl)ConnectionUrl.Creates |
| public Session | |
| public Session | Returns: aSession instance.the properties)Properties instance that contains the session components.Creates a |
| protected ConnectionUrl | Returns: aConnectionUrl instance containing the URL components.the connection string URL. url)Parses the connection string URL. |
| SessionFactory | back to summary |
|---|---|
| public SessionFactory() | |
| getSession | back to summary |
|---|---|
| protected Session getSession(ConnectionUrl connUrl) Creates
| |
| getSession | back to summary |
|---|---|
| public Session getSession(String url) Creates | |
| getSession | back to summary |
|---|---|
| public Session getSession(Properties properties) Creates a
| |
| parseUrl | back to summary |
|---|---|
| protected ConnectionUrl parseUrl(String url) Parses the connection string URL.
| |