Commit graph

299 commits

Author SHA1 Message Date
Greg Burd
90e19907d2 Merge branch '2.0.15-SNAPSHOT' into develop 2017-08-10 16:10:31 -04:00
Greg Burd
cf2740337e Add 'Drafted' interface and extend the InsertOperation to recognize that so as to be able to persist the mutated set of keys only yet return a pojo with values matching the draft, not just the mutations.
Changed {in,up}sert() to return the instance of the object.
2017-08-10 16:06:31 -04:00
Greg Burd
8569eaa76f Add 'Drafted' interface and extend the InsertOperation to recognize that so as to be able to persist the mutated set of keys only yet return a pojo with values matching the draft, not just the mutations. 2017-08-10 13:09:34 -04:00
Greg Burd
a126607c09 Added check for mutated set so that the backingMap could contain all object values. The other option was to auto-refresh the instance's backing map when a getter is invoked for a valid property that isn't included in the backing map (which still may be handy/required for caching to work). 2017-08-09 16:20:38 -04:00
Greg Burd
871c8d0c90 Fix minor error. 2017-08-09 15:12:24 -04:00
Greg Burd
fa39908f4c Remove Integer/Enum conversion, it wasn't necessary. 2017-08-09 15:00:19 -04:00
Greg Burd
f008a33e53 Changed Zipkin API a bit, now requires a TraceContext rather than a Span before sync/async calls. 2017-08-09 10:22:59 -04:00
Greg Burd
b9600ac931 Fix Zipkin tracing logic. 2017-08-08 15:28:51 -04:00
Greg Burd
71e84da3bd Start plumbing for Dropwizard metrics and Zipkin tracing. Ensure proper bean value when working with enums. 2017-08-08 12:02:32 -04:00
Greg Burd
f4dbf34920 Remove Scala support and trim Future support at some point I'll re-introduce using Java 8 classes rather than Guava's or Scala's 2017-08-04 11:18:54 -04:00
Greg Burd
c42803b964 Return a Function on successful UnitOfWork.commit() so as to allow users to execute code post-commit iff that commit was successful. 2017-08-04 09:26:58 -04:00
Greg Burd
7497cf5a18 Add compatibility with Java 8 CompletableFuture converting our Guava-supplied ListenableFuture. 2017-08-03 15:38:13 -04:00
Greg Burd
b44c898682 Add the LOCAL_* consistency levels. Add a way to provide a default consistency level for all session operations. 2017-08-02 12:54:01 -04:00
Greg Burd
18cfc85f45 Move logic that filters out unset columns from INSERT statements into InsertOperations because we need to use the proxy implementation's ability to fetch default type-specific values in other places. This change also enables concrete implementations of mapped interfaces to implement MapExportable and use the same method to filter unset values. 2017-08-02 11:35:11 -04:00
Greg Burd
03567dc57e Enable partial updates using partial entity maps. 2017-08-01 12:48:14 -04:00
Greg Burd
de495ae0eb Fixed the embedded Cassandra server by using a newer version, no published artifact so had to include JAR file. Ran Facebook tool called 'infer' which was fairly clean (mvn clean; infer -- mvn package -Dmaven.test.skip=true), two minor potential resource leaks and one possible null pointer dereference 2017-07-28 11:44:48 -04:00
Greg Burd
715fb0e673 Helenus was the son of King Priam and Queen Hecuba of Troy, and the twin brother of the prophetess Cassandra. Like Cassandra, he was always right, but unlike her, others believed him. Seems like a good name for a layer to access DataStax, Apache, or ScyllaDB's implementations of the Cassandra database.
- move to 3.x DataStax drivers (NOTE, this broke the Casser.dsl() API a bit)
 - introduce UnitOfWork-style pseudo transactional scoping (WIP as of this commit)
 - introduce session and UnitOfWork scoped caches (WIP as of this commit)
 - add support for SASI-based secondary index types (such as case insensitive matching, etc.)
 - add support for Lucene-based secondary index types (WIP https://github.com/Stratio/cassandra-lucene-index)
 - update types for Java 8 (WIP)
 - add in Codahale/Dropwizard and Zipkin metrics/tracing support (WIP)
 - and a lot more...
2017-07-27 15:02:17 -04:00
Alex Shvid
13a2f5bffa update information about author 2016-07-04 10:24:04 -07:00
Albert Shift
c1f710584a refactor Timeuuid, add minOf and maxOf methods for Timeuuid 2015-09-12 20:35:24 -07:00
Albert Shift
071f6466ae use Scala Option and Stream in Scala future results 2015-06-23 08:34:20 -07:00
Albert Shift
ba416ba1ff correct java docs 2015-06-19 13:56:09 -07:00
Albert Shift
49b7c07ab2 add java doc comments to all annotations in mapping 2015-06-19 12:55:38 -07:00
Albert Shift
c1ca49fbea query syntax sugar fix in 'in()' operator 2015-06-14 14:07:11 -07:00
Albert Shift
66ccb0feb1 skeep annotations in package scaning process 2015-06-10 16:51:19 -07:00
Albert Shift
1eb3c17d6b support annotaiton on constraint annotation 2015-06-10 16:46:57 -07:00
Albert Shift
52c3f19ea2 add value validator implementation for simple types (does not support
collections and maps)
2015-06-09 23:18:42 -07:00
Albert Shift
c0b16c2db6 Add CasserValidator for property values 2015-06-09 14:55:57 -07:00
Albert Shift
49cb219849 parse contraint annotations and initilize validators 2015-06-09 13:23:25 -07:00
Albert Shift
9919fd9e25 implement common validators for constraints 2015-06-09 12:48:55 -07:00
Albert Shift
46a476a34f update comments in Constraints 2015-06-08 23:18:22 -07:00
Albert Shift
7e87bce918 rename annotation name 2015-06-08 21:52:18 -07:00
Albert Shift
3966640694 rename Constraint class to Constraints 2015-06-08 21:50:00 -07:00
Albert Shift
99db68d75c update Constraint java docs and annotations 2015-06-07 12:52:04 -07:00
Albert Shift
78d076768e Constraint name for the data integrity annotation 2015-06-07 12:35:33 -07:00
Albert Shift
fe3782bf10 check columns for UDT types as well as Tables 2015-06-07 00:24:31 -07:00
Albert Shift
a46421fcce addPackage test 2015-06-06 15:27:14 -07:00
Albert Shift
6e3a130279 add package of entities 2015-06-06 15:12:21 -07:00
Albert Shift
ba86534086 add java doc in Types annotations 2015-06-05 14:16:45 -07:00
Albert Shift
18ee6ab214 add Data annotations 2015-06-05 13:02:28 -07:00
Albert Shift
7f68e7a027 add single() method in SelectOperation 2015-06-03 13:29:33 -07:00
Albert Shift
a4260436e8 change version and add more scala future methods 2015-06-03 12:51:05 -07:00
Albert Shift
869fd0aae3 add scala 2.11 support 2015-06-03 12:22:22 -07:00
Albert Shift
323ce05162 removed Example.java, the file from what the project was started ;) 2015-04-27 20:50:16 -07:00
Albert Shift
5f5e99f26f add Casser.shutdown() method 2015-04-27 20:08:32 -07:00
Albert Shift
9453aef063 showValues setting for showCql in all operations 2015-04-27 17:42:52 -07:00
Albert Shift
4dd187ed77 rename register to singleton in Casser 2015-04-26 14:13:36 -07:00
Albert Shift
579785279f fix small bug on update schema 2015-04-24 23:07:44 -07:00
Albert Shift
14a771ca9c group converter packages by type 2015-04-23 00:12:39 -07:00
Albert Shift
6f9a9ed802 tuple collections converters and tests 2015-04-23 00:07:19 -07:00
Albert Shift
557e6c19d6 more fun with transformers, guava does not supports nulls for lists 2015-04-22 16:28:29 -07:00
Albert Shift
5ad93b2e78 refactor transformers in converters 2015-04-22 16:01:21 -07:00
Albert Shift
c6d0043aa6 optimize immutables for single entries 2015-04-22 13:49:48 -07:00
Albert Shift
2f2b43a529 implement rest udt map converters and cover by tests 2015-04-21 17:48:39 -07:00
Albert Shift
fdc7b27f7c UDTKeyMap convertion and test 2015-04-21 13:53:12 -07:00
Albert Shift
f7de3257c2 UDT tests decomposition 2015-04-20 22:50:40 -07:00
Albert Shift
46742cd2df add UDTList converters and tests 2015-04-20 22:37:01 -07:00
Albert Shift
ec36db0b5f implement UDTSet test and operations 2015-04-20 21:50:15 -07:00
Albert Shift
f59bf9ec2f Set and UDTSet converter 2015-04-18 11:28:20 -07:00
Albert Shift
153c7cc7bf refactoring and prepare for UDT collection tests 2015-04-17 21:54:29 -07:00
Albert Shift
7601fe1fdb counter integration test 2015-04-17 21:31:56 -07:00
Albert Shift
b16292d4bf allowFiltering in select operations 2015-04-17 21:15:22 -07:00
Albert Shift
3353d10976 static column test implementation 2015-04-17 21:10:09 -07:00
Albert Shift
3f127e3b9c write common tests for simple values 2015-04-17 17:55:38 -07:00
Albert Shift
f627eb9741 test collections and implement collection operations 2015-04-17 14:26:30 -07:00
Albert Shift
9b26dc67a4 additional tests for UDT values 2015-04-16 23:38:47 -07:00
Albert Shift
7703ad1892 add test no mapping for TupleValue type 2015-04-16 18:00:30 -07:00
Albert Shift
e884dc22e8 test inner tuples 2015-04-16 17:39:53 -07:00
Albert Shift
feaffda0ab update type annotations in tests 2015-04-16 17:28:25 -07:00
Albert Shift
895867f082 refactoring of the packages 2015-04-16 17:21:07 -07:00
Albert Shift
28b2186854 refactor tuples and mappers 2015-04-16 17:18:20 -07:00
Albert Shift
862804a225 rename types namespace from T to Types 2015-04-16 16:54:30 -07:00
Albert Shift
8230b574f4 refactor types 2015-04-16 16:52:07 -07:00
Albert Shift
71ecc85cfd rename column annotations name to volume 2015-04-16 16:14:42 -07:00
Albert Shift
d32416a905 continue refactoring for simple data types 2015-04-14 23:10:39 -07:00
Albert Shift
f4222cc3a6 java type mapping to DataType refactoring 2015-04-14 23:01:27 -07:00
Albert Shift
6fe8080db8 prepare code for javatype mapping refactoring 2015-04-14 21:39:33 -07:00
Albert Shift
8b6c201ef1 ordinal in columns became optional for cases where it is not important 2015-04-14 20:04:17 -07:00
Albert Shift
a9d9a7fa8c annotation per cassandra type 2015-04-14 12:47:32 -07:00
Albert Shift
84f04f9951 remove comments 2015-04-14 12:18:24 -07:00
Albert Shift
9f1b2bfe7c make ordinal optional only for Column, add validations 2015-04-14 11:58:46 -07:00
Albert Shift
49736b594e ordinal is required for each column 2015-04-14 11:35:57 -07:00
Albert Shift
182afb6619 refactoring 2015-04-14 10:34:05 -07:00
Albert Shift
7b2065c59a columns ordering refactoring 2015-04-14 10:32:47 -07:00
Albert Shift
e03bfeeb50 repackaging 2015-04-14 09:54:15 -07:00
Albert Shift
73733fdb06 add annotation StaticColumn 2015-04-14 09:49:05 -07:00
Albert Shift
88bacf02e0 fix build on Windows 2015-04-14 09:44:59 -07:00
Albert Shift
90e860a118 refactoring, remove dublicates 2015-04-13 22:08:09 -07:00
Albert Shift
3e91401d4a tuple mapping implementation 2015-04-13 22:00:38 -07:00
Albert Shift
018f9c3cf9 start tuple implementation 2015-04-13 18:24:00 -07:00
Albert Shift
bb3fe691ae Merge branch 'master' of https://github.com/noorq/casser.git
Conflicts:
	src/main/java/com/noorq/casser/mapping/ColumnInformation.java
2015-04-13 17:34:12 -07:00
Albert Shift
14bda7af4e internal refactoring 2015-04-13 17:33:03 -07:00
Albert Shift
7c37545f66 internal refactoring 2015-04-13 17:21:58 -07:00
Albert Shift
f5125c02f8 UDT collections schema support 2015-04-13 16:02:06 -07:00
Albert Shift
129562e4a8 Merge branch 'master' of https://github.com/noorq/casser.git
Conflicts:
	src/main/java/com/noorq/casser/mapping/CasserMappingProperty.java
	src/test/java/com/noorq/casser/test/integration/core/udtcollection/UDTCollectionTest.java
2015-04-13 13:04:03 -07:00
Albert Shift
3c7a06024a prepare for UDT collections implementation task 2015-04-13 13:00:25 -07:00
Albert Shift
b30d3f1b92 prepare for UDT collections implementation task 2015-04-09 23:30:56 -07:00
Albert Shift
00d309121f refactoring 2015-04-09 22:59:12 -07:00
Albert Shift
1af2c8c875 refactoring 2015-04-09 22:53:54 -07:00
Albert Shift
6a192499f8 refactoring 2015-04-09 22:32:49 -07:00
Albert Shift
402b086337 refactoring 2015-04-09 22:30:45 -07:00
Albert Shift
b5690bb843 refactoring 2015-04-09 22:27:42 -07:00
Albert Shift
6b50e86dde make casser as a central entity cache 2015-04-09 22:18:50 -07:00
Albert Shift
00a3e20a98 more flexible initialization of the mappingRepository 2015-04-09 20:56:22 -07:00
Albert Shift
4a309b10d0 singletons for all dsl support 2015-04-09 19:14:29 -07:00
Albert Shift
6e59ccdb29 integration test for CRUD operations for UDT values 2015-04-09 18:50:12 -07:00
Albert Shift
fce170d723 UserDefinedType creation in recursion 2015-04-09 17:35:03 -07:00
Albert Shift
e2e8bcabf3 initialize cassandra-unit only in static methods in integration tests 2015-04-09 14:45:51 -07:00
Albert Shift
bde9ffd7a0 support no mapping for UDTValue type 2015-04-09 14:28:54 -07:00
Albert Shift
05dc642c41 flexiable mapping with UDTValue 2015-04-09 13:57:23 -07:00
Albert Shift
b36875c2ab add other operations in UpdateOperation 2015-04-08 22:41:24 -07:00
Albert Shift
5e680701ab map put operation implementation 2015-04-08 22:01:51 -07:00
Albert Shift
c2a093ed97 start implementing collections 2015-04-08 18:10:45 -07:00
Albert Shift
6ec448f1cd implement entity mapping on select 2015-04-07 23:18:45 -07:00
Albert Shift
030f6e0be6 prepare for hierarchy intergration test 2015-04-04 20:29:35 -07:00
Albert Shift
113bd3cb07 support onlyIf conditions 2015-04-04 20:13:16 -07:00
Albert Shift
b70e8a348e added more options to staements 2015-04-04 19:49:55 -07:00
Albert Shift
a32d5609ba add options for common statement 2015-04-04 19:24:14 -07:00
Albert Shift
c69ef2b19c add synchronized protection in SessionInitializer in building 2015-04-03 17:06:04 -07:00
Albert Shift
e67bb3cd85 make CasserMappingRepository immutable for multi-threading env 2015-04-03 17:04:57 -07:00
Albert Shift
f5c990d18f make mapping entity and property multi-threading 2015-04-01 22:44:09 -07:00
Albert Shift
5e91f069ca update licenses in headers 2015-04-01 00:12:02 -07:00
Albert Shift
14d82ac475 prepared statements test 2015-04-01 00:10:33 -07:00
Albert Shift
cbec10d5f0 implement prepared statements 2015-03-31 23:33:09 -07:00
Albert Shift
fcaeb8fe8d add SecondaryIndexTest and classical insert operation support 2015-03-31 22:04:17 -07:00
Albert Shift
c585bc76d2 update and verify index support 2015-03-31 21:15:10 -07:00
Albert Shift
626c732a91 use IdentityName for column and index names 2015-03-30 22:52:33 -07:00
Albert Shift
7a87482546 use IdentityName for entities 2015-03-30 22:33:08 -07:00
Albert Shift
e40c40b49c refactor existing classes 2015-03-30 22:06:40 -07:00
Albert Shift
e7cd42577a add index annotation 2015-03-30 19:52:31 -07:00
Albert Shift
af811228d9 add a little sugar in code 2015-03-30 17:18:33 -07:00
Albert Shift
427cf4ab7a unification of tuple names and variables 2015-03-30 13:47:51 -07:00
Albert Shift
2abd7a9e10 rename packages 2015-03-30 12:49:44 -07:00
Albert Shift
6a9c07de8d implement selects for User Defined Types 2015-03-27 20:15:42 -07:00
Albert Shift
476dc4887c revert back dsl cache 2015-03-27 20:15:42 -07:00
Albert Shift
9e4377b9c0 implement user defined type reader and writer 2015-03-27 20:15:42 -07:00
Albert Shift
f74c0a106b create special package mapping.value for all column value
readers/writers
2015-03-27 20:15:42 -07:00
Albert Shift
454f33a82e fix simple user test 2015-03-27 20:15:42 -07:00
Albert Shift
e6dae633f7 remove dsl caching in Casser, no need it 2015-03-27 20:15:42 -07:00
Albert Shift
9afca8a957 refactoring and update readme document 2015-03-27 20:15:42 -07:00
Albert Shift
647cc9b4ea removed setter, keep only getters 2015-03-27 20:15:42 -07:00
Albert Shift
5c88f2d4e4 implement wrapper to replace Casser.pojo 2015-03-27 20:15:42 -07:00
Albert Shift
64d2d6fdd9 remove Setter class 2015-03-27 20:15:42 -07:00
Albert Shift
3a2daf2722 move getter to core package 2015-03-27 20:15:42 -07:00
Albert Shift
99ead051f0 add collections test 2015-03-27 20:15:42 -07:00
Albert Shift
82bbb6cde7 add instantiator interface set default reflection instantiators 2015-03-26 21:02:48 -07:00
Albert Shift
e59f98fb3d UDTValue converter for properties 2015-03-26 20:46:29 -07:00
Albert Shift
1812823e52 row column value provider optimization 2015-03-26 20:04:43 -07:00
Albert Shift
0543370b64 remove generics from CasserEntity and CasserProperty 2015-03-26 19:42:04 -07:00
Albert Shift
a6129ac239 fix the build 2015-03-25 23:09:52 -07:00
Albert Shift
e31f22ac2c async ListenableFuture for operations 2015-03-25 23:04:50 -07:00