Skip to content

Commit

Permalink
Update PA directories from plugins to root
Browse files Browse the repository at this point in the history
Signed-off-by: sruti1312 <srutiparthiban@gmail.com>
  • Loading branch information
sruti1312 committed Apr 18, 2022
1 parent c020cc9 commit 374dd9b
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 6 deletions.
2 changes: 1 addition & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ This document walks you through the process of building and deploying the RCA fr
This will not currently enforce client authentication. This feature, including full support for TLS is
planned for an upcoming release.

a. Open config/performance-analyzer.properties
a. Open $OPENSEARCH-HOME/config/opensearch-performance-analyzer/performance-analyzer.properties

b. Modify the certificate-file-path, private-key-file-path, and https-enabled entries

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ __Metrics__: Metrics are typically served as continuous datastreams to downstrea

### Components

__Framework__: The RCA runtime operates on an `AnalysisGraph`. You can extend this class and override the `construct` method to build your own RCAs. You should specify the path to the class in the `analysis-graph-implementor` section of `config/rca.conf`. The `addLeaf` and `addAllUpstreams` helper methods are useful when you define the dependencies between nodes of the graph.
__Framework__: The RCA runtime operates on an `AnalysisGraph`. You can extend this class and override the `construct` method to build your own RCAs. You should specify the path to the class in the `analysis-graph-implementor` section of `config/opensearch-performance-analyzer/rca.conf`. The `addLeaf` and `addAllUpstreams` helper methods are useful when you define the dependencies between nodes of the graph.

__Scheduler__: The scheduler invokes the `operate` method on each graph node in topological order as defined in the `AnalysisGraph`. Nodes with no dependencies can be executed in parallel. Use flow-units to share data between RCA nodes instead of shared objects to avoid data races and performance bottlenecks.

Expand Down
4 changes: 1 addition & 3 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,6 @@ RUN chown -R opensearch:0 . && \

RUN unzip config/performance-analyzer-rca-2.0.0.0-rc1-SNAPSHOT.zip

RUN cp -r performance-analyzer-rca/* plugins/opensearch-performance-analyzer/
RUN chmod 755 /usr/share/opensearch/plugins/opensearch-performance-analyzer/bin/performance-analyzer-agent
RUN chmod -R 755 /dev/shm
################################################################################
# Build stage 1 (the actual OpenSearch image):
Expand Down Expand Up @@ -118,7 +116,7 @@ RUN chgrp 0 /usr/local/bin/docker-entrypoint.sh && \
chmod 0775 /usr/local/bin/docker-entrypoint.sh

# Bind to all interfaces so that the docker container is accessible from the host machine
RUN sed -i "s|#webservice-bind-host =|webservice-bind-host = 0.0.0.0|g" /usr/share/opensearch/plugins/opensearch-performance-analyzer/config/performance-analyzer.properties
RUN sed -i "s|#webservice-bind-host =|webservice-bind-host = 0.0.0.0|g" /usr/share/opensearch/config/opensearch-performance-analyzer/performance-analyzer.properties

EXPOSE 9200 9300 9600 9650

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

package org.opensearch.performanceanalyzer.config;

import static org.opensearch.performanceanalyzer.core.Util.OPENSEARCH_HOME;

import com.google.common.annotations.VisibleForTesting;
import java.io.File;
Expand All @@ -23,7 +24,13 @@ public class PluginSettings {
private static PluginSettings instance;
public static final String CONFIG_FILES_PATH = "config/";
private static final String DEFAULT_CONFIG_FILE_PATH =
Util.PLUGIN_LOCATION + "config/performance-analyzer.properties";
OPENSEARCH_HOME
+ File.separator
+ "config"
+ File.separator
+ "opensearch-performance-analyzer"
+ File.separator
+ "performance-analyzer.properties";
private static final String METRICS_LOCATION_KEY = "metrics-location";
private static final String METRICS_LOCATION_DEFAULT = "/dev/shm/performanceanalyzer/";
private static final String DELETION_INTERVAL_KEY = "metrics-deletion-interval";
Expand Down

0 comments on commit 374dd9b

Please sign in to comment.