LogWriterConfig
Name | Description |
---|---|
base_url | Base URL for the Maxim API. |
api_key | API key for authentication. |
repository_id | ID of the repository to write logs to. |
auto_flush | Whether to automatically flush logs periodically. |
flush_interval | Time interval in seconds between automatic flushes. |
is_debug | Whether to enable debug logging. |
raise_exceptions | Whether to raise exceptions or handle them silently. |
__init__
Name | Description |
---|---|
base_url | Base URL for the Maxim API. |
api_key | API key for authentication. |
repository_id | ID of the repository to write logs to. |
auto_flush | Whether to automatically flush logs periodically. |
flush_interval | Time interval in seconds between automatic flushes. |
is_debug | Whether to enable debug logging. |
raise_exceptions | Whether to raise exceptions or handle them silently. |
LogWriter
__init__
Name | Description |
---|---|
config | Configuration for the LogWriter. |
ValueError
- If auto_flush is enabled but flush_interval is None.
repository_id
Name | Description |
---|---|
str | The repository ID. |
upload_file_data
upload_file
upload_attachments
upload_attachment
Name | Description |
---|---|
attachment | Attachment object to upload. |
is_running_on_lambda
Name | Description |
---|---|
bool | True if running in AWS Lambda, False otherwise. |
write_to_file
Name | Description |
---|---|
logs | List of CommitLog objects to write. |
Exception
- If raise_exceptions is True and writing fails.
flush_log_files
Exception
- If raise_exceptions is True and an error occurs.
can_access_filesystem
Name | Description |
---|---|
bool | True if filesystem is accessible, False otherwise. |
flush_logs
Name | Description |
---|---|
logs | List of CommitLog objects to flush. |
commit
Name | Description |
---|---|
log | CommitLog object to add to the queue. |
ValueError
- If the entity_id is invalid and raise_exceptions is True.