milleruntime commented on code in PR #2946:
URL: https://github.com/apache/accumulo/pull/2946#discussion_r977695377


##########
core/src/main/java/org/apache/accumulo/core/spi/crypto/PerTableCryptoServiceFactory.java:
##########
@@ -46,12 +48,24 @@ public class PerTableCryptoServiceFactory implements 
CryptoServiceFactory {
   private static final TableId REC_FAKE_ID = 
TableId.of("RECOVERY_CryptoService_FAKE_ID");
 
   @Override
-  public CryptoService getService(CryptoEnvironment environment, 
Map<String,String> props) {
+  public CryptoService getService(CryptoEnvironment environment, 
Map<String,String> props)
+      throws CryptoException {
     if (environment.getScope() == CryptoEnvironment.Scope.WAL) {
-      return cryptoServiceMap.computeIfAbsent(WAL_FAKE_ID, (id) -> 
getWALServiceInitialized(props));
+      return cryptoServiceMap.computeIfAbsent(WAL_FAKE_ID, (id) -> {
+        try {
+          return getWALServiceInitialized(props);
+        } catch (CryptoException e) {
+          throw new UncheckedIOException("Error creating WAL crypto service", 
e);

Review Comment:
   OK that makes sense. Check out my other comment about checked vs unchecked. 



-- 
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]

Reply via email to