Cluster_DDL

Demonstrates the use of SQL DDL statements such as "CREATE TABLE ...", "CREATE INDEX ...", and "DROP TABLE ..." in a cluster environment. It starts several threads (the number of threads is determined by command-line arguments). Some threads execute DDL statements; others execute normal DML statements such as "INSERT ...", "UPDATE...", and "DELETE ...". Thus, this sample can also be used to measure performance, as can cluster_demo for the C API.

The sample uses the same command-line parameters as cluster_demo (i.e., -w, -l, ... -u, with the same meanings), plus the following:

-W <ddl_thread_num> - The number of DDL threads. Can be 0; in this case, only network transactions will be performed. Default: 1.

-R <ddl_trans_rate> - The maximum DDL transaction rate in transactions per second. 0 means "infinity". Default: 100.

-N <ddl_trans_count> - The total number of DDL transactions per thread. Default: 5000.

How to Run

In a console window, run:

    cluster_ddl 2 0

Then, in a second console window, run:

    cluster_ddl 2 1

But it is more instructive to run one instance in your development environment debugger, stepping through the code.