Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License;
* you may not use this file except in compliance with the Elastic License.
*/

package org.elasticsearch.xpack.sql.qa.single_node;

import org.elasticsearch.xpack.sql.qa.jdbc.SysColumnsTestCase;

public class SysColumnsIT extends SysColumnsTestCase {

}

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
package org.elasticsearch.xpack.sql.type;

import org.elasticsearch.xpack.sql.SqlIllegalArgumentException;
import org.elasticsearch.xpack.sql.util.StringUtils;

import java.util.Objects;

Expand All @@ -25,6 +26,11 @@ public InvalidMappedField(String name, String errorMessage) {
this.errorMessage = errorMessage;
}

public InvalidMappedField(String name) {
super(name, DataType.UNSUPPORTED, emptyMap(), false);
this.errorMessage = StringUtils.EMPTY;
}

public String errorMessage() {
return errorMessage;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,4 +72,11 @@ public static <T> List<T> combine(Collection<? extends T> left, T... entries) {
}
return list;
}

public static int mapSize(int size) {
if (size < 2) {
return size + 1;
}
return (int) (size / 0.75f + 1f);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -315,8 +315,8 @@ public static IndexResolution merge(EsIndex... indices) {
}

public static List<EsIndex> separate(EsIndex... indices) {
return IndexResolver.separateMappings("*", null, Stream.of(indices).map(EsIndex::name).toArray(String[]::new),
fromMappings(indices));
return IndexResolver.separateMappings(null, Stream.of(indices).map(EsIndex::name).toArray(String[]::new),
fromMappings(indices), null);
}

public static Map<String, Map<String, FieldCapabilities>> fromMappings(EsIndex... indices) {
Expand Down