In order to simplify db session management, datagov wants to implement a single session for a given environment ( i.e. testing and deployment ) per application ( flask and harvest runner )
Acceptance Criteria
[ACs should be clearly demoable/verifiable whenever possible. Try specifying them using BDD.]
[ ] GIVEN the harvesting logic repo \
WHEN a db session is expected for either testing or deployment for a given app \
THEN 1 session is created and used
Background
need to organize our HarvestDBInterface instances. there's multiple instances throughout the repo which means there's multiple separate db sessions. depending on which session is used the db will return back different results
[Any security concerns that might be implicated in the change. "None" is OK, just be explicit here!]
Sketch
create a session manager class
or create a db interface instance in the init file for harvest.py which will be used as the default in HarvestSource. pass a difference db interface for testing. in this case, there's 2 session types: testing and deployment.
User Story
In order to simplify db session management, datagov wants to implement a single session for a given environment ( i.e. testing and deployment ) per application ( flask and harvest runner )
Acceptance Criteria
[ACs should be clearly demoable/verifiable whenever possible. Try specifying them using BDD.]
Background
HarvestDBInterface
instances. there's multiple instances throughout the repo which means there's multiple separate db sessions. depending on which session is used the db will return back different resultsSecurity Considerations (required)
[Any security concerns that might be implicated in the change. "None" is OK, just be explicit here!]
Sketch
HarvestSource
. pass a difference db interface for testing. in this case, there's 2 session types: testing and deployment.