ignite-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Uday Kale (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (IGNITE-9532) Binary mode for Ignite Queue
Date Mon, 17 Sep 2018 10:54:00 GMT

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

Uday Kale commented on IGNITE-9532:
-----------------------------------

I am trying to check if the SameHash object exists in the queue 'q1' after adding both Binary
Object and SameHash Object to it. Currently this is failing. It is successful only if the
object is converted to Binary Object. Below is a simplified test.
{code:java}
    public void testContains() throws Exception {
        IgniteQueue<SameHashItem> queue = grid(0).queue("q1", 0, config(false));
        IgniteQueue<BinaryObject> queueBin = grid(0).queue("q1", 0, config(false)).withKeepBinary();

        queue.add(new SameHashItem(Integer.toString(14)));
        queueBin.add(sameHashBinObj(grid(0), 14));

        assertTrue(queue.contains(new SameHashItem(Integer.toString(14)))); // Fails
        assertTrue(queueBin.contains(sameHashBinObj(grid(0), 14))); // Succeeds
    }

    private static BinaryObject sameHashBinObj(Ignite ignite, int i) {
        return ignite.binary().toBinary(new SameHashItem(Integer.toString(i)));
    }
{code}
Is this the expected behaviour?

> Binary mode for Ignite Queue
> ----------------------------
>
>                 Key: IGNITE-9532
>                 URL: https://issues.apache.org/jira/browse/IGNITE-9532
>             Project: Ignite
>          Issue Type: New Feature
>          Components: binary, data structures
>            Reporter: Uday Kale
>            Assignee: Uday Kale
>            Priority: Major
>             Fix For: 2.8
>
>
> Add binary mode (withKeepBinary) to Data Structures Queue.
> This will allow retrieving values in binary format when needed or when class is not available,
and will allow implementing the structures in other platforms (.NET, C++).



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message