Edited README.md via GitHub

This commit is contained in:
1602 2011-10-07 00:21:27 +04:00
parent 098fa9897f
commit 40b346d326
1 changed files with 15 additions and 7 deletions

View File

@ -1,6 +1,9 @@
## About
JugglingDB -- cross-db ORM, providing **common interface** to access most popular database formats. Currently supported: mysql, mongodb, redis, neo4j and js-memory-storage (yep, self-written engine for test-usage only). You can add your favorite database adapter, checkout one of existing adapters to learn how, it's super-easy, I guarantee.
JugglingDB is cross-db ORM, providing **common interface** to access most popular database formats.
Currently supported are: mysql, mongodb, redis, neo4j and js-memory-storage (yep,
self-written engine for test-usage only). You can add your favorite database adapter, checkout one of the
existing adapters to learn how, it's super-easy, I guarantee.
## Installation
@ -79,7 +82,7 @@ Read the tests for usage examples: ./test/common_test.js
## Your own database adapter
To use custom adapter, pass it package name as first argument to Schema constructor:
To use custom adapter, pass it's package name as first argument to `Schema` constructor:
mySchema = new Schema('couch-db-adapter', {host:.., port:...});
@ -89,11 +92,12 @@ Make sure, your adapter can be required (just put it into ./node_modules):
## Running tests
All tests written using nodeunit:
All tests are written using nodeunit:
nodeunit test/common_test.js
If you run this line, of course it will fall, because it requres different databases to be up and running, but you can use js-memory-engine out of box! Specify ONLY env var:
If you run this line, of course it will fall, because it requres different databases to be up and running,
but you can use js-memory-engine out of box! Specify ONLY env var:
ONLY=memory nodeunit test/common_test.js
@ -103,13 +107,17 @@ of course, if you have redis running, you can run
## Package structure
Now all common logic desribed in ./index.js, and database-specific stuff in ./lib/*.js. It super-tiny, yep?
Now all common logic described in ./index.js, and database-specific stuff in ./lib/*.js. It's super-tiny, right?
## Project status
This project written in one weekend (1,2 oct 2011), and of course it not pretend to be preduction-ready, but I plan to use this project as default ORM for RailwayJS in nearest future. So, if you familiar with some database engines - please help me to improve adapter for that database.
This project was written in one weekend (1,2 oct 2011), and of course does not claim to be production-ready,
but I plan to use this project as default ORM for RailwayJS in nearest future.
So, if you are familiar with some database engines - please help me to improve adapter for that database.
For example, I know, mysql implementation sucks now, 'cause I'm not digging too deep into SequelizeJS code, and I think would be better to replace sequelize with something low-level in nearest future, such as `mysql` package from npm.
For example, I know, mysql implementation sucks now, 'cause I'm not digging too deep into SequelizeJS code,
and I think it would be better to replace sequelize with something low-level in nearest future, such
as `mysql` package from npm.
## Contributing