Modifying Start-up Parameters

These functions modify the start-up parameters specified at start-up for the Server for which this is a session.

ostc_ServerSession::setServiceName()

void setServiceName(oscs_String servicename);

Sets the name of the Server, the name by which clients can connect to it using ostc::connect().

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setPort()

void setPort(oscs_Int32 port);

Sets the port the Server uses to listen for client requests.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setTxnType()

void setTxnType(ostc::transaction_type txntype);

Sets the transaction type of the current session.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setUserRouteData()

void setUserRouteData(void *, oscs_Uint32 length);

Sets the Server's routing data. The void* can point to any user-specified data, such as a character string. A thin client can specify routing data along with a request for execution of an operation, and the request is routed to a Server with matching routing data. Matches are identified with memcmp().

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setNumThreads()

void setNumThreads(oscs_Uint32 numthreads);

Sets the number of threads used by the Server to process client requests.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::addRouterHostName()

void addRouterHostName(oscs_String routerhostname);

Specifies the network address for the system router.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setRouterFile()

void setRouterFile(oscs_String routerfilename);

Sets the file used by the router to maintain routes persistently, in case of failures or restarts.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setIncrementalTimeout()

void setIncrementalTimeout(oscs_Uint32 timeout);

Sets the timeout for access to incremental object sets on the Server. If the set is not accessed in the amount of time specified, the Server discards it.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setBoundTimeout()

void setBoundTimeout(oscs_Uint32 timeout);

Sets the timeout for bound transactions (that is, transactions started by the thin client with ostc_Session::beginTxn()). If a bound transaction is started but is not being used, it aborts when this timeout is exceeded. This prevents the Server from hanging if the client fails in the middle of a bound transaction.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setSharedTimeout()

void setSharedTimeout(oscs_Uint32 timeout);

Sets the timeout for shared (that is shared_update, read, or mvccRead) transactions. Shared transactions commit after a certain number of requests complete or this timeout is exceeded, whichever comes first.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setSharedMaxOps()

void setSharedMaxOps(oscs_Uint32 maxops);

Sets the number of requests that can use a shared transaction before a commit occurs. This parameter is ignored for isolated_update Servers.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setRouterPingInterval()

void setRouterPingInterval(oscs_Uint32 interval);

A router pings all its routes at this interval. This parameter is ignored for Servers that are not routers.

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerSession::setServerLogging()

void setServerLogging(oscs_Bool logging);

Turns Server logging on or off. With logging on, the Server writes information to the file server.log in the directory from which the Server was executed. 

otcs_ArgsLocked is thrown if this function is called outside the dynamic scope of ostcConnect().

ostc_ServerOperation

This class defines the protocol for members you must implement in derived classes:

It also provides functions for the following tasks:



[previous] [next]