Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
37f9710
6.4 updated x-pack API's
Mpdreamz Aug 15, 2018
52c96a0
6.4 new x-pack API's
Mpdreamz Aug 15, 2018
8e1e826
6.4 updated rest spec files
Mpdreamz Aug 15, 2018
a037e28
add patch file for indices.analyze.json in order to maintain backward…
Mpdreamz Aug 15, 2018
eda0b3b
Ran codegen against the updated 6.4 json rest spec
Mpdreamz Aug 15, 2018
22bec65
DummyProgram hack from master to make Test.Profiling build even if bu…
Mpdreamz Sep 20, 2018
b946675
update paket targets file
Mpdreamz Sep 20, 2018
63edd99
Move test.default.yaml over to 6.4
Mpdreamz Sep 20, 2018
e0d7e95
fix failing test due to https://github.com/elastic/elasticsearch/pull…
Mpdreamz Sep 20, 2018
9c212b5
painless execute api was set not to generate however we implemented t…
Mpdreamz Sep 20, 2018
f398f16
Allow API's to be renamed by using their rest-spec name
Mpdreamz Sep 20, 2018
ff792a2
explicit wrapped assert response exception rather then relying on Ass…
Mpdreamz Sep 21, 2018
f9637a8
duplicate inherited tests in base class hierarchy, this fixes a bug i…
Mpdreamz Sep 24, 2018
ee571a7
make sure PropertyTestsBase proxies inherited tests https://youtrack.…
Mpdreamz Sep 28, 2018
ae973dc
update to latest greatest Elastic.Xunit
Mpdreamz Oct 1, 2018
81f29b6
Fixed multisearch integration not including routing key for project l…
Mpdreamz Oct 1, 2018
47997f3
build.bat cluster now picks up the seed from test(.default).yaml, thi…
Mpdreamz Oct 2, 2018
a59a00a
Add support for the SQL APIs (#3414)
Mpdreamz Oct 16, 2018
559367b
obsolete copy_settings as of 6.4 (#3416)
Mpdreamz Oct 16, 2018
6c4f69f
Add support for Moving Function aggregation (#3419)
Mpdreamz Oct 16, 2018
6461c8f
Refactor Analysis tests (#3424)
Mpdreamz Oct 17, 2018
ef88c30
Add Multiplexer Token Filter (#3425)
Mpdreamz Oct 17, 2018
fdb05e8
Add support for Weighted Avg Aggregation (#3417)
Mpdreamz Oct 17, 2018
6db6095
Add support for Remove Duplicates token filter (#3426)
Mpdreamz Oct 17, 2018
2009094
Fix generated envelope coordinates
russcam Oct 17, 2018
8a57b8f
add split_queries_on_whitespace to keyword property mappings (#3431)
Mpdreamz Oct 17, 2018
4e3543b
Add support for index_phrases (#3433)
Mpdreamz Oct 17, 2018
d03dacc
Add support for alias property mapping (#3434)
Mpdreamz Oct 17, 2018
64bf26c
Update KeywordPropertyTests to remove unneeded index creation
russcam Oct 17, 2018
9ab4384
Add support for the char_group tokenizer (#3427)
Mpdreamz Oct 17, 2018
1adc417
Add lenient to synonym and synonym_graph token filters (#3428)
Mpdreamz Oct 17, 2018
f7100fd
Add support for ignore_unmapped on geo sorts (#3436)
Mpdreamz Oct 17, 2018
7f99a91
return user on watch record (#3445)
Mpdreamz Oct 17, 2018
13867d0
Parse buckets key on ip range aggregation (#3446)
Mpdreamz Oct 17, 2018
7d78767
Support 2nd level field collapsing (#3444)
Mpdreamz Oct 17, 2018
98a3943
Feature/alias is write index (#3447)
Mpdreamz Oct 17, 2018
657481c
Allow Processors tested and guarded in isolation with a SkipVersion (…
Mpdreamz Oct 17, 2018
31bb3c6
add mode to keep_types token filter (#3429)
Mpdreamz Oct 17, 2018
ae5ae5b
Allow context to be specified on the painless execute API (#3435)
Mpdreamz Oct 17, 2018
ee4096e
Add ignore_missing to the remove processor (#3441)
Mpdreamz Oct 17, 2018
cdfcc2c
Add uuid to indices stats (#3437)
Mpdreamz Oct 17, 2018
2130ddf
Add cluster_uuid to root of the cluster_state response (#3443)
Mpdreamz Oct 17, 2018
c7e51cb
Add support for nori plugin (#3430)
Mpdreamz Oct 17, 2018
b3e286f
Add KeyValueProcessor tests and add support for trimming properties (…
Mpdreamz Oct 17, 2018
577888a
add support for the bytes processor (#3440)
Mpdreamz Oct 17, 2018
d48dc4e
Add support for indexed_chars_field on the AttachmentProcessor (#3442)
Mpdreamz Oct 17, 2018
f7712ff
add support for missing_bucket on Composite Aggregation (#3420)
Mpdreamz Oct 18, 2018
4cb05c0
Add support for Rollup APIs (#3448)
Mpdreamz Oct 18, 2018
84d77b6
Generate APIs from 6.4 branch
russcam Oct 18, 2018
fb05345
Fix XML comments and documentation structure
russcam Oct 18, 2018
e204fd3
Correct spelling and inherit documentation for BulkAll
russcam Oct 18, 2018
011300d
Include document substitution
russcam Oct 18, 2018
4501da2
Dispose CancellationTokenSource
russcam Oct 18, 2018
d62e095
Fix compiler warnings
russcam Oct 18, 2018
01591c5
Regenerate documentation
russcam Oct 18, 2018
f521129
Fix integration tests
russcam Oct 18, 2018
936835d
More integration test fixes
russcam Oct 18, 2018
df209f9
Use CallIsolatedValue for OpaqueId header
russcam Oct 18, 2018
e2e402c
Merge branch '6.x' into 6.4
russcam Oct 18, 2018
05b91a8
Move OpaqueId assertion into ExpectResponse
russcam Oct 18, 2018
7898e9c
Make ListTasks the target call for OpaqueId
russcam Oct 18, 2018
2ec5850
Fix OpaqueId unit tests
russcam Oct 18, 2018
589433a
Comment out assertion that all tasks must have OpaqueId header
russcam Oct 18, 2018
ab5cc0d
Update source file links in documentation
russcam Oct 18, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 2 additions & 1 deletion .paket/Paket.Restore.targets
Original file line number Diff line number Diff line change
Expand Up @@ -144,11 +144,12 @@
<PackageName>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[0])</PackageName>
<PackageVersion>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[1])</PackageVersion>
<AllPrivateAssets>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[4])</AllPrivateAssets>
<CopyLocal>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[5])</CopyLocal>
</PaketReferencesFileLinesInfo>
<PackageReference Include="%(PaketReferencesFileLinesInfo.PackageName)">
<Version>%(PaketReferencesFileLinesInfo.PackageVersion)</Version>
<PrivateAssets Condition=" ('%(PaketReferencesFileLinesInfo.AllPrivateAssets)' == 'true') Or ('$(PackAsTool)' == 'true') ">All</PrivateAssets>
<ExcludeAssets Condition="%(PaketReferencesFileLinesInfo.AllPrivateAssets) == 'exclude'">runtime</ExcludeAssets>
<ExcludeAssets Condition="%(PaketReferencesFileLinesInfo.CopyLocal) == 'false'">runtime</ExcludeAssets>
<Publish Condition=" '$(PackAsTool)' == 'true' ">true</Publish>
</PackageReference>
</ItemGroup>
Expand Down
1 change: 1 addition & 0 deletions build/scripts/Commandline.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ NOTE: both the `test` and `integrate` targets can be suffixed with `-all` to for
Execution hints can be provided anywhere on the command line
- skiptests : skip running tests as part of the target chain
- skipdocs : skip generating documentation
- docs:<B> : the branch name B to use when generating documentation
- seed:<N> : provide a seed to run the tests with.
- random:<K><:B> : sets random K to bool B if if B is omitted will default to true
K can be: sourceserializer, typedkeys or oldconnection (only valid on windows)
Expand Down
15 changes: 12 additions & 3 deletions build/scripts/Targets.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ open Commandline
open Differ
open Differ.Differ
open Fake.IO
open Octokit

Commandline.parse()

Expand Down Expand Up @@ -107,14 +108,22 @@ Target "Cluster" <| fun _ ->
let clusterVersion = getBuildParam "clusterVersion"
let testsProjectDirectory = Path.Combine(Path.GetFullPath(Paths.Output("Tests.ClusterLauncher")), "netcoreapp2.1")
let tempDir = Path.Combine(Path.GetTempPath(), Path.GetRandomFileName());

let sourceDir = Paths.Source("Tests/Tests.Configuration");
let defaultYaml = Path.Combine(sourceDir, "tests.default.yaml");
let userYaml = Path.Combine(sourceDir, "tests.yaml");
let e f = File.Exists f;
match ((e userYaml), (e defaultYaml)) with
| (true, _) -> setProcessEnvironVar "NEST_YAML_FILE" (Path.GetFullPath(userYaml))
| (_, true) -> setProcessEnvironVar "NEST_YAML_FILE" (Path.GetFullPath(defaultYaml))
| _ -> ignore()

Shell.copyDir tempDir testsProjectDirectory (fun s -> true)
trace testsProjectDirectory
trace tempDir
let command = sprintf "%s %s" clusterName clusterVersion
DotNetCli.RunCommand(fun p ->
{ p with
WorkingDir = tempDir;
TimeOut = TimeSpan.FromMinutes(60.)
TimeOut = TimeSpan.FromMinutes(120.)
}) (sprintf "%s %s" (Path.Combine(tempDir, "Tests.ClusterLauncher.dll")) command)

Shell.deleteDir tempDir
Expand Down
10 changes: 9 additions & 1 deletion docs/aggregations.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
////
IMPORTANT NOTE
==============
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/master/src/Tests/aggregations.asciidoc.
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/master/src/Tests/Tests/aggregations.asciidoc.
If you wish to submit a PR for any spelling mistakes, typos or grammatical errors for this file,
please modify the original csharp file found at the link and submit the PR with that change. Thanks!
////
Expand Down Expand Up @@ -62,6 +62,8 @@ The values are typically extracted from the fields of the document (using the fi

* <<value-count-aggregation-usage,Value Count Aggregation Usage>>

* <<weighted-average-aggregation-usage,Weighted Average Aggregation Usage>>

See the Elasticsearch documentation on {ref_current}/search-aggregations-metrics.html[Metric aggregations] for more details.

:includes-from-dirs: aggregations/metric
Expand Down Expand Up @@ -94,6 +96,8 @@ include::aggregations/metric/top-hits/top-hits-aggregation-usage.asciidoc[]

include::aggregations/metric/value-count/value-count-aggregation-usage.asciidoc[]

include::aggregations/metric/weighted-average/weighted-average-aggregation-usage.asciidoc[]

[[bucket-aggregations]]
== Bucket Aggregations

Expand Down Expand Up @@ -233,6 +237,8 @@ There are many different types of pipeline aggregation, each computing different

* <<moving-average-simple-aggregation-usage,Moving Average Simple Aggregation Usage>>

* <<moving-function-aggregation-usage,Moving Function Aggregation Usage>>

* <<percentiles-bucket-aggregation-usage,Percentiles Bucket Aggregation Usage>>

* <<serial-differencing-aggregation-usage,Serial Differencing Aggregation Usage>>
Expand Down Expand Up @@ -273,6 +279,8 @@ include::aggregations/pipeline/moving-average/moving-average-linear-aggregation-

include::aggregations/pipeline/moving-average/moving-average-simple-aggregation-usage.asciidoc[]

include::aggregations/pipeline/moving-function/moving-function-aggregation-usage.asciidoc[]

include::aggregations/pipeline/percentiles-bucket/percentiles-bucket-aggregation-usage.asciidoc[]

include::aggregations/pipeline/serial-differencing/serial-differencing-aggregation-usage.asciidoc[]
Expand Down
2 changes: 1 addition & 1 deletion docs/aggregations/aggregation-meta-usage.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
////
IMPORTANT NOTE
==============
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Aggregations/AggregationMetaUsageTests.cs.
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Tests/Aggregations/AggregationMetaUsageTests.cs.
If you wish to submit a PR for any spelling mistakes, typos or grammatical errors for this file,
please modify the original csharp file found at the link and submit the PR with that change. Thanks!
////
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
////
IMPORTANT NOTE
==============
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Aggregations/Bucket/AdjacencyMatrix/AdjacencyMatrixUsageTests.cs.
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Tests/Aggregations/Bucket/AdjacencyMatrix/AdjacencyMatrixUsageTests.cs.
If you wish to submit a PR for any spelling mistakes, typos or grammatical errors for this file,
please modify the original csharp file found at the link and submit the PR with that change. Thanks!
////
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
////
IMPORTANT NOTE
==============
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Aggregations/Bucket/Children/ChildrenAggregationUsageTests.cs.
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Tests/Aggregations/Bucket/Children/ChildrenAggregationUsageTests.cs.
If you wish to submit a PR for any spelling mistakes, typos or grammatical errors for this file,
please modify the original csharp file found at the link and submit the PR with that change. Thanks!
////
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
////
IMPORTANT NOTE
==============
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Aggregations/Bucket/Composite/CompositeAggregationUsageTests.cs.
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Tests/Aggregations/Bucket/Composite/CompositeAggregationUsageTests.cs.
If you wish to submit a PR for any spelling mistakes, typos or grammatical errors for this file,
please modify the original csharp file found at the link and submit the PR with that change. Thanks!
////
Expand Down Expand Up @@ -145,7 +145,7 @@ new CompositeAggregation("my_buckets")

==== Handling Responses

Each Composite aggregation bucket key is an `CompositeKey`, a specialized
Each Composite aggregation bucket key is a `CompositeKey` type, a specialized
`IReadOnlyDictionary<string, object>` type with methods to convert values to supported types

[source,csharp]
Expand Down Expand Up @@ -185,3 +185,133 @@ foreach (var item in composite.Buckets)
}
----

[float]
=== Missing buckets

By default documents without a value for a given source are ignored.
It is possible to include them in the response by setting missing_bucket to `true` (defaults to `false`):

NOTE: Only available in Elasticsearch 6.4.0+

==== Fluent DSL example

[source,csharp]
----
a => a
.Composite("my_buckets", date => date
.Sources(s => s
.Terms("branches", t => t
.Field(f => f.Branches.Suffix("keyword"))
.MissingBucket()
.Order(SortOrder.Ascending)
)
)
.Aggregations(childAggs => childAggs
.Nested("project_tags", n => n
.Path(p => p.Tags)
.Aggregations(nestedAggs => nestedAggs
.Terms("tags", avg => avg.Field(p => p.Tags.First().Name))
)
)
)
)
----

==== Object Initializer syntax example

[source,csharp]
----
new CompositeAggregation("my_buckets")
{
Sources = new List<ICompositeAggregationSource>
{
new TermsCompositeAggregationSource("branches")
{
Field = Infer.Field<Project>(f => f.Branches.Suffix("keyword")),
MissingBucket = true,
Order = SortOrder.Ascending
}
},
Aggregations = new NestedAggregation("project_tags")
{
Path = Field<Project>(p => p.Tags),
Aggregations = new TermsAggregation("tags")
{
Field = Field<Project>(p => p.Tags.First().Name)
}
}
}
----

[source,javascript]
.Example json output
----
{
"my_buckets": {
"composite": {
"sources": [
{
"branches": {
"terms": {
"field": "branches.keyword",
"order": "asc",
"missing_bucket": true
}
}
}
]
},
"aggs": {
"project_tags": {
"nested": {
"path": "tags"
},
"aggs": {
"tags": {
"terms": {
"field": "tags.name"
}
}
}
}
}
}
}
----

==== Handling Responses

Each Composite aggregation bucket key is an `CompositeKey`, a specialized
`IReadOnlyDictionary<string, object>` type with methods to convert values to supported types

[source,csharp]
----
response.ShouldBeValid();

var composite = response.Aggregations.Composite("my_buckets");
composite.Should().NotBeNull();
composite.Buckets.Should().NotBeNullOrEmpty();
composite.AfterKey.Should().NotBeNull();

if (TestConfiguration.Instance.InRange(">=6.3.0"))
composite.AfterKey.Should().HaveCount(1).And.ContainKeys("branches");

var i = 0;
foreach (var item in composite.Buckets)
{
var key = item.Key;
key.Should().NotBeNull();

key.TryGetValue("branches", out string branches).Should().BeTrue("expected to find 'branches' in composite bucket");
if (i == 0) branches.Should().BeNull("First key should be null as we expect to have some projects with no branches");
else branches.Should().NotBeNullOrEmpty();

var nested = item.Nested("project_tags");
nested.Should().NotBeNull();

var nestedTerms = nested.Terms("tags");
nestedTerms.Buckets.Count.Should().BeGreaterThan(0);
i++;
}
----

Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
////
IMPORTANT NOTE
==============
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Aggregations/Bucket/DateHistogram/DateHistogramAggregationUsageTests.cs.
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Tests/Aggregations/Bucket/DateHistogram/DateHistogramAggregationUsageTests.cs.
If you wish to submit a PR for any spelling mistakes, typos or grammatical errors for this file,
please modify the original csharp file found at the link and submit the PR with that change. Thanks!
////
Expand Down Expand Up @@ -114,14 +114,12 @@ new DateHistogramAggregation("projects_started_per_month")
}
----

=== Handling responses
==== Handling responses

The `AggregateDictionary found on `.Aggregations` on `ISearchResponse<T>` has several helper methods
so we can fetch our aggregation results easily in the correct type.
<<handling-aggregate-response, Be sure to read more about these helper methods>>

==== Handling Responses

[source,csharp]
----
response.ShouldBeValid();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
////
IMPORTANT NOTE
==============
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Aggregations/Bucket/DateRange/DateRangeAggregationUsageTests.cs.
This file has been generated from https://github.com/elastic/elasticsearch-net/tree/6.x/src/Tests/Tests/Aggregations/Bucket/DateRange/DateRangeAggregationUsageTests.cs.
If you wish to submit a PR for any spelling mistakes, typos or grammatical errors for this file,
please modify the original csharp file found at the link and submit the PR with that change. Thanks!
////
Expand Down Expand Up @@ -93,14 +93,12 @@ new DateRangeAggregation("projects_date_ranges")
}
----

=== Handling Responses
==== Handling Responses

The `AggregateDictionary found on `.Aggregations` on `ISearchResponse<T>` has several helper methods
so we can fetch our aggregation results easily in the correct type.
<<handling-aggregate-response, Be sure to read more about these helper methods>>

==== Handling Responses

[source,csharp]
----
response.ShouldBeValid();
Expand Down
Loading