removed not needed lock on distributed index management that could cause deadlock
@@ -105,8 +105,6 @@ public class OIndexManagerProxy extends OProxedResource<OIndexManagerAbstract> i
if (metadata != null)
createIndexDDL += " " + OCommandExecutorSQLCreateIndex.KEYWORD_METADATA + " " + metadata.toJSON();
- delegate.acquireExclusiveLock();
- try {
if (progressListener != null)
progressListener.onBegin(this, 0, false);
@@ -122,9 +120,6 @@ public class OIndexManagerProxy extends OProxedResource<OIndexManagerAbstract> i
final Locale locale = delegate.getServerLocale();
return delegate.preProcessBeforeReturn(getDatabase(), delegate.getIndex(iName));
- } finally {
- delegate.releaseExclusiveLock();
- }
}
public ODocument getConfiguration() {
@@ -144,17 +139,12 @@ public class OIndexManagerProxy extends OProxedResource<OIndexManagerAbstract> i
String dropIndexDDL = "DROP INDEX `" + iName + "`";
- delegate.acquireExclusiveLock();
- try {
getDatabase().command(new OCommandSQL(dropIndexDDL)).execute();
ORecordInternal
.setIdentity(delegate.getDocument(), new ORecordId(getDatabase().getStorage().getConfiguration().getIndexMgrRecordId()));
reload();
- } finally {
- delegate.releaseExclusiveLock();
- }
}
public String getDefaultClusterName() {
