Page MenuHomePhabricator

Add missing where clause to event storage

Authored by sashank on Dec 19 2019, 6:09 AM.



When using PostgresEventLogStorage, we would see incorrect stats for runs. This diff adds a simple where clause to the query in SqlEventLogStorage.get_stats_for_run.

We didn't see this issue with SqliteEventLogStorage because we shard the sqlite files by run_id, so this where clause is not necessary in the sqlite case.

Test Plan


Diff Detail

R1 dagster
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

sashank created this revision.Dec 19 2019, 6:09 AM
sashank updated this revision to Diff 8081.Dec 20 2019, 7:05 PM

Add test

sashank updated this revision to Diff 8083.Dec 20 2019, 7:44 PM

Add postgres test

sashank edited the summary of this revision. (Show Details)Dec 20 2019, 7:57 PM
sashank edited the test plan for this revision. (Show Details)
sashank added reviewers: max, schrockn.
max accepted this revision.Dec 20 2019, 9:06 PM
This revision is now accepted and ready to land.Dec 20 2019, 9:06 PM