You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/10/12 12:09:00 UTC

[jira] [Commented] (IGNITE-6135) java.sql.Date is serialized using OptimizedMarshaller

    [ https://issues.apache.org/jira/browse/IGNITE-6135?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16201855#comment-16201855 ] 

ASF GitHub Bot commented on IGNITE-6135:
----------------------------------------

GitHub user NSAmelchev opened a pull request:

    https://github.com/apache/ignite/pull/2837

    IGNITE-6135

    - add new type SQL_DATE(for java.sql.Date class) into the Binary Marshaller.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/NSAmelchev/ignite ignite-6135

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/ignite/pull/2837.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #2837
    
----
commit 27d01e55406df1b1f498b8c09c278c29a47ba038
Author: NSAmelchev <ns...@gmail.com>
Date:   2017-10-11T12:53:09Z

    add test

commit ed8ec5d0a1e59f87e8dd0f7fba07bbfb117dcb47
Author: NSAmelchev <ns...@gmail.com>
Date:   2017-10-12T12:02:38Z

    Fix

----


> java.sql.Date is serialized using OptimizedMarshaller
> -----------------------------------------------------
>
>                 Key: IGNITE-6135
>                 URL: https://issues.apache.org/jira/browse/IGNITE-6135
>             Project: Ignite
>          Issue Type: Bug
>          Components: binary
>    Affects Versions: 2.1
>            Reporter: Valentin Kulichenko
>            Assignee: Amelchev Nikita
>
> For some reason, if an object has a field of {{java.sql.Date}}, it's serialized with {{OptimizedMarshaller}}. It should be a first class citizen, similar to {{java.util.Date}}.
> In addition, it's possible to write a field using builder like this:
> {code}
> builder.setField(name, val, java.util.Date.class)
> {code}
> where {{val}} is instance of {{java.sql.Date}}. This leads to an exception during deserialization, because {{java.util.Date}} would be expected.
> More context and code reproducing the issue can be found here: http://apache-ignite-users.70518.x6.nabble.com/JDBC-store-Date-deserialization-problem-td16276.html



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)