File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
operator-framework/src/main/java/io/javaoperatorsdk/operator Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 66import io .javaoperatorsdk .operator .api .ResourceController ;
77import org .apache .commons .lang3 .ClassUtils ;
88
9+ import java .io .BufferedReader ;
910import java .io .IOException ;
11+ import java .io .InputStreamReader ;
1012import java .net .URL ;
1113import java .nio .file .Files ;
1214import java .nio .file .Path ;
@@ -25,9 +27,12 @@ public class ControllerUtils {
2527 final Enumeration <URL > customResourcesMetadaList = ControllerUtils .class .getClassLoader ().getResources (CONTROLLERS_RESOURCE_PATH );
2628 for (Iterator <URL > it = customResourcesMetadaList .asIterator (); it .hasNext (); ) {
2729 URL url = it .next ();
28- final List <String > classNamePairs = Files .lines (Path .of (url .getPath ()))
29- .collect (Collectors .toList ());
3030
31+ List <String > classNamePairs = new BufferedReader (
32+ new InputStreamReader (
33+ url .openStream ()
34+ )
35+ ).lines ().collect (Collectors .toList ());
3136 classNamePairs .forEach (clazzPair -> {
3237 try {
3338
You can’t perform that action at this time.
0 commit comments