apolloconfig / apollo-java

Apollo Java Clients
Apache License 2.0
40 stars 72 forks source link

fix: compatible with snakeyaml-2.0 #34

Closed richieyan closed 1 year ago

richieyan commented 1 year ago

What's the purpose of this PR

since snakeyaml-2.0 has remove empty args constructor, we need use the constructor with options

Which issue(s) this PR fixes:

Fixes # https://github.com/apolloconfig/apollo/issues/4960

Brief changelog

-    return new Yaml(new SafeConstructor(), new Representer(), new DumperOptions(), loadingConfig);
+   DumperOptions dumperOptions = new DumperOptions();
+   return new Yaml(new SafeConstructor(loadingConfig),
            new Representer(dumperOptions), dumperOptions, loadingConfig);

Follow this checklist to help us incorporate your contribution quickly and easily:

github-actions[bot] commented 1 year ago

CLA Assistant Lite bot:
Thank you for your submission, we really appreciate it. Like many open-source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution. You can sign the CLA by just posting a Pull Request Comment same as the below format.


I have read the CLA Document and I hereby sign the CLA


yanzhuzhu seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You can retrigger this bot by commenting recheck in this Pull Request