You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Martin Kreidenweis (JIRA)" <ji...@apache.org> on 2011/05/26 09:35:47 UTC
[jira] [Created] (OFBIZ-4295) Deserialization of arrays with
UtilObject.getObject() throws ClassNotFoundException
Deserialization of arrays with UtilObject.getObject() throws ClassNotFoundException
-----------------------------------------------------------------------------------
Key: OFBIZ-4295
URL: https://issues.apache.org/jira/browse/OFBIZ-4295
Project: OFBiz
Issue Type: Bug
Components: framework
Affects Versions: SVN trunk
Reporter: Martin Kreidenweis
Deserialization of arrays with {{UtilObject.getObject()}} throws a {{ClassNotFoundException}}. This happened to us when we enabled the distributed cache clear feature and it was sending arrays of {{EntityExpr}} objects to other OFBiz instances.
The reason is, that the {{org.ofbiz.base.util.ObjectInputStream}} calls {{classLoader.loadClass(name)}} directly instead of using {{Class.forName(name, init, classLoader)}}.
According to java bug http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6446627 {{ClassLoader.loadClass()}} is not intended to being used this way and doesn't support loading arrays.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Assigned] (OFBIZ-4295) Deserialization of arrays with
UtilObject.getObject() throws ClassNotFoundException
Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-4295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jacques Le Roux reassigned OFBIZ-4295:
--------------------------------------
Assignee: Jacques Le Roux
> Deserialization of arrays with UtilObject.getObject() throws ClassNotFoundException
> -----------------------------------------------------------------------------------
>
> Key: OFBIZ-4295
> URL: https://issues.apache.org/jira/browse/OFBIZ-4295
> Project: OFBiz
> Issue Type: Bug
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Martin Kreidenweis
> Assignee: Jacques Le Roux
> Attachments: OFBIZ-4295-classloader.patch
>
>
> Deserialization of arrays with {{UtilObject.getObject()}} throws a {{ClassNotFoundException}}. This happened to us when we enabled the distributed cache clear feature and it was sending arrays of {{EntityExpr}} objects to other OFBiz instances.
> The reason is, that the {{org.ofbiz.base.util.ObjectInputStream}} calls {{classLoader.loadClass(name)}} directly instead of using {{Class.forName(name, init, classLoader)}}.
> According to java bug http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6446627 {{ClassLoader.loadClass()}} is not intended to being used this way and doesn't support loading arrays.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (OFBIZ-4295) Deserialization of arrays with
UtilObject.getObject() throws ClassNotFoundException
Posted by "Martin Kreidenweis (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-4295?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13114519#comment-13114519 ]
Martin Kreidenweis commented on OFBIZ-4295:
-------------------------------------------
Just checking up on the ticket status... :-)
Do you need more info or did you just not get around to applying the patch yet?
> Deserialization of arrays with UtilObject.getObject() throws ClassNotFoundException
> -----------------------------------------------------------------------------------
>
> Key: OFBIZ-4295
> URL: https://issues.apache.org/jira/browse/OFBIZ-4295
> Project: OFBiz
> Issue Type: Bug
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Martin Kreidenweis
> Attachments: OFBIZ-4295-classloader.patch
>
>
> Deserialization of arrays with {{UtilObject.getObject()}} throws a {{ClassNotFoundException}}. This happened to us when we enabled the distributed cache clear feature and it was sending arrays of {{EntityExpr}} objects to other OFBiz instances.
> The reason is, that the {{org.ofbiz.base.util.ObjectInputStream}} calls {{classLoader.loadClass(name)}} directly instead of using {{Class.forName(name, init, classLoader)}}.
> According to java bug http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6446627 {{ClassLoader.loadClass()}} is not intended to being used this way and doesn't support loading arrays.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Closed] (OFBIZ-4295) Deserialization of arrays with
UtilObject.getObject() throws ClassNotFoundException
Posted by "Jacques Le Roux (Closed) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-4295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jacques Le Roux closed OFBIZ-4295.
----------------------------------
Resolution: Fixed
Fix Version/s: SVN trunk
Release Branch 11.04
Release Branch 10.04
Release Branch 09.04
Thanks Martin and sorry for the delay,
Your patch is in
trunk r1226223
R11.04 r1226224
R10.04 r1226225
R09.04 r1226228 (no UtilIO.java)
> Deserialization of arrays with UtilObject.getObject() throws ClassNotFoundException
> -----------------------------------------------------------------------------------
>
> Key: OFBIZ-4295
> URL: https://issues.apache.org/jira/browse/OFBIZ-4295
> Project: OFBiz
> Issue Type: Bug
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Martin Kreidenweis
> Assignee: Jacques Le Roux
> Fix For: Release Branch 09.04, Release Branch 10.04, Release Branch 11.04, SVN trunk
>
> Attachments: OFBIZ-4295-classloader.patch
>
>
> Deserialization of arrays with {{UtilObject.getObject()}} throws a {{ClassNotFoundException}}. This happened to us when we enabled the distributed cache clear feature and it was sending arrays of {{EntityExpr}} objects to other OFBiz instances.
> The reason is, that the {{org.ofbiz.base.util.ObjectInputStream}} calls {{classLoader.loadClass(name)}} directly instead of using {{Class.forName(name, init, classLoader)}}.
> According to java bug http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6446627 {{ClassLoader.loadClass()}} is not intended to being used this way and doesn't support loading arrays.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (OFBIZ-4295) Deserialization of arrays with
UtilObject.getObject() throws ClassNotFoundException
Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-4295?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13114542#comment-13114542 ]
Jacques Le Roux commented on OFBIZ-4295:
----------------------------------------
Thanks for reminder Martin, I will have a look...
> Deserialization of arrays with UtilObject.getObject() throws ClassNotFoundException
> -----------------------------------------------------------------------------------
>
> Key: OFBIZ-4295
> URL: https://issues.apache.org/jira/browse/OFBIZ-4295
> Project: OFBiz
> Issue Type: Bug
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Martin Kreidenweis
> Attachments: OFBIZ-4295-classloader.patch
>
>
> Deserialization of arrays with {{UtilObject.getObject()}} throws a {{ClassNotFoundException}}. This happened to us when we enabled the distributed cache clear feature and it was sending arrays of {{EntityExpr}} objects to other OFBiz instances.
> The reason is, that the {{org.ofbiz.base.util.ObjectInputStream}} calls {{classLoader.loadClass(name)}} directly instead of using {{Class.forName(name, init, classLoader)}}.
> According to java bug http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6446627 {{ClassLoader.loadClass()}} is not intended to being used this way and doesn't support loading arrays.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (OFBIZ-4295) Deserialization of arrays with
UtilObject.getObject() throws ClassNotFoundException
Posted by "Martin Kreidenweis (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-4295?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Kreidenweis updated OFBIZ-4295:
--------------------------------------
Attachment: OFBIZ-4295-classloader.patch
This patch fixes the array deserialization issue in for UtilIO and UtilObject by using {{Class.forName()}}.
> Deserialization of arrays with UtilObject.getObject() throws ClassNotFoundException
> -----------------------------------------------------------------------------------
>
> Key: OFBIZ-4295
> URL: https://issues.apache.org/jira/browse/OFBIZ-4295
> Project: OFBiz
> Issue Type: Bug
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Martin Kreidenweis
> Attachments: OFBIZ-4295-classloader.patch
>
>
> Deserialization of arrays with {{UtilObject.getObject()}} throws a {{ClassNotFoundException}}. This happened to us when we enabled the distributed cache clear feature and it was sending arrays of {{EntityExpr}} objects to other OFBiz instances.
> The reason is, that the {{org.ofbiz.base.util.ObjectInputStream}} calls {{classLoader.loadClass(name)}} directly instead of using {{Class.forName(name, init, classLoader)}}.
> According to java bug http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6446627 {{ClassLoader.loadClass()}} is not intended to being used this way and doesn't support loading arrays.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira