Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-11 Thread via GitHub


nsivabalan merged PR #17843:
URL: https://github.com/apache/hudi/pull/17843


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-10 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3876979688

   
   ## CI report:
   
   * 59feff309b96fa4f9cc5973286cb26832d800a2c Azure: 
[FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11893)
 
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-10 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3876802637

   
   ## CI report:
   
   * 24b029414d756a4058770f1a540f8f72d18b6b7b Azure: 
[FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11891)
 
   * 59feff309b96fa4f9cc5973286cb26832d800a2c Azure: 
[PENDING](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11893)
 
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-10 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3876711835

   
   ## CI report:
   
   * 24b029414d756a4058770f1a540f8f72d18b6b7b Azure: 
[FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11891)
 
   * 59feff309b96fa4f9cc5973286cb26832d800a2c UNKNOWN
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-10 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3876647713

   
   ## CI report:
   
   * 91573b5ea4938c5aaa20754c194810c684dc224a Azure: 
[SUCCESS](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11694)
 
   * 24b029414d756a4058770f1a540f8f72d18b6b7b Azure: 
[PENDING](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11891)
 
   * 59feff309b96fa4f9cc5973286cb26832d800a2c UNKNOWN
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-10 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3876476075

   
   ## CI report:
   
   * 91573b5ea4938c5aaa20754c194810c684dc224a Azure: 
[SUCCESS](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11694)
 
   * 24b029414d756a4058770f1a540f8f72d18b6b7b Azure: 
[PENDING](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11891)
 
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-10 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3876458923

   
   ## CI report:
   
   * 91573b5ea4938c5aaa20754c194810c684dc224a Azure: 
[SUCCESS](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11694)
 
   * 24b029414d756a4058770f1a540f8f72d18b6b7b UNKNOWN
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-09 Thread via GitHub


nsivabalan commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3875182499

   I don't see https://github.com/apache/hudi/pull/17780 being CPed?
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-05 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3853496722

   
   ## CI report:
   
   * 91573b5ea4938c5aaa20754c194810c684dc224a Azure: 
[SUCCESS](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11694)
 
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-05 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3853233611

   
   ## CI report:
   
   * 644ced556f3838b57dc84539180944d6802c03a1 Azure: 
[SUCCESS](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=10979)
 
   * 91573b5ea4938c5aaa20754c194810c684dc224a Azure: 
[PENDING](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=11694)
 
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-05 Thread via GitHub


hudi-bot commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3853214574

   
   ## CI report:
   
   * 644ced556f3838b57dc84539180944d6802c03a1 Azure: 
[SUCCESS](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=10979)
 
   * 91573b5ea4938c5aaa20754c194810c684dc224a UNKNOWN
   
   
   Bot commands
 @hudi-bot supports the following commands:
   
- `@hudi-bot run azure` re-run the last Azure build
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-05 Thread via GitHub


lokeshj1703 commented on PR #17843:
URL: https://github.com/apache/hudi/pull/17843#issuecomment-3853204101

   @nsivabalan I have cherry-picked HUDI-7258, HUDI-7782, HUDI-8043 and 
https://github.com/apache/hudi/pull/13039/changes.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-05 Thread via GitHub


lokeshj1703 commented on code in PR #17843:
URL: https://github.com/apache/hudi/pull/17843#discussion_r2768767907


##
hudi-aws/src/main/java/org/apache/hudi/aws/transaction/lock/DynamoDBBasedLockProviderBase.java:
##
@@ -0,0 +1,226 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.hudi.aws.transaction.lock;
+
+import org.apache.hudi.aws.credentials.HoodieAWSCredentialsProviderFactory;
+import org.apache.hudi.aws.utils.DynamoTableUtils;
+import org.apache.hudi.common.config.LockConfiguration;
+import org.apache.hudi.common.lock.LockProvider;
+import org.apache.hudi.common.lock.LockState;
+import org.apache.hudi.common.util.StringUtils;
+import org.apache.hudi.config.DynamoDbBasedLockConfig;
+import org.apache.hudi.exception.HoodieLockException;
+import org.apache.hudi.storage.StorageConfiguration;
+
+import com.amazonaws.services.dynamodbv2.AcquireLockOptions;
+import com.amazonaws.services.dynamodbv2.AmazonDynamoDBLockClient;
+import com.amazonaws.services.dynamodbv2.AmazonDynamoDBLockClientOptions;
+import com.amazonaws.services.dynamodbv2.LockItem;
+import com.amazonaws.services.dynamodbv2.model.LockNotGrantedException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import software.amazon.awssdk.regions.Region;
+import software.amazon.awssdk.services.dynamodb.DynamoDbClient;
+import software.amazon.awssdk.services.dynamodb.model.AttributeDefinition;
+import software.amazon.awssdk.services.dynamodb.model.BillingMode;
+import software.amazon.awssdk.services.dynamodb.model.CreateTableRequest;
+import software.amazon.awssdk.services.dynamodb.model.KeySchemaElement;
+import software.amazon.awssdk.services.dynamodb.model.KeyType;
+import software.amazon.awssdk.services.dynamodb.model.ProvisionedThroughput;
+import software.amazon.awssdk.services.dynamodb.model.ScalarAttributeType;
+
+import javax.annotation.concurrent.NotThreadSafe;
+
+import java.net.URI;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List;
+import java.util.concurrent.TimeUnit;
+
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_ENDPOINT_URL;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_BILLING_MODE;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_READ_CAPACITY;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_REGION;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_TABLE_CREATION_TIMEOUT;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_WRITE_CAPACITY;
+
+/**
+ * A DynamoDB based lock. This {@link LockProvider} implementation allows to 
lock table operations
+ * using DynamoDB. Users need to have access to AWS DynamoDB to be able to use 
this lock.
+ */
+@NotThreadSafe
+public abstract class DynamoDBBasedLockProviderBase implements 
LockProvider {
+
+  protected static final Logger LOG = 
LoggerFactory.getLogger(DynamoDBBasedLockProviderBase.class);
+
+  protected static final String DYNAMODB_ATTRIBUTE_NAME = "key";
+
+  protected final DynamoDbBasedLockConfig dynamoDbBasedLockConfig;
+  protected final AmazonDynamoDBLockClient client;
+  protected final String tableName;
+  protected final String dynamoDBPartitionKey;
+  protected volatile LockItem lock;
+
+  protected DynamoDBBasedLockProviderBase(final LockConfiguration 
lockConfiguration, final StorageConfiguration conf, DynamoDbClient dynamoDB) 
{
+if (dynamoDB == null) {
+  dynamoDB = getDynamoDBClient();

Review Comment:
   Cherry-picked https://github.com/apache/hudi/pull/11728. That should address 
your concern @linliu-code.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-05 Thread via GitHub


lokeshj1703 commented on code in PR #17843:
URL: https://github.com/apache/hudi/pull/17843#discussion_r2768750879


##
hudi-aws/src/main/java/org/apache/hudi/aws/transaction/lock/DynamoDBBasedImplicitPartitionKeyLockProvider.java:
##
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.hudi.aws.transaction.lock;
+
+import org.apache.hudi.common.config.HoodieCommonConfig;
+import org.apache.hudi.common.config.LockConfiguration;
+import org.apache.hudi.common.util.hash.HashID;
+import org.apache.hudi.storage.StorageConfiguration;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.apache.hudi.common.util.StringUtils;
+import software.amazon.awssdk.services.dynamodb.DynamoDbClient;
+
+import javax.annotation.concurrent.NotThreadSafe;
+
+import static org.apache.hudi.common.fs.FSUtils.s3aToS3;
+
+/**
+ * A DynamoDB based lock.
+ * It implicitly derives the partition key from the hudi table name and hudi 
table base path
+ * available in the lock configuration.
+ */
+@NotThreadSafe
+public class DynamoDBBasedImplicitPartitionKeyLockProvider extends 
DynamoDBBasedLockProviderBase {
+  protected static final Logger LOG = 
LoggerFactory.getLogger(DynamoDBBasedImplicitPartitionKeyLockProvider.class);
+
+  private final String hudiTableBasePath;
+
+  public DynamoDBBasedImplicitPartitionKeyLockProvider(final LockConfiguration 
lockConfiguration, final StorageConfiguration conf) {
+this(lockConfiguration, conf, null);
+  }
+
+  public DynamoDBBasedImplicitPartitionKeyLockProvider(
+  final LockConfiguration lockConfiguration, final StorageConfiguration 
conf, DynamoDbClient dynamoDB) {
+super(lockConfiguration, conf, dynamoDB);
+hudiTableBasePath = 
s3aToS3(lockConfiguration.getConfig().getString(HoodieCommonConfig.BASE_PATH.key()));

Review Comment:
   `TypedProperties#getString(java.lang.String)` already has a check for 
presence of key



##
hudi-aws/src/main/java/org/apache/hudi/aws/transaction/lock/DynamoDBBasedImplicitPartitionKeyLockProvider.java:
##
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.hudi.aws.transaction.lock;
+
+import org.apache.hudi.common.config.HoodieCommonConfig;
+import org.apache.hudi.common.config.LockConfiguration;
+import org.apache.hudi.common.util.hash.HashID;
+import org.apache.hudi.storage.StorageConfiguration;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.apache.hudi.common.util.StringUtils;
+import software.amazon.awssdk.services.dynamodb.DynamoDbClient;
+
+import javax.annotation.concurrent.NotThreadSafe;
+
+import static org.apache.hudi.common.fs.FSUtils.s3aToS3;
+
+/**
+ * A DynamoDB based lock.
+ * It implicitly derives the partition key from the hudi table name and hudi 
table base path
+ * available in the lock configuration.
+ */
+@NotThreadSafe
+public class DynamoDBBasedImplicitPartitionKeyLockProvider extends 
DynamoDBBasedLockProviderBase {
+  protected static final Logger LOG = 
LoggerFactory.getLogger(DynamoDBBasedImplicitPartitionKeyLockProvider.class);
+
+  private final String hudiTableBasePath;
+
+  public DynamoDBBasedImplicitPartitionKeyLockProvider(final LockConfiguration 
lockConfiguration, final StorageConfiguration conf) {
+this(lockConfiguration, conf, null);
+  }
+
+  public DynamoDBBasedImplicitPartitionKeyLockProvider(
+  final LockConfiguration lockCo

Re: [PR] [HUDI-8490] Adding DynamoDB Implicit Lock Provider support [hudi]

2026-02-05 Thread via GitHub


nsivabalan commented on code in PR #17843:
URL: https://github.com/apache/hudi/pull/17843#discussion_r2767955755


##
hudi-aws/src/main/java/org/apache/hudi/aws/transaction/lock/DynamoDBBasedLockProviderBase.java:
##
@@ -0,0 +1,226 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.hudi.aws.transaction.lock;
+
+import org.apache.hudi.aws.credentials.HoodieAWSCredentialsProviderFactory;
+import org.apache.hudi.aws.utils.DynamoTableUtils;
+import org.apache.hudi.common.config.LockConfiguration;
+import org.apache.hudi.common.lock.LockProvider;
+import org.apache.hudi.common.lock.LockState;
+import org.apache.hudi.common.util.StringUtils;
+import org.apache.hudi.config.DynamoDbBasedLockConfig;
+import org.apache.hudi.exception.HoodieLockException;
+import org.apache.hudi.storage.StorageConfiguration;
+
+import com.amazonaws.services.dynamodbv2.AcquireLockOptions;
+import com.amazonaws.services.dynamodbv2.AmazonDynamoDBLockClient;
+import com.amazonaws.services.dynamodbv2.AmazonDynamoDBLockClientOptions;
+import com.amazonaws.services.dynamodbv2.LockItem;
+import com.amazonaws.services.dynamodbv2.model.LockNotGrantedException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import software.amazon.awssdk.regions.Region;
+import software.amazon.awssdk.services.dynamodb.DynamoDbClient;
+import software.amazon.awssdk.services.dynamodb.model.AttributeDefinition;
+import software.amazon.awssdk.services.dynamodb.model.BillingMode;
+import software.amazon.awssdk.services.dynamodb.model.CreateTableRequest;
+import software.amazon.awssdk.services.dynamodb.model.KeySchemaElement;
+import software.amazon.awssdk.services.dynamodb.model.KeyType;
+import software.amazon.awssdk.services.dynamodb.model.ProvisionedThroughput;
+import software.amazon.awssdk.services.dynamodb.model.ScalarAttributeType;
+
+import javax.annotation.concurrent.NotThreadSafe;
+
+import java.net.URI;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List;
+import java.util.concurrent.TimeUnit;
+
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_ENDPOINT_URL;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_BILLING_MODE;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_READ_CAPACITY;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_REGION;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_TABLE_CREATION_TIMEOUT;
+import static 
org.apache.hudi.config.DynamoDbBasedLockConfig.DYNAMODB_LOCK_WRITE_CAPACITY;
+
+/**
+ * A DynamoDB based lock. This {@link LockProvider} implementation allows to 
lock table operations
+ * using DynamoDB. Users need to have access to AWS DynamoDB to be able to use 
this lock.
+ */
+@NotThreadSafe
+public abstract class DynamoDBBasedLockProviderBase implements 
LockProvider {
+
+  protected static final Logger LOG = 
LoggerFactory.getLogger(DynamoDBBasedLockProviderBase.class);
+
+  protected static final String DYNAMODB_ATTRIBUTE_NAME = "key";
+
+  protected final DynamoDbBasedLockConfig dynamoDbBasedLockConfig;
+  protected final AmazonDynamoDBLockClient client;
+  protected final String tableName;
+  protected final String dynamoDBPartitionKey;
+  protected volatile LockItem lock;
+
+  protected DynamoDBBasedLockProviderBase(final LockConfiguration 
lockConfiguration, final StorageConfiguration conf, DynamoDbClient dynamoDB) 
{
+if (dynamoDB == null) {
+  dynamoDB = getDynamoDBClient();

Review Comment:
   don't we need to CP https://github.com/apache/hudi/pull/11728 as well 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]