org.apache.yoko.orb.OB
Interface DispatchStrategyFactoryOperations

All Known Subinterfaces:
DispatchStrategyFactory
All Known Implementing Classes:
DispatchStrategyFactory_impl

public interface DispatchStrategyFactoryOperations

This interface is a factory to create dispatch strategies, and to manage thread pools.

See Also:
DispatchStrategy

Method Summary
 DispatchStrategy create_default_dispatch_strategy()
          Create a default dispatch strategy.
 DispatchStrategy create_same_thread_strategy()
          Create a same thread dispatch strategy.
 DispatchStrategy create_thread_per_request_strategy()
          Create a same thread per request dispatch strategy.
 DispatchStrategy create_thread_pool_strategy(int id)
          Create a thread pool dispatch strategy.
 int create_thread_pool(int nthreads)
          Create a thread pool containing nthreads.
 void destroy_thread_pool(int id)
          Destroy a thread pool with the given id.
 

Method Detail

create_thread_pool

int create_thread_pool(int nthreads)
Create a thread pool containing nthreads.

Parameters:
nthreads - The number of threads the pool in the pool

destroy_thread_pool

void destroy_thread_pool(int id)
                         throws InvalidThreadPool
Destroy a thread pool with the given id. If the thread pool is is use by an object adapter any new requests will cause an OBJ_ADAPTER exception.

Parameters:
id - The thread pool id
Throws:
InvalidThreadPool - If the thread pool id is valid.

create_thread_pool_strategy

DispatchStrategy create_thread_pool_strategy(int id)
                                             throws InvalidThreadPool
Create a thread pool dispatch strategy.

Parameters:
id - The thread pool id
Returns:
A dispatch strategy
Throws:
InvalidThreadPool - If the thread pool id is valid.

create_same_thread_strategy

DispatchStrategy create_same_thread_strategy()
Create a same thread dispatch strategy.

Returns:
A dispatch strategy

create_thread_per_request_strategy

DispatchStrategy create_thread_per_request_strategy()
Create a same thread per request dispatch strategy.

Returns:
A dispatch strategy

create_default_dispatch_strategy

DispatchStrategy create_default_dispatch_strategy()
Create a default dispatch strategy. The default dispatch strategy is created according to the ooc.orb.oa.conc_model property.

Returns:
A dispatch strategy


Copyright © 2006-2011 Apache Software Foundation. All Rights Reserved.