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

level too large : " + this.level #1618

Closed
KissSmile opened this issue Jul 6, 2023 · 9 comments
Closed

level too large : " + this.level #1618

KissSmile opened this issue Jul 6, 2023 · 9 comments
Labels
question Further information is requested
Milestone

Comments

@KissSmile
Copy link

throw new JSONException("level too large : " + this.level);
会抛出这个异常是因为啥原因。

@KissSmile KissSmile added the question Further information is requested label Jul 6, 2023
@wenshao
Copy link
Member

wenshao commented Jul 8, 2023

有循环引用

@KissSmile
Copy link
Author

目测没循环引用。同样的方法,数据量小的没问题,只有数据量大的才有这个错。

@wenshao
Copy link
Member

wenshao commented Jul 12, 2023

因为这样的报错有多个地方,能提供下错误堆栈信息么?

@KissSmile
Copy link
Author

暂时没有了。下回有在碰到在贴上来。

@AaronWong002
Copy link

遇到类似问题,寻求帮助
com.alibaba.fastjson2.JSONException: level too large : 2048 (不方便获取全部堆栈信息,此为手敲)
...... JSONWriterJSONB.java:81
....................................
....... DubboCodec.java:284
....................................
...... DubboCountCodec.java:51

问题描述:大批量(20000)返回时报这个问题,将单次数据返回量限制到一定条数(150)以下,不再报这个问题

@AaronWong002
Copy link

这个问题如果出现在dubbo服务中只需换掉fastjson2序列化,使用hessian2即可,配置dubbo.protocol.serialization=hassian2

@wenshao
Copy link
Member

wenshao commented Jul 16, 2023

帮忙用fastjson 2.0.35版本试下问题是否还存在

@wenshao
Copy link
Member

wenshao commented Jul 17, 2023

https://oss.sonatype.org/content/repositories/snapshots/com/alibaba/fastjson2/fastjson2/2.0.36-SNAPSHOT/
问题已经修复,帮忙用2.0.36-SNAPSHOT版本验证

@wenshao wenshao added this to the 2.0.36 milestone Jul 19, 2023
@wenshao
Copy link
Member

wenshao commented Jul 19, 2023

@wenshao wenshao closed this as completed Jul 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants