| 59 | |
| 60 | |
| 61 | class LoggingConfig: |
| 62 | def __init__(self, filename_pattern=None, date_format=None) -> None: |
| 63 | self.filename_pattern = filename_pattern |
| 64 | self.date_format = date_format |
| 65 | |
| 66 | @classmethod |
| 67 | def from_json(cls, json_config): |
| 68 | config = LoggingConfig() |
| 69 | |
| 70 | if json_config: |
| 71 | json_logging_config = json_config |
| 72 | config.filename_pattern = json_logging_config.get('execution_file') |
| 73 | config.date_format = json_logging_config.get('execution_date_format') |
| 74 | |
| 75 | return config |
| 76 | |
| 77 | |
| 78 | def _build_env_vars(json_object): |
no outgoing calls