@Override
    public Secret getSecret(Key key, SecretVersionId version) {
        try {
            return cache.getUnchecked(new VersionKey(key, version));
        } catch (Exception e) {
            var msg = version == null ?
                    "Failed to retrieve current version of secret with key " + key
                    : "Failed to retrieve secret with key " + key + ", version: " + version.value();
            throw new IllegalArgumentException(msg + ":\n" + e.getMessage());
        }
    }
If version is null, the version with label AWSCURRENT is returned.
jdisc-cloud-aws/src/main/java/ai/vespa/secret/aws/AsmSecretReader.java