ClusterSync

The ClusterSync component aims to provide an easy to use interface for synchronising file and directory write/delete actions across multiple servers.

The Jadu_ClusterSync class provides several static methods to write and delete files and directories from the servers specified during configuration.

Usage

Usage is extremely simple, just call the static method with the path of the file/directory to be synced.

For example, if we wanted to write the file /path/to/images/test.jpg to all clustered servers we would call:

Jadu_ClusterSync::write('/path/to/images/test.jpg');

Or delete the file:

Jadu_ClusterSync::delete('/path/to/images/test.jpg');

The exact same approach is used for writing and deleting directories:

Jadu_ClusterSync::writeDirectory('/path/to/');

Jadu_ClusterSync::deleteDirectory('/path/to/');

Note: ClusterSync requires a passive FTP port to be enabled on IIS.

results matching ""

    No results matching ""