You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@asterixdb.apache.org by mb...@apache.org on 2024/05/18 12:36:52 UTC
(asterixdb) 04/04: Merge branch 'gerrit/trinity' into 'master'
This is an automated email from the ASF dual-hosted git repository.
mblow pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/asterixdb.git
commit 482fdc993b5d3fa0a52c99cf9c228bbc6794845a
Merge: 079f119f50 531f765551
Author: Michael Blow <mi...@couchbase.com>
AuthorDate: Fri May 17 23:56:30 2024 -0400
Merge branch 'gerrit/trinity' into 'master'
Change-Id: Id5bc38ec8fd856550f118668e17e73b9420fdf5a
.../asterix/common/context/GlobalVirtualBufferCache.java | 11 +++++++----
.../replication/messaging/PartitionResourcesListTask.java | 6 ++++++
2 files changed, 13 insertions(+), 4 deletions(-)
diff --cc asterixdb/asterix-replication/src/main/java/org/apache/asterix/replication/messaging/PartitionResourcesListTask.java
index 0f5949e61b,97d03e6228..0856969b2d
--- a/asterixdb/asterix-replication/src/main/java/org/apache/asterix/replication/messaging/PartitionResourcesListTask.java
+++ b/asterixdb/asterix-replication/src/main/java/org/apache/asterix/replication/messaging/PartitionResourcesListTask.java
@@@ -18,6 -18,6 +18,8 @@@
*/
package org.apache.asterix.replication.messaging;
++import static org.apache.asterix.common.utils.StorageConstants.METADATA_PARTITION;
++
import java.io.DataInput;
import java.io.DataOutputStream;
import java.io.IOException;
@@@ -51,6 -51,11 +53,10 @@@ public class PartitionResourcesListTas
@Override
public void perform(INcApplicationContext appCtx, IReplicationWorker worker) throws HyracksDataException {
LOGGER.debug("processing {}", this);
- if (appCtx.getMetadataPartitionId().isPresent() && appCtx.getMetadataPartitionId().getAsInt() == partition
- && appCtx.getReplicaManager().getPartitions().contains(partition)) {
++ if (METADATA_PARTITION == partition && appCtx.getReplicaManager().getPartitions().contains(partition)) {
+ LOGGER.warn("received request to get metadata files from non-master {}", worker.getRemoteAddress());
+ throw new IllegalStateException();
+ }
final PersistentLocalResourceRepository localResourceRepository =
(PersistentLocalResourceRepository) appCtx.getLocalResourceRepository();
localResourceRepository.cleanup(partition);