Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [incquery-dev] Viewers refactoring, help needed

Hi,

for now, I have sent a message to the Platform forum, as maybe we have missed something (although I am more likely to think it is a bug).

I am not entirely sure about it, but maybe a more complex computedset implementation could also solve the issue, as we did not experience the same issues with only a single ComputedSet, but maybe I have missed some corner case. (The current implementation is logically cleaner, but maybe this is required).

Zoli
-- Zoltán Ujhelyi
https://www.inf.mit.bme.hu/en/members/ujhelyiz

Fault Tolerant Systems Research Group
Budapest University of Technology and Economics

On 2013.07.31., at 18:13, Istvan Rath <rath@xxxxxxxxxx> wrote:

> Guys,
> 
> many thanks for debugging this!
> 
> What to do next?
> 
> - Should we (Abel) file a bug on this in the bugzilla?
> - What to use inside of Viewers instead of the ComputedSet / UnionSet combo?
> 
> Istvan
> 
> 
> 
> --
> Istvan RATH, PhD
> Research fellow
> Budapest University of Technology and Economics
> Fault Tolerant Systems Research Group
> 
> 
> 
> On Wednesday, July 31, 2013 at 3:32 PM, Ábel Hegedüs wrote:
> 
>> Hi all,
>> 
>> the code is not working correctly, because the UnionSet of ComputedSets is buggy.
>> We have created a minimal example with Zoli that shows this, without any EMF-IncQuery or Viewers:
>> https://gist.github.com/abelhegedus/6121875
>> 
>> - Computed set works fine, as long as it is not used in anything that uses a staleness listener
>> - Union set works fine when used with a regular observable set
>> - Union set registers a staleness listener in the Computed set, which causes the set to recalculate its contents upon change _before_ it stores the old values
>> 
>> To sum it up, unless we are missing something related to Computed sets or Union set, this is a bug in the org.eclipse.core.databinding.observable package.
>> 
>> Cheers,
>>  Ábel Hegedüs
>> 
>> Fault Tolerant Systems Research Group
>> Department of Measurement and Information Systems
>> Budapest University of Technology and Economics
>> 
>>> 
>>> On 2013.07.29. 11:50:16, Istvan Rath <rath@xxxxxxxxxx (mailto:rath@xxxxxxxxxx)> wrote:
>>> 
>>> Hi all,  
>>> 
>>> I have committed a refactoring of the Viewers Framework internals, namely the switch from …List to …Set. The main motivation behind this change is that 1) observable pattern match results are (mathematically) sets anyway
>>> 2) many useful operations (e.g. search) are much faster over sets
>>> 3) these operations are necessary to efficiently support runtime validation features (e.g. dangling edge detection).
>>> 
>>> Some additional (small) API changes were necessary to hide the internal implementation from client code, so that the switch from …List to …Set can be made easily (i.e. without having to touch client code further on).
>>> 
>>> Unfortunately, the Set-based implementation doesn't work well yet:
>>> - Items are handled correctly, but Edges and Containments are not
>>> - it seems that the combination of UnionSet with ComputedSets is the culprit
>>> - but I am not sure about the correctness of my itemMap implementation either.
>>> 
>>> I would be very grateful if someone knowledgeable (e.g. Zoli) could take a look at the code and help figure out why it is not working correctly.
>>> 
>>> Istvan
>>> 
>>> 
>>> --
>>> Istvan RATH, PhD
>>> Research fellow
>>> Budapest University of Technology and Economics
>>> Fault Tolerant Systems Research Group
>>> 
>>> 
>>> _______________________________________________ incquery-dev mailing list incquery-dev@xxxxxxxxxxx https://dev.eclipse.org/mailman/listinfo/incquery-dev  
>> 
>> 
>> 
>> _______________________________________________
>> incquery-dev mailing list
>> incquery-dev@xxxxxxxxxxx (mailto:incquery-dev@xxxxxxxxxxx)
>> https://dev.eclipse.org/mailman/listinfo/incquery-dev
>> 
>> 
> 
> 
> _______________________________________________
> incquery-dev mailing list
> incquery-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/incquery-dev



Back to the top