This repository has been archived by the owner on May 27, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 171
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'branch-3.9' into branch-3.8
# Conflicts: # .jenkins.yml # CHANGELOG.md # builder/pom.xml # doc/documentation.rst # plugin/pom.xml # plugin/src/main/java/com/stratio/cassandra/lucene/common/GeoTransformation.java # plugin/src/main/java/com/stratio/cassandra/lucene/index/NoIDFSimilarity.java # plugin/src/main/java/com/stratio/cassandra/lucene/schema/Schema.java # plugin/src/main/java/com/stratio/cassandra/lucene/schema/analysis/SnowballAnalyzerBuilder.java # plugin/src/main/java/com/stratio/cassandra/lucene/schema/analysis/SnowballFilter.java # plugin/src/main/java/com/stratio/cassandra/lucene/schema/mapping/Mapper.java # plugin/src/main/java/com/stratio/cassandra/lucene/util/BlockingExecutor.java # plugin/src/main/scala/com/stratio/cassandra/lucene/Index.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexException.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexOptions.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexPagingState.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexQueryHandler.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexService.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexServiceMBean.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexServiceSkinny.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexServiceWide.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexWriter.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexWriterSkinny.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/IndexWriterWide.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/column/Column.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/column/Columns.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/column/ColumnsMapper.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/index/DocumentIterator.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/index/FSIndex.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/index/NoIDFSimilarity.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/index/RAMIndex.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/index/TokenLengthAnalyzer.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/util/SimplePartitionIterator.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/util/TaskQueue.scala # plugin/src/main/scala/com/stratio/cassandra/lucene/util/Tracing.scala # plugin/src/test/scala/com/stratio/cassandra/lucene/IndexOptionsTest.scala # plugin/src/test/scala/com/stratio/cassandra/lucene/column/ColumnTest.scala # plugin/src/test/scala/com/stratio/cassandra/lucene/column/ColumnsMapperTest.scala # plugin/src/test/scala/com/stratio/cassandra/lucene/index/FSIndexTest.scala # pom.xml # testsAT/pom.xml # testsAT/src/test/java/com/stratio/cassandra/lucene/testsAT/udt/CheckNonFrozenUDTIT.java # testsAT/src/test/java/com/stratio/cassandra/lucene/testsAT/udt/UDTPartialUpdateIT.java # testsAT/src/test/java/com/stratio/cassandra/lucene/testsAT/util/CassandraUtils.java
- Loading branch information
Showing
168 changed files
with
3,640 additions
and
2,581 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
@Library('libpipelines@feature/multibranch') _ | ||
|
||
hose { | ||
EMAIL = 'cassandra' | ||
MODULE = 'cassandra-lucene-index' | ||
DEVTIMEOUT = 50 | ||
RELEASETIMEOUT = 30 | ||
FOSS = true | ||
REPOSITORY = 'cassandra-lucene-index' | ||
LANG = 'java' | ||
PKGMODULES = ['plugin'] | ||
PKGMODULESNAMES = ['stratio-cassandra-lucene-index'] | ||
DEBARCH = 'all' | ||
RPMARCH = 'noarch' | ||
EXPOSED_PORTS = [9042, 7199, 8000] | ||
|
||
PARALLELIZE_AT = true | ||
|
||
ATSERVICES = [ | ||
['CASSANDRA': [ | ||
'image': 'stratio/cassandra-lucene-index:%%VERSION', | ||
'volumes':[ | ||
'jts:1.14.0'], | ||
'env': [ | ||
'MAX_HEAP=256M', | ||
'START_JOLOKIA=true', | ||
'JOLOKIA_OPTS="port=8000,host=$(hostname --ip)"'], | ||
'sleep': 10]], | ||
] | ||
|
||
ATPARAMETERS = """ | ||
| -Dit.host=%%CASSANDRA | ||
| -Dit.monitor_service=jolokia | ||
| -Dit.monitor_services_url=%%CASSANDRA:8000 | ||
| -DJACOCO_SERVER=%%CASSANDRA | ||
| -Dit-embedded=false""" | ||
|
||
DEV = { config -> | ||
|
||
doCompile(config) | ||
doUT(config) | ||
doPackage(config) | ||
|
||
parallel(DOC: { | ||
doDoc(config) | ||
}, QC: { | ||
doStaticAnalysis(config) | ||
}, DEPLOY: { | ||
doDeploy(config) | ||
}, DOCKER : { | ||
doDocker(config) | ||
}, failFast: config.FAILFAST) | ||
|
||
doAT(config) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
58 changes: 58 additions & 0 deletions
58
builder/src/main/java/com/stratio/cassandra/lucene/builder/index/Partitioner.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
/* | ||
* Copyright (C) 2014 Stratio (http://stratio.com) | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package com.stratio.cassandra.lucene.builder.index; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
import com.fasterxml.jackson.annotation.JsonSubTypes; | ||
import com.fasterxml.jackson.annotation.JsonTypeInfo; | ||
import com.stratio.cassandra.lucene.builder.JSONBuilder; | ||
import com.stratio.cassandra.lucene.builder.index.Partitioner.*; | ||
|
||
/** | ||
* An index partitioner to split the index in multiple partitions. | ||
* | ||
* Index partitioning is useful to speed up some searches to the detriment of others, depending on the implementation. | ||
* It is also useful to overcome the Lucene's hard limit of 2147483519 documents per index. | ||
* | ||
* @author Andres de la Pena {@literal <[email protected]>} | ||
*/ | ||
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "type", defaultImpl = None.class) | ||
@JsonSubTypes({@JsonSubTypes.Type(value = None.class, name = "none"), | ||
@JsonSubTypes.Type(value = OnToken.class, name = "token")}) | ||
public abstract class Partitioner extends JSONBuilder { | ||
|
||
/** | ||
* {@link Partitioner} with no action, equivalent to not defining a partitioner. | ||
*/ | ||
public static class None extends Partitioner { | ||
} | ||
|
||
/** | ||
* {@link Partitioner} based on the Cassandra's partitioning token. | ||
* | ||
* Partitioning on token guarantees a good load balancing between partitions while speeding up partition-directed | ||
* searches to the detriment of token range searches. | ||
*/ | ||
public static class OnToken extends Partitioner { | ||
|
||
@JsonProperty("partitions") | ||
public final int partitions; | ||
|
||
public OnToken(int partitions) { | ||
this.partitions = partitions; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.