Skip to main content

Log to an SQL database from multiple threads.

Project description

README

Log to an SQL database from multiple threads.

This program allows you to log information to different topics stored in a database file, extract subsets based on certain condition, as well as converting such selections into dataframes.

Run instructions

Note, only tested with Python 3

  1. Create an account with Amazon Web Services and create a MySQL RDS database instance

  2. Clone the repository

    git clone https://github.com/robotpt/sql-logger
    
  3. Install the dependencies and setup the project with your Python path

    pip install -e sql-logger
    
  4. Go into the sql-logger

    cd sql-logger
    
  5. Create a config.yml file in the home directory that mirrors the following. If id is left blank, then one is assigned based on the next available id in the database.

    log_info:
      database_name: my_database
      id: 
    sql_database:
      host: <url>
      password: mysecretpassword
      port: 3306
      user: <user name>
    
  6. Tests can be run with the following commands.

    python3 -m unittest
    

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

sql-logger-0.0.1.tar.gz (5.5 kB view details)

Uploaded Source

File details

Details for the file sql-logger-0.0.1.tar.gz.

File metadata

  • Download URL: sql-logger-0.0.1.tar.gz
  • Upload date:
  • Size: 5.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4

File hashes

Hashes for sql-logger-0.0.1.tar.gz
Algorithm Hash digest
SHA256 b2ecf3fcfc2186a00999824dc46a31fe946230d1a002425135430b3f0c045d7b
MD5 c2318529081194d608ab5654a44d7b5b
BLAKE2b-256 18ae59b5f984b12eea9a11db3f15e58f8e9c4207c2d49b394b29236f528b7787

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