mirror of
https://github.com/jlengrand/helidon.git
synced 2026-03-10 08:21:17 +00:00
Helidon Features.
Signed-off-by: Tomas Langer <tomas.langer@oracle.com>
This commit is contained in:
committed by
Tomas Langer
parent
a4051f985b
commit
6375428deb
@@ -39,6 +39,8 @@ import java.util.stream.Collectors;
|
||||
import javax.annotation.Priority;
|
||||
|
||||
import io.helidon.common.GenericType;
|
||||
import io.helidon.common.HelidonFeatures;
|
||||
import io.helidon.common.HelidonFlavor;
|
||||
import io.helidon.common.Prioritized;
|
||||
import io.helidon.common.serviceloader.HelidonServiceLoader;
|
||||
import io.helidon.common.serviceloader.Priorities;
|
||||
@@ -65,6 +67,10 @@ import org.eclipse.microprofile.config.spi.Converter;
|
||||
class BuilderImpl implements Config.Builder {
|
||||
static final Executor DEFAULT_CHANGES_EXECUTOR = Executors.newCachedThreadPool(new ConfigThreadFactory("config"));
|
||||
|
||||
static {
|
||||
HelidonFeatures.register(HelidonFlavor.SE, "Config");
|
||||
}
|
||||
|
||||
/*
|
||||
* Config sources
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2018, 2019 Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2018, 2020 Oracle and/or its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -25,6 +25,7 @@ import java.util.function.Function;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import io.helidon.common.HelidonFeatures;
|
||||
import io.helidon.common.pki.KeyConfig;
|
||||
import io.helidon.config.Config;
|
||||
import io.helidon.config.MissingValueException;
|
||||
@@ -66,6 +67,10 @@ public final class EncryptionFilter implements ConfigFilter {
|
||||
private static final String PREFIX_ALIAS = "${ALIAS=";
|
||||
private static final String PREFIX_CLEAR = "${CLEAR=";
|
||||
|
||||
static {
|
||||
HelidonFeatures.register("Config", "Encryption");
|
||||
}
|
||||
|
||||
private final PrivateKey privateKey;
|
||||
private final char[] masterPassword;
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, 2019 Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2017, 2020 Oracle and/or its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -23,6 +23,7 @@ import java.util.Optional;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import io.helidon.common.HelidonFeatures;
|
||||
import io.helidon.config.Config;
|
||||
import io.helidon.config.ConfigException;
|
||||
import io.helidon.config.ConfigHelper;
|
||||
@@ -43,6 +44,10 @@ public class EtcdConfigSource extends AbstractParsableConfigSource<Long> {
|
||||
|
||||
private static final Logger LOGGER = Logger.getLogger(EtcdConfigSource.class.getName());
|
||||
|
||||
static {
|
||||
HelidonFeatures.register("Config", "etcd");
|
||||
}
|
||||
|
||||
private final EtcdEndpoint endpoint;
|
||||
private final EtcdClient client;
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, 2019 Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2017, 2020 Oracle and/or its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -33,6 +33,7 @@ import java.util.Optional;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import io.helidon.common.HelidonFeatures;
|
||||
import io.helidon.config.Config;
|
||||
import io.helidon.config.ConfigException;
|
||||
import io.helidon.config.ConfigHelper;
|
||||
@@ -61,6 +62,10 @@ public class GitConfigSource extends AbstractParsableConfigSource<byte[]> {
|
||||
|
||||
private static final Logger LOGGER = Logger.getLogger(GitConfigSource.class.getName());
|
||||
|
||||
static {
|
||||
HelidonFeatures.register("Config", "git");
|
||||
}
|
||||
|
||||
private final URI uri;
|
||||
private final String branch;
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, 2019 Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2017, 2020 Oracle and/or its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -21,6 +21,7 @@ import java.util.Set;
|
||||
|
||||
import javax.annotation.Priority;
|
||||
|
||||
import io.helidon.common.HelidonFeatures;
|
||||
import io.helidon.config.ConfigException;
|
||||
import io.helidon.config.ConfigHelper;
|
||||
import io.helidon.config.spi.ConfigNode.ListNode;
|
||||
@@ -71,6 +72,10 @@ public class HoconConfigParser implements ConfigParser {
|
||||
private static final Set<String> SUPPORTED_MEDIA_TYPES =
|
||||
Set.of(MEDIA_TYPE_APPLICATION_HOCON, MEDIA_TYPE_APPLICATION_JSON);
|
||||
|
||||
static {
|
||||
HelidonFeatures.register("Config", "HOCON");
|
||||
}
|
||||
|
||||
private final boolean resolvingEnabled;
|
||||
private final ConfigResolveOptions resolveOptions;
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2018, 2019 Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2018, 2020 Oracle and/or its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -19,6 +19,7 @@ import java.lang.invoke.MethodHandle;
|
||||
import java.util.Collection;
|
||||
import java.util.function.Function;
|
||||
|
||||
import io.helidon.common.HelidonFeatures;
|
||||
import io.helidon.config.Config;
|
||||
import io.helidon.config.ConfigMappingException;
|
||||
import io.helidon.config.MissingValueException;
|
||||
@@ -29,6 +30,11 @@ import io.helidon.config.objectmapping.ReflectionUtil.PropertyAccessor;
|
||||
* Various mappers used in {@link ObjectConfigMapperProvider}.
|
||||
*/
|
||||
class ObjectConfigMappers {
|
||||
|
||||
static {
|
||||
HelidonFeatures.register("Config", "Object Mapping");
|
||||
}
|
||||
|
||||
abstract static class MethodHandleConfigMapper<T, P> implements Function<Config, T> {
|
||||
private final Class<T> type;
|
||||
private final String methodName;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, 2019 Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2017, 2020 Oracle and/or its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -22,6 +22,7 @@ import java.util.Set;
|
||||
|
||||
import javax.annotation.Priority;
|
||||
|
||||
import io.helidon.common.HelidonFeatures;
|
||||
import io.helidon.config.ConfigException;
|
||||
import io.helidon.config.ConfigHelper;
|
||||
import io.helidon.config.spi.ConfigNode.ListNode;
|
||||
@@ -59,6 +60,10 @@ public class YamlConfigParser implements ConfigParser {
|
||||
|
||||
private static final Set<String> SUPPORTED_MEDIA_TYPES = Set.of(MEDIA_TYPE_APPLICATION_YAML);
|
||||
|
||||
static {
|
||||
HelidonFeatures.register("Config", "YAML");
|
||||
}
|
||||
|
||||
/**
|
||||
* Default constructor needed by Java Service loader.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user