private boolean loadConfigFile() {
        InputStream inStream = null;
        try {
            URL url = getClass().getClassLoader().getResource(COMMON_CONFIG_FILE_NAME);
            inStream = url != null ? url.openStream() : null;
            if (inStream == null) {
                LOG.error("Fail to open {} as the input stream is null, exit!",
                        COMMON_CONFIG_FILE_NAME);
                System.exit(1);
                return false;
            }
            String strKey;
            String strVal;
            Properties tmpProps = new Properties();
            tmpProps.load(inStream);
            props = new HashMap<>(tmpProps.size());
            for (Map.Entry<Object, Object> entry : tmpProps.entrySet()) {
                if (entry == null || entry.getKey() == null || entry.getValue() == null) {
                    continue;
                }
                strKey = (String) entry.getKey();
                strVal = (String) entry.getValue();
                if (StringUtils.isBlank(strKey) || StringUtils.isBlank(strVal)) {
                    continue;
                }
                props.put(strKey.trim(), strVal.trim());
            }
            LOG.info("Read success from {}, content is {}", COMMON_CONFIG_FILE_NAME, props);
        } catch (Throwable e) {
            LOG.error("Fail to load properties from {}, exit!",
                    COMMON_CONFIG_FILE_NAME, e);
            System.exit(1);
            return false;
        } finally {
            if (null != inStream) {
                try {
                    inStream.close();
                } catch (IOException e) {
                    LOG.error("Fail to InputStream.close() for file {}, exit!",
                            COMMON_CONFIG_FILE_NAME, e);
                    System.exit(1);
                }
            }
        }
        return true;
    }
getStringFromContext

@param context
@param key
@param defaultValue
@return
inlong-dataproxy/dataproxy-source/src/main/java/org/apache/inlong/dataproxy/config/CommonConfigHolder.java