You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "t-rana (via GitHub)" <gi...@apache.org> on 2024/06/10 09:56:42 UTC
[PR] OAK-10867: add service principal support in oak-run commons [jackrabbit-oak]
t-rana opened a new pull request, #1513:
URL: https://github.com/apache/jackrabbit-oak/pull/1513
(no comment)
--
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: dev-unsubscribe@jackrabbit.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] OAK-10867: add service principal support in oak-run commons [jackrabbit-oak]
Posted by "amit-jain (via GitHub)" <gi...@apache.org>.
amit-jain commented on code in PR #1513:
URL: https://github.com/apache/jackrabbit-oak/pull/1513#discussion_r1634480173
##########
oak-blob-cloud-azure/src/main/java/org/apache/jackrabbit/oak/blob/cloud/azure/blobstorage/Utils.java:
##########
@@ -19,38 +19,61 @@
package org.apache.jackrabbit.oak.blob.cloud.azure.blobstorage;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.InetSocketAddress;
-import java.net.Proxy;
-import java.net.SocketAddress;
-import java.net.URISyntaxException;
-import java.security.InvalidKeyException;
-import java.util.Properties;
-
-import org.apache.jackrabbit.guava.common.base.Strings;
+import com.azure.core.credential.AccessToken;
+import com.azure.core.credential.TokenRequestContext;
+import com.azure.identity.ClientSecretCredential;
+import com.azure.identity.ClientSecretCredentialBuilder;
import com.microsoft.azure.storage.CloudStorageAccount;
import com.microsoft.azure.storage.OperationContext;
import com.microsoft.azure.storage.RetryExponentialRetry;
import com.microsoft.azure.storage.RetryNoRetry;
import com.microsoft.azure.storage.RetryPolicy;
+import com.microsoft.azure.storage.StorageCredentialsToken;
import com.microsoft.azure.storage.StorageException;
import com.microsoft.azure.storage.blob.BlobRequestOptions;
import com.microsoft.azure.storage.blob.CloudBlobClient;
import com.microsoft.azure.storage.blob.CloudBlobContainer;
import org.apache.commons.lang3.StringUtils;
import org.apache.jackrabbit.core.data.DataStoreException;
+import org.apache.jackrabbit.guava.common.base.Strings;
import org.apache.jackrabbit.oak.commons.PropertiesUtil;
+import org.apache.jackrabbit.oak.commons.concurrent.ExecutorCloser;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.InetSocketAddress;
+import java.net.Proxy;
+import java.net.SocketAddress;
+import java.net.URISyntaxException;
+import java.security.InvalidKeyException;
+import java.time.LocalDateTime;
+import java.time.OffsetDateTime;
+import java.time.format.DateTimeFormatter;
+import java.util.Properties;
+import java.util.concurrent.Executors;
+import java.util.concurrent.ScheduledExecutorService;
+import java.util.concurrent.TimeUnit;
public final class Utils {
- public static final String DEFAULT_CONFIG_FILE = "azure.properties";
+ static {
Review Comment:
This should not be needed. Instead the close() method should be implemented as earlier and property called in the DataStore/Backend#close() e.g. https://github.com/apache/jackrabbit-oak/blob/trunk/oak-blob-cloud-azure/src/main/java/org/apache/jackrabbit/oak/blob/cloud/azure/blobstorage/AzureBlobStoreBackend.java#L518
--
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: dev-unsubscribe@jackrabbit.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] OAK-10867: add service principal support in oak-run commons [jackrabbit-oak]
Posted by "nit0906 (via GitHub)" <gi...@apache.org>.
nit0906 commented on PR #1513:
URL: https://github.com/apache/jackrabbit-oak/pull/1513#issuecomment-2160182222
Check on a couple of things -
Currently the azureBlobContainerProvider is not getting closed - this should be handled in the AzureBlobStoreBacked#close.
Another point , if the executor service being used for the token refresh stalls the jvm from closure - will the shutdown hook be actually called ?
--
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: dev-unsubscribe@jackrabbit.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] OAK-10867: add service principal support in oak-run commons [jackrabbit-oak]
Posted by "t-rana (via GitHub)" <gi...@apache.org>.
t-rana commented on PR #1513:
URL: https://github.com/apache/jackrabbit-oak/pull/1513#issuecomment-2175731261
Closing this PR for now, will raise a new one.
--
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: oak-dev-unsubscribe@jackrabbit.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] OAK-10867: add service principal support in oak-run commons [jackrabbit-oak]
Posted by "t-rana (via GitHub)" <gi...@apache.org>.
t-rana closed pull request #1513: OAK-10867: add service principal support in oak-run commons
URL: https://github.com/apache/jackrabbit-oak/pull/1513
--
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: oak-dev-unsubscribe@jackrabbit.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org