code as blow. is it necessary to lock shard when createWorkflow, what will happen if not lock shard when create workflow. will it cause problem ?
Shard lock exists because Cassandra does not support concurrent lightweight transaction on same partition and shard id is the partition key.
Historically, Cassandra was the first and only supported persistence so the lock exists to protect Cassandra.