VMware GemFire Native C++ Reference  9.1
apache::geode::client::FunctionService Class Reference

entry point for function execution More...

Inherits apache::geode::client::SharedBase.

Public Member Functions

void preserveSB () const
 Atomically increment reference count. More...
 
int32_t refCount ()
 
void releaseSB () const
 Atomically decrement reference count, the SharedBase object is automatically deleted when its reference count goes to zero. More...
 

Static Public Member Functions

static ExecutionPtr onRegion (RegionPtr region)
 Returns a Execution object that can be used to execute a data dependent function on the specified Region. More...
 
static ExecutionPtr onServer (const PoolPtr &pool)
 Returns a Execution object that can be used to execute a data independent function on a server in the provided Pool. More...
 
static ExecutionPtr onServer (const RegionServicePtr &cache)
 Returns a Execution object that can be used to execute a data independent function on a server where Cache is attached. More...
 
static ExecutionPtr onServers (const PoolPtr &pool)
 Returns a Execution object that can be used to execute a data independent function on all the servers in the provided Pool. More...
 
static ExecutionPtr onServers (const RegionServicePtr &cache)
 Returns a Execution object that can be used to execute a data independent function on all the servers where Cache is attached. More...
 

Detailed Description

entry point for function execution

See also
Execution

Member Function Documentation

static ExecutionPtr apache::geode::client::FunctionService::onRegion ( RegionPtr  region)
static

Returns a Execution object that can be used to execute a data dependent function on the specified Region.


When invoked from a Geode client, the method returns an Execution instance that sends a message to one of the connected servers as specified by the Pool for the region. Depending on the filters setup on the Execution, the function is executed on all Geode members that define the data region, or a subset of members. Execution::withFilter(filter)).

Parameters
regionIf Pool is multiusersecure mode then one need to pass nstance of Region from RegionService.
Returns
Execution
Exceptions
NullPointerExceptionif the region passed in is NULLPTR
static ExecutionPtr apache::geode::client::FunctionService::onServer ( const PoolPtr pool)
inlinestatic

Returns a Execution object that can be used to execute a data independent function on a server in the provided Pool.

If the server goes down while dispatching or executing the function, an Exception will be thrown.

Parameters
poolfrom which to chose a server for execution
Returns
Execution
Exceptions
NullPointerExceptionif Pool instance passed in is NULLPTR
UnsupportedOperationExceptionif Pool is in multiusersecure Mode
static ExecutionPtr apache::geode::client::FunctionService::onServer ( const RegionServicePtr cache)
inlinestatic

Returns a Execution object that can be used to execute a data independent function on a server where Cache is attached.

If the server goes down while dispatching or executing the function, an Exception will be thrown.

Parameters
cachecache from which to chose a server for execution
Returns
Execution
Exceptions
NullPointerExceptionif Pool instance passed in is NULLPTR
UnsupportedOperationExceptionif Pool is in multiusersecure Mode
static ExecutionPtr apache::geode::client::FunctionService::onServers ( const PoolPtr pool)
inlinestatic

Returns a Execution object that can be used to execute a data independent function on all the servers in the provided Pool.

If one of the servers goes down while dispatching or executing the function on the server, an Exception will be thrown.

Parameters
poolthe set of servers to execute the function
Returns
Execution
Exceptions
NullPointerExceptionif Pool instance passed in is NULLPTR
UnsupportedOperationExceptionif Pool is in multiusersecure Mode
static ExecutionPtr apache::geode::client::FunctionService::onServers ( const RegionServicePtr cache)
inlinestatic

Returns a Execution object that can be used to execute a data independent function on all the servers where Cache is attached.

If one of the servers goes down while dispatching or executing the function on the server, an Exception will be thrown.

Parameters
cachethe Cache where function need to execute.
Returns
Execution
Exceptions
NullPointerExceptionif Pool instance passed in is NULLPTR
UnsupportedOperationExceptionif Pool is in multiusersecure Mode
void apache::geode::client::SharedBase::preserveSB ( ) const
inherited

Atomically increment reference count.

int32_t apache::geode::client::SharedBase::refCount ( )
inlineinherited
Returns
the reference count
void apache::geode::client::SharedBase::releaseSB ( ) const
inherited

Atomically decrement reference count, the SharedBase object is automatically deleted when its reference count goes to zero.


Pivotal GemFire C++ Cache API Documentation