Giter VIP home page Giter VIP logo

cqengine's People

Contributors

codingchili avatar curiousleo avatar dependabot[bot] avatar efernandezleon avatar glockhart avatar gzsombor avatar inego avatar jvissers avatar kimptoc avatar melozzola avatar nivs avatar npgall avatar uujava avatar voldyman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cqengine's Issues

Performance improvement - Add NotEqual SimpleQuery

First, thanks for this awesome library. It provides exactly what I needed, and 
it is very adaptable.

Unfortunately, in my case, a query like 'not(equals(attribute,value))' performs 
very badly without indicies, as the 'ResultSetDifference' calls has to call 
'contains' on the original query result for every element in my collection. For 
my collection the 'equals' method for each element is quite expensive (think of 
a list of maps), so the whole operation is much slower than just directly 
querying for 'notequals'.

To work around I wrote (copied from the equals implementation) the attached 
NotEquals query. Maybe it can be added and used for special cases like the one 
I mentioned. Even better would be to recognize simple negations (not(equals()), 
not(greater()), ..) and rewrite them automatically.

Original issue reported on code.google.com by felix.mannhardt on 26 Jul 2015 at 8:49

Attachments:

Add ability to limit number of results

See discussion in forum: 
https://groups.google.com/forum/#!topic/cqengine-discuss/o4oUCc-PGOA

It would be nice if CQEngine had an explicit way to limit the number of results 
returned. Currently, the application can just stop iterating when it has enough 
results. But built-in support might be useful as an alternative.

Possible approach:

ResultSet<Car> results = cars.retrieve(equal(Car.MANUFACTURER, "Ford"), 
queryOptions(limit(20)));

However, then support for pagination would seem like a good idea, but the limit 
approach would be inefficient as it would require re-starting the query for the 
second page.

Efficient pagination approach:

ResultSet<Car> results = cars.retrieve(equal(Car.MANUFACTURER, "Ford")); // 
cache this
for (Car car : Pagination.limit(results, 20)) { // Advances through the first 
20 cars
    // Process the first 20 cars
}
for (Car car : Pagination.limit(results, 20)) { // Advances through the next 20 
cars
    // Process the next 20 cars
}

Original issue reported on code.google.com by [email protected] on 28 Aug 2013 at 1:38

ObjectLockingIndexedCollection's StripedLock does not handle negative hashcodes

What steps will reproduce the problem?
1. Create a class that overrides hashCode method and produces a negative hash 
code.

2. Create an indexed collection of the class created in step 1 that is backed 
by an ObjectLockingIndexedCollection.

3. Attempt to add an instance of the test class to the collection.

What is the expected output? What do you see instead?
Expected: object added to collection.
Instead: ArrayIndexOutOfBoundsException

What version of the product are you using? On what operating system?
1.2.6, Windows 7 Enterprise


Please provide any additional information below.
The StripedLock class needs to account for negative hash code values to avoid 
indexing into the array of locks with a negative index value.

Original issue reported on code.google.com by [email protected] on 7 Apr 2014 at 9:59

Documentation for JOINs

Need better documentation (wiki page) for performing JOINs between indexed 
collections. This feature is implemented in trunk, but is not well documented 
yet.

For background, discussion forum: 
https://groups.google.com/forum/?fromgroups#!forum/cqengine-discuss

Code examples added to CQEngine trunk:
http://cqengine.googlecode.com/svn/cqengine/trunk/src/test/java/com/googlecode/c
qengine/examples/join/

Original issue reported on code.google.com by [email protected] on 27 Jan 2013 at 10:18

Modify Or/And to allow only one child, or else remove single-parameter QueryFactory methods.

What steps will reproduce the problem?
1. Create an or()/and() with only one child query.

What is the expected output? What do you see instead?
The result should check the return of the single child query.
An IllegalStateException is thrown saying that the query cannot have fewer than 
2 child queries.


What version of the product are you using? On what operating system?
1.2.6

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 16 Jan 2014 at 12:24

Null pointer exception indexed attribute has null value.

What steps will reproduce the problem?
1.Create IndexedCollection for a POJO type and add index on any attribute.
2.Add a object of that POJO with indexed attribute null.
3. Works with empty string.

What is the expected output? What do you see instead?
Should behave as with empty string even with complex type is null there.
Otherwise user have to check and set empty string for null.

What version of the product are you using? On what operating system?
0.9.1-all

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 25 Oct 2012 at 2:47

deduplication not return duplicate objects from the collection

 DeduplicationOption<SchoolFeesDefinitionAssignment> deduplication = deduplicate(DeduplicationStrategy.LOGICAL_ELIMINATION);



       Query<SchoolFeesDefinitionAssignment> findByTermId= equal(SchoolFeesDefinitionAssignment.TERM_ID,termCompareId);

 ResultSet<SchoolFeesDefinitionAssignment> resultSetTwo= definitionAssignmentsCqengine2.retrieve(findByTermId,queryOptions(deduplication));

resultSetTwo contains all the objects?what wrong with my code.please suggest 

Original issue reported on code.google.com by [email protected] on 15 Mar 2015 at 10:47

Query CONSISTENTLY slower with the addition of NavigableIndex

What steps will reproduce the problem?
1. Run this code, see below.

What is the expected output? What do you see instead?
I expected the queries against a NavigableIndex to be similar to or faster
instead of nearly 2x slower, than without.

What version of the product are you using? On what operating system?
1.2.7 from Maven on Ubuntu 13.10

Running this code will spit out some times. If you run it with and without the 
index line commented out you'll see that commenting it out is much faster.

Thanks for looking into it!

Original issue reported on code.google.com by [email protected] on 30 May 2014 at 9:34

Attachments:

Enhancement :Allow to set the concurrency level in order to reduce memory

What steps will reproduce the problem?
1. Insert  100000 object total around 5 mb memory size, with single index field 
of integer.  
2.
3.

What is the expected output? What do you see instead?

Memory consumed by the concurrent hashmap@segment more than 80mb. 

What version of the product are you using? On what operating system?
Win7

Please provide any additional information below.
It is suggests to allow providing factory of the underlying concurrent hashmap 
such that level of currency, load factor , etc can be customized.




Original issue reported on code.google.com by [email protected] on 12 Nov 2012 at 12:19

Allow configuration of the NodeFactory used by InvertedRadixTreeIndex

Hi, I have been following you for a while, first with the concurrent-trees project and now with this one. I think the feature of having an InvertedRadixTree in here is quite useful. However I came to a problem with this feature:

-I created a test example following your code and I found that the with the InvertedRadixTreeIndex having a collection of 5 millions of cars gives an OutOfMemory exception. Is there a workaround for this?

Furthermore, now that the InvertedRadixTree structure has the serialization feature, it could quite useful the option of saving the InvertedRadixTreeIndex to disk so we don't need to construct it again after loading the data from disk.

Enhancement Req : support for case insensitive search/query.

What steps will reproduce the problem?
1.Query on indexed string field with contains or starts with or equals etc.
2.Will return case sensitive result.
3.

What is the expected output? What do you see instead?
There should any way to perform case insensitive comparisons. Currently achived 
this by adding one morw attribute in POJO and indexed this rather than desired 
attribute and in this attribute stored lower case version of the desired 
attribute. Then performed search with search term converted to lowercase.

This will be good to have if possible without sacrificing performance.

What version of the product are you using? On what operating system?
0.9.1-all

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 25 Oct 2012 at 3:14

Deploy to Maven Central

Deploy to Maven Central per: 
https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage
+Guide

Original issue reported on code.google.com by [email protected] on 18 Jul 2012 at 9:58

IndexedCollection is not Serializable

What steps will reproduce the problem?
1. Try to serialize IndexedCollection

What is the expected output? What do you see instead?
Serializable IndexedCollection

What version of the product are you using? On what operating system?
1.0.3 on Mac OS X

Please provide any additional information below.
Support for serialization would be great. In this case user would be able to 
setup some indexes, serialize the entity and later retrieve it already with 
indexes.

Original issue reported on code.google.com by [email protected] on 5 Feb 2013 at 2:47

Support specifying generic types manually (release notes)

Support exists in CQEngine 1.0.3, but only via protected constructor in 
SimpleAttribute.

The constructor has been made public in trunk for releases >1.0.3. Needs to be 
documented in release notes for next release.

See discussion in forum: 
https://groups.google.com/forum/#!topic/cqengine-discuss/XQhVgDVIngE

Original issue reported on code.google.com by [email protected] on 6 Aug 2013 at 9:50

Comparing two objects?

What steps will reproduce the problem?

Object structure:
Order --< Item

Is possible to return Order objects with filter on Item.id = xxxx AND 
Item.price > 100.00 ?

To extend more, Is possible to get Customer information list for instead of 
Order if following is Object Structure:

Customer --o< Order



Original issue reported on code.google.com by [email protected] on 5 Mar 2014 at 9:34

IllegalArgumentException when ResultSet.getMergeCost() changes during query

The stacktrace is:

Caused by: java.lang.IllegalArgumentException: Comparison method violates its 
general contract!
        at java.util.TimSort.mergeLo(TimSort.java:747) [rt.jar:1.7.0_71]
        at java.util.TimSort.mergeAt(TimSort.java:483) [rt.jar:1.7.0_71]
        at java.util.TimSort.mergeCollapse(TimSort.java:410) [rt.jar:1.7.0_71]
        at java.util.TimSort.sort(TimSort.java:214) [rt.jar:1.7.0_71]
        at java.util.TimSort.sort(TimSort.java:173) [rt.jar:1.7.0_71]
        at java.util.Arrays.sort(Arrays.java:659) [rt.jar:1.7.0_71]
        at java.util.Collections.sort(Collections.java:217) [rt.jar:1.7.0_71]
        at com.googlecode.cqengine.resultset.connective.ResultSetIntersection.<init>(ResultSetIntersection.java:41) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.engine.impl.QueryEngineImpl.retrieveRecursive(QueryEngineImpl.java:330) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.engine.impl.QueryEngineImpl$2$1.next(QueryEngineImpl.java:351) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.engine.impl.QueryEngineImpl$2$1.next(QueryEngineImpl.java:333) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.resultset.connective.ResultSetIntersection.<init>(ResultSetIntersection.java:38) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.engine.impl.QueryEngineImpl.retrieveRecursive(QueryEngineImpl.java:330) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.engine.impl.QueryEngineImpl$2$1.next(QueryEngineImpl.java:351) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.engine.impl.QueryEngineImpl$2$1.next(QueryEngineImpl.java:333) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.resultset.connective.ResultSetIntersection.<init>(ResultSetIntersection.java:38) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.engine.impl.QueryEngineImpl.retrieveRecursive(QueryEngineImpl.java:330) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.engine.impl.QueryEngineImpl.retrieve(QueryEngineImpl.java:241) [cqengine-1.3.2.jar:]
        at com.googlecode.cqengine.collection.impl.ConcurrentIndexedCollection.retrieve(ConcurrentIndexedCollection.java:79) [cqengine-1.3.2.jar:]

It's hard to reproduce, but it looks like it's happening when one thread is 
executing a query at the same time another thread is modifying the 
ConcurrentIndexedCollection. The simple workaround is to add 
-Djava.util.Arrays.useLegacyMergeSort=true to revert back to the pre-Java 7 
mergesort that silently ignored Comparators that broke the contract, however, 
it would probably be better to somehow take a snapshot of the size of the 
underlying Set (or whatever other method is being used to determine the merge 
cost for a particular ResultSet) so it can't change during the sort.

Further discussion here: 
https://groups.google.com/forum/#!topic/cqengine-discuss/dixsmISmbx8

Original issue reported on code.google.com by [email protected] on 7 Apr 2015 at 2:38

Support application threads racing to add/remove same object

A data race between multiple application threads racing each other to add and 
remove the *same* object simultaneously, can leave indexes in an inconsistent 
state.

See discussion in forum: 
https://groups.google.com/forum/?fromgroups=#!topic/cqengine-discuss/7sxA-MDr7yk

The following sequence of method calls is unsafe:

 // setup
collection.addIndex( ... ) 
collection.addIndex( ... ) 
collection.addIndex( ... ) 

// .... calls
collection.add(instance); // thread 1
collection.remove(instance) // thread 2

By default CQEngine supports application threads adding/removing different 
objects concurrently, but a race in the application to add/remove the same 
object concurrently, can leave the object added to some indexes but removed 
from others.

This issue is to add locking support inside CQEngine, to force attempts by the 
application threads to add/remove the same object simultaneously to be 
performed sequentially.

Concurrent modification for different objects, should not incur locking. Reads 
should remain lock-free.

Original issue reported on code.google.com by [email protected] on 23 Dec 2012 at 11:18

Set remove() and removeAll() doesn't follow substitutability principle.


Set.remove(o) takes on Object where as Set.add(E) takes generic, this is 
because Set.remove() can not damage internals of Set representation even if the 
type doesn't match the element. Because only if the element is present it gets 
removed.

However in IndexedCollection implementation we pass the object after (an 
unchecked cast), to the indices. Now the indices are called even the object is 
removed or not. This causes Class Cast Exception. Instead we should check first 
if the element is a member only then call index update steps.

More here: 
http://smallwig.blogspot.in/2007/12/why-does-setcontains-take-object-not-e.html


Original issue reported on code.google.com by [email protected] on 9 Nov 2013 at 9:40

Attachments:

Benchmarks for indexing overhead

Added to trunk: 
http://cqengine.googlecode.com/svn/cqengine/trunk/src/test/java/com/googlecode/c
qengine/indexingbenchmark/

And wiki: 
http://code.google.com/p/cqengine/wiki/Benchmark#Indexing_Overhead_/_Indexing_Sp
eed

Original issue reported on code.google.com by [email protected] on 4 Dec 2012 at 11:23

A small bug in uniqueResult() + resolution

What steps will reproduce the problem?
1. Try a query that returns a ResultSet with a single item
2. call uniqueResult() on that query
3. an exception is thrown saying that the ResultSet has multiple items

What is the expected output? What do you see instead?
The single item should be returned

What version of the product are you using? On what operating system?
latest from svn, XP

Please provide any additional information below.

in ResultSet.java, line 58 should be:
O result = iterator.next();
instead of:
O result = iterator().next();

Original issue reported on code.google.com by [email protected] on 29 Oct 2012 at 1:15

Consider adding support to use lambda functions as attributes

(1)对象上的属性支持lambda,而当前使用匿名内部类的方式非常不爽,尤其Java8了,看到匿名内部类就有种本能的退缩感觉(The property on the object supports lambda, and the current use of anonymous inner classes is very uncomfortable, especially Java8 when seeiing the anonymous inner class has a kind of instinctive retreat)

eg:
public static final Attribute<Car, Integer> CAR_ID = new SimpleAttribute<Car, Integer>( "carId") {
@OverRide
public Integer getValue(Car car, QueryOptions queryOptions ) {
return car.carId;
}
};

该被类似如下简洁lambda代替:should be replaced by some followings:

public static final Attribute<Car, Integer> CAR_ID = new SimpleAttribute<Car,Integer>("carId", (car,queryOptions) => car.carId );

(2) 应该支持基本类型的属性,类似 Java8 中的 IntFunction,DoubleFunction 之类,原因是查询往往在大数据量中的应用,应该想尽一切办法消除自动装箱拆箱的性能损耗以达到最高的运行效率[Should support the primitives types of attributes, like DoubleFunction IntFunction similar in java8. The reason is that queries are often in a large amount of data application, CQEngine should try every possible way to eliminate the performance loss of the automatic boxing and unboxing in order to achieve the highest efficiency]

eg:

public static final Attribute<Car, Integer> CAR_ID = new SimpleAttribute<Car, Integer>( "carId") {
@OverRide
public Integer getValue(Car car, QueryOptions queryOptions ) {
return car.carId;
}
};

可使用如下:(Maybe use followings:)

public static final IntAttribute CAR_ID = new IntAttribute("carId"){
@OverRide
public int getValue(Car car, QueryOptions queryOptions ) {
//no boxing Integer here!
return car.carId;
}
};

and lambda support above:

public static final IntAttribute CAR_ID = new IntAttribute("carId", (car,queryOptions) => car.carId);

ReflectiveAttribute only works for public Members

What steps will reproduce the problem?
1. create a class with private members, accessible via getter and setters
2. Use the reflective Attribute to preform a search.
3. java.lang.NoSuchFieldException is thrown.

What is the expected output? What do you see instead?
Successful search on private member.

What version of the product are you using? On what operating system?
1.1.0

Please provide any additional information below.
The problem is caused by using getField("fieldName") on the object rather than 
getDeclaredField("fieldName"). 

I have included a patch to fix this issue.

Original issue reported on code.google.com by [email protected] on 16 Aug 2013 at 9:03

Attachments:

Set.add semantics is not perfect.


Collections.newSetFromMap() has a small problem in the way add() is handled,
if the element is already present by "equals()" semantics it will overwrite
it. Set.add() clearly says update only if not already present. This cannot
be done without extra cost unless the underlying map is ConcurrentMap,
because in ConcurrentMap we have putIfAbsent() operation to make this work.

I'm attaching a patch to fix this, feel free to take this. 

Original issue reported on code.google.com by [email protected] on 8 Nov 2013 at 10:05

Attachments:

Add support for SQL EXISTS and exists-based JOIN

Add support to query against foreign collections, similar to SQL EXISTS.

SELECT * From LocalCollection
WHERE EXISTS (
    SELECT * FROM ForeignCollection
    WHERE LocalCollection.localAttribute = ForeignCollection.foreignAttribute
)

This would enable joins between indexed collections.

Original issue reported on code.google.com by [email protected] on 27 Jan 2013 at 10:07

Recommendation on ID indexes

Hi,

We have structure ( Trade ) which has ID fields unique always.
We noticed if use Hash or Navigable index on ID field to push it into CqEngine 
collection the size of heap taken is doubled up, which is baffling in a way. 
SO basically adding a index where values are going to Unique is not working out 
well for us. DO you have any recommendation on which index to be used and how 
we can reduce the memory footprint here ?
The more indexes the heap size is getting lot worst, specially if the values 
are unique and spread is high.

Any recommendations are highly appreciated. 

Thanks,
Sandeep

Original issue reported on code.google.com by [email protected] on 15 Oct 2013 at 6:58

Add ReflectiveAttribute

Note to self: sometimes it might be useful to build an index on a field, or 
query the field, without defining an attribute programmatically.

Original issue reported on code.google.com by [email protected] on 4 Dec 2012 at 11:20

Upgrade to concurrent-trees 2.0

The concurrent-trees 2.0 library has lower memory usage and lower latency than 
1.0.

CQEngine should be updated to use the new version (minimal changes required).

Original issue reported on code.google.com by [email protected] on 24 Mar 2013 at 11:36

Add support for a STRICT_REPLACEMENT option in TransactionalIndexedCollection

TransactionalIndexedCollection.html seems to suggest that it is possible to replace objects atomically.

Specifically, I am looking for a Thread-safe compare-and-set style atomic interaction.

I had assumed that boolean update(Iterable<O> objectsToRemove, Iterable<O> objectsToAdd) would support this with the CAS semantics update(expected, update), but this doesn't appear to be the case. That is, I had assumed that update would abort the transaction if any of the removes or adds "failed".

Is there any way to atomically replace objects? Any help would be much appreciated.

Support wildcard queries

Wildcard support is being added to concurrent-trees: 
http://code.google.com/p/concurrent-trees/issues/detail?id=3

CQEngine should have an explicit way to perform queries with wildcards.

For reference, the following is a workaround to perform waldcard queries in 
CQEngine <= 1.0.3:

import static com.googlecode.cqengine.query.QueryFactory.*;
public class Wildcard {

   public static void main(String[] args) {
       IndexedCollection<String> collection = CQEngine.copyFrom(Arrays.asList("TEAM", "TEST", "TOAST", "T", "TT"));
       collection.addIndex(RadixTreeIndex.onAttribute(SELF));
       collection.addIndex(ReversedRadixTreeIndex.onAttribute(SELF));

       for (String match : retrieveWildcardMatches(collection, "T", "T")) { // ...wildcard query "T*T"
           System.out.println(match); // TOAST, TEST, TT
       }
   }

   public static ResultSet<String> retrieveWildcardMatches(IndexedCollection<String> collection, final String prefix, final String suffix) {
       ResultSet<String> candidates = collection.retrieve(and(startsWith(SELF, prefix), endsWith(SELF, suffix)));
       // Post-filter...
       return new FilteringResultSet<String>(candidates) {
           @Override
           public boolean isValid(String candidate) {
               return candidate.length() >= prefix.length() + suffix.length();
           }
       };
   }

   static Attribute<String, String> SELF = new SimpleAttribute<String, String>() {
       public String getValue(String object) { return object; }
   };
}

Original issue reported on code.google.com by [email protected] on 24 Mar 2013 at 11:40

Add listeners (observers) to IndexedCollection

From discussion in the forum: 
https://groups.google.com/forum/#!topic/cqengine-discuss/8sPccIElN7M

Should add an ObservableIndexedCollection, which can wrap another, and notify a 
given listener when objects are added and removed. 

This will be purely a wrapper so will not have any impact on applications not 
requiring this functionality.

Original issue reported on code.google.com by [email protected] on 25 Nov 2013 at 9:49

Find two java files

Hi, recently I download the source code, but, I did'nt found the files:

import com.googlecode.cqengine.query.parser.sql.grammar.SQLGrammarLexer;
import com.googlecode.cqengine.query.parser.sql.grammar.SQLGrammarParser;

In the java class:
com.googlecode.cqengine.query.parser.sql.SQLParser

Can you help me?

Thanks

FilteringIterator.hasNext advances iterator every time it is called.

I have attached a patch with the fix to FilteringIterator and an associated 
unit test.

What steps will reproduce the problem?

1. Return a ResultSet that will apply filtering.
2. Use the returned Iterator's hasNext() function several times.
3. Note that the value of next() is no longer the first value of the ResultSet.

What is the expected output? What do you see instead?

Calling hasNext() on an iterator should always return true if a call to next 
will return an object.  It should not advance the pointer as this will cause 
skipping of values.

What version of the product are you using? On what operating system?
1.2.2

Please provide any additional information below.

This was exposed by attempting to copy a ResultSet into a Guava immutable 
collection. They use hasNext() to verify the size of the collection and this 
was causing the iterator to skip values.  

Original issue reported on code.google.com by [email protected] on 26 Sep 2013 at 5:25

Attachments:

Support to order by combinations of attributes, ascending/descending

QueryFactory.orderBy and orderByDescending methods signature return type are 
not the specific implementation OrderByOption/DeduplicationOption but 
QueryOption.

This leads to use of instanceof operator when validating the Map dynamic 
population when some of the implementations (DeduplicationOption) are not 
desired.

By the way... thank you for publishing this great project. You saved me a lot 
of time!

Original issue reported on code.google.com by [email protected] on 8 May 2013 at 7:43

SelfAttribute broken in CQEngine 1.2.0

A regressions was introduced when reflection support was being refactored, 
which now prevents SelfAttributes from being declared.

SelfAttribute<String> attribute = new SelfAttribute<String>();

Produces:

java.lang.IllegalStateException: Attribute '<Unnamed attribute, class 
com.googlecode.cqengine.attribute.SelfAttribute>' is declared with invalid type 
parameters (class com.googlecode.cqengine.attribute.SelfAttribute)

In the meantime a workaround is to declare as a SimpleAttribute instead:

    static final Attribute<String, String> SELF = new SimpleAttribute<String, String>() {
        public String getValue(String object) { return object; }
    };

Original issue reported on code.google.com by [email protected] on 10 Sep 2013 at 9:57

Documentation for selective READ_COMMITTED transaction isolation using RW lock

CQEngine currently supports selective (per write, per query, or global) 
READ_COMMITTED transaction isolation, if the application takes care to 
demarcate its transactions using a ReadWriteLock.
This was discussed in the forum: 
https://groups.google.com/forum/#!topic/cqengine-discuss/9jIo0y5RDHA

Although it was discussed in the forum, the approach should be documented 
properly on a wiki page.

Original issue reported on code.google.com by [email protected] on 21 Dec 2013 at 2:28

Provide the way to determine how much memory used by index

As I can see here 
https://groups.google.com/forum/#!topic/cqengine-discuss/RX_ESsAKZqQ index can 
take a lot of memory. In provided example up to 40 times the size of the data.
It would be nice to have ability to detect how much memory gone where.
At least approximately.

Original issue reported on code.google.com by [email protected] on 15 Dec 2014 at 3:12

Auto-generate attributes

It would be nice to auto-generate the source code for SimpleAttributes and 
MultiValueAttributes using reflection automatically using reflection.

Note this would be different from defining attributes at runtime using 
reflection (using ReflectiveAttribute etc). Attributes generated here as source 
code, would not use reflection at runtime and would be as fast as hand-written 
attributes.

Original issue reported on code.google.com by [email protected] on 16 Sep 2013 at 11:03

Allow queries to be printed

From forum: https://groups.google.com/forum/#!topic/cqengine-discuss/xhpeTIH0uh0

It should be possible to print queries for debugging purposes.

toString should be implemented consistently across all Query objects.

Original issue reported on code.google.com by [email protected] on 27 Aug 2013 at 11:03

And.calcHashCode being performance Bottlneck

We make a huge number of queries while processing an http request. These 
queries are unique in nature, that they do not appear again. Their sub queries 
may appear again.

Where does the calcHashCode() of the main AND query being used?

query = and(q1, q2, q3, ... );

We do roughly 50-500 of these for every request, and And.calcHashCode() takes 
up majority of our server time.

Do you have any recommendations regarding minimizing this overhead?

Original issue reported on code.google.com by [email protected] on 28 Oct 2013 at 4:06

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.