Open adamkorynta opened 1 month ago
well, hard to put the database engine in a query and query it without knowing, but shouldn't be too much of an issue to keep the table simple enough it doesn't really matter and we can get the "type".
We definitely need to get away from the isOracle/PG, isCwms/HDB/etc checks over time as 1. it just makes the code easier to read, and 2. kinda benefits the project to let additional usages slurp in the concept with OpenDCS needing to know about them.
Component to be refactored The REST API currently requires configuration inputs to determine what database it is connecting to.
Purpose of refactoring Less configuration for deployment.
Proposed method Add information to the database schema which could tell the REST API which database (oracle/postgresql/etc) and which type (CWMS/OpenTSDB/HDB/etc) instead of needing to add additional configuration parameters.
Additional context Brought up in PR: https://github.com/opendcs/rest_api/pull/186#discussion_r1773879778