Refactor Ingestor and OPC Manager for Asynchronous Operations - Updated main function to be asynchronous and integrated asyncio for better concurrency. - Refactored Ingestor methods to support async operations, including prepare_ingestor, loop, and shutdown. - Enhanced IngestorManager and OpcManager with async methods for improved performance and responsiveness. - Replaced blocking calls with await statements to ensure non-blocking behavior during operations. - Added a new run_async_main function to handle the async event loop setup.
19 lines
432 B
Bash
Executable File
19 lines
432 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Exit on any error
|
|
set -e
|
|
|
|
echo "Activating virtual environment..."
|
|
source ./venv/bin/activate
|
|
|
|
echo "Loading environment variables from .env..."
|
|
if [ -f .env ]; then
|
|
export $(cat .env | grep -v '^#' | xargs)
|
|
echo "Environment variables loaded from .env"
|
|
else
|
|
echo "Warning: .env file not found. Continuing without environment variables."
|
|
fi
|
|
|
|
echo "Starting ingestor application..."
|
|
python -m ingestor.app
|