Changed to use indexBlockedException instead of indicesBlockedException

Original commit: elastic/x-pack-elasticsearch@33f581ddd2
This commit is contained in:
Martijn van Groningen 2014-12-05 19:13:31 +01:00
parent bbaa122d7e
commit b039f8bbdb
4 changed files with 4 additions and 4 deletions

View File

@ -61,7 +61,7 @@ public class TransportAckAlertAction extends TransportMasterNodeOperationAction<
@Override
protected ClusterBlockException checkBlock(AckAlertRequest request, ClusterState state) {
return state.blocks().indicesBlockedException(ClusterBlockLevel.WRITE, new String[]{AlertsStore.ALERT_INDEX});
return state.blocks().indexBlockedException(ClusterBlockLevel.WRITE, AlertsStore.ALERT_INDEX);
}

View File

@ -63,7 +63,7 @@ public class TransportConfigAlertAction extends TransportMasterNodeOperationActi
@Override
protected ClusterBlockException checkBlock(ConfigAlertRequest request, ClusterState state) {
request.beforeLocalFork(); // This is the best place to make the config source safe
return state.blocks().indicesBlockedException(ClusterBlockLevel.WRITE, new String[]{AlertsStore.ALERT_INDEX});
return state.blocks().indexBlockedException(ClusterBlockLevel.WRITE, AlertsStore.ALERT_INDEX);
}

View File

@ -61,7 +61,7 @@ public class TransportDeleteAlertAction extends TransportMasterNodeOperationActi
@Override
protected ClusterBlockException checkBlock(DeleteAlertRequest request, ClusterState state) {
return state.blocks().indicesBlockedException(ClusterBlockLevel.WRITE, new String[]{AlertsStore.ALERT_INDEX});
return state.blocks().indexBlockedException(ClusterBlockLevel.WRITE, AlertsStore.ALERT_INDEX);
}

View File

@ -62,7 +62,7 @@ public class TransportPutAlertAction extends TransportMasterNodeOperationAction<
@Override
protected ClusterBlockException checkBlock(PutAlertRequest request, ClusterState state) {
request.beforeLocalFork(); // This is the best place to make the alert source safe
return state.blocks().indicesBlockedException(ClusterBlockLevel.WRITE, new String[]{AlertsStore.ALERT_INDEX});
return state.blocks().indexBlockedException(ClusterBlockLevel.WRITE, AlertsStore.ALERT_INDEX);
}
}