Use "rowboat" db in simulation runner

This commit is contained in:
Ramnique Singh 2025-02-18 20:39:24 +05:30 committed by GitHub
parent 467d141690
commit a98519c388
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -13,7 +13,7 @@ SIMULATION_AGGREGATE_RESULT_COLLECTION_NAME = "simulation_aggregate_result"
def get_db():
client = MongoClient(MONGO_URI)
return client.get_default_database()
return client["rowboat"]
def get_collection(collection_name: str):
db = get_db()
@ -71,4 +71,4 @@ def get_scenarios_for_run(simulation_run: SimulationRun):
def write_simulation_result(result: SimulationResult):
collection = get_collection(SIMULATION_RESULT_COLLECTION_NAME)
collection.insert_one(result.model_dump())
collection.insert_one(result.model_dump())