Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logging does not log the project nor the project instance #159

Closed
pbchase opened this issue May 21, 2024 · 2 comments
Closed

Logging does not log the project nor the project instance #159

pbchase opened this issue May 21, 2024 · 2 comments
Assignees

Comments

@pbchase
Copy link
Contributor

pbchase commented May 21, 2024

Logging has no way to identify the project or the instance of the project. Without a project identifier, it's difficult to query all of a project's logging and impossible to guarantee that a query is not returning data from an unintended project. If two projects use the same script name, their logging records would be indistinguishable.

Without an instance identifier, a second instance of a project's scripts would be indistinguishable from the first.

We could address these issues by adding a project column and an instance column to the rcc_job_log data model, setting environment variables with standard names, reading those names from the env, and writing those values on each log record. Such code would need to behave gracefully if the values are absent setting NULL values as login records are written.

The standard names in the environment should be INSTANCE and PROJECT

@pbchase
Copy link
Contributor Author

pbchase commented May 21, 2024

This would require changes in

We probably need to write

  • set_project()
  • get_project()
  • set_instance()
  • get_instance()

We'd call the new setters in init_etl. We'd call the getters in build_etl_job_log_df

@pbchase
Copy link
Contributor Author

pbchase commented Jun 13, 2024

Addressed by PR #159

@pbchase pbchase closed this as completed Jun 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants