-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Spring-Native 打包后运行报错,请问有这方面的例子吗? #4028
Comments
不支持反射吧。 我记得是需要配置文件指定下要反射类信息的 |
是的呢!自己一个个去找太麻烦了。 |
mybatis/mybatis-3#1552 是 mybatis 不支持吧 |
这个也看过,好像是的,就是不知道怎么解决。mybatis 不能用,微服务项目就暂时没法用 spring-native了。有合适的解决方案吗? |
@Lee27149 跟你一样的报错,请问你解决了吗? |
@Lee27149 我的解决办法是使用svm的targetClass, substitue,替代上面那段源码的getLog方法,亲测可行 |
解决了? |
很可惜几乎所有的库或多或少都用到了反射 不过graalvm好像有工具可以生成配置文件 |
这个自定义 reflect-config.json, 增加 { |
Hi, I want to ask if you can explain it in detail? It would be great if you can submit a DEMO to https://github.com/mybatis/spring-boot-starter/tree/master/mybatis-spring-boot-samples . |
This problem has been preliminarily solved by Mybatis maintainer. Would you like to try integration in Mybatis Plus at an early stage? Of course, XML files are currently supported now. Related to this link is |
mybatis/mybatis-3#1611 |
No, to this day Mybatis full support for GraalVM is still a problem. The issue is on it. |
和spring集成只能手动集成, 自己集成mybati-plus 的 SQLSessionFactory等. 这样是可以的. 但是使用wrapper的时候有一些反射类型转换的问题. 当前版本的graalvm还不支持. 只能等等了. 或者mp改实现方式 |
Such as spring-attic/spring-native#404 (comment), Mybatis officially supports Spring Native, and I think it's easier than ever for us to move this process forward. |
mp中的LambdaQuery会动态生成Lambda类. 这些类会被反射调用其
这些类如何在编译期间被graalvm 构建? 类似于
|
quarkiverse/quarkus-mybatis#184 这个问题已经解决. 对与spring native 可以增加
|
@siaron 不知道能否提供一个完整的案例,迫切希望能收到你的回答。 |
|
quarkiverse/quarkus-mybatis#184 看下这个issue. 里面有demo. 不过是quarkus. springboot3.0 还没测试过. |
#5527 统一至此处讨论. |
The text was updated successfully, but these errors were encountered: