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

Implement an Order data model #189

Merged
merged 21 commits into from
Dec 23, 2024
Merged

Conversation

f-galland
Copy link
Member

Description

This PR implements a data model for orders using XContent.

Issues Resolved

Closes #183

@f-galland f-galland marked this pull request as ready for review December 18, 2024 21:01
@f-galland f-galland requested a review from a team as a code owner December 18, 2024 21:01
@QU3B1M
Copy link
Member

QU3B1M commented Dec 19, 2024

On my system, it fails when trying to run or build the plugin

./gradlew build
=======================================
OpenSearch Build Hamster says Hello!
  Gradle Version        : 8.10
  OS Info               : Mac OS X 15.2 (aarch64)
  JDK Version           : 21 (Amazon Corretto JDK)
  JAVA_HOME             : /Users/quebim_wz/Library/Java/JavaVirtualMachines/corretto-21.0.4/Contents/Home
  Random Testing Seed   : 87B25F7233690325
  In FIPS 140 mode      : false
=======================================

...

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':compileJava'.
> Compilation failed; see the compiler error output for details.

* Try:
> Run with --info option to get more log output.
> Run with --scan to get full insights.

BUILD FAILED in 512ms
2 actionable tasks: 1 executed, 1 up-to-date

Full trace
 ./gradlew build
=======================================
OpenSearch Build Hamster says Hello!
  Gradle Version        : 8.10
  OS Info               : Mac OS X 15.2 (aarch64)
  JDK Version           : 21 (Amazon Corretto JDK)
  JAVA_HOME             : /Users/quebim_wz/Library/Java/JavaVirtualMachines/corretto-21.0.4/Contents/Home
  Random Testing Seed   : 87B25F7233690325
  In FIPS 140 mode      : false
=======================================

> Task :compileJava FAILED
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:166: error: illegal start of type
        } catch (IOException e) {
          ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:166: error: ';' expected
        } catch (IOException e) {
                              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:176: error: class, interface, or enum expected
    private SimpleHttpResponse deliverOrders(String orders) {
            ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:178: error: class, interface, or enum expected
        try {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:179: error: class, interface, or enum expected
            final PluginSettings settings = PluginSettings.getInstance();
                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:180: error: class, interface, or enum expected
            final URI host =
                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:183: error: class, interface, or enum expected
            response =
            ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:187: error: class, interface, or enum expected
                                        final AuthHttpRestClient httpClient =
                                              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:189: error: class, interface, or enum expected
                                        return httpClient.post(host, orders, null);
                                        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:190: error: class, interface, or enum expected
                                    });
                                    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:191: error: class, interface, or enum expected
        } catch (URISyntaxException e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:193: error: class, interface, or enum expected
        } catch (Exception e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:195: error: class, interface, or enum expected
        }
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:197: error: class, interface, or enum expected
    }
    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:206: error: class, interface, or enum expected
    private void setSentStatus(SearchHit hit, Status status) throws IllegalStateException {
            ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:207: error: class, interface, or enum expected
        final Map<String, Object> commandMap =
              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:211: error: <identifier> expected
                        Map.class);
                                 ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:212: error: class, interface, or enum expected
        commandMap.put(Command.STATUS, status);
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:213: error: class, interface, or enum expected
        hit.getSourceAsMap()
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:215: error: class, interface, or enum expected
        final IndexRequest indexRequest =
              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:220: error: class, interface, or enum expected
        this.client
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:223: error: class, interface, or enum expected
    }
    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:233: error: class, interface, or enum expected
    public SearchResponse pitQuery(PointInTimeBuilder pointInTimeBuilder, Object[] searchAfter)
           ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:235: error: class, interface, or enum expected
        final SearchRequest searchRequest = new SearchRequest(CommandManagerPlugin.INDEX_NAME);
              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:236: error: class, interface, or enum expected
        final TermQueryBuilder termQueryBuilder =
              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:238: error: class, interface, or enum expected
        final TimeValue timeout =
              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:240: error: class, interface, or enum expected
        this.searchSourceBuilder
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:246: error: class, interface, or enum expected
        if (this.searchSourceBuilder.sorts() == null) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:248: error: class, interface, or enum expected
        }
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:251: error: class, interface, or enum expected
        }
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:253: error: class, interface, or enum expected
        return this.client.search(searchRequest).actionGet(timeout);
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:254: error: class, interface, or enum expected
    }
    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:257: error: class, interface, or enum expected
    public void run() {
           ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:259: error: class, interface, or enum expected
        long consumableHits = 0L;
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:260: error: class, interface, or enum expected
        boolean firstPage = true;
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:261: error: class, interface, or enum expected
        final PointInTimeBuilder pointInTimeBuilder = buildPit();
              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:262: error: class, interface, or enum expected
        try {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:268: error: class, interface, or enum expected
                if (firstPage) {
                ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:270: error: class, interface, or enum expected
                    consumableHits = totalHits();
                    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:271: error: class, interface, or enum expected
                    firstPage = false;
                    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:272: error: class, interface, or enum expected
                }
                ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:275: error: class, interface, or enum expected
                    consumableHits -= getPageLength();
                    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:276: error: class, interface, or enum expected
                }
                ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:278: error: class, interface, or enum expected
        } catch (ArrayIndexOutOfBoundsException e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:280: error: class, interface, or enum expected
        } catch (IllegalStateException e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:282: error: class, interface, or enum expected
        } catch (Exception e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:284: error: class, interface, or enum expected
            e.printStackTrace();
            ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:285: error: class, interface, or enum expected
        }
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:293: error: class, interface, or enum expected
    }
    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:301: error: class, interface, or enum expected
        } else {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:303: error: class, interface, or enum expected
        }
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:317: error: class, interface, or enum expected
        }
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:319: error: class, interface, or enum expected
            final List<SearchHit> hits = Arrays.asList(searchResponse.getHits().getHits());
                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:320: error: class, interface, or enum expected
            if (hits.isEmpty()) {
            ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:322: error: class, interface, or enum expected
                return Optional.empty();
                ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:323: error: class, interface, or enum expected
            }
            ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:325: error: class, interface, or enum expected
        } catch (NullPointerException | NoSuchElementException e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:327: error: class, interface, or enum expected
            return Optional.empty();
            ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:328: error: class, interface, or enum expected
        }
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:337: error: class, interface, or enum expected
        final CompletableFuture<CreatePitResponse> future = new CompletableFuture<>();
              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:338: error: class, interface, or enum expected
        final ActionListener<CreatePitResponse> actionListener =
              ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:341: error: class, interface, or enum expected
                    public void onResponse(CreatePitResponse createPitResponse) {
                           ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:343: error: class, interface, or enum expected
                    }
                    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:346: error: class, interface, or enum expected
                    public void onFailure(Exception e) {
                           ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:348: error: class, interface, or enum expected
                        future.completeExceptionally(e);
                        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:349: error: class, interface, or enum expected
                    }
                    ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:351: error: class, interface, or enum expected
        this.client.createPit(
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:357: error: class, interface, or enum expected
        try {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:359: error: class, interface, or enum expected
        } catch (CancellationException e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:361: error: class, interface, or enum expected
        } catch (ExecutionException e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:363: error: class, interface, or enum expected
        } catch (InterruptedException e) {
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:365: error: class, interface, or enum expected
        }
        ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:367: error: class, interface, or enum expected
    }
    ^
73 errors

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':compileJava'.
> Compilation failed; see the compiler error output for details.

* Try:
> Run with --info option to get more log output.
> Run with --scan to get full insights.

BUILD FAILED in 512ms
2 actionable tasks: 1 executed, 1 up-to-date

@f-galland
Copy link
Member Author

After merging master, I introduced an error with a try-catch block within SearchThread.

The error is fixed, but it seems we also brought in an error from master that precludes indexing of new commands:

[2024-12-19T08:09:06,229][INFO ][c.w.c.r.RestPostCommandAction] [integTest-0] Received POST /_plugins/_command_manager/commands request id [2] from host [127.0.0.1:9200]
[2024-12-19T08:09:06,230][ERROR][c.w.c.r.RestPostCommandAction] [integTest-0] Token does not match VALUE_STRING
[2024-12-19T08:09:06,230][INFO ][c.w.c.i.CommandIndex     ] [integTest-0] Index template index-template-commands already exists. Skipping creation.
[2024-12-19T08:09:06,231][ERROR][c.w.c.i.CommandIndex     ] [integTest-0] Error indexing commands with bulk due to Validation Failed: 1: no requests added;

@f-galland
Copy link
Member Author

The issue was being caused by a bad json being generated by VSCode's openapi plugin. Indexing and delivering orders seems to work as expected.

@QU3B1M
Copy link
Member

QU3B1M commented Dec 19, 2024

The command-manager plugin starts and builds correctly

Full start logs
./gradlew run  
=======================================
OpenSearch Build Hamster says Hello!
  Gradle Version        : 8.10
  OS Info               : Mac OS X 15.2 (aarch64)
  JDK Version           : 21 (Amazon Corretto JDK)
  JAVA_HOME             : /Users/quebim_wz/Library/Java/JavaVirtualMachines/corretto-21.0.4/Contents/Home
  Random Testing Seed   : C4C90EB7BDD56C57
  In FIPS 140 mode      : false
=======================================

> Task :run
[2024-12-19T13:29:02.486065Z] [BUILD] Configuring custom cluster specific distro directory: /Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/distro/2.18.0-ARCHIVE
[2024-12-19T13:29:02.643879Z] [BUILD] Copying additional config files from distro [/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/distro/2.18.0-ARCHIVE/config/jvm.options.d, /Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/distro/2.18.0-ARCHIVE/config/opensearch.yml, /Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/distro/2.18.0-ARCHIVE/config/log4j2.properties, /Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/distro/2.18.0-ARCHIVE/config/jvm.options]
[2024-12-19T13:29:02.645821Z] [BUILD] installing 2 plugins in a single transaction
[2024-12-19T13:29:03.630544Z] [BUILD] installed plugins
[2024-12-19T13:29:03.630683Z] [BUILD] Creating opensearch keystore with password set to []
[2024-12-19T13:29:04.168050Z] [BUILD] Adding 3 keystore settings and 0 keystore files
[2024-12-19T13:29:05.795819Z] [BUILD] Starting OpenSearch process
[2024-12-19T10:29:07,680][INFO ][o.o.n.Node               ] [integTest-0] version[2.18.0-SNAPSHOT], pid[67541], build[tar/99a9a81da366173b0c2b963b26ea92e15ef34547/2024-10-31T19:11:01.423491Z], OS[Mac OS X/15.2/aarch64], JVM[Amazon.com Inc./OpenJDK 64-Bit Server VM/21.0.4/21.0.4+7-LTS]
[2024-12-19T10:29:07,681][INFO ][o.o.n.Node               ] [integTest-0] JVM home [/Users/quebim_wz/Library/Java/JavaVirtualMachines/corretto-21.0.4/Contents/Home], using bundled JDK/JRE [false]
[2024-12-19T10:29:07,681][INFO ][o.o.n.Node               ] [integTest-0] JVM arguments [-Xshare:auto, -Dopensearch.networkaddress.cache.ttl=60, -Dopensearch.networkaddress.cache.negative.ttl=10, -XX:+AlwaysPreTouch, -Xss1m, -Djava.awt.headless=true, -Dfile.encoding=UTF-8, -Djna.nosys=true, -XX:-OmitStackTraceInFastThrow, -XX:+ShowCodeDetailsInExceptionMessages, -Dio.netty.noUnsafe=true, -Dio.netty.noKeySetOptimization=true, -Dio.netty.recycler.maxCapacityPerThread=0, -Dio.netty.allocator.numDirectArenas=0, -Dlog4j.shutdownHookEnabled=false, -Dlog4j2.disable.jmx=true, -Djava.security.manager=allow, -Djava.locale.providers=SPI,COMPAT, -Xms1g, -Xmx1g, -XX:+UseG1GC, -XX:G1ReservePercent=25, -XX:InitiatingHeapOccupancyPercent=30, -Djava.io.tmpdir=/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/tmp, -XX:+HeapDumpOnOutOfMemoryError, -XX:HeapDumpPath=logs, -XX:ErrorFile=logs/hs_err_pid%p.log, -Xlog:gc*,gc+age=trace,safepoint:file=logs/gc.log:utctime,pid,tags:filecount=32,filesize=64m, -Djava.security.manager=allow, --add-modules=jdk.incubator.vector, -Djava.util.concurrent.ForkJoinPool.common.threadFactory=org.opensearch.secure_sm.SecuredForkJoinWorkerThreadFactory, -Xms512m, -Xmx512m, -ea, -esa, -XX:MaxDirectMemorySize=268435456, -Dopensearch.path.home=/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/distro/2.18.0-ARCHIVE, -Dopensearch.path.conf=/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/config, -Dopensearch.distribution.type=tar, -Dopensearch.bundled_jdk=true]
[2024-12-19T10:29:07,682][WARN ][o.o.n.Node               ] [integTest-0] version [2.18.0-SNAPSHOT] is a pre-release version of OpenSearch and is not suitable for production
[2024-12-19T10:29:07,774][INFO ][o.a.l.i.v.PanamaVectorizationProvider] [integTest-0] Java vector incubator API enabled; uses preferredBitSize=128
[2024-12-19T10:29:08,253][INFO ][o.o.i.r.ReindexPlugin    ] [integTest-0] ReindexPlugin reloadSPI called
[2024-12-19T10:29:08,254][INFO ][o.o.i.r.ReindexPlugin    ] [integTest-0] Unable to find any implementation for RemoteReindexExtension
[2024-12-19T10:29:08,257][INFO ][c.w.c.CommandManagerPlugin] [integTest-0] getJobParser() executed
[2024-12-19T10:29:08,258][INFO ][c.w.c.CommandManagerPlugin] [integTest-0] getJobRunner() executed
[2024-12-19T10:29:08,258][INFO ][o.o.j.JobSchedulerPlugin ] [integTest-0] Loaded scheduler extension: command_manager_scheduler_extension, index: .scheduled-commands
[2024-12-19T10:29:08,261][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [aggs-matrix-stats]
[2024-12-19T10:29:08,261][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [analysis-common]
[2024-12-19T10:29:08,261][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [cache-common]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [geo]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [ingest-common]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [ingest-geoip]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [ingest-user-agent]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [lang-expression]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [lang-mustache]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [lang-painless]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [mapper-extras]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [opensearch-dashboards]
[2024-12-19T10:29:08,262][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [parent-join]
[2024-12-19T10:29:08,263][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [percolator]
[2024-12-19T10:29:08,263][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [rank-eval]
[2024-12-19T10:29:08,264][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [reindex]
[2024-12-19T10:29:08,264][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [repository-url]
[2024-12-19T10:29:08,264][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [search-pipeline-common]
[2024-12-19T10:29:08,265][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [test-delayed-aggs]
[2024-12-19T10:29:08,265][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded module [transport-netty4]
[2024-12-19T10:29:08,265][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded plugin [opensearch-job-scheduler]
[2024-12-19T10:29:08,265][INFO ][o.o.p.PluginsService     ] [integTest-0] loaded plugin [wazuh-indexer-command-manager]
[2024-12-19T10:29:08,281][WARN ][stderr                   ] [integTest-0] WARNING: A restricted method in java.lang.foreign.Linker has been called
[2024-12-19T10:29:08,281][WARN ][stderr                   ] [integTest-0] WARNING: java.lang.foreign.Linker::downcallHandle has been called by the unnamed module
[2024-12-19T10:29:08,281][WARN ][stderr                   ] [integTest-0] WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for this module
[2024-12-19T10:29:08,305][INFO ][o.a.l.s.MemorySegmentIndexInputProvider] [integTest-0] Using MemorySegmentIndexInput and native madvise support with Java 21 or later; to disable start with -Dorg.apache.lucene.store.MMapDirectory.enableMemorySegments=false
[2024-12-19T10:29:08,309][INFO ][o.o.e.NodeEnvironment    ] [integTest-0] using [1] data paths, mounts [[/System/Volumes/Data (/dev/disk3s5)]], net usable_space [297.5gb], net total_space [460.4gb], types [apfs]
[2024-12-19T10:29:08,310][INFO ][o.o.e.NodeEnvironment    ] [integTest-0] heap size [512mb], compressed ordinary object pointers [true]
[2024-12-19T10:29:08,324][INFO ][o.o.n.Node               ] [integTest-0] node name [integTest-0], node ID [2cksA6ioTa-EoldES6UQtQ], cluster name [integTest], roles [ingest, remote_cluster_client, data, cluster_manager]
[2024-12-19T10:29:08,334][INFO ][o.o.e.ExtensionsManager  ] [integTest-0] ExtensionsManager initialized
[2024-12-19T10:29:09,413][INFO ][c.w.c.s.PluginSettings   ] [integTest-0] Plugin created with the keystore information.
[2024-12-19T10:29:09,475][INFO ][o.o.t.NettyAllocator     ] [integTest-0] creating NettyAllocator with the following configs: [name=unpooled, suggested_max_allocation_size=256kb, factors={opensearch.unsafe.use_unpooled_allocator=null, g1gc_enabled=true, g1gc_region_size=1mb, heap_size=512mb}]
[2024-12-19T10:29:09,509][INFO ][o.o.d.DiscoveryModule    ] [integTest-0] using discovery type [zen] and seed hosts providers [settings, file]
[2024-12-19T10:29:09,628][WARN ][o.o.g.DanglingIndicesState] [integTest-0] gateway.auto_import_dangling_indices is disabled, dangling indices will not be automatically detected or imported and must be managed manually
[2024-12-19T10:29:09,712][INFO ][o.o.n.Node               ] [integTest-0] initialized
[2024-12-19T10:29:09,712][INFO ][o.o.n.Node               ] [integTest-0] starting ...
[2024-12-19T10:29:09,765][INFO ][o.o.t.TransportService   ] [integTest-0] publish_address {127.0.0.1:9300}, bound_addresses {[::1]:9300}, {127.0.0.1:9300}
[2024-12-19T10:29:09,766][INFO ][o.o.t.TransportService   ] [integTest-0] Remote clusters initialized successfully.
[2024-12-19T10:29:09,843][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] startInitialJoin: coordinator becoming CANDIDATE in term 0 (was null, lastKnownLeader was [Optional.empty])
[2024-12-19T10:29:09,844][INFO ][o.o.c.c.Coordinator      ] [integTest-0] setting initial configuration to VotingConfiguration{2cksA6ioTa-EoldES6UQtQ}
[2024-12-19T10:29:09,844][WARN ][o.o.d.FileBasedSeedHostsProvider] [integTest-0] expected, but did not find, a dynamic hosts list at [/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/build/testclusters/integTest-0/config/unicast_hosts.txt]
[2024-12-19T10:29:09,871][DEBUG][o.o.c.c.ElectionSchedulerFactory] [integTest-0] scheduling scheduleNextElection{gracePeriod=0s, thisAttempt=0, maxDelayMillis=100, delayMillis=96, ElectionScheduler{attempt=1, ElectionSchedulerFactory{initialTimeout=100ms, backoffTime=100ms, maxTimeout=10s}}}
[2024-12-19T10:29:09,879][INFO ][o.o.h.AbstractHttpServerTransport] [integTest-0] publish_address {127.0.0.1:9200}, bound_addresses {[::1]:9200}, {127.0.0.1:9200}
[2024-12-19T10:29:09,880][INFO ][o.o.n.Node               ] [integTest-0] started
[2024-12-19T10:29:09,969][DEBUG][o.o.c.c.ElectionSchedulerFactory] [integTest-0] scheduleNextElection{gracePeriod=0s, thisAttempt=0, maxDelayMillis=100, delayMillis=96, ElectionScheduler{attempt=1, ElectionSchedulerFactory{initialTimeout=100ms, backoffTime=100ms, maxTimeout=10s}}} starting election with duration 500ms
[2024-12-19T10:29:09,970][DEBUG][o.o.c.c.ElectionSchedulerFactory] [integTest-0] scheduling scheduleNextElection{gracePeriod=500ms, thisAttempt=1, maxDelayMillis=200, delayMillis=606, ElectionScheduler{attempt=2, ElectionSchedulerFactory{initialTimeout=100ms, backoffTime=100ms, maxTimeout=10s}}}
[2024-12-19T10:29:09,972][DEBUG][o.o.c.c.PreVoteCollector ] [integTest-0] PreVotingRound{preVotesReceived={}, electionStarted=false, preVoteRequest=PreVoteRequest{sourceNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, currentTerm=0}, isClosed=false} requesting pre-votes from [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]
[2024-12-19T10:29:09,975][DEBUG][o.o.c.c.PreVoteCollector ] [integTest-0] PreVotingRound{preVotesReceived={{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}=PreVoteResponse{currentTerm=0, lastAcceptedTerm=0, lastAcceptedVersion=0}}, electionStarted=true, preVoteRequest=PreVoteRequest{sourceNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, currentTerm=0}, isClosed=false} added PreVoteResponse{currentTerm=0, lastAcceptedTerm=0, lastAcceptedVersion=0} from {integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, starting election
[2024-12-19T10:29:09,976][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] starting election with StartJoinRequest{term=1,node={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}}
[2024-12-19T10:29:09,976][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] joinLeaderInTerm: for [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}] with term 1
[2024-12-19T10:29:09,976][DEBUG][o.o.c.c.CoordinationState] [integTest-0] handleStartJoin: leaving term [0] due to StartJoinRequest{term=1,node={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}}
[2024-12-19T10:29:09,988][DEBUG][o.o.c.c.JoinHelper       ] [integTest-0] attempting to join {integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true} with JoinRequest{sourceNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, minimumTerm=0, optionalJoin=Optional[Join{term=1, lastAcceptedTerm=0, lastAcceptedVersion=0, sourceNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, targetNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}}]}
[2024-12-19T10:29:09,989][DEBUG][o.o.c.c.JoinHelper       ] [integTest-0] successful response to StartJoinRequest{term=1,node={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}} from {integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}
[2024-12-19T10:29:09,990][DEBUG][o.o.c.c.CoordinationState] [integTest-0] handleJoin: added join Join{term=1, lastAcceptedTerm=0, lastAcceptedVersion=0, sourceNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, targetNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}} from [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}] for election, electionWon=true lastAcceptedTerm=0 lastAcceptedVersion=0
[2024-12-19T10:29:09,990][DEBUG][o.o.c.c.CoordinationState] [integTest-0] handleJoin: election won in term [1] with VoteCollection{votes=[2cksA6ioTa-EoldES6UQtQ], joins=[Join{term=1, lastAcceptedTerm=0, lastAcceptedVersion=0, sourceNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, targetNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}}]}
[2024-12-19T10:29:09,990][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] handleJoinRequest: coordinator becoming LEADER in term 1 (was CANDIDATE, lastKnownLeader was [Optional.empty])
[2024-12-19T10:29:09,998][DEBUG][o.o.c.c.JoinHelper       ] [integTest-0] received a join request for an existing node [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]
[2024-12-19T10:29:10,000][INFO ][o.o.c.s.MasterService    ] [integTest-0] Tasks batched with key: org.opensearch.cluster.coordination.JoinHelper and count: 3, term: 1, version: 1, delta: cluster-manager node changed {previous [], current [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]}
[2024-12-19T10:29:10,003][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] initialized PublicationContext using class: class org.opensearch.cluster.coordination.PublicationTransportHandler$PublicationContext
[2024-12-19T10:29:10,006][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publishing version 1 to [PublicationTarget{discoveryNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, state=NOT_STARTED, ackIsPending=true}]
[2024-12-19T10:29:10,008][DEBUG][o.o.c.c.PublicationTransportHandler] [integTest-0] received full cluster state version [1] with size [327]
[2024-12-19T10:29:10,008][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] handlePublishRequest: handling version [1] from [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]
[2024-12-19T10:29:10,033][INFO ][o.o.c.c.CoordinationState] [integTest-0] cluster UUID set to [wgsneZSSSmOyEOtj9nVeEw]
[2024-12-19T10:29:10,051][INFO ][o.o.c.s.ClusterApplierService] [integTest-0] cluster-manager node changed {previous [], current [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]}, term: 1, version: 1, reason: Publication{term=1, version=1}
[2024-12-19T10:29:10,054][INFO ][c.w.c.j.JobDocument      ] [integTest-0] Getting JobDocument Instance
[2024-12-19T10:29:10,058][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publication ended successfully: Publication{term=1, version=1}
[2024-12-19T10:29:10,060][DEBUG][o.o.c.c.JoinHelper       ] [integTest-0] successfully joined {integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true} with JoinRequest{sourceNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, minimumTerm=0, optionalJoin=Optional[Join{term=1, lastAcceptedTerm=0, lastAcceptedVersion=0, sourceNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, targetNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}}]}
[2024-12-19T10:29:10,060][INFO ][o.o.d.PeerFinder         ] [integTest-0] setting findPeersInterval to [1s] as node commission status = [true] for local node [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]
[2024-12-19T10:29:10,061][WARN ][o.o.c.r.a.AllocationService] [integTest-0] Falling back to single shard assignment since batch mode disable or multiple custom allocators set
[2024-12-19T10:29:10,064][WARN ][o.o.c.r.a.AllocationService] [integTest-0] Falling back to single shard assignment since batch mode disable or multiple custom allocators set
[2024-12-19T10:29:10,065][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] initialized PublicationContext using class: class org.opensearch.cluster.coordination.PublicationTransportHandler$PublicationContext
[2024-12-19T10:29:10,065][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publishing version 2 to [PublicationTarget{discoveryNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, state=NOT_STARTED, ackIsPending=true}]
[2024-12-19T10:29:10,065][DEBUG][o.o.c.c.PublicationTransportHandler] [integTest-0] received full cluster state version [2] with size [278]
[2024-12-19T10:29:10,065][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] handlePublishRequest: handling version [2] from [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]
[2024-12-19T10:29:10,077][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publication ended successfully: Publication{term=1, version=2}
[2024-12-19T10:29:10,078][INFO ][o.o.g.GatewayService     ] [integTest-0] recovered [0] indices into cluster_state
[2024-12-19T10:29:10,083][INFO ][o.o.p.PluginsService     ] [integTest-0] PluginService:onIndexModule index:[GAOz4mFBTy25A1REmY1WyQ/hgZBMLbXQiqGF3cTgHDcwg]
[2024-12-19T10:29:10,129][INFO ][o.o.c.m.MetadataIndexTemplateService] [integTest-0] adding template [index-template-scheduled-commands] for index patterns [.scheduled-commands]
[2024-12-19T10:29:10,131][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] initialized PublicationContext using class: class org.opensearch.cluster.coordination.PublicationTransportHandler$PublicationContext
[2024-12-19T10:29:10,132][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publishing version 3 to [PublicationTarget{discoveryNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, state=NOT_STARTED, ackIsPending=true}]
[2024-12-19T10:29:10,132][DEBUG][o.o.c.c.PublicationTransportHandler] [integTest-0] received diff cluster state version [3] with uuid [-q6DqCoGS5OSEjqLiAusAw], diff size [448]
[2024-12-19T10:29:10,133][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] handlePublishRequest: handling version [3] from [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]
[2024-12-19T10:29:10,149][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publication ended successfully: Publication{term=1, version=3}
[2024-12-19T10:29:10,150][INFO ][c.w.c.u.IndexTemplateUtils] [integTest-0] Index template [index-template-scheduled-commands] created successfully
[2024-12-19T10:29:10,155][INFO ][o.o.p.PluginsService     ] [integTest-0] PluginService:onIndexModule index:[.scheduled-commands/Ab2ph-VcSKegl5E6P0OeXg]
[2024-12-19T10:29:10,156][INFO ][o.o.j.JobSchedulerPlugin ] [integTest-0] JobSweeper started listening to operations on index .scheduled-commands
[2024-12-19T10:29:10,160][INFO ][o.o.c.m.MetadataCreateIndexService] [integTest-0] [.scheduled-commands] creating index, cause [auto(bulk api)], templates [index-template-scheduled-commands], shards [1]/[0]
[2024-12-19T10:29:10,162][WARN ][o.o.c.r.a.AllocationService] [integTest-0] Falling back to single shard assignment since batch mode disable or multiple custom allocators set
[2024-12-19T10:29:10,166][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] initialized PublicationContext using class: class org.opensearch.cluster.coordination.PublicationTransportHandler$PublicationContext
[2024-12-19T10:29:10,167][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publishing version 4 to [PublicationTarget{discoveryNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, state=NOT_STARTED, ackIsPending=true}]
[2024-12-19T10:29:10,168][DEBUG][o.o.c.c.PublicationTransportHandler] [integTest-0] received diff cluster state version [4] with uuid [1rWTYklDT6ayAM4_ROrWOg], diff size [624]
[2024-12-19T10:29:10,168][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] handlePublishRequest: handling version [4] from [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]
[2024-12-19T10:29:10,183][INFO ][o.o.p.PluginsService     ] [integTest-0] PluginService:onIndexModule index:[.scheduled-commands/Ab2ph-VcSKegl5E6P0OeXg]
[2024-12-19T10:29:10,183][INFO ][o.o.j.JobSchedulerPlugin ] [integTest-0] JobSweeper started listening to operations on index .scheduled-commands
[2024-12-19T10:29:10,209][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publication ended successfully: Publication{term=1, version=4}
[2024-12-19T10:29:10,287][INFO ][o.o.c.r.a.AllocationService] [integTest-0] Cluster health status changed from [YELLOW] to [GREEN] (reason: [shards started [[.scheduled-commands][0]]]).
[2024-12-19T10:29:10,288][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] initialized PublicationContext using class: class org.opensearch.cluster.coordination.PublicationTransportHandler$PublicationContext
[2024-12-19T10:29:10,289][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publishing version 5 to [PublicationTarget{discoveryNode={integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}, state=NOT_STARTED, ackIsPending=true}]
[2024-12-19T10:29:10,290][DEBUG][o.o.c.c.PublicationTransportHandler] [integTest-0] received diff cluster state version [5] with uuid [JfiVH94jTDmmZy8JcYn3hA], diff size [391]
[2024-12-19T10:29:10,290][DEBUG][o.o.c.c.Coordinator      ] [integTest-0] handlePublishRequest: handling version [5] from [{integTest-0}{2cksA6ioTa-EoldES6UQtQ}{TA_Oe2WcTyOaZkHBgSsnHw}{127.0.0.1}{127.0.0.1:9300}{dimr}{testattr=test, shard_indexing_pressure_enabled=true}]
[2024-12-19T10:29:10,303][DEBUG][o.o.c.c.C.CoordinatorPublication] [integTest-0] publication ended successfully: Publication{term=1, version=5}
[2024-12-19T10:29:10,305][WARN ][o.o.c.r.a.AllocationService] [integTest-0] Falling back to single shard assignment since batch mode disable or multiple custom allocators set
[2024-12-19T10:29:10,319][INFO ][o.o.j.s.JobScheduler     ] [integTest-0] Scheduling job id MnAb35MBBM3eHt4voNCn for index .scheduled-commands .
[2024-12-19T10:29:10,329][INFO ][c.w.c.CommandManagerPlugin] [integTest-0] Scheduled task successfully, response: CREATED
[2024-12-19T10:29:10,581][DEBUG][o.o.c.c.ElectionSchedulerFactory] [integTest-0] scheduleNextElection{gracePeriod=500ms, thisAttempt=1, maxDelayMillis=200, delayMillis=606, ElectionScheduler{attempt=2, ElectionSchedulerFactory{initialTimeout=100ms, backoffTime=100ms, maxTimeout=10s}}} not starting election
<===========--> 88% EXECUTING [21s]
> :run
Full build log
./gradlew build
=======================================
OpenSearch Build Hamster says Hello!
  Gradle Version        : 8.10
  OS Info               : Mac OS X 15.2 (aarch64)
  JDK Version           : 21 (Amazon Corretto JDK)
  JAVA_HOME             : /Users/quebim_wz/Library/Java/JavaVirtualMachines/corretto-21.0.4/Contents/Home
  Random Testing Seed   : ADC82873B9C52DA7
  In FIPS 140 mode      : false
=======================================

> Task :javadoc
warning: unknown enum constant When.MAYBE
  reason: class file for javax.annotation.meta.When not found
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Action.java:28: warning: no comment
    public static final String ACTION = "action";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Action.java:30: warning: no comment
    public static final String ARGS = "args";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Action.java:29: warning: no comment
    public static final String NAME = "name";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Action.java:31: warning: no comment
    public static final String VERSION = "version";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Agent.java:28: warning: no comment
    public static final String AGENT = "agent";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Agent.java:29: warning: no comment
    public static final String GROUPS = "groups";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:33: warning: no comment
    public static final String COMMAND = "command";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:34: warning: no comment
    public static final String ORDER_ID = "order_id";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:35: warning: no comment
    public static final String REQUEST_ID = "request_id";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:36: warning: no comment
    public static final String SOURCE = "source";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:39: warning: no comment
    public static final String STATUS = "status";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:37: warning: no comment
    public static final String TIMEOUT = "timeout";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:38: warning: no comment
    public static final String USER = "user";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:185: warning: no comment
    public Action getAction() {
                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:189: warning: no comment
    public String getSource() {
                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:193: warning: no comment
    public Target getTarget() {
                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Command.java:197: warning: no comment
    public String getUser() {
                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/CommandManagerJobParameter.java:29: warning: no comment
    public static final String ENABLED_FIELD = "enabled";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/CommandManagerJobParameter.java:33: warning: no comment
    public static final String ENABLED_TIME_FIELD = "enabled_time";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/CommandManagerJobParameter.java:34: warning: no comment
    public static final String ENABLED_TIME_FIELD_READABLE = "enabled_time_field";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/CommandManagerJobParameter.java:30: warning: no comment
    public static final String LAST_UPDATE_TIME_FIELD = "last_update_time";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/CommandManagerJobParameter.java:31: warning: no comment
    public static final String LAST_UPDATE_TIME_FIELD_READABLE = "last_update_time_field";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/CommandManagerJobParameter.java:28: warning: no comment
    public static final String NAME_FIELD = "name";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/CommandManagerJobParameter.java:32: warning: no comment
    public static final String SCHEDULE_FIELD = "schedule";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:84: warning: no comment
    public static final String COMMAND_DOCUMENT_PARENT_OBJECT_NAME = "command";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:80: warning: no comment
    public static final String COMMAND_MANAGER_BASE_URI = "/_plugins/_command_manager";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:81: warning: no comment
    public static final String COMMANDS_URI = COMMAND_MANAGER_BASE_URI + "/commands";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:89: warning: no comment
    public static final Long DEFAULT_TIMEOUT_SECONDS = 20L;
                             ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:82: warning: no comment
    public static final String INDEX_NAME = ".commands";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:83: warning: no comment
    public static final String INDEX_TEMPLATE_NAME = "index-template-commands";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:85: warning: no comment
    public static final String JOB_INDEX_NAME = ".scheduled-commands";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:86: warning: no comment
    public static final String JOB_INDEX_TEMPLATE_NAME = "index-template-scheduled-commands";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:87: warning: no comment
    public static final Integer JOB_PERIOD_MINUTES = 1;
                                ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:93: warning: no comment
    public static final String JOB_TYPE = "command_manager_scheduler_extension";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:88: warning: no comment
    public static final Integer PAGE_SIZE = 100;
                                ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:90: warning: no comment
    public static final TimeValue PIT_KEEP_ALIVE_SECONDS = TimeValue.timeValueSeconds(30L);
                                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/CommandManagerPlugin.java:78: warning: use of default constructor, which does not provide a comment
public class CommandManagerPlugin extends Plugin
       ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/settings/CommandManagerSettingsException.java:19: warning: no comment
public class CommandManagerSettingsException extends Exception {
       ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/settings/CommandManagerSettingsException.java:22: warning: no comment
    public CommandManagerSettingsException(String message) {
           ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/settings/CommandManagerSettingsException.java:27: warning: no comment
    public static CommandManagerSettingsException loadSettingsFailed(
                                                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/settings/CommandManagerSettingsException.java:34: warning: no comment
    public static CommandManagerSettingsException reloadPluginFailed(String pluginName) {
                                                  ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Document.java:36: warning: no comment
    public static final String DELIVERY_TIMESTAMP = "delivery_timestamp";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Document.java:35: warning: no comment
    public static final String TIMESTAMP = "@timestamp";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Documents.java:27: warning: no comment
    public static final String DOCUMENTS = "_documents";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Documents.java:28: warning: no comment
    public static final String ID = "_id";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Order.java:30: warning: no comment
public class Order implements ToXContent {
       ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Order.java:34: warning: no comment
    public static final String DOCUMENT_ID = "document_id";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Order.java:31: warning: no comment
    public static final String ORDERS = "orders";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Order.java:32: warning: no comment
    public static final String SOURCE = "source";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Order.java:33: warning: no comment
    public static final String USER = "user";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/rest/RestPostCommandAction.java:52: warning: no comment
    public static final String POST_COMMAND_ACTION_REQUEST_DETAILS =
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:68: warning: no comment
    public static final String COMMAND_STATUS_FIELD = Command.COMMAND + "." + Command.STATUS;
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:69: warning: no comment
    public static final String DELIVERY_TIMESTAMP_FIELD = Document.DELIVERY_TIMESTAMP;
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/jobscheduler/SearchThread.java:71: warning: no comment
    public static final String ORDERS_ENDPOINT = "/orders";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Target.java:29: warning: no comment
    public static final String ID = "id";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Target.java:27: warning: no comment
    public static final String TARGET = "target";
                               ^
/Users/quebim_wz/IdeaProjects/wazuh-indexer-plugins/plugins/command-manager/src/main/java/com/wazuh/commandmanager/model/Target.java:28: warning: no comment
    public static final String TYPE = "type";
                               ^
58 warnings

> Task :integTest
Dec 19, 2024 10:34:11 AM sun.util.locale.provider.LocaleProviderAdapter <clinit>
WARNING: COMPAT locale provider will be removed in a future release

WARNING: A terminally deprecated method in java.lang.System has been called
WARNING: System::setSecurityManager has been called by org.opensearch.bootstrap.BootstrapForTesting (file:/Users/quebim_wz/.gradle/caches/modules-2/files-2.1/org.opensearch.test/framework/2.18.0-SNAPSHOT/84ab0741ecfc70dbbc7d11340fe527d9e160d91d/framework-2.18.0-SNAPSHOT.jar)
WARNING: Please consider reporting this to the maintainers of org.opensearch.bootstrap.BootstrapForTesting
WARNING: System::setSecurityManager will be removed in a future release
WARNING: A terminally deprecated method in java.lang.System has been called
WARNING: System::setSecurityManager has been called by org.gradle.api.internal.tasks.testing.worker.TestWorker (file:/Users/quebim_wz/.gradle/wrapper/dists/gradle-8.10-all/3ym48ijgw9iixtry4iwty4ydy/gradle-8.10/lib/plugins/gradle-testing-base-infrastructure-8.10.jar)
WARNING: Please consider reporting this to the maintainers of org.gradle.api.internal.tasks.testing.worker.TestWorker
WARNING: System::setSecurityManager will be removed in a future release
WARNING: A terminally deprecated method in java.lang.System has been called
WARNING: System::setSecurityManager has been called by org.opensearch.bootstrap.BootstrapForTesting (file:/Users/quebim_wz/.gradle/caches/modules-2/files-2.1/org.opensearch.test/framework/2.18.0-SNAPSHOT/84ab0741ecfc70dbbc7d11340fe527d9e160d91d/framework-2.18.0-SNAPSHOT.jar)
WARNING: Please consider reporting this to the maintainers of org.opensearch.bootstrap.BootstrapForTesting
WARNING: System::setSecurityManager will be removed in a future release
WARNING: A terminally deprecated method in java.lang.System has been called
WARNING: System::setSecurityManager has been called by org.opensearch.bootstrap.BootstrapForTesting (file:/Users/quebim_wz/.gradle/caches/modules-2/files-2.1/org.opensearch.test/framework/2.18.0-SNAPSHOT/84ab0741ecfc70dbbc7d11340fe527d9e160d91d/framework-2.18.0-SNAPSHOT.jar)
WARNING: Please consider reporting this to the maintainers of org.opensearch.bootstrap.BootstrapForTesting
WARNING: System::setSecurityManager will be removed in a future release
WARNING: A terminally deprecated method in java.lang.System has been called
WARNING: System::setSecurityManager has been called by org.gradle.api.internal.tasks.testing.worker.TestWorker (file:/Users/quebim_wz/.gradle/wrapper/dists/gradle-8.10-all/3ym48ijgw9iixtry4iwty4ydy/gradle-8.10/lib/plugins/gradle-testing-base-infrastructure-8.10.jar)
WARNING: Please consider reporting this to the maintainers of org.gradle.api.internal.tasks.testing.worker.TestWorker
WARNING: System::setSecurityManager will be removed in a future release

> Task :test
Dec 19, 2024 10:34:15 AM sun.util.locale.provider.LocaleProviderAdapter <clinit>
WARNING: COMPAT locale provider will be removed in a future release
Dec 19, 2024 10:34:15 AM sun.util.locale.provider.LocaleProviderAdapter <clinit>
WARNING: COMPAT locale provider will be removed in a future release

WARNING: A terminally deprecated method in java.lang.System has been called
WARNING: System::setSecurityManager has been called by org.gradle.api.internal.tasks.testing.worker.TestWorker (file:/Users/quebim_wz/.gradle/wrapper/dists/gradle-8.10-all/3ym48ijgw9iixtry4iwty4ydy/gradle-8.10/lib/plugins/gradle-testing-base-infrastructure-8.10.jar)
WARNING: Please consider reporting this to the maintainers of org.gradle.api.internal.tasks.testing.worker.TestWorker
WARNING: System::setSecurityManager will be removed in a future release

BUILD SUCCESSFUL in 19s
25 actionable tasks: 16 executed, 9 up-to-date
  • Generate commands using the API
    curl -X POST "http://127.0.0.1:9200/_plugins/_command_manager/commands" \
    -H "Content-Type: application/json" \
    -d '{"commands": [{"source": "Engine", "user": "user73", "target": {"id": "target8", "type": "group"}, "action": {"name": "apply_policy", "args": ["/path/to/executable/arg6"], "version": "v2"}, "timeout": 77}, {"source": "Content manager", "user": "user48", "target": {"id": "target4", "type": "agent"}, "action": {"name": "update", "args": ["/path/to/executable/arg9"], "version": "v4"}, "timeout": 44}, {"source": "Engine", "user": "user68", "target": {"id": "target8", "type": "group"}, "action": {"name": "apply_policy", "args": ["/path/to/executable/arg9"], "version": "v5"}, "timeout": 64}]}' --cacert ~/Wazuh/imposter/wazuh-certificates/root-ca.pem
    {"_index":".commands","_documents":[{"_id":"FcAW35MBxyzgMoPcoo1L"},{"_id":"FsAW35MBxyzgMoPcoo1N"},{"_id":"F8AW35MBxyzgMoPcoo1N"}],"result":"OK"}
  • The command is processed and request is sent to the management API (in this case to the imposter)
    10:24:35 DEBUG i.g.i.h.AbstractResourceMatcher - Matched resource config for POST https://127.0.0.1:55000/orders
    {
      "orders": [
        {
          "source": "Content manager",
          "user": "user48",
          "target": {
            "type": "agent",
            "id": "target4"
          },
          "action": {
            "name": "update",
            "args": [
              "/path/to/executable/arg9"
            ],
            "version": "v4"
          },
          "document_id": "FsAW35MBxyzgMoPcoo1N"
        },
        {
          "source": "Engine",
          "user": "user68",
          "target": {
            "type": "group",
            "id": "target8"
          },
          "action": {
            "name": "apply_policy",
            "args": [
              "/path/to/executable/arg9"
            ],
            "version": "v5"
          },
          "document_id": "F8AW35MBxyzgMoPcoo1N"
        },
        {
          "source": "Engine",
          "user": "user73",
          "target": {
            "type": "group",
            "id": "target8"
          },
          "action": {
            "name": "apply_policy",
            "args": [
              "/path/to/executable/arg6"
            ],
            "version": "v2"
          },
          "document_id": "FcAW35MBxyzgMoPcoo1L"
        }
      ]
    }

Copy link
Member

@QU3B1M QU3B1M left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@AlexRuiz7 AlexRuiz7 merged commit f9b2542 into master Dec 23, 2024
1 check passed
@AlexRuiz7 AlexRuiz7 deleted the enhancement/183-orders-data-review branch December 23, 2024 10:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Review orders' data sent from the CM plugin to the agent
3 participants