public class KVStoreFactory extends Object
Constructor and Description |
---|
KVStoreFactory() |
Modifier and Type | Method and Description |
---|---|
static KVStore |
getStore(KVStoreConfig config)
Get a handle to an existing KVStore.
|
static KVStore |
getStore(KVStoreConfig config,
LoginCredentials creds,
ReauthenticateHandler reauthHandler)
Get a handle to an existing KVStore, with optional authentication
arguments for accessing a secure KVStore instance.
|
public static KVStore getStore(KVStoreConfig config) throws FaultException
config
- the KVStore configuration parameters.IllegalArgumentException
- if an illegal configuration parameter
is specified.FaultException
public static KVStore getStore(KVStoreConfig config, LoginCredentials creds, ReauthenticateHandler reauthHandler) throws FaultException
If no LoginCredentials
are provided in this call, this method
will attempt to locate credentials through other sources, in the
following search order.
oracle.kv.login
Java
system property.config
- the KVStore configuration parameters.creds
- the KVStore user login credentials. If null, the KVStore
client will attempt to locate credentials based on Java system
properties.reauthHandler
- an optional re-authentication handler to be used in
the event a login session expires and must be renewed. If both creds and
reauthHandler are null, but login information is located using either of
the above lookup methods, an internally-supplied reauthentication handler
is automatically provided which will re-read login credentials as needed
for reauthentication. User passwords are not retained in memory by
the KVStore client, so if you explicitly provide LoginCredentials,
you are also responsible for supplying a reauthentication handler, if
desired.IllegalArgumentException
- if an illegal configuration parameter
is specified.FaultException
Copyright (c) 2011, 2014 Oracle and/or its affiliates. All rights reserved.