Skip to main content

Logger with saving logs to s3 storage

Project description

Xgua - Logger with saving logs to s3 storage

Save files to the vault to fix bugs and improve your product!


Quick Startup

import asyncio
from Xgua.config import Config, S3Config
from Xgua.logger import Logger

s3 = S3Config("access_key", "secret_key", "endpoint_url", "bucket_name")
config = Config(s3)
logger = Logger(config)

async def main():
	try:
		"0" + 1
	except Exception as e:
		await logger.log(e)

asyncio.run(main())

Configuration

Argument README
access_key Get after adding a serialized user
secret_key Get after adding a serialized user
endpoint_url If you haven't enabled "Virtual-Hosted Addressing", then https://s3.storage.selcloud.ru or else name-container.s3.storage.selcloud.ru
bucket_name The name of the container at creation.

How do I get all the parameters?

Through the side navigation block go to "Access Control" -> Next tab "Service Users" and add a new user.

Fast open "Access Control"

How do you create a container?

Using the navigation box on the right, navigate to "Cloud Storage" and click on the "Create Container" button

View Photo

Fast Open "Storage"

Config

Now substitute your values by key

s3 = S3Config("access_key", "secret_key", "endpoint_url", "bucket_name")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Xgua-0.0.2.tar.gz (4.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

Xgua-0.0.2-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

Details for the file Xgua-0.0.2.tar.gz.

File metadata

  • Download URL: Xgua-0.0.2.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.10.11

File hashes

Hashes for Xgua-0.0.2.tar.gz
Algorithm Hash digest
SHA256 a49ffb71dc577277c71420761783ed7ce9b61b64e569e0ac825122f2322fb352
MD5 4e0f7eeaae7608098e17816d8323f4d3
BLAKE2b-256 c0b8fdb2f7f567974156686b49a0f3fee7ff83abee88975e289746965e88ba6c

See more details on using hashes here.

File details

Details for the file Xgua-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: Xgua-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 5.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.10.11

File hashes

Hashes for Xgua-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 cfe21ca4255147090ca23f90dada9fe71c3a468248499e47357413f3b669a1df
MD5 7710119fc12b164ca8917246536ea513
BLAKE2b-256 0983b3552d5095303ae9ebe130f7b8848fef69c2b62e5c34efc60da19acf13c7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page