commands.. factory.stop();}
Command object vs. execution method interfaces
ScspClient provides methods for creating command objects that can execute SCSP commands and for direct execution of the same commands. For each command object, there is an equivalent ScspClient execution method.
For example, the following two pieces of code are equivalent:
{@code}void doInfo(ScspClient client, String uuid) ScspResponse response = client.info(uuid); System.out.println(response.toString()); }}
and
{@code}void doInfo(ScspClient client, String uuid) ScspInfo infoCommand = client.createInfoCommand(uuid); ScspResponse response = infoCommand.execute(); System.out.println(response.toString()); } }
Mutable vs. Non-mutable methods
This API provides separate execution interfaces for CAStor anchor streams and regular streams. The anchor stream commands contain 'Mutable' in their method names.
Validate mode
If setValidating(true)
is called, all execution methods (write
, read
, etc.) will validate their arguments instead of executing requests to CAStor.
The Path
Parameter
The path
parameter to the ScspClient
execution methods and the path
property in ScspCommand
can be used to specify the Remote Cluster Name for ScspProxy
remote proxy features; for named object names, including bucket and object names; and for uuids. Note that the uuid
parameter is deprecated in this release and will be removed altogether in the next release or the one following - please use the path
parameter and property instead.
Copyright (c) 2009 by Caringo, Inc. -- All rights reserved
This is free software, distributed under the terms of the New BSD license.
See the LICENSE.txt file included in this archive.
@author pray
@created September 20, 2009
@id ${Id}