Zend Session Clustering - PHP API

This topic lists the PHP API functions of the Zend Session Clustering.

Zend Session Clustering Functions

Function

Description

zend_sc_get_statistics

Gets the statistics of the Session Clustering module

zend_sc_get_daemon_status

Gets the status of the Session Clustering daemon

zend_sc_graceful_shutdown

Orders the SC daemon to perform a graceful shutdown.

zend_sc_get_last_error

Gets the status of the Session Clustering module.

zend_sc_get_last_error_code

Returns the last error code that the SC daemon has.

zend_sc_reset_last_error

Gets the status of the Session Clustering module.

zend_sc_reload_configuration

Order the daemon to reload its configuration file.

Zend Session Clustering Constants

Constant

Type

Available Since Version

Description

ZEND_SC_STATUS_OFF

int

4.0

Daemon is not running

ZEND_SC_STATUS_STANDBY

int

4.0

Daemon is in standby mode

ZEND_SC_STATUS_OK

int

4.0

Daemon is in working mode

ZEND_SC_STATUS_INTERNAL_ERROR

int

4.0

Daemon has an internal error and is not working properly

ZEND_SC_STATUS_SHUTDOWN_IN_PROCESS

int

4.0

Daemon has started to shutdown

ZEND_SC_STATUS_SHUTDOWN_FAILED

int

4.0

Daemon shutdown process failed

ZEND_SC_STATUS_STARTING_UP_ERROR

int

4.0

Daemon startup had errors process failed

ZEND_SC_STATUS_STARTING_UP

int

4.0

Daemon startup is in progress

ZEND_SC_NO_ERROR

int

4.0

Event Type: custom event

ZEND_SC_NETWORK_ERROR

int

4.0

Event Type: custom event

ZEND_SC_TIMEOUT_ERROR

int

4.0

Event Type: custom event

ZEND_SC_UNKNOWN_ERROR

int

4.0

Event Type: custom event

zend_sc_get_statistics

Gets the statistics of the Session Clustering module

Available Since Version: 4.0

Return Value: array - The function returns an array of statistics

zend_sc_get_daemon_status

Gets the status of the Session Clustering daemon

Available Since Version: 4.0

Return Value: int - 1. ZEND_SC_STATUS_OFF [integer]
2. ZEND_SC_STATUS_STANDBY [integer]
3. ZEND_SC_STATUS_OK [integer]
4. ZEND_SC_STATUS_SHUTDOWN_IN_PROCESS [integer]
5. ZEND_SC_STATUS_SHUTDOWN_FAILED [integer]
6. ZEND_SC_STATUS_STARTING_UP_ERROR [integer]
7. ZEND_SC_STATUS_STARTING_UP [integer]

zend_sc_graceful_shutdown

Orders the SC daemon to perform a graceful shutdown.

Available Since Version: 4.0

Return Value: boolean - True if successful, False otherwise.

zend_sc_get_last_error

Gets the status of the Session Clustering module.

Available Since Version: 4.0

Return Value: string - Returns the last error string that the SC daemon has.

zend_sc_get_last_error_code

Returns the last error code that the SC daemon has.

Available Since Version: 4.0

Return Value: int - 1. ZEND_SC_NO_ERROR [integer]
2. ZEND_SC_NETWORK_ERROR [integer]
3. ZEND_SC_TIMEOUT_ERROR [integer]
4. ZEND_SC_UNKNOWN_ERROR [integer]

zend_sc_reset_last_error

Gets the status of the Session Clustering module.

Available Since Version: 4.0

zend_sc_reload_configuration

Order the daemon to reload its configuration file.

Available Since Version: 4.0

Return Value: boolean - True if successful, False otherwise.