Skip to content

Improve filtering for invalid schemas in Hive hook #27695

Description

@PApostol

Description

#27647 has introduced filtering for invalid schemas in Hive hook based on the characters ; and !. I'm wondering if a more generic filtering could be introduced, e.g. one that adheres to the regex [^a-z0-9_], since Hive schemas (and table names) can only contain alphanumeric characters and the character _.

Note: since the Hive metastore stores schemas and tables in lowercase, checking against [^a-z0-9_] is probably better than [^a-zA-Z0-9_].

Use case/motivation

Ensure that Hive schemas used in apache-airflow-providers-apache-hive hooks contain no invalid characters.

Related issues

No response

Are you willing to submit a PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions