private void loadResource(String fileName, boolean isJson) {
        Reader reader = null;
        try {
            InputStream inputStream = classLoader.getResourceAsStream(fileName);
            if (inputStream != null) {
                reader = new InputStreamReader(inputStream, StandardCharsets.UTF_8);
                if (isJson) {
                    JsonElement tmpElement = JsonParser.parseReader(reader).getAsJsonObject();
                    updateConfig(new HashMap<>(10), 0, tmpElement);
                } else {
                    Properties properties = new Properties();
                    properties.load(reader);
                    properties.forEach((key, value) -> configStorage.put((String) key,
                            new JsonPrimitive((String) value)));
                }
            }
        } catch (Exception ioe) {
            LOGGER.error("error init {}", fileName, ioe);
        } finally {
            AgentUtils.finallyClose(reader);
        }
    }
support load config file from json/properties file.

@param fileName file name
@param isJson whether is json file
inlong-agent/agent-common/src/main/java/org/apache/inlong/agent/conf/AbstractConfiguration.java