Skip to content

Commit

Permalink
precommit fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
taylorwalton committed Apr 18, 2024
1 parent f5f89df commit 9c18149
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 4 deletions.
6 changes: 4 additions & 2 deletions backend/app/connectors/wazuh_indexer/routes/monitoring.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,10 @@
from app.connectors.wazuh_indexer.services.monitoring import cluster_healthcheck
from app.connectors.wazuh_indexer.services.monitoring import indices_stats
from app.connectors.wazuh_indexer.services.monitoring import node_allocation
from app.connectors.wazuh_indexer.services.monitoring import (
output_shard_number_to_be_set_based_on_nodes,
)
from app.connectors.wazuh_indexer.services.monitoring import shards
from app.connectors.wazuh_indexer.services.monitoring import output_shard_number_to_be_set_based_on_nodes

wazuh_indexer_router = APIRouter()

Expand Down Expand Up @@ -122,6 +124,7 @@ async def get_shards() -> Union[ShardsResponse, HTTPException]:
else:
raise HTTPException(status_code=500, detail="Failed to retrieve shards.")


@wazuh_indexer_router.get(
"/output_shard_number_to_be_set_based_on_nodes",
description="Fetch Wazuh Indexer output_shard_number_to_be_set_based_on_nodes",
Expand All @@ -144,4 +147,3 @@ async def get_output_shard_number_to_be_set_based_on_nodes_route() -> int:
return output_shard_number_to_be_set_based_on_nodes_response
else:
raise HTTPException(status_code=500, detail="Failed to retrieve output_shard_number_to_be_set_based_on_nodes.")

4 changes: 3 additions & 1 deletion backend/app/integrations/carbonblack/services/provision.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
from app.connectors.grafana.utils.universal import create_grafana_client
from app.connectors.graylog.services.management import start_stream
from app.connectors.graylog.utils.universal import send_post_request
from app.connectors.wazuh_indexer.services.monitoring import (
output_shard_number_to_be_set_based_on_nodes,
)
from app.customer_provisioning.schema.grafana import GrafanaDatasource
from app.customer_provisioning.schema.grafana import GrafanaDataSourceCreationResponse
from app.customer_provisioning.schema.graylog import GraylogIndexSetCreationResponse
Expand All @@ -28,7 +31,6 @@
from app.integrations.routes import create_integration_meta
from app.integrations.schema import CustomerIntegrationsMetaSchema
from app.utils import get_connector_attribute
from app.connectors.wazuh_indexer.services.monitoring import output_shard_number_to_be_set_based_on_nodes


################## ! GRAYLOG ! ##################
Expand Down
5 changes: 4 additions & 1 deletion backend/app/integrations/huntress/services/provision.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
from app.connectors.grafana.utils.universal import create_grafana_client
from app.connectors.graylog.services.management import start_stream
from app.connectors.graylog.utils.universal import send_post_request
from app.connectors.wazuh_indexer.services.monitoring import (
output_shard_number_to_be_set_based_on_nodes,
)
from app.customer_provisioning.schema.grafana import GrafanaDatasource
from app.customer_provisioning.schema.grafana import GrafanaDataSourceCreationResponse
from app.customer_provisioning.schema.graylog import GraylogIndexSetCreationResponse
Expand All @@ -28,7 +31,7 @@
from app.integrations.routes import create_integration_meta
from app.integrations.schema import CustomerIntegrationsMetaSchema
from app.utils import get_connector_attribute
from app.connectors.wazuh_indexer.services.monitoring import output_shard_number_to_be_set_based_on_nodes


################## ! GRAYLOG ! ##################
async def build_index_set_config(
Expand Down

0 comments on commit 9c18149

Please sign in to comment.