public interface ConnectionRetrievalInfo
extends oracle.ucp.RACConnectionRetrievalInfo
The connection retrieval info object also provides methods for equality and hash so that like-connections can be pooled efficiently.
The connection retrieval object supports Connection Labeling, a common mechanism for all types of connections. Represented as key/value pairs, connection labels are used for application-driven connection matching purposes.
ConnectionFactoryAdapter| Modifier and Type | Method and Description |
|---|---|
void |
addLabel(java.lang.String key,
java.lang.String value)
Adds a connection label to this connection retrieval info object.
|
default java.util.function.Predicate<oracle.ucp.common.CoreConnection> |
criMatchSelector()
Default predicate for CRI matching.
|
boolean |
equalsIncludingPassword(ConnectionRetrievalInfo cri)
Checks whether this instance is equal to another.
|
default boolean |
equalsNotIncludingPassword(ConnectionRetrievalInfo cri)
Checks whether this instance is equal to another.
|
ConnectionRetrievalInfo |
getCopyWithNoLabels()
Clones this connection retrieval object but removes all the
connection labels associated.
|
default oracle.ucp.jdbc.JDBCConnectionRetrievalInfo |
getCopyWithUpdatedPassword()
Default db account's password can be changed, but CRI as a connection attribute still holds an old password.
|
default oracle.ucp.common.CriStats |
getCriMetadata()
get borrow conext metadata (counters, appropriate semaphores and queues).
|
java.util.Properties |
getLabels()
Retrieves all the connection labels stored on this connection
retrieval info object.
|
void |
removeLabel(java.lang.String key)
Removes the connection label with the given key from this connection
retrieval info object.
|
void addLabel(java.lang.String key,
java.lang.String value)
throws UniversalConnectionPoolException
key - The key of the connection label to be added. Cannot
be null or an empty string.value - The value of the connection label to be added. Can be
null or an empty string.UniversalConnectionPoolException - If the key is null
or an empty string.void removeLabel(java.lang.String key)
throws UniversalConnectionPoolException
key - The key of the connection label to be removed. Cannot be
null or an empty string.UniversalConnectionPoolException - If the key is null
or an empty string.ConnectionRetrievalInfo getCopyWithNoLabels()
ConnectionRetrievalInfo object with all
connection labels removed.java.util.Properties getLabels()
java.util.Properties object storing all the stored
labels as key/value pairs. Returns null if there
are no stored labels on this connection retrieval info object.boolean equalsIncludingPassword(ConnectionRetrievalInfo cri)
cri - Connection retrieval info object.default boolean equalsNotIncludingPassword(ConnectionRetrievalInfo cri)
cri - Connection retrieval info object.cri - default oracle.ucp.common.CriStats getCriMetadata()
default java.util.function.Predicate<oracle.ucp.common.CoreConnection> criMatchSelector()
default oracle.ucp.jdbc.JDBCConnectionRetrievalInfo getCopyWithUpdatedPassword()