Creates the necessary database schema for taskqueue, including all required tables, types, and constraints. This function must be run once before using taskqueue for the first time.
Details
This function creates:
Custom PostgreSQL types (e.g.,
task_statusenum)projecttable for managing projectsresourcetable for computing resourcesproject_resourcetable for project-resource associations
It is safe to call this function multiple times; existing tables and types will not be modified or deleted.
Examples
if (FALSE) { # \dontrun{
# Not run:
# Initialize database (run once)
db_init()
# Verify initialization
con <- db_connect()
DBI::dbListTables(con)
db_disconnect(con)
} # }