-
Bug
-
Resolution: Done
-
Normal
-
None
-
None
-
False
-
-
False
-
-
Description of the problem:
The cost-onprem-db-init configmap creates hive role and DB to overcome ONPREM issue in koku:
-- Koku requires special setup for Trino/Hive integration -- Create hive role (used by Trino for table operations) DO \$\$ BEGIN IF NOT EXISTS (SELECT FROM pg_catalog.pg_roles WHERE rolname = 'hive') THEN CREATE ROLE hive LOGIN; END IF; END \$\$; GRANT hive TO $KOKU_USER WITH ADMIN OPTION; -- Hive Database (required by Koku migration 0039_create_hive_db) SELECT 'CREATE DATABASE hive OWNER $KOKU_USER' WHERE NOT EXISTS (SELECT FROM pg_database WHERE datname = 'hive') \gexec
How reproducible:
always
Steps to reproduce:
1. Remove the hive role and DB and watch koku logs.
Actual results:
koku migration fails to run if hive role/db don't exist
Expected results:
not to have hive resources in on-prem.
This seems like an issue on koku side that was shown first during the trino2postgres work for on prem.