Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[7.17] Remove deprecated include_type_name parameter from es_archiver #122962

Merged
merged 38 commits into from
Jan 15, 2022
Merged
Show file tree
Hide file tree
Changes from 25 commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
dfdcacd
remove deprecated include_type_name parameter
Jan 13, 2022
57bd623
update mappings
Jan 13, 2022
94279ac
fix jest test
Jan 13, 2022
1078ad6
fix auditbeat archives
Jan 13, 2022
3206ffc
fix disable_features archive
Jan 13, 2022
43728fa
fix copy_to_space_archive
Jan 13, 2022
4017fe2
fix saved_objects/spaces mappings
Jan 13, 2022
e7fd736
fix global_search archive
Jan 13, 2022
5275cb5
fix another global_search archive
Jan 13, 2022
f66a2e6
fix feature control archives
Jan 13, 2022
b34d69d
fix saved_objects/spaces archive
Jan 13, 2022
4e6b33c
fix so_management archive
Jan 13, 2022
7dbb086
Remove _type from reporting es archives
rudolf Jan 13, 2022
11c73d8
(try to?) fix the SOT archives
pgayvallet Jan 14, 2022
bd50467
Remove _type from another reporting es archive
rudolf Jan 14, 2022
2ea06ae
Fix another so tagging archive
rudolf Jan 14, 2022
cd8784b
uncomment SOT tests
Jan 14, 2022
396121a
Merge remote-tracking branch 'upstream/7.17' into no-include_type_name
Jan 14, 2022
db32d11
Merge remote-tracking branch 'upstream/no-include_type_name' into no-…
Jan 14, 2022
478d450
Allow esArchiver 7.x to work with 8.x system indices
rudolf Jan 14, 2022
cdd1310
Try to fix no handler found for uri when creating default space
rudolf Jan 14, 2022
bac827e
remove deprecated type param from es client call
Jan 14, 2022
a836a50
Make index_patterns api_integration test compatible with 8
rudolf Jan 14, 2022
5f16a8a
Remove mapping field types not supported in 8.0
rudolf Jan 14, 2022
c4ffe3a
Merge branch 'test-8.0-fixes' into no-include_type_name
rudolf Jan 14, 2022
7f1a59c
Merge remote-tracking branch 'upstream/no-include_type_name' into no-…
Jan 14, 2022
15cc59e
fix x-pack/test/functional/apps/maps/documents_source/docvalue_fields.js
Jan 14, 2022
ae8bd8a
remove deprecated params
Jan 14, 2022
78cf2fe
fix failed tests
Jan 14, 2022
5a1c774
make test compatible with 7.x and 8.x
Jan 14, 2022
1cc0f75
Merge branch '7.17' into no-include_type_name
kibanamachine Jan 14, 2022
53bf605
skip input control range
TinaHeiligers Jan 14, 2022
429bfbd
Skip failing functional tests
TinaHeiligers Jan 14, 2022
b756a53
[Reporting] Update CSV Export tests (#123093)
tsullivan Jan 14, 2022
6451c74
Fix tests in _handle_version_conflict
TinaHeiligers Jan 15, 2022
450e1cd
Merge remote-tracking branch 'upstream/no-include_type_name' into no-…
Jan 15, 2022
8e5f470
Revert "[Reporting] Update CSV Export tests (#123093)"
Jan 15, 2022
fdfcf73
fix a few other failures
Jan 15, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion packages/kbn-es-archiver/src/actions/load.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,15 +85,17 @@ export async function loadAction({
progress.deactivate();
const result = stats.toJSON();

const indicesWithDocs: string[] = [];
for (const [index, { docs }] of Object.entries(result)) {
if (docs && docs.indexed > 0) {
log.info('[%s] Indexed %d docs into %j', name, docs.indexed, index);
indicesWithDocs.push(index);
}
}

await client.indices.refresh(
{
index: '_all',
index: indicesWithDocs.join(','),
allow_no_indices: true,
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,6 @@ describe('esArchiver: createCreateIndexStream()', () => {

sinon.assert.calledWith(client.indices.create as sinon.SinonSpy, {
index: 'index',
include_type_name: false,
body: {
settings: undefined,
mappings: undefined,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,6 @@ export function createCreateIndexStream({

async function handleIndex(record: DocRecord) {
const { index, settings, mappings, aliases } = record.value;

// Determine if the mapping belongs to a pre-7.0 instance, for BWC tests, mainly
const isPre7Mapping = !!mappings && Object.keys(mappings).length > 0 && !mappings.properties;
const isKibanaTaskManager = index.startsWith('.kibana_task_manager');
const isKibana = index.startsWith('.kibana') && !isKibanaTaskManager;

Expand All @@ -79,7 +76,6 @@ export function createCreateIndexStream({
await client.indices.create(
{
index,
include_type_name: isPre7Mapping,
body: {
settings,
mappings,
Expand Down
1 change: 0 additions & 1 deletion packages/kbn-es-archiver/src/lib/indices/kibana_index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ export async function createDefaultSpace({
await client.create(
{
index,
type: '_doc',
id: 'space:default',
refresh: 'wait_for',
body: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ export async function getDocNotFoundError(es) {
try {
await es.get({
index: 'basic_index',
type: 'type',
id: '1234',
});
} catch (err) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,7 @@
"map": {
"properties": {
"bounds": {
"type": "geo_shape",
"tree": "quadtree"
"type": "geo_shape"
},
"description": {
"type": "text"
Expand Down Expand Up @@ -418,4 +417,4 @@
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,7 @@
"map": {
"properties": {
"bounds": {
"type": "geo_shape",
"tree": "quadtree"
"type": "geo_shape"
},
"description": {
"type": "text"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,7 @@
"map": {
"properties": {
"bounds": {
"type": "geo_shape",
"tree": "quadtree"
"type": "geo_shape"
},
"description": {
"type": "text"
Expand Down
Binary file not shown.
Loading