public class SyncReplClient extends Object
| Modifier and Type | Field and Description |
|---|---|
private Connection |
connection
Connection to invoke the search operation on.
|
protected Logger |
logger
Logger for this class.
|
private boolean |
refreshAndPersist
Controls which mode the sync repl control should use.
|
| Constructor and Description |
|---|
SyncReplClient(Connection conn,
boolean persist)
Creates a new sync repl client.
|
| Modifier and Type | Method and Description |
|---|---|
Response<Void> |
cancel(int messageId)
Invokes a cancel operation on the supplied ldap message id.
|
BlockingQueue<SyncReplItem> |
execute(SearchRequest request)
Invokes
execute(SearchRequest, CookieManager, int) with a DefaultCookieManager and a capacity of
Integer.MAX_VALUE. |
BlockingQueue<SyncReplItem> |
execute(SearchRequest request,
CookieManager manager)
Invokes
execute(SearchRequest, CookieManager, int) with a capacity of Integer.MAX_VALUE. |
BlockingQueue<SyncReplItem> |
execute(SearchRequest request,
CookieManager manager,
int capacity)
Performs an async search operation with the
SyncRequestControl. |
protected final Logger logger
private final Connection connection
private final boolean refreshAndPersist
public SyncReplClient(Connection conn, boolean persist)
conn - to execute the async search operation onpersist - whether to refresh and persist or just refreshpublic BlockingQueue<SyncReplItem> execute(SearchRequest request) throws LdapException
execute(SearchRequest, CookieManager, int) with a DefaultCookieManager and a capacity of
Integer.MAX_VALUE.request - search request to executeLdapException - if the search failspublic BlockingQueue<SyncReplItem> execute(SearchRequest request, CookieManager manager) throws LdapException
execute(SearchRequest, CookieManager, int) with a capacity of Integer.MAX_VALUE.request - search request to executemanager - for reading and writing cookiesLdapException - if the search failspublic BlockingQueue<SyncReplItem> execute(SearchRequest request, CookieManager manager, int capacity) throws LdapException
SyncRequestControl. The supplied request is modified in the
following way:
AbstractRequest.setControls( org.ldaptive.control.RequestControl...) is invoked with SyncRequestControlSearchRequest.setSearchEntryHandlers(SearchEntryHandler...) is invoked with a custom handler that
places sync repl data in a blocking queue.AbstractRequest.setIntermediateResponseHandlers( IntermediateResponseHandler...) is invoked with a
custom handler that places sync repl data in a blocking queue.AbstractOperation.setOperationResponseHandlers( OperationResponseHandler[]) is invoked with a
custom handler that places the sync repl response in a blocking queue.AbstractAsyncOperation.setExceptionHandler(org.ldaptive.async.handler.ExceptionHandler) is invoked with
a custom handler that places the exception in a blocking queue.The search request object should not be reused for any other search operations.
request - search request to executemanager - for reading and writing cookiescapacity - of the returned blocking queueLdapException - if the search failspublic Response<Void> cancel(int messageId) throws LdapException
messageId - of the operation to cancelLdapException - if the cancel operation failsCopyright © 2003-2019 Virginia Tech. All Rights Reserved.