{"id":23415856,"url":"https://github.com/gutenye/sails-rethinkdb","last_synced_at":"2025-04-12T07:44:57.894Z","repository":{"id":50470775,"uuid":"47165796","full_name":"gutenye/sails-rethinkdb","owner":"gutenye","description":"a RethinkDB Adapter for Sails.js","archived":false,"fork":false,"pushed_at":"2017-05-24T08:47:35.000Z","size":26,"stargazers_count":16,"open_issues_count":1,"forks_count":6,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-12T07:44:54.090Z","etag":null,"topics":["rethinkdb","sails","sails-adapter"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gutenye.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-12-01T04:37:44.000Z","updated_at":"2022-07-29T10:32:29.000Z","dependencies_parsed_at":"2022-08-30T22:30:21.303Z","dependency_job_id":null,"html_url":"https://github.com/gutenye/sails-rethinkdb","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gutenye%2Fsails-rethinkdb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gutenye%2Fsails-rethinkdb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gutenye%2Fsails-rethinkdb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gutenye%2Fsails-rethinkdb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gutenye","download_url":"https://codeload.github.com/gutenye/sails-rethinkdb/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248536977,"owners_count":21120684,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["rethinkdb","sails","sails-adapter"],"created_at":"2024-12-22T21:28:32.518Z","updated_at":"2025-04-12T07:44:57.866Z","avatar_url":"https://github.com/gutenye.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"sails-rethinkdb, a RethinkDB Adapter for Sails.\n====================================\n\n\n[Homepage](https://github.com/gutenye/sails-rethinkdb) |\n[Documentation](https://github.com/gutenye/sails-rethinkdb/wiki) |\n[Issue Tracker](https://github.com/gutenye/sails-rethinkdb/issues) |\n[MIT License](http://choosealicense.com/licenses/mit) |\n[by Guten](http://guten.me) |\n[Gratipay](https://gratipay.com/gutenye) |\n[Bountysource](https://www.bountysource.com/teams/gutenye)\n\nContributions are welcome, the code is well structured and easy to understand.\n\nInstall\n-------\n\n```\n$ npm install gutenye/sails-rethinkdb#master\n```\n\nUSAGE\n-----\n\n```\n# edit config/connections.js\n\n  rethinkdb: {\n    adapter: 'sails-rethinkdb',\n    host: 'localhost',\n    db: 'test'\n  }\n\n# edit config/models.js\n\n  connection: 'rethinkdb'\n```\n\n[Connections Options Reference](http://rethinkdb.com/api/javascript/connect)\n\nnative() method\n\n```\nUser.native((err, table) =\u003e {\n  var {conn, r} = table\n  table.filter({id: 1}).count().run(conn, (err, result) =\u003e {\n    ..\n  })\n})\n```\n\nRelationships\n\none-to-many: `r.table(\"posts\").indexCreate(\"user\")`\nmany-to-many: `r.table(\"tags_users__users_tags\").indexCreate(\"users_tags\")` `r.table(\"tags_users__users_tags\").indexCreate(\"tags_users\")`\n\nAssess rethinkdb\n\n```\nsails.r\nsails.conn\n\n# Some times you need create index manulaly\n\nconst {r, conn} = sails\nr.table(\"tags_users__users_tags\").indexCreate(\"users_tags\").run(conn, (err, result) =\u003e {})\n```\n\nRoadmap\n------\n\n|                     |                     |\n|---------------------|---------------------|\n|Sails Query Language | [80%](https://github.com/gutenye/sails-rethinkdb/blob/master/lib/query.js)\n| create              | COMPLETED\n| update              | COMPLETED\n| destroy             | COMPLETED\n| count               | COMPLETED\n| native              | COMPLETED\n| join                | COMPLETED\n| stream              | NOT\n\nQuery Language Different from Official\n\n- contains is for array\n\n```\n{tags: {\"contains\": [1, 2]}} means tags.includes(1) and tags.includes(2)\n```\n\n- limit, skip support string, and limit support -1\n\n```\n{limit: 30}\n{limit: \"30\"}\n{limit: -1}     -1 means all records\n```\n\nDevelopment\n===========\n\nContributing\n-------------\n\n* Submit any bugs/features/ideas to github issue tracker.\n\nThanks to [all contributors](https://github.com/gutenye/sails-rethinkdb/contributors).\n\nCopyright\n---------\n\nThe MIT License (MIT)\n\nCopyright (c) 2015-2016 Guten Ye\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgutenye%2Fsails-rethinkdb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgutenye%2Fsails-rethinkdb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgutenye%2Fsails-rethinkdb/lists"}