diff options
author | Arne H Juul <arnej27959@users.noreply.github.com> | 2023-06-08 12:24:35 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-08 12:24:35 +0200 |
commit | 1f9fbce8103fc7330f706b2e29480f3f18c5169e (patch) | |
tree | 358f0fe13d77994c81b459a4d1003745186dec93 /config-model/src/main | |
parent | 2c7de524f66b86d694f09e673938cb8bf0828764 (diff) | |
parent | 13e465415ee572db48ba22f3fb1563b393ee7c30 (diff) |
Merge pull request #27340 from vespa-engine/arnej/only-index-command-for-indices
avoid having "index" command for fields without an index
Diffstat (limited to 'config-model/src/main')
-rw-r--r-- | config-model/src/main/java/com/yahoo/schema/derived/IndexInfo.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/config-model/src/main/java/com/yahoo/schema/derived/IndexInfo.java b/config-model/src/main/java/com/yahoo/schema/derived/IndexInfo.java index b2648aec88e..7d88985b2d5 100644 --- a/config-model/src/main/java/com/yahoo/schema/derived/IndexInfo.java +++ b/config-model/src/main/java/com/yahoo/schema/derived/IndexInfo.java @@ -133,7 +133,9 @@ public class IndexInfo extends Derived implements IndexInfoConfig.Producer { addIndexCommand(field.getName(), CMD_DEFAULT_POSITION); } - addIndexCommand(field, CMD_INDEX); // List the indices + for (var index : field.getIndices().values()) { + addIndexCommand(index.getName(), CMD_INDEX); // List the indices + } if (needLowerCase(field)) { addIndexCommand(field, CMD_LOWERCASE); |