asterixdb-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From AsterixDB Code Review <do-not-re...@asterix-gerrit.ics.uci.edu>
Subject Change in asterixdb[mad-hatter]: [NO ISSUE][MD] Ensure metadata node is initialized
Date Thu, 24 Jun 2021 01:06:29 GMT
>From Murtadha Hubail <mhubail@apache.org>:

Murtadha Hubail has uploaded this change for review. ( https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12023
)


Change subject: [NO ISSUE][MD] Ensure metadata node is initialized
......................................................................

[NO ISSUE][MD] Ensure metadata node is initialized

- user model changes: no
- storage format changes: no
- interface changes: no

Details:

- Before attempting to being any metadata transaction, ensure
  the metadata node has been bound to avoid NPE.

Change-Id: Ic54314e9da42b4111a1aab53d1ec355ad13922e1
Reviewed-on: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/10444
Integration-Tests: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
Tested-by: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
Reviewed-by: Murtadha Hubail <mhubail@apache.org>
Reviewed-by: Ali Alsuliman <ali.al.solaiman@gmail.com>
(cherry picked from commit e8428051a7550578e2b28f5987e87ede41c83832)
---
M asterixdb/asterix-metadata/src/main/java/org/apache/asterix/metadata/MetadataManager.java
1 file changed, 5 insertions(+), 0 deletions(-)



  git pull ssh://asterix-gerrit.ics.uci.edu:29418/asterixdb refs/changes/23/12023/1

diff --git a/asterixdb/asterix-metadata/src/main/java/org/apache/asterix/metadata/MetadataManager.java
b/asterixdb/asterix-metadata/src/main/java/org/apache/asterix/metadata/MetadataManager.java
index e5ee163..362ead8 100644
--- a/asterixdb/asterix-metadata/src/main/java/org/apache/asterix/metadata/MetadataManager.java
+++ b/asterixdb/asterix-metadata/src/main/java/org/apache/asterix/metadata/MetadataManager.java
@@ -129,6 +129,11 @@
 
     @Override
     public MetadataTransactionContext beginTransaction() throws RemoteException {
+        try {
+            INSTANCE.init();
+        } catch (HyracksDataException e) {
+            throw new ACIDException(e);
+        }
         TxnId txnId = createTxnId();
         metadataNode.beginTransaction(txnId);
         return new MetadataTransactionContext(txnId);

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/12023
To unsubscribe, or for help writing mail filters, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-Project: asterixdb
Gerrit-Branch: mad-hatter
Gerrit-Change-Id: Ic54314e9da42b4111a1aab53d1ec355ad13922e1
Gerrit-Change-Number: 12023
Gerrit-PatchSet: 1
Gerrit-Owner: Murtadha Hubail <mhubail@apache.org>
Gerrit-MessageType: newchange

Mime
View raw message