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

[BUG]Oracle Clob 序列化问题 2.0.14可以 后面试了2.0.16和2.0.18都不可以 #920

Closed
1195952223 opened this issue Nov 10, 2022 · 11 comments
Labels
bug Something isn't working fixed
Milestone

Comments

@1195952223
Copy link

问题描述

简要描述您碰到的问题。

Oracle Clob 序列化问题 2.0.14可以 后面是2.0.16和2.0.18都不可以

环境信息

请填写以下信息:

  • JDK信息: [e.g.:Openjdk 1.8.0_312]
  • 版本信息:[e.g.:Fastjson2 2.0.18]

重现步骤

如何操作可以重现该问题:
序列化问题 2.0.14可以 后面是2.0.16和2.0.18都不可以

期待的正确结果

对您期望发生的结果进行清晰简洁的描述。

相关日志输出

请复制并粘贴任何相关的日志输出。

附加信息

如果你还有其他需要提供的信息,可以在这里填写(可以提供截图、视频等)。

@1195952223 1195952223 added the bug Something isn't working label Nov 10, 2022
@1195952223 1195952223 changed the title [BUG]Oracle Clob 序列化问题 2.0.14可以 后面是2.0.16和2.0.18都不可以 [BUG]Oracle Clob 序列化问题 2.0.14可以 后面试了2.0.16和2.0.18都不可以 Nov 10, 2022
@wenshao
Copy link
Member

wenshao commented Nov 10, 2022

不可以是结果不对还是报错了?

@1195952223
Copy link
Author

image
image

@1195952223
Copy link
Author

不可以是结果不对还是报错了?

截图是2.0.18版本

@wenshao wenshao added this to the 2.0.19 milestone Nov 10, 2022
wenshao added a commit that referenced this issue Nov 10, 2022
@wenshao
Copy link
Member

wenshao commented Nov 11, 2022

https://oss.sonatype.org/content/repositories/snapshots/com/alibaba/fastjson2/fastjson2/2.0.19-SNAPSHOT/
问题已修复,请帮忙用2.0.19-SNAPSHOT验证,2.0.19版本预计在11月13日前发布。

@wenshao wenshao added the fixed label Nov 11, 2022
@wenshao
Copy link
Member

wenshao commented Nov 12, 2022

@wenshao wenshao closed this as completed Nov 12, 2022
@1195952223
Copy link
Author

https://github.com/alibaba/fastjson2/releases/tag/2.0.19 请用新版本
今天试了一下2.0.19版本 发现依然不能使用,目前能使用的版本2.0.14,错误信息:
to 'OutputStream' at com.alibaba.fastjson2.support.spring.http.converter.FastJsonHttpMessageConverter.writeInternal(FastJsonHttpMessageConverter.java:139) at org.springframework.http.converter.AbstractHttpMessageConverter.write(AbstractHttpMessageConverter.java:227) at com.alibaba.fastjson2.support.spring.http.converter.FastJsonHttpMessageConverter.write(FastJsonHttpMessageConverter.java:83) at org.springframework.web.servlet.mvc.method.annotation.AbstractMessageConverterMethodProcessor.writeWithMessageConverters(AbstractMessageConverterMethodProcessor.java:290) at org.springframework.web.servlet.mvc.method.annotation.RequestResponseBodyMethodProcessor.handleReturnValue(RequestResponseBodyMethodProcessor.java:183) at org.springframework.web.method.support.HandlerMethodReturnValueHandlerComposite.handleReturnValue(HandlerMethodReturnValueHandlerComposite.java:78) at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:135) at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:895) at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:808) at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1067) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:963) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006) at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:909) at javax.servlet.http.HttpServlet.service(HttpServlet.java:681) at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883) at javax.servlet.http.HttpServlet.service(HttpServlet.java:764) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:227) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
com.alibaba.fastjson2.JSONException: invoke getter method error, DBAccessProperties at com.alibaba.fastjson2.writer.FieldWriterObjectMethod.getFieldValue(FieldWriterObjectMethod.java:29) at com.alibaba.fastjson2.writer.FieldWriterObject.write(FieldWriterObject.java:156) at com.alibaba.fastjson2.writer.ObjectWriterAdapter.write(ObjectWriterAdapter.java:312) at com.alibaba.fastjson2.writer.ObjectWriter_10.write(Unknown Source) at com.alibaba.fastjson2.writer.ObjectWriter_8.write(Unknown Source) at com.alibaba.fastjson2.writer.ObjectWriterImplMap.write(ObjectWriterImplMap.java:542) at com.alibaba.fastjson2.writer.ObjectWriterImplList.write(ObjectWriterImplList.java:373) at com.alibaba.fastjson2.writer.ObjectWriterImplMap.write(ObjectWriterImplMap.java:542) at com.alibaba.fastjson2.writer.ObjectWriterImplMap.write(ObjectWriterImplMap.java:542) at com.alibaba.fastjson2.JSON.toJSONString(JSON.java:2183)
Caused by: java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.alibaba.fastjson2.writer.FieldWriterObjectMethod.getFieldValue(FieldWriterObjectMethod.java:27) ... 139 more Caused by: java.sql.SQLException: 不支持的特性 at oracle.jdbc.driver.PhysicalConnection.getDBAccessProperties(PhysicalConnection.java:8660) ... 144 more at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)

@wenshao wenshao modified the milestones: 2.0.19, 2.0.20 Nov 17, 2022
@wenshao wenshao reopened this Nov 17, 2022
@wenshao
Copy link
Member

wenshao commented Nov 17, 2022

能帮看下你序列化的Oracle Clob的实际类型的类名么?

@1195952223
Copy link
Author

image

@wenshao
Copy link
Member

wenshao commented Nov 25, 2022

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

wenshao added a commit that referenced this issue Nov 25, 2022
wenshao added a commit that referenced this issue Nov 25, 2022
wenshao added a commit that referenced this issue Nov 25, 2022
@1195952223 1195952223 reopened this Nov 25, 2022
@1195952223
Copy link
Author

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

已修复

@wenshao
Copy link
Member

wenshao commented Nov 28, 2022

@wenshao wenshao closed this as completed Nov 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fixed
Projects
None yet
Development

No branches or pull requests

2 participants