Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sharding startup failed after upgrading the snake yml component to version 2.0 #25291

Closed
sushuliang113 opened this issue Apr 23, 2023 · 7 comments · Fixed by #28805
Closed

Sharding startup failed after upgrading the snake yml component to version 2.0 #25291

sushuliang113 opened this issue Apr 23, 2023 · 7 comments · Fixed by #28805
Assignees
Labels
stale type: dependencies Pull requests that update a dependency file type: question

Comments

@sushuliang113
Copy link

sushuliang113 commented Apr 23, 2023

sharding version:

org.apache.shardingsphere
shardingsphere-jdbc-core
5.3.2

snakeYaml version:

org.yaml
snakeyaml
2.0

Caused by: java.lang.NoSuchMethodError: org.yaml.snakeyaml.representer.Representer: method ()V not found
at org.apache.shardingsphere.infra.util.yaml.representer.ShardingSphereYamlRepresenter.(ShardingSphereYamlRepresenter.java:42) ~[shardingsphere-infra-util-5.3.2.jar:5.3.2]
at org.apache.shardingsphere.infra.util.yaml.YamlEngine.marshal(YamlEngine.java:113) ~[shardingsphere-infra-util-5.3.2.jar:5.3.2]
at org.apache.shardingsphere.mode.metadata.persist.service.config.global.PropertiesPersistService.persist(PropertiesPersistService.java:45) ~[shardingsphere-mode-core-5.3.2.jar:5.3.2]
at org.apache.shardingsphere.mode.metadata.persist.service.config.global.PropertiesPersistService.conditionalPersist(PropertiesPersistService.java:39) ~[shardingsphere-mode-core-5.3.2.jar:5.3.2]
at org.apache.shardingsphere.mode.metadata.persist.MetaDataPersistService.persistConfigurations(MetaDataPersistService.java:86) ~[shardingsphere-mode-core-5.3.2.jar:5.3.2]
at org.apache.shardingsphere.mode.manager.standalone.StandaloneContextManagerBuilder.persistConfigurations(StandaloneContextManagerBuilder.java:61) ~[shardingsphere-standalone-mode-core-5.3.2

@RaigorJiang
Copy link
Contributor

ShardingSphere now uses snakeyaml 1.3.3, there may be compatibility problem with different versions.

@RaigorJiang RaigorJiang added type: question type: dependencies Pull requests that update a dependency file labels Apr 23, 2023
@linghengqian
Copy link
Member

linghengqian commented Apr 23, 2023

@zhchhawks
Copy link

zhchhawks commented May 10, 2023

I am using 4.1.1, will this version support snakeyaml 2.0?

@linghengqian
Copy link
Member

linghengqian commented May 10, 2023

I am using 4.1.1, will this version support snakeyaml 2.0?

  • Considering the API changes in SnakeYAML in the last 2 years, I don't think this is possible.

@hsld9527
Copy link

hsld9527 commented Jun 7, 2023

SpringBoot 2.7.10 alreadey supports SnakeYaml 2.0, but I see there is no Sharding 4.x to support SnakeYaml 2.0, and the problem still exists

@github-actions github-actions bot added the stale label Jul 12, 2023
@linghengqian
Copy link
Member

SpringBoot 2.7.10 alreadey supports SnakeYaml 2.0, but I see there is no Sharding 4.x to support SnakeYaml 2.0, and the problem still exists

  • Considering that it is impossible to commit back to the ShardingSphere 4.x branch, I think this is an impossible thing.

@github-actions
Copy link

There hasn't been any activity on this issue recently, and in order to prioritize active issues, it will be marked as stale.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale type: dependencies Pull requests that update a dependency file type: question
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants