https://github.com/optum/legion-data
The data gem for the LegionIO framework for connecting to persistent storage
https://github.com/optum/legion-data
legionio mysql ruby sequel
Last synced: about 1 year ago
JSON representation
The data gem for the LegionIO framework for connecting to persistent storage
- Host: GitHub
- URL: https://github.com/optum/legion-data
- Owner: Optum
- License: apache-2.0
- Created: 2021-06-01T22:09:03.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2021-06-09T19:10:54.000Z (almost 5 years ago)
- Last Synced: 2025-04-14T15:22:02.538Z (about 1 year ago)
- Topics: legionio, mysql, ruby, sequel
- Language: Ruby
- Homepage:
- Size: 22.5 KB
- Stars: 1
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Security: SECURITY.md
Awesome Lists containing this project
README
Legion::Data
=====
Legion::Data is a gem for the LegionIO framework to use persistent storage. Currently only MySQL is supported
Supported Ruby versions and implementations
------------------------------------------------
Legion::Json should work identically on:
* Ruby 2.5+
Installation and Usage
------------------------
You can verify your installation using this piece of code:
```bash
gem install legion-data
```
```ruby
require 'legion/data'
Legion::Data.setup
Legion::Data.connected? # => true
Legion::Data::Model::Extension.all # Sequel::Dataset
```
Settings
----------
```json
{
"connected": false,
"cache": {
"connected": false,
"auto_enable": null,
"ttl": 60
},
"connection": {
"log": false,
"log_connection_info": false,
"log_warn_duration": 1,
"log_warn_duration": "debug",
"max_connections": 10,
"preconnect": false
},
"creds": {
"username": "legion",
"password": "legion",
"database": "legionio",
"host": "127.0.0.1",
"port": 3306
},
"migrations": {
"continue_on_fail": false,
"auto_migrate": true,
"ran": false,
"version": null
},
"models": {
"continue_on_load_fail": false,
"autoload": true
},
"connect_on_start": true
}
```
Authors
----------
* [Matthew Iverson](https://github.com/Esity) - current maintainer