public int addCluster(String clusterName, int requestedId, boolean forceListBased, Object... parameters) {
lock.acquireExclusiveLock();
try {
if (requestedId < 0) {
throw new OConfigurationException("Cluster id must be positive!");
}
if (requestedId < clusters.size() && clusters.get(requestedId) != null) {
throw new OConfigurationException("Requested cluster ID [" + requestedId + "] is occupied by cluster with name ["
+ clusters.get(requestedId).getName() + "]");
}
makeStorageDirty();
return addClusterInternal(clusterName, requestedId, true, parameters);