Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021 Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2021, 2025 Oracle and/or its affiliates. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0, which is available at
Expand Down Expand Up @@ -49,9 +49,11 @@ protected AbstractFeatureConfigurator(Class contract, RuntimeType runtimeType) {
* @param loader specific classloader (must not be NULL)
* @return list of found classes
*/

protected List<Class<T>> loadImplementations(Map<String, Object> applicationProperties, ClassLoader loader) {
if (PropertiesHelper.isMetaInfServicesEnabled(applicationProperties, getRuntimeType())) {
return Stream.of(ServiceFinder.find(getContract(), loader, true).toClassArray())
return Stream.of(ServiceFinder.service(getContract()).loader(loader).ignoreNotFound(true)
.runtimeType(getRuntimeType()).find().toClassArray())
.collect(Collectors.toList());
}
return Collections.emptyList();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, 2021 Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2017, 2025 Oracle and/or its affiliates. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0, which is available at
Expand Down Expand Up @@ -60,8 +60,8 @@ protected AbstractServiceFinderConfigurator(Class<T> contract, RuntimeType runti
*/
protected List<Class<T>> loadImplementations(Map<String, Object> applicationProperties) {
if (PropertiesHelper.isMetaInfServicesEnabled(applicationProperties, runtimeType)) {
return Stream.of(ServiceFinder.find(contract, true).toClassArray())
.collect(Collectors.toList());
return Stream.of(ServiceFinder.service(contract).ignoreNotFound(true).runtimeType(runtimeType)
.find().toClassArray()).collect(Collectors.toList());
}
return Collections.emptyList();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2019, 2025 Oracle and/or its affiliates. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0, which is available at
Expand Down Expand Up @@ -114,7 +114,8 @@ private <T> HeaderDelegate<T> _createHeaderDelegate(final Class<T> type) {

static {
Set<HeaderDelegateProvider> hps = new HashSet<HeaderDelegateProvider>();
for (HeaderDelegateProvider provider : ServiceFinder.find(HeaderDelegateProvider.class, true)) {
for (HeaderDelegateProvider provider : ServiceFinder
.service(HeaderDelegateProvider.class).ignoreNotFound(true).find()) {
hps.add(provider);
}
headerDelegateProviders = Collections.unmodifiableSet(hps);
Expand Down
Loading
Loading