Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dplewis/parse-server-mysql-adapter
MySQL Adapter for Parse Server
https://github.com/dplewis/parse-server-mysql-adapter
hacktoberfest mysql-adapter parse-server
Last synced: 1 day ago
JSON representation
MySQL Adapter for Parse Server
- Host: GitHub
- URL: https://github.com/dplewis/parse-server-mysql-adapter
- Owner: dplewis
- License: apache-2.0
- Created: 2017-07-13T06:51:45.000Z (over 7 years ago)
- Default Branch: main
- Last Pushed: 2024-11-01T01:23:08.000Z (2 months ago)
- Last Synced: 2024-12-25T08:07:47.831Z (9 days ago)
- Topics: hacktoberfest, mysql-adapter, parse-server
- Language: JavaScript
- Homepage:
- Size: 55.7 KB
- Stars: 47
- Watchers: 5
- Forks: 13
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# MySQL Parse Server Adapter
[![Build Status](https://travis-ci.org/dplewis/parse-server-mysql-adapter.svg?branch=master)](https://travis-ci.org/dplewis/parse-server-mysql-adapter)
[![codecov.io](https://codecov.io/gh/dplewis/parse-server-mysql-adapter/coverage.svg?branch=master)](https://codecov.io/gh/dplewis/parse-server-mysql-adapter?branch=master)
[![npm version](https://badge.fury.io/js/parse-server-mysql-adapter.svg)](https://badge.fury.io/js/parse-server-mysql-adapter)
[![Greenkeeper badge](https://badges.greenkeeper.io/dplewis/parse-server-mysql-adapter.svg)](https://greenkeeper.io/)This is database adapter to add support of MySQL to Parse Server
## Setup
Runs on Parse-Server 2.5.0+
Runs on MySQL >= 5.7.Create **one** Database using the MySQL CLI or Query Expression Editor on your MySQL instance.
```
mysql> CREATE DATABASE `database_here`
```## Usage
```
const uri = 'mysql://root@localhost:3306/database_here';
const { MySQL } = require('parse-server-mysql-adapter');
const mysql = new MySQL(uri);var api = new ParseServer({
databaseAdapter: mysql.getAdapter(),
appId: 'myAppId',
masterKey: 'myMasterKey'
serverURL: 'http://localhost:1337/parse'
...
});
```
This adapter is backwards compatible with `node-mysql`. You can pass connection options into the adapter.
You can find a list of available options [here](https://github.com/mysqljs/mysql#connection-options)---
## Limits in MySQL
Just like other databases MySQL has also some limits that are documented [here](https://dev.mysql.com/doc/refman/5.7/en/limits.html)
## Compatibility with Parse Server
Please remember MySQL has recently added a JSON Type in version 5.7. This adapter tried its best to simulate how Parse Server works with other Databases like Postgres, however these features or functions won't work as you expect. Features including JSON and Array will be improved in future updates.
- **Removing From Array** : You can only `remove` strings from array and only one.
- **Regex** : Limited support for regex.---
## Logging
You can enable verbose logging with environment variables:
```
VERBOSE=1or
VERBOSE_PARSE_SERVER_MYSQL_ADAPTER=1
```