Giter Site home page Giter Site logo

pouchbase's Introduction

PouchDB โ€“ The Database that Syncs!

Build Status Coverage Status Greenkeeper badge npm version jsDelivr Hits

PouchDB is an open-source JavaScript database inspired by Apache CouchDB that is designed to run well within the browser.

PouchDB was created to help web developers build applications that work as well offline as they do online.

Using PouchDB

To get started using PouchDB, check out the web site and API documentation.

Getting Help

The PouchDB community is active in #pouchdb on the CouchDB Slack, in the Google Groups mailing list, and on StackOverflow. Or you can mastodon @pouchdb!

If you think you've found a bug in PouchDB, please write a reproducible test case and file a Github issue.

Prerelease builds

If you like to live on the bleeding edge, you can build PouchDB from source using these steps:

git clone https://github.com/pouchdb/pouchdb.git
cd pouchdb
npm install

After running these steps, the browser build can be found in packages/node_modules/pouchdb/dist/pouchdb.js.

Changelog

PouchDB follows semantic versioning. To see a changelog with all PouchDB releases, check out the Github releases page.

For a concise list of breaking changes, there's the wiki list of breaking changes.

Keep in mind that PouchDB is auto-migrating, so a database created in 1.0.0 will still work if you open it in 4.0.0+. Any release containing a migration is clearly marked in the release notes.

Contributing

We're always looking for new contributors! If you'd like to try your hand at writing code, writing documentation, designing the website, writing a blog post, or answering questions on StackOverflow, then we'd love to have your input.

If you have a pull request that you'd like to submit, please read the contributing guide for info on style, commit message format, and other (slightly!) nitpicky things like that. PouchDB is heavily tested, so you'll also want to check out the testing guide.

pouchbase's People

Contributors

antono avatar daleharvey avatar maciej-kisiel avatar nickcolley avatar peterdavehello avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pouchbase's Issues

client Authentication

Hello.js provides OAuth 2 based login in the browser. I've only just found it/skimmed it, but it seemed of interest here.

Password is stored in plaintext

userDoc.password = uuid.v1();
userDoc.thepassword = userDoc.password;

This means the password is stored in plaintext in the user document and is readable, at least, to the user himself? Is this a good practice?

Perhaps if the _id of the user document was something like a hash of the user's email, not the email itself, no one would know anyone's password?

Stop using CouchDB users

Now that we proxy everything, there is no need to use couchdb users system, we can store tokens for users in any plain databases that only we have acccess to.

This has the added benefit of meaning we dont need to use couchdb, pouchdb-server will work fine too (in fact, use pouchdb instead of request in the client and we dont need an additional server)

I would like to keep couchdb being the default option for now though

Get demo working

So to get this first working version up I am going to skip review and just use this as a global issue to just get a demo working, It will be easier to get something up and running then we can go back to review systems when it works

Initial REST api

So on the back of the wireframe, I think theres a decent idea of what we need the initial rest api to look like

Setup tests

I think we should add a few simple regression tests. It would make the development faster, because after making some (especially small) changes there would not be a need to check if everything still works by hand.

/logout does not work

call /logout, it return 'bad request 400'
Error: invalid json
at parse (/home/dir/pouch.host/node_modules/body-parser/lib/types/json.js:72:15)
at /home/dir/pouch.host/node_modules/body-parser/lib/read.js:98:18
at IncomingMessage.onEnd (/home/dir/pouch.host/node_modules/body-parser/node_modules/raw-body/index.js:136:7)
at IncomingMessage.g (events.js:175:14)
at IncomingMessage.EventEmitter.emit (events.js:92:17)
at _stream_readable.js:920:16

HTTP error status codes

Right now if error occurs during authentication we return 400 status code. I don't think it's the best choice, sometimes we should probably use 5XX.

Changes feed times out

Since we use pouchdb-server on the backend, it doesnt request the timeout option in long poll changes so pouchdb things replication has failed, need to fix in express-pouchdb but tracking here

I keep being logged out

We use the default session handling in express, I assumed this wouldnt persist across restarts, I wrote a test that checks that it does and passes, but I still get logged out when restarting the server occasionally, need to figure out whats wrong with the test + use persistent sessions

License

Shouldn't there be a LICENSE document to allow people to work on and use this project?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.