You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ignite.apache.org by Vladimir Ozerov <vo...@gridgain.com> on 2015/10/16 11:03:12 UTC

(nearly) Constant portable object field lookup.

Igniters,

We need to implement constant or nearly-constant random field lookup in
serialized portable object to boost our queries.
With current protocol it is O(N).

I created design document with proposed solution:
https://cwiki.apache.org/confluence/display/IGNITE/Portable+object+constant-time+field+lookup

Please review it and give your comments, if any. I'm going to start working
on this feature in the nearest time.

Vladimir.

Re: (nearly) Constant portable object field lookup.

Posted by Vladimir Ozerov <vo...@gridgain.com>.
I do not see any problems with object detach. This change is simply a
matter of moving some object metadata from header to footer. It is not lost
or reduced and it is still inside object's body.

On Fri, Oct 16, 2015 at 2:11 PM, Denis Magda <dm...@gridgain.com> wrote:

> Vladimir,
>
> Didn't have much time for review, will revisit your design proposal a bit
> later.
>
> However, have one comment for now. In your algo you're planning to use
> some relative offsets.
> Do you take into account that a field, that may be of portable type is
> well, can be detached from its object. See PortableObjectImp.detach()
> method.
> Won't this detaching break the offsets and the whole logic that is based
> on them?
>
> --
> Denis
>
>
> On 10/16/2015 12:03 PM, Vladimir Ozerov wrote:
>
>> Igniters,
>>
>> We need to implement constant or nearly-constant random field lookup in
>> serialized portable object to boost our queries.
>> With current protocol it is O(N).
>>
>> I created design document with proposed solution:
>>
>> https://cwiki.apache.org/confluence/display/IGNITE/Portable+object+constant-time+field+lookup
>>
>> Please review it and give your comments, if any. I'm going to start
>> working
>> on this feature in the nearest time.
>>
>> Vladimir.
>>
>>
>

Re: (nearly) Constant portable object field lookup.

Posted by Denis Magda <dm...@gridgain.com>.
Vladimir,

Didn't have much time for review, will revisit your design proposal a 
bit later.

However, have one comment for now. In your algo you're planning to use 
some relative offsets.
Do you take into account that a field, that may be of portable type is 
well, can be detached from its object. See PortableObjectImp.detach() 
method.
Won't this detaching break the offsets and the whole logic that is based 
on them?

--
Denis

On 10/16/2015 12:03 PM, Vladimir Ozerov wrote:
> Igniters,
>
> We need to implement constant or nearly-constant random field lookup in
> serialized portable object to boost our queries.
> With current protocol it is O(N).
>
> I created design document with proposed solution:
> https://cwiki.apache.org/confluence/display/IGNITE/Portable+object+constant-time+field+lookup
>
> Please review it and give your comments, if any. I'm going to start working
> on this feature in the nearest time.
>
> Vladimir.
>