jason810496 commented on code in PR #67056:
URL: https://github.com/apache/airflow/pull/67056#discussion_r3263671272
##########
airflow-core/src/airflow/providers_manager.py:
##########
@@ -1240,6 +1256,32 @@ def _discover_logging(self) -> None:
if _correctness_check(provider_package,
logging_class_name, provider):
self._logging_class_name_set.add(logging_class_name)
+ def _discover_remote_logging(self) -> None:
+ """Retrieve all remote logging IO handlers defined in the providers."""
+ for provider_package, provider in self._provider_dict.items():
+ entries = provider.data.get("remote-logging") or []
+ for entry in entries:
+ classpath = entry["classpath"]
+ if not _correctness_check(provider_package, classpath,
provider):
+ continue
+ info = RemoteLoggingInfo(
+ classpath=classpath,
+ scheme=entry["scheme"],
+ package_name=provider_package,
+ )
+ self._remote_logging_info_list.append(info)
+ existing = self._remote_logging_by_scheme.get(info.scheme)
+ if existing is not None:
+ log.warning(
+ "Remote logging scheme '%s' is already registered by
%s; ignoring "
+ "duplicate registration from %s.",
+ info.scheme,
+ existing.package_name,
+ info.package_name,
+ )
+ continue
+ self._remote_logging_by_scheme[info.scheme] = info
Review Comment:
Nice catch! Addressed in
https://github.com/apache/airflow/pull/67056/changes/37939dca6bf004b45a8b78d82da0550e48b20b03
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]