public class ManagedImportProcessI extends AbstractCloseableAmdServant implements _ImportProcessOperations, ServiceFactoryAware, ProcessContainer.Process
| Constructor and Description |
|---|
ManagedImportProcessI(ManagedRepositoryI repo,
Fileset fs,
ImportLocation location,
ImportSettings settings,
Ice.Current __current,
java.lang.String rootToken)
Create and register a servant for servicing the import process
within a managed repository.
|
| Modifier and Type | Method and Description |
|---|---|
void |
closeCalled(int idx) |
Fileset |
getFileset() |
long |
getGroup() |
HandlePrx |
getHandle(Ice.Current ignore)
Reacquire the handle which was returned by
verifyUpload. |
ImportSettings |
getImportSettings(Ice.Current __current) |
ImportProcessPrx |
getProxy() |
RawFileStorePrx |
getUploader(int i,
Ice.Current current)
Step 1: Returns a RawFileStore that can be used to upload one of
the used files.
|
long |
getUploadOffset(int idx,
Ice.Current ignore)
In case an upload must be resumed, this provides the
location of the last successful upload.
|
void |
ping() |
protected void |
postClose(Ice.Current current)
Should not throw any exceptions which should be detected by clients
since it is called in a finally block after the client thread has been
released.
|
protected void |
preClose(Ice.Current current) |
protected void |
registerCallback(RawFileStorePrx prx,
int idx) |
protected ImportProcessPrx |
registerProxy(Ice.Current ignore)
Adds this instance to the current session so that clients can communicate
with it.
|
void |
setOffset(int idx,
long offset) |
void |
setServiceFactory(ServiceFactoryI sf) |
void |
shutdown() |
HandlePrx |
verifyUpload(java.util.List<java.lang.String> hashes,
Ice.Current __current)
Step 2: Passes a set of client-side calculated hashes to the
server for verifying that all of the files were correctly
uploaded.
|
close_async, closeactivate_async, applyHardWiredInterceptors, callInvokerOnMappedArgs, callInvokerOnRawArgs, executorWorkCall, getCurrentEventContext_async, onSetOmeroContext, passivate_async, runnableCall, safeRunnableCall, setApplicationContext, setHolderclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitactivate_async, close_async, getCurrentEventContext_async, passivate_asyncpublic ManagedImportProcessI(ManagedRepositoryI repo, Fileset fs, ImportLocation location, ImportSettings settings, Ice.Current __current, java.lang.String rootToken) throws ServerError
ServerErrorpublic void setServiceFactory(ServiceFactoryI sf) throws ServerError
setServiceFactory in interface ServiceFactoryAwareServerErrorprotected ImportProcessPrx registerProxy(Ice.Current ignore) throws ServerError
ServerErrorpublic ImportProcessPrx getProxy()
getProxy in interface ProcessContainer.Processpublic Fileset getFileset()
getFileset in interface ProcessContainer.Processpublic ImportSettings getImportSettings(Ice.Current __current)
getImportSettings in interface _ImportProcessOperationspublic long getGroup()
getGroup in interface ProcessContainer.Processpublic void ping()
ping in interface ProcessContainer.Processpublic void shutdown()
shutdown in interface ProcessContainer.Processpublic RawFileStorePrx getUploader(int i, Ice.Current current) throws ServerError
_ImportProcessOperationsImportLocation. omero.api.RawFileStore.close
should be called once all data has been transferred. If the
file must be re-written, call getUploader with the
same index again. Once all uploads have been completed,
verifyUpload should be called to initiate background
processinggetUploader in interface _ImportProcessOperationscurrent - The Current object for the invocation.ServerErrorprotected void registerCallback(RawFileStorePrx prx, int idx)
public HandlePrx verifyUpload(java.util.List<java.lang.String> hashes, Ice.Current __current) throws ServerError
_ImportProcessOperationsHandle
proxy is returned, which completes all the necessary import
steps. A successful import will return an
ImportResponse. Otherwise, some ERR
will be returned.verifyUpload in interface _ImportProcessOperations__current - The Current object for the invocation.ServerErrorpublic long getUploadOffset(int idx,
Ice.Current ignore)
throws ServerError
_ImportProcessOperationsgetUploadOffset in interface _ImportProcessOperationsignore - The Current object for the invocation.ServerErrorpublic HandlePrx getHandle(Ice.Current ignore)
_ImportProcessOperationsverifyUpload. This is useful in case a new
client is re-attaching to a running import.
From the Handle instance, the
original ImportRequest can also be found.getHandle in interface _ImportProcessOperationsignore - The Current object for the invocation.public void setOffset(int idx,
long offset)
public void closeCalled(int idx)
protected void preClose(Ice.Current current)
throws java.lang.Throwable
preClose in class AbstractCloseableAmdServantjava.lang.Throwableprotected void postClose(Ice.Current current)
AbstractCloseableAmdServantpostClose in class AbstractCloseableAmdServant