code stringlengths 23 201k | docstring stringlengths 17 96.2k | func_name stringlengths 0 235 | language stringclasses 1
value | repo stringlengths 8 72 | path stringlengths 11 317 | url stringlengths 57 377 | license stringclasses 7
values |
|---|---|---|---|---|---|---|---|
@Override
public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
this.context = applicationContext;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setApplicationContext | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@BeforeEach
public void before() {
indexNameProvider.increment();
operations.indexOps(SampleEntity.class).createWithMapping();
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | before | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Test
@Order(java.lang.Integer.MAX_VALUE)
void cleanup() {
operations.indexOps(IndexCoordinates.of(indexNameProvider.getPrefix() + "*")).delete();
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | cleanup | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Test
public void bootstrapsRepository() {
assertThat(repository).isNotNull();
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | bootstrapsRepository | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Test
public void shouldScanSelectedPackage() {
// given
// when
String[] beanNamesForType = context.getBeanNamesForType(ElasticsearchRepository.class);
// then
assertThat(beanNamesForType).containsExactlyInAnyOrder("sampleElasticsearchRepository",
"sampleUUIDKeyedElasticsearchRepository");
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | shouldScanSelectedPackage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Test
public void hasNotNestedRepository() {
assertThat(nestedRepository).isNull();
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | hasNotNestedRepository | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public String getId() {
return id;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setId(@Nullable String id) {
this.id = id;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public String getType() {
return type;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getType | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setType(@Nullable String type) {
this.type = type;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setType | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public String getMessage() {
return message;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getMessage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setMessage(@Nullable String message) {
this.message = message;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setMessage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public int getRate() {
return rate;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getRate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setRate(int rate) {
this.rate = rate;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setRate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public java.lang.@Nullable Double getScriptedRate() {
return scriptedRate;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getScriptedRate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setScriptedRate(java.lang.@Nullable Double scriptedRate) {
this.scriptedRate = scriptedRate;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setScriptedRate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public boolean isAvailable() {
return available;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | isAvailable | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setAvailable(boolean available) {
this.available = available;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setAvailable | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public String getHighlightedMessage() {
return highlightedMessage;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getHighlightedMessage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setHighlightedMessage(@Nullable String highlightedMessage) {
this.highlightedMessage = highlightedMessage;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setHighlightedMessage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public GeoPoint getLocation() {
return location;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getLocation | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setLocation(@Nullable GeoPoint location) {
this.location = location;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setLocation | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public java.lang.@Nullable Long getVersion() {
return version;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getVersion | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setVersion(java.lang.@Nullable Long version) {
this.version = version;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setVersion | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public UUID getId() {
return id;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setId(@Nullable UUID id) {
this.id = id;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public String getType() {
return type;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getType | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setType(@Nullable String type) {
this.type = type;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setType | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public String getMessage() {
return message;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getMessage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setMessage(@Nullable String message) {
this.message = message;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setMessage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public int getRate() {
return rate;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getRate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setRate(int rate) {
this.rate = rate;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setRate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public java.lang.@Nullable Long getScriptedRate() {
return scriptedRate;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getScriptedRate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setScriptedRate(java.lang.@Nullable Long scriptedRate) {
this.scriptedRate = scriptedRate;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setScriptedRate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public boolean isAvailable() {
return available;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | isAvailable | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setAvailable(boolean available) {
this.available = available;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setAvailable | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public String getHighlightedMessage() {
return highlightedMessage;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getHighlightedMessage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setHighlightedMessage(@Nullable String highlightedMessage) {
this.highlightedMessage = highlightedMessage;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setHighlightedMessage | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Nullable
public GeoPoint getLocation() {
return location;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getLocation | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setLocation(@Nullable GeoPoint location) {
this.location = location;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setLocation | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public java.lang.@Nullable Long getVersion() {
return version;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | getVersion | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
public void setVersion(java.lang.@Nullable Long version) {
this.version = version;
} | @author Rizwan Idrees
@author Mohsin Husen
@author Kevin Leturc
@author Gad Akuka
@author Peter-Josef Meisch | setVersion | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/config/notnested/EnableRepositoriesIntegrationTests.java | Apache-2.0 |
@Bean
IndexNameProvider indexNameProvider() {
return new IndexNameProvider("integration");
} | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | indexNameProvider | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Test // #2263
public void shouldSortResultsBySortOptions() {
List<IndexQuery> indexQueries = new ArrayList<>();
indexQueries.add(buildIndex(SampleEntity.builder().id("1").message("ab xz").build()));
indexQueries.add(buildIndex(SampleEntity.builder().id("2").message("bc").build()));
indexQueries.add(buildInd... | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | shouldSortResultsBySortOptions | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected Query queryWithIds(String... ids) {
return Queries.queryWithIds(ids);
} | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | queryWithIds | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected Query getTermQuery(String field, String value) {
return NativeQuery.builder().withQuery(termQueryAsQuery(field, value)).build();
} | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getTermQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected BaseQueryBuilder<?, ?> getBuilderWithMatchAllQuery() {
return Queries.getBuilderWithMatchAllQuery();
} | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getBuilderWithMatchAllQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected BaseQueryBuilder<?, ?> getBuilderWithMatchQuery(String field, String value) {
return NativeQuery.builder().withQuery(matchQueryAsQuery(field, value, null, null));
} | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getBuilderWithMatchQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected BaseQueryBuilder<?, ?> getBuilderWithTermQuery(String field, String value) {
return NativeQuery.builder().withQuery(termQueryAsQuery(field, value));
} | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getBuilderWithTermQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected BaseQueryBuilder<?, ?> getBuilderWithWildcardQuery(String field, String value) {
return NativeQuery.builder().withQuery(wildcardQueryAsQuery(field, value));
} | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getBuilderWithWildcardQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected Query getBoolQueryWithWildcardsFirstMustSecondShouldAndMinScore(String firstField, String firstValue,
String secondField, String secondValue, float minScore) {
return NativeQuery.builder().withQuery(q -> q //
.bool(BoolQuery.of(b -> b //
.must(m -> m.wildcard(w1 -> w1.field(firstFie... | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getBoolQueryWithWildcardsFirstMustSecondShouldAndMinScore | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected Query getQueryWithCollapse(String collapseField, @Nullable String innerHits, @Nullable Integer size) {
return NativeQuery.builder() //
.withQuery(matchAllQueryAsQuery()) //
.withFieldCollapse(FieldCollapse.of(fc -> {
fc.field(collapseField);
if (innerHits != null) {
fc.in... | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getQueryWithCollapse | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected Query getMatchAllQueryWithFilterForId(String id) {
return NativeQuery.builder() //
.withQuery(matchAllQueryAsQuery()) //
.withFilter(termQueryAsQuery("id", id)) //
.build();
} | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getMatchAllQueryWithFilterForId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected Query getQueryForParentId(String type, String id, @Nullable String route) {
NativeQueryBuilder queryBuilder = NativeQuery.builder() //
.withQuery(qb -> qb //
.parentId(p -> p.type(type).id(id)) //
);
if (route != null) {
queryBuilder.withRoute(route);
}
return queryBuild... | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getQueryForParentId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected Query getMatchAllQueryWithIncludesAndInlineExpressionScript(@Nullable String includes, String fieldName,
String script, Map<String, Object> params) {
NativeQueryBuilder nativeQueryBuilder = NativeQuery.builder().withQuery(matchAllQueryAsQuery());
if (includes != null) {
nativeQueryBuild... | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getMatchAllQueryWithIncludesAndInlineExpressionScript | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
@Override
protected Query getQueryWithRescorer() {
return NativeQuery.builder()
.withQuery(q -> q
.bool(b -> b
.filter(f -> f.exists(e -> e.field("rate")))
.should(s -> s.term(t -> t.field("message").value("message")))))
.withRescorerQuery(
new RescorerQuery(NativeQuery.builder()... | @author Farid Faoudi
@author Sascha Woo
@since 4.4 | getQueryWithRescorer | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchELCIntegrationTests.java | Apache-2.0 |
private Query queryWithIds(Collection<String> ids) {
return queryWithIds(ids.toArray(new String[ids.size()]));
} | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | queryWithIds | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
protected Query getMatchAllQueryWithInlineExpressionScript(String fieldName, String script,
Map<String, java.lang.Object> params) {
return getMatchAllQueryWithIncludesAndInlineExpressionScript(null, fieldName, script, params);
} | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | getMatchAllQueryWithInlineExpressionScript | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // #2304
public void shouldThrowDataAccessExceptionIfDocumentDoesNotExistWhileDoingPartialUpdateByEntity() {
// given
String documentId = nextIdAsString();
String messageBeforeUpdate = "some test message";
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message(messageBeforeUpdate)
... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldThrowDataAccessExceptionIfDocumentDoesNotExistWhileDoingPartialUpdateByEntity | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // #2405
public void shouldNotIgnoreIdFromIndexQuery() {
String indexName = indexNameProvider.indexName();
IndexCoordinates indexCoordinates = IndexCoordinates.of(indexName);
SampleEntity object1 = SampleEntity.builder().id("objectId1").message("objectMessage1").build();
SampleEntity object2 = SampleEnt... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldNotIgnoreIdFromIndexQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldThrowDataAccessExceptionIfDocumentDoesNotExistWhileDoingPartialUpdate() {
org.springframework.data.elasticsearch.core.document.Document document = org.springframework.data.elasticsearch.core.document.Document
.create();
UpdateQuery updateQuery = UpdateQuery.builder(nextIdAsString()).wi... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldThrowDataAccessExceptionIfDocumentDoesNotExistWhileDoingPartialUpdate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-106
public void shouldReturnCountForGivenCriteriaQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEnt... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnCountForGivenCriteriaQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldReturnCountForGivenSearchQuery() {
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
operations.index(in... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnCountForGivenSearchQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-722
public void shouldReturnObjectForGivenId() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
ope... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnObjectForGivenId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-52, #1678
public void shouldReturnObjectsForGivenIdsUsingMultiGet() {
// given
// first document
String documentId = nextIdAsString();
SampleEntity sampleEntity1 = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
// second docum... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnObjectsForGivenIdsUsingMultiGet | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-791, #1678
public void shouldReturnNullObjectForNotExistingIdUsingMultiGet() {
// given
// first document
String documentId = nextIdAsString();
SampleEntity sampleEntity1 = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
// sec... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnNullObjectForNotExistingIdUsingMultiGet | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // #1678
@DisplayName("should return failure in multiget result")
void shouldReturnFailureInMultigetResult() {
Query query = queryWithIds("42");
List<MultiGetItem<SampleEntity>> sampleEntities = operations.multiGet(query, SampleEntity.class,
IndexCoordinates.of("not-existing-index"));
// then
asse... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnFailureInMultigetResult | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-52, #1678
public void shouldReturnObjectsForGivenIdsUsingMultiGetWithFields() {
// given
// first document
String documentId = nextIdAsString();
SampleEntity sampleEntity1 = SampleEntity.builder().id(documentId).message("some message").type("type1")
.version(System.currentTimeMillis()).bui... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnObjectsForGivenIdsUsingMultiGetWithFields | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldReturnSearchHitsForGivenSearchQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
op... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnSearchHitsForGivenSearchQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-595
public void shouldReturnSearchHitsUsingLocalPreferenceForGivenSearchQuery() {
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuer... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnSearchHitsUsingLocalPreferenceForGivenSearchQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-595
public void shouldThrowExceptionWhenInvalidPreferenceForSearchQuery() {
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(samp... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldThrowExceptionWhenInvalidPreferenceForSearchQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-422 - Add support for IndicesOptions in search queries
public void shouldPassIndicesOptionsForGivenSearchQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).bui... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldPassIndicesOptionsForGivenSearchQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldDoBulkIndex() {
// given
List<IndexQuery> indexQueries = new ArrayList<>();
// first document
String documentId = nextIdAsString();
SampleEntity sampleEntity1 = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
// seco... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDoBulkIndex | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // #2362
@DisplayName("should do bulk index into different indices")
void shouldDoBulkIndexIntoDifferentIndices() {
var indexName = indexNameProvider.indexName();
var documentId1 = "1";
var sampleEntity1 = SampleEntity.builder().id(documentId1).message("some message").build();
var indexQuery1 = new Ind... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDoBulkIndexIntoDifferentIndices | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldDoBulkUpdate() {
// given
String documentId = nextIdAsString();
String messageBeforeUpdate = "some test message";
String messageAfterUpdate = "test message";
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message(messageBeforeUpdate)
.version(System.currentTim... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDoBulkUpdate | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldDeleteDocumentForGivenId() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
operations.in... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDeleteDocumentForGivenId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldDeleteEntityForGivenId() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
operations.inde... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDeleteEntityForGivenId | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldDeleteDocumentForGivenQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
operations... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDeleteDocumentForGivenQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-547
public void shouldDeleteAcrossIndex() {
operations.indexOps(IndexCoordinates.of(MULTI_INDEX_ALL)).delete();
operations.indexOps(IndexCoordinates.of(MULTI_INDEX_1_NAME)).create();
operations.indexOps(IndexCoordinates.of(MULTI_INDEX_2_NAME)).create();
SampleEntity sampleEntity = SampleEntit... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDeleteAcrossIndex | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-547
public void shouldDeleteAcrossIndexWhenNoMatchingDataPresent() {
// given
SampleEntity sampleEntity = SampleEntity.builder() //
.message("positive") //
.version(System.currentTimeMillis()) //
.build();
IndexQuery idxQuery1 = new IndexQueryBuilder().withId(nextIdAsString()).withO... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDeleteAcrossIndexWhenNoMatchingDataPresent | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldFilterSearchResultsForGivenFilter() {
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
operations.index... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldFilterSearchResultsForGivenFilter | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldSortResultsGivenSortCriteria() {
// given
List<IndexQuery> indexQueries = new ArrayList<>();
// first document
String documentId = nextIdAsString();
SampleEntity sampleEntity1 = SampleEntity.builder().id(documentId).message("abc").rate(10)
.version(System.currentTimeMillis()).bui... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldSortResultsGivenSortCriteria | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldSortResultsGivenMultipleSortCriteria() {
SampleEntity sampleEntity1 = SampleEntity.builder().id(nextIdAsString()).message("abc").rate(10)
.version(System.currentTimeMillis()).build();
SampleEntity sampleEntity2 = SampleEntity.builder().id(nextIdAsString()).message("xyz").rate(5)
.v... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldSortResultsGivenMultipleSortCriteria | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-312
public void shouldSortResultsGivenNullFirstSortCriteria() {
// given
List<IndexQuery> indexQueries;
// first document
String documentId = nextIdAsString();
SampleEntity sampleEntity1 = SampleEntity.builder().id(documentId).message("abc").rate(15)
.version(System.currentTimeMillis())... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldSortResultsGivenNullFirstSortCriteria | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-312
public void shouldSortResultsGivenNullLastSortCriteria() {
// given
List<IndexQuery> indexQueries;
// first document
String documentId = nextIdAsString();
SampleEntity sampleEntity1 = SampleEntity.builder().id(documentId).message("abc").rate(15)
.version(System.currentTimeMillis()).... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldSortResultsGivenNullLastSortCriteria | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-467, DATAES-657
public void shouldSortResultsByScore() {
// given
List<SampleEntity> entities = Arrays.asList( //
SampleEntity.builder().id("1").message("green").build(), //
SampleEntity.builder().id("2").message("yellow green").build(), //
SampleEntity.builder().id("3").message("blue"... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldSortResultsByScore | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldExecuteStringQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
operations.index(in... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldExecuteStringQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldUseScriptedFields() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = new SampleEntity();
sampleEntity.setId(documentId);
sampleEntity.setRate(2);
sampleEntity.setMessage("some message");
sampleEntity.setVersion(System.currentTimeMillis());
IndexQuer... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldUseScriptedFields | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldReturnPageableResultsGivenStringQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnPageableResultsGivenStringQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldReturnSortedResultsGivenStringQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = new SampleEntity();
sampleEntity.setId(documentId);
sampleEntity.setMessage("some message");
sampleEntity.setVersion(System.currentTimeMillis());
IndexQuery indexQu... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnSortedResultsGivenStringQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldReturnObjectMatchingGivenStringQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("some message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
o... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnObjectMatchingGivenStringQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldCreateIndexGivenEntityClass() {
// when
// creation is done in setup method
Settings setting = indexOperations.getSettings().flatten();
// then
assertThat(setting.get("index.number_of_shards")).isEqualTo("1");
assertThat(setting.get("index.number_of_replicas")).isEqualTo("0");
} | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldCreateIndexGivenEntityClass | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldExecuteGivenCriteriaQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("test message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
operations.i... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldExecuteGivenCriteriaQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldDeleteGivenCriteriaQuery() {
// given
String documentId = nextIdAsString();
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message("test message")
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIndexQuery(sampleEntity);
operations.in... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldDeleteGivenCriteriaQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldReturnFieldsBasedOnSourceFilter() {
// given
String documentId = nextIdAsString();
String message = "some test message";
SampleEntity sampleEntity = SampleEntity.builder().id(documentId).message(message)
.version(System.currentTimeMillis()).build();
IndexQuery indexQuery = getIn... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnFieldsBasedOnSourceFilter | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldReturnSimilarResultsGivenMoreLikeThisQuery() {
// given
String sampleMessage = "So we build a web site or an application and want to add search to it, "
+ "and then it hits us: getting search working is hard. We want our search solution to be fast,"
+ " we want a painless setup and... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnSimilarResultsGivenMoreLikeThisQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // #1787
@DisplayName("should use Pageable on MoreLikeThis queries")
void shouldUsePageableOnMoreLikeThisQueries() {
String sampleMessage = "So we build a web site or an application and want to add search to it, "
+ "and then it hits us: getting search working is hard. We want our search solution to be f... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldUsePageableOnMoreLikeThisQueries | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-167
public void shouldReturnResultsWithScanAndScrollForGivenCriteriaQuery() {
// given
List<IndexQuery> entities = createSampleEntitiesWithMessage("Test message", 30);
// when
operations.bulkIndex(entities, IndexCoordinates.of(indexNameProvider.indexName()));
// then
CriteriaQuery criter... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnResultsWithScanAndScrollForGivenCriteriaQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test
public void shouldReturnResultsWithScanAndScrollForGivenSearchQuery() {
// given
List<IndexQuery> entities = createSampleEntitiesWithMessage("Test message", 30);
// when
operations.bulkIndex(entities, IndexCoordinates.of(indexNameProvider.indexName()));
// then
Query searchQuery = operations.matc... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnResultsWithScanAndScrollForGivenSearchQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
@Test // DATAES-167
public void shouldReturnResultsWithScanAndScrollForSpecifiedFieldsForCriteriaQuery() {
// given
List<IndexQuery> entities = createSampleEntitiesWithMessage("Test message", 30);
// when
operations.bulkIndex(entities, IndexCoordinates.of(indexNameProvider.indexName()));
// then
Criteri... | @return a {@link BaseQueryBuilder} that allready has a matchAll query set | shouldReturnResultsWithScanAndScrollForSpecifiedFieldsForCriteriaQuery | java | spring-projects/spring-data-elasticsearch | src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | https://github.com/spring-projects/spring-data-elasticsearch/blob/master/src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchIntegrationTests.java | Apache-2.0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.