{"_id":"@atlas.js/mongoose","_rev":"28-e3d8d4e47b6d2129891dbb1f7e3db1f9","name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","dist-tags":{"latest":"3.2.2","next":"3.2.0-alpha.7"},"versions":{"0.1.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"0.1.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^0.0.2","@atlas.js/service":"^0.0.2","babel-runtime":"^6.23.0","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@0.1.0","_npmVersion":"5.3.0","_nodeVersion":"8.3.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-f3n6DAdgK4zD/Ozv78jThkOp45mcUAnSVNTMVG9Wmz+h7TjEILzxxx6FyEg3AUR9wV8GR3GNy7Z2XdZIu1/TZg==","shasum":"c27a3df74e09fb21178339ea7d788bb81a1b25b5","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-0.1.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDrvIhYVoMQSeM/ulacxHiB1hSy0oBtElgh1SFGIrZsfQIhALVP0m4E1vDtyu2ewR3LVyTPsUXCGIKrqjNlI3kStTAZ"}]},"maintainers":[{"name":"robertrossmann","email":"robert.rossmann@strv.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-0.1.0.tgz_1502872976763_0.9979157431516796"},"directories":{}},"0.1.1":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"0.1.1","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^0.0.2","@atlas.js/service":"^0.0.2","babel-runtime":"^6.23.0","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@0.1.1","_npmVersion":"5.3.0","_nodeVersion":"8.4.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-e7BX5iHokEv4JrI0DyPZeSpl5R6XwgXifhF2UAteFOQ0bge4o58mmgCZS4ZKD+KKjBhic+LdLWHbm2TAz6Rn9A==","shasum":"4ce28af542b24416445a4afe42f2f796ec317c69","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-0.1.1.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIC3b+N82IPK4cXSbA0DkTDiwoP8NzKpTTF46QT9TfM4oAiEAyr86gZdpS1KJyoE/Nf4Yk2zV8/BCrLqjzqqxZw0v+eA="}]},"maintainers":[{"email":"licenses@strv.com","name":"strvuser"},{"email":"robert.rossmann@strv.com","name":"robertrossmann"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-0.1.1.tgz_1502891728539_0.4944315238390118"},"directories":{}},"0.1.2":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"0.1.2","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^0.0.3","@atlas.js/service":"^0.0.3","babel-runtime":"^6.23.0","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@0.1.2","_npmVersion":"5.4.0","_nodeVersion":"8.4.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-tXVg3fg0qnloBZvii2QvhukecjAYRGlC0/itDIDm79YYJndZFQZayn191es7pVjjsLPi1rW0p0KGQQxnnaM2YQ==","shasum":"39fafc89ee5c58286b734ac0d98b6fdbfc5ca29a","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-0.1.2.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAMUlwEPSDuQGCt8jaEANRcYDCfOPjJDirK9VqefOADLAiBI8SpHUZK0r6RaBFy83VliKYj/LX1rjpin7WzMdlVilQ=="}]},"maintainers":[{"email":"licenses@strv.com","name":"strvuser"},{"email":"robert.rossmann@strv.com","name":"robertrossmann"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-0.1.2.tgz_1504355316528_0.5343133027199656"},"directories":{}},"0.1.3":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"0.1.3","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^0.0.4","@atlas.js/service":"^0.0.4","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@0.1.3","_npmVersion":"5.4.2","_nodeVersion":"8.5.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-YWExzk9hHxIl9Ch+2DMJ1xU9SmHnnXigR5w/h0hOJGmV5fP7KhxPnMnyQJE/hkcxYaJj/WUoONFvgBxrWX5E2Q==","shasum":"91b10c0e84129887e145691af272d68b28c093ce","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-0.1.3.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCo26lYvPyyqA294OA0s9dANs3YVv4yptncr2GRf0xTCQIga15BarNbN/yedQbtoXVa//X6qJqyAc2zS/HAT7RXHXY="}]},"maintainers":[{"email":"licenses@strv.com","name":"strvuser"},{"email":"robert.rossmann@strv.com","name":"robertrossmann"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-0.1.3.tgz_1506067621968_0.1024373872205615"},"directories":{}},"0.2.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"0.2.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^0.0.4","@atlas.js/service":"^0.0.4","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@0.2.0","_npmVersion":"5.4.2","_nodeVersion":"8.5.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-FOypX+SqazK0ahP1Ni6KJFRBSd2YGdidfn3jNJKzNSEQitZEhIiPCcyeXeIdvGPMnr/maruQbnaeAMSKsCG0Ig==","shasum":"5fb9932d4b8faf56b096491add921829861f3491","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-0.2.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIB1wldsJcjZQHL8eR8Kuem1JoMzfSkTqH9y5mn41m5nuAiEAz4kKWLF8X/RDYGHSO72MQ2RqE+2yW9zHrsQ7/lJFrXo="}]},"maintainers":[{"email":"licenses@strv.com","name":"strvuser"},{"email":"robert.rossmann@strv.com","name":"robertrossmann"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-0.2.0.tgz_1506425708427_0.4005287878680974"},"directories":{}},"0.3.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"0.3.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^0.1.0","@atlas.js/service":"^0.1.0","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@0.3.0","_npmVersion":"5.4.2","_nodeVersion":"8.6.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-41xKP55JRZNNzapW6hwE/zaeKjpDb0VSAe5yIi1RhXaFWcL6DqgvvuWmidu+bzlDo5af6hAK/2Zycl3GGPK5Sg==","shasum":"e43a5a1088391469981fc29a6c9cbff7331c797e","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-0.3.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQChYrAPqtKH2SjQQHxAbX+wO9h2Jx75/k6rGywMKC95lwIgTdrXJnnnWDhgU9ty6a90xORu2fn8uudUwLiEma4vQh8="}]},"maintainers":[{"email":"licenses@strv.com","name":"strvuser"},{"email":"robert.rossmann@strv.com","name":"robertrossmann"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-0.3.0.tgz_1506502230983_0.9981405353173614"},"directories":{}},"1.0.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"1.0.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^1.0.0","@atlas.js/service":"^1.0.0","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@1.0.0","_npmVersion":"5.5.1","_nodeVersion":"8.7.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-A4n1S22kbViy5Hw6bSmJIoy1mJUBzMWRZcoVZ9aMPxEesse0keGHgnGzHqogFLp8jpiY7VN7l0LPbjrE2GCnrg==","shasum":"c4dbe3c756072819bfb3bdc18cc97c5bc1e87e7e","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-1.0.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGbvnG1r+EAbGbixqst3JGaC8Kg5Vafic3K5/Ff9aqolAiBpx462nGILcrxdkFvLevnYS7vHBgVpZOZfrD0obUk3Gw=="}]},"maintainers":[{"email":"licenses@strv.com","name":"strvuser"},{"email":"robert.rossmann@strv.com","name":"robertrossmann"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-1.0.0.tgz_1508878110467_0.5774248347152025"},"directories":{}},"1.0.1":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"1.0.1","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^1.0.1","@atlas.js/service":"^1.0.1","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@1.0.1","_npmVersion":"5.5.1","_nodeVersion":"8.9.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-pr2a9tAFIeEUkLMlOeqppTRjx6zRarJnMJRQKYiFeCxoxCKykhg1/fey6NN1Oj0WS7kIcjJ8ZZw8DWD6FCAETw==","shasum":"dbfb136acffefdabed2947d0f17cc4e0f7e1ad68","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-1.0.1.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD3yPxBn+le5Vzw73/w5L7v3R8PKb4SjXw3nzfAc60taAIhAOuw0JALPDaJOoIYcgo+RXM5E/JE7HMHnoyIxZ425MeX"}]},"maintainers":[{"email":"licenses@strv.com","name":"strvuser"},{"email":"robert.rossmann@strv.com","name":"robertrossmann"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-1.0.1.tgz_1511776463092_0.9873968451283872"},"directories":{}},"1.1.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"1.1.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^1.0.2","@atlas.js/service":"^1.0.2","lodash":"^4.17.4","mongoose":"^4.11.6"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@1.1.0","_npmVersion":"5.5.1","_nodeVersion":"8.9.3","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-VqQLv//kRb7MN9SYgGHJWsMaxfUzgeNIXdpZn0JLGtOIUUL16CbJJrkvERXIdqHb7YVSaAkknB8LYIpy6EgDgQ==","shasum":"cafc1526040f2c35ccad159f9ed414845ee1706e","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-1.1.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIC2g6qY0rnFs0j+X2srEvDBkAehpXh5/Aty6Glay54uoAiA603FATwJG70S3HmMKb6Sd8qyMywfJdLud+EXHNvxwqg=="}]},"maintainers":[{"email":"licenses@strv.com","name":"strvuser"},{"email":"robert.rossmann@strv.com","name":"robertrossmann"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose-1.1.0.tgz_1513166193264_0.6873234084341675"},"directories":{}},"2.0.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"2.0.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^1.0.2","@atlas.js/service":"^1.0.2","lodash":"^4.17.4","mongoose":"^5.0.0"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@2.0.0","_npmVersion":"5.6.0","_nodeVersion":"8.9.4","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-U3Rt+7tBk0Hk6LAXxFEnMPx3kjAY0O3jgKWKtxNWgo2KyKy9NJeodX3NUuRR6s/jFny3JW4NJ6eSlLNMV3jatA==","shasum":"284d20a1f19e8d2488609bf91867f286f0592edb","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-2.0.0.tgz","fileCount":22,"unpackedSize":42202,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEYuKsGQmQ3hXviNGpvO8J5E5/gY2hcqs/HS1mYZ4LonAiBpAhj2Av3JiCBuUcgEElhTTS9TymFT12lbnbu4Mge7yw=="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_2.0.0_1518704949706_0.028605931284308328"},"_hasShrinkwrap":false},"2.1.0-alpha.a596c671":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"2.1.0-alpha.a596c671","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^1.1.0-alpha.a596c671","@atlas.js/service":"^1.1.0-alpha.a596c671","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^1.4.0-alpha.a596c671"},"engines":{"node":"^8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@2.1.0-alpha.a596c671","_npmVersion":"6.0.1","_nodeVersion":"8.11.1","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-tnol9U2RCxGGZlUMDVI6Kasyp39NEYUDjeIFFS3qeAFuTBShTgyDVVIyCAhSBJ5tIx2FmYb2DOHEW2ivzP3CFA==","shasum":"2ebd91c04c86c4b5fae27b12fd2cb314194e2d92","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-2.1.0-alpha.a596c671.tgz","fileCount":22,"unpackedSize":47435,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJa+aTLCRA9TVsSAnZWagAAvEIQAJVErwzIuqCf9WKshwoh\n5PlR+jN6uw5Iqm7ZlNHBVSwxdjbD20zE+nDuHXH/JLEFrIZC5RoxVcQn45oU\nGOTTgeVqAnhnhj3VAO6ke12j17nFNZtAPNYxHdSFwNDvujFPl6oN44n8uu0z\nfMTdDgWcIQPuXuLT0uIgbVPYQz9X6S3Cpc4L+2hJEZM8yIbTYKqajlggRm7K\nLeHuZEXF8vkzGYZ7xKXdagD2rPSXeUB0JlW/DlVrqG6J7B/KvewlpRNQgkG4\nrM4ZApUONau/Hu9kLEWcUPN4VK0GqP8aofXIULO6yiLTK95CIAx6zC1CKCJ7\n793kMqY7lZJa4TIzxryNjmb3VfZboFKUeh8m05ULT/tsjuHvZDpPZM3AlnzS\ntCItNYMmNyKwa66zWHy84FGAmyxdhfZZEQiFEdVeokh+QKDxnZBOXgKx9fB2\nIDksno4F6GxjH1U7pEnvSbJWV4pmFWxnf+wSuBSTtgiDZbfyBBq9SGjWCgB0\nMiOyjp7t1ctv3dJK1TYReLvnatdrADcwE9mOPMmZ6UCl+LaaltRa6Nb+RCaJ\nMBySuyFSfE73WkmctAd7LtXzE5tDl7zli1WEsbWkfs2b8FDFv+vVEIFuDCP9\nB4doF1wItRV0r/mZcwdmru5Ot6cmKzFmgoCp1zVCIv7TjD/QRXGSG6Tpsqw3\n+egj\r\n=KoTP\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCXeLal6JQukHxMJl2hh5nadbVOTeBJjtGy44K4UR0GJQIgIu1hqsIsD8ZxA79N/36Nj3YRX+4EiBh6M+a8TXNy6DU="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_2.1.0-alpha.a596c671_1526310090942_0.9678356945188797"},"_hasShrinkwrap":false},"3.0.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.0.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.0.0","@atlas.js/service":"^1.1.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.0.0","_npmVersion":"6.0.1","_nodeVersion":"10.1.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-VaTtN5lkIFZn+DJsY6MGY6Yl3p0EJCX+0awmcqC5KOwRzEbRxPSE9kFY9NddMCA8Dr+EGip7uRceFW6JvgXcaA==","shasum":"fb6cd2c85f4037de810a74ddbbbb2301415f7b80","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.0.0.tgz","fileCount":22,"unpackedSize":47453,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbBDkeCRA9TVsSAnZWagAAwFoQAIQBKi9V0QQ53xIB3JCh\nV+/m9qjZqJnbcXtfRPzOGYww3J1r2JJDF9fR8dAl4JjHJXTARxI38MrzLdfV\n263PU9H36Q/u/io2GMLSi3SE9P91zUZ9iOhHt2sCAmI1M0Ax07/jZlgwZ0qk\nSwXdzjRXZjWOPPH1Gyo68YiscDUn4Y2Uhz2TRCHRWGAQtSH5pTsnlykENfYQ\niDE8dnUKZ6t3SAu1xP5gi9ejPfwBOhKHb+yUTAKX9/2KW1ngDkEiGC4vrnMR\nAa0RPhAdvgV5fUc9jCAMiAnin/av/th+h6Sm0tqpTBRMQ0basePfwXPHup1s\nbORUlHNC4PnnnTjiUXNbsmPhmUXR53EOEi0SoPVmKqGCxfjYtnSJr0ghzpH2\ndS3t4f91VIrhZ5AwejnVwT3Fu55QI00T6WmdLrQIKh+JBMniKwQz0syvH7A/\nK0pvYT4Fxn3G/HoVdSJ13HXR2CO99MHKfVMwM8OhCUyi+1obhJIoyMIB5Z3O\n6AdTC9huFzB7+cs36fIEXqKozWiGfiFO2P4yNjXUFgWopxHGi6XPYxWikepk\nHu54Lo7hi2Vz3OMoxRaNaujwbBmRXyMfCZC7pM8vRWMLTSsmW5c/IQ0rfW0x\nkZT/hS0PnbSOWqI1Ax3bL8ixRxXQE1+o0fA2jRUd/FP9HeRgWeWJfdbSlP0u\nxA2k\r\n=cWSm\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC+ifnXPivGj64ZIGm0RnBiR5vYq3Li9b4I1MjXgCuCZgIhAJDofHojeKWtLs2eJneFYSXQjwWaxbWI3MTOP2J40dn5"}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.0.0_1527003422315_0.3480411104216712"},"_hasShrinkwrap":false},"3.0.1":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.0.1","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.0.1","@atlas.js/service":"^1.1.1","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.1.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@3.0.1","_npmVersion":"6.1.0","_nodeVersion":"10.6.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-NdqkdcuXBrmSySBTbSSNTlEclezpcZTlWZLNiqCVkb9KA8rGzoshZHgPc/+tWGewN5vltqMs1UrzjgP5UVi9Ug==","shasum":"18f431fc4b3032bc3bec954c5fe74d1e242ff5f9","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.0.1.tgz","fileCount":22,"unpackedSize":48650,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbR0orCRA9TVsSAnZWagAAz5sP/2cSohTv4iUqYF/HDGNG\nqfzSg3gvLfrYVO6j/HqYSPi2QFBjgy2ikFHYgqP9/DPOvTrd/QFJg+kiCArY\nqQLjzm3+hImfALVH6dwSI5crsl1e0kOGUQgx3oPoWoNIoZZeY6Fx4sOcOK3z\npJYqwr1KnOkKEXvmaylUZPyKpJKb8j51RiRcRI2JdJ8n9WXNVlW/0z1FSyAh\nDM45DuJXqL1I2SJEFv/zeRImfSrDVry6gOZTM1IzDHmHtKNrYttmLUuclA2g\nfuGo0NPKmAGsDOHdROp7TBOJEA4JOiBiYvE0Pq/1TdU7xTXLSVUYEPp/PSbM\nhET0duEMsdN68Fu/dj6wqMjXiHdNAggZmegEU1ISKLNsKJcgF9HbyboWPlVK\nEvl4Gk3omWQfCDBuJBJzO+NU8VlY3pG+4lJI0Qvmzw9aBRaYqJInlIIdjQ9O\n5eXwRRuaizjnQJn6wkWNuaKFekplev0hIRhX+taUJj1TZYG3+xjCmhA544oF\n99gKXJG2HdgK+BVGNIjgw0FyvZojDQIP+iB50VIKD0jx4Ok0VYezF1uW0i6r\n+WPNoGTss1a0DvomVy6r4WNTJZX1PdhwpmpQZf11gziZ54nmKA2uiExA2AUm\nUTPBU+86LG7ZRAf5OYxQzl8TtNZGexu8C/QVkEobgREPLdxi0oEGammkiki7\nTLz7\r\n=4BU1\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDDJzxQJsId5S7h5RAhiOI7mo0rC7sJQwffEHjrVspn2AiADdSyRr6dvgJkaf+O2jwdAEHo9VSMNB1zLSbJu545tnQ=="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.0.1_1531398699033_0.4174692034129819"},"_hasShrinkwrap":false},"3.0.2":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.0.2","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.0.1","@atlas.js/service":"^1.1.1","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.1.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@3.0.2","_npmVersion":"6.2.0","_nodeVersion":"10.6.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-fQtEk0oRzyLnArgNL5LiLslzMRRER89XBhMAz2OD9mWMm0E5wV7dWHy74xA5zJQjRcMWP+kUdVsBF25IHwS5wA==","shasum":"30bc67bdb6a846600cef17cc65b517a77fd4f1ba","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.0.2.tgz","fileCount":22,"unpackedSize":49074,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbTDJhCRA9TVsSAnZWagAAoNwP/R0YAS/b9/eTrc5Ioahv\nTniD0jJe6ISDpY7EwLPC2LQS010nup9pqnSePcq4CbXur38WVNwJRDRBoZJs\nTDAh8E2bV/aJbBntydSrJEnpe1U7gLl/DOV9H2KtIJV0hU8N5VaW3mupDWSJ\nTh6iWNiwkqFzHT0CkLJzIrW547x6Zhut9V5mSh7/Mh06ZkY3MrrrgIJW6ctv\nMBr7G+l4Auesqet0iCXsvZvFZ2c/ioPcE/2xtS0OzAylRCPK78qCK6V6E4Of\nIgmUmFggwFhwcRhNqSkY919erFyWrKnS281w78eveIz0DYOEzUPtQfJgVXBa\niyfrrmJoetF1R2N0HgO0UV5/f8/3Z85LQyNk3U/n5noVN+neHcCrcMCBn1yG\nqyg0i0TL0gmwPYZ2dLwxIteogWg1juOkTSjqm2urRrdwRhki37FYif8uLQpq\niN6iGOk5mD8YYIZxfaQ2QcPU37yOvww481Z+uTpkOa86UzanTj8E3oyMkPT7\nC2oslp+tnvSAiSNL5i59bnXt/k6GwvptVtKXhZbLOD3oRef9b8KM34yoKuhG\nxnEN407Hnxnno8qiXnCl2Sgq9I9am7UR2hvcq1CPTTXTL25NAYFFdugsqcUp\nYRlD7xIGb8FCOgo1ZsRv1AB3SSQ/AvbErBN3kobNwxa+7vYDQelIFBYrY91z\nwby5\r\n=McGl\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFgQ/jd1c1LY/YeT9cnw1iSvA5IppHRSNw8gMFz/LOcJAiAotmyLbQoqudb3kqO+oQowp1WjCJb9zMGhvDa9fIWXmQ=="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.0.2_1531720289235_0.8257828221468266"},"_hasShrinkwrap":false},"3.1.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.1.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.0.1","@atlas.js/service":"^1.1.1","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.1.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"_id":"@atlas.js/mongoose@3.1.0","_npmVersion":"6.2.0","_nodeVersion":"10.6.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-cUBirXjn4bnPwxXepWG3pJc1undgqX8xyJP6zTwQSWp+7gQIC9TXlfugjnjpSCv3PQYUWfaf5GLSHJSKEc+zBQ==","shasum":"4b52da1bc7613a06f4d35c5f1e04f798bc5c0416","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.1.0.tgz","fileCount":22,"unpackedSize":51676,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbTeEMCRA9TVsSAnZWagAAijAP/3cDanW8WT6IeOfSjTNz\nxwEE3D7/uINAJlbrt1HPsIlAKGmdVjsANpbnrHi9PZhRD6cl71fSJD4Iyf9R\nE8RVRcHEtEtUpSEkx7Ms3o+m9QThRbGGS3DU91jZ3ci2uFjN65dYr5YvIiL3\nc0XPxeAQkgr1aDpvLzwyjchXVxAca+b7pK/XTWj2PJmNf0HfrnDV8Hd8Abm8\nXluEQC2Lu6DcH2f/eveUxCQhNX2lgh/OXN0RUpaoCjtleozOdxtcS9ff9N0V\nUwbHw+ECAIBoBf0G3lrgp/m747EliiFF9dY3nZDxS1ziFvmzmpro497DfZyZ\nupodevjltn8R0yJreyeaaw3HTfS364a0tJ1eXmFWHZ/oJPuSH+3KGpqr006i\nwX1G8fiA3msqkWd7/ThDuTSAn+jY8q+Oh2Beshn5TdyImmUKmw6QhFi6cv9I\ndiEXWWQriZZ/oyNWqR3dcCvbKaI5oH0JCVWCL7u/G4xzAjF14ZtjkRGIWuxR\nm4LqlxGsDQPYVNBELN/oTrAYTAZDzAsngxonzuXpIp8fRbwxw9Lhe7vOTq/L\nEkKQ29rw7G0pkTeaMRLjlL+sY9c8H4gZi2O2+HkeL/EXSAaxtKEnk+mDI0HU\ncJvPwH9B3J2a/7VojUw7tAyWStC1BOlUpOlx65zBvax3RiyC5jX025UbMcJv\nH0mq\r\n=B638\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDPXCcahcL4PJ9t9Clnxue/Ilgsvh0eAg++upv7j+P2fQIgPlXDDIoI/wy6g5ocwPUQtOUUxct5vmrDuSd79LzpneU="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.1.0_1531830540873_0.8647424257400731"},"_hasShrinkwrap":false},"3.2.0-alpha.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0-alpha.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0-alpha.0","@atlas.js/service":"^1.2.0-alpha.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0-alpha.0","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"8b6af27b5ca8e64ba5dffa05e92c01d804dbf6f1","_resolved":"","_integrity":"","_from":"file:atlas.js-mongoose-3.2.0-alpha.0.tgz","readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.2.0-alpha.0","_npmVersion":"6.4.1","_nodeVersion":"11.3.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-LBlrnnmHcPPkkmRqpKMe3nCTJxMN2vmLYflKMOrZXcx2ZBdfiREY5vURDKuXUN8R29TYW1vjoRQPpb9bswBOlw==","shasum":"ea5d2b14f2983c4b55aae737fe2ebc1d68c3540d","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0-alpha.0.tgz","fileCount":25,"unpackedSize":57228,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcCnM4CRA9TVsSAnZWagAAIlUP/jR9lFu3YCqI802OkGbG\nqDFRKfq5wFf03np6JZPsFzbb2CQpkFDlppOjTr80uSQsuRFw2vnQimU2iU9d\nRPI+XxZ86EwYAw1/ZsoQK6RXqi76fVBBC1+kjUcQ31YSABCbQUJlWxswjw28\nnFERjkO6grKyz5Pa3SaFkdbscIqWiVWfbz7oOr5APnol616IlNpwMORV2ODb\nhKUAuSUWU7EKjlkMN2GNEv9Dh5pYyjTjCTFMIvSj3tygphPumny5MRGTIw2k\nqSpEOHHNGakU0of4Xp7iVSmROBCmVbGU8gJ1MrJt0y2JSFMAMyHB8Y5+gjrY\n0uOvOEa/5mUTflEA5snCm8TQioEmdWpP7B4CTOa3qH/bpio0Q+Dw0VvRiS+V\n7uAf3JqGXI4axvM4x4fG6/164WSomWFsCUFsx8bxKACdMdDCponilaA2unB6\nrZ5FY3wDcoqojE8a3DfpffLJ1TKYS+THLRNKtbAWtcrr/WKha/J7GppZ6h7i\ncXw90Z/gh7hBG0UadWgpKAuq8I3B8ynDYqmp+sDQUtONZPZ/OI486UBz5V+3\nbOuxFLCuGWhwpxeS28cCScabfW3lvd1TuDeOKyns73iHopqj8B887h5K52h3\ny9++mnR8+LcAez8Rp2qiHkjyx1MJsWnX0GOiCVx4MR3OVlGJNnwisgTpv9PD\njRJy\r\n=2dY0\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDnsi/9/mpxoutfVtKfT1rIYHrGAD4ppxUUPyeRET2iXgIgPdKmfD6am6nWL8F1ojhOhcOhrxmHoNCg9NeDrQq7uBs="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0-alpha.0_1544188727775_0.7358361116318002"},"_hasShrinkwrap":false},"3.2.0-alpha.1":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0-alpha.1","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0-alpha.0","@atlas.js/service":"^1.2.0-alpha.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0-alpha.1","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"e58999d8f2eee67c5e5e0f079f273f65ee9932fa","_resolved":"","_integrity":"","_from":"file:atlas.js-mongoose-3.2.0-alpha.1.tgz","readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.2.0-alpha.1","_npmVersion":"6.4.1","_nodeVersion":"11.3.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-PwuB5P/VfMkYijPr5V3iQXjSl+Jt7KRSkxMD8ksKc/Ki/Xxz45TDooJxmnCx+PcOxV+W8bEOnukAbokvlqHNZQ==","shasum":"233c25e068eaf5951aa0bde905d63f9d0de12350","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0-alpha.1.tgz","fileCount":25,"unpackedSize":57222,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcDi1iCRA9TVsSAnZWagAALuUP/2A4go6NhkRUsHmNyqv0\njrWaj3QfSmFu+28hrvT+STt2FCnQSlNY1iK4GOWNCwlO78ZGlaRJGy7Ib0sf\n1yAaVOu+2j2DGNS3MpSIuXrioDmmy8prdb72+ivHgALlSPMxvquDQ6x7gMXz\nDQi0tD20toIYjGiIdyVYOi3WD/+Q4ySVMeetkCXHtQbVy66n2MQUkbHmt3ML\nQNRWcFsI4fIbTiSpE173pUQV+JHA2ahn+dO1VDKYW/oYTRLaPmnUIN8a9WM+\n/KIzGP4P/x8Dk0/bBB8Q6ePIRbRGCFF8jnP/Xpf4qB3gbQ5zPWu0HoiehOiS\noMnQDGtHSBSSSvd5CyGmI94bsNeQhEkwPlGeXIdioxgksKUvbyPSogg5Ylng\n845Wxt5m6wBi/14lmGn+mNXABp0w0+8lTYhXYczPf4H53YLRjnd6sGk1S3Gn\nePMPsw3fs9NLON6XXW/oyzLobP20lBi28m2nLRTj1Tl82Phlnxt9aVq6bskW\nvKrbXoQlGLdygUZmbTbP92XsLPiYWzAvmsvjI9HAqBPia1R0M18Fsq3V9hhb\n+Jiw9alnCVMfLHt88Feha+Z0WyfwmHXr0rHuovQTRkKVPEtevakbMCKtI5Zp\noqsbUvc6WZPywjs7l6069iVHoewqg+Hv8V3ujt1YIps34vhnNciWNzSWY11i\nIM+4\r\n=zHtQ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCzRLjAXA7F1C8NudPWTezaZV1FUQ+ODug789roEa8ELgIgYDV6nS841Tk4e0vzdYGsp5vY2OezlGVyH1H5NrTBp2c="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0-alpha.1_1544432993276_0.945432140576403"},"_hasShrinkwrap":false},"3.2.0-alpha.2":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0-alpha.2","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0-alpha.0","@atlas.js/service":"^1.2.0-alpha.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0-alpha.2","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"7b27ac160fb022b2f275b850faa70b26347c339a","_resolved":"","_integrity":"","_from":"file:atlas.js-mongoose-3.2.0-alpha.2.tgz","readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.2.0-alpha.2","_npmVersion":"6.4.1","_nodeVersion":"11.3.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-994k15KmqkmugBL6z9Pw3zTUjKDNf1jO1jpJAwwtaQF8Lq3D4Vq6g8tjmMN4WsBrp6SqlnmIQZ9TqqHOn5zWrw==","shasum":"c4feefb8317153ccdb77ca3e33b485311fde866a","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0-alpha.2.tgz","fileCount":25,"unpackedSize":57222,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcD7e6CRA9TVsSAnZWagAAogEQAJyE3Jfxzy5Ce7m1M630\nsRBs8hyEi9n5Z0ysbZQ0/KUJ4ED1c5l5vkY8BTnGzv+D4FUQtkk2ClXESSuQ\nObQI3OwTsstQXfOpD6g7bV/FZTgyRnivt20db4Ad5nbMMdfyS5elR+48lZgb\nTBjiEVUyMYtoTSN1+AHd93k9v65fZavg0KR0/vR3UxK9zoOWNZzes81Agub7\nvdxLwbeFL0U6JtTIVpItPTIvHEH9SGoOu68cAA0W4RMiNTlGeUNzwAPxeqSa\nF2B6ZbUbr8BG2aj93fFF9lh9QXyG76WsP9BLPmlixhM46bb0skZ3Psz7o+q6\nxP3oZvlsdvpGsOT98LKCg6Uv1dH2GusLkh19I473gfCc+JdVFghG50tQv/5Z\n+BocUld6QnPN1wP8y+chAQMnRF3wjgEnryFOzimLexnGzWBgzmmObKHwjp+4\neDyLJ8xVy9BmnqXwXAgFaHaZ/pMgYlqJU08n2eskmzZkJkSQRuoJcQgX8pyN\npedjagPKi80cR+vzpL0lu1qgKtVX9TeDd5ARSVxqlzTl7o7Lni5jZ1dhpnef\nCohMoambnwUdd5S2qtdbjffNe4onIxKiImBXHPYtlGN0SJsqRpKINjTNsw7L\n5AYfgpqxuyFZgYLbuiiBiWTfw916jTGBFmqEtXJSYWSBY/buytlla6SRNswh\nK6Ya\r\n=8RyL\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIH/9a77bvQ5Zv+zuL92jBKmPskaq+VpRO7RxKm+G8t24AiBFtCnQ3qPAXgfnLlIhNCnOl3xBZdAvGLdQLN+UwOQG2g=="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0-alpha.2_1544533945247_0.3078802275072201"},"_hasShrinkwrap":false},"3.2.0-alpha.3":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0-alpha.3","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0-alpha.0","@atlas.js/service":"^1.2.0-alpha.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0-alpha.3","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"ee441a017595bb0b88e20eec1df9cacddfdae96f","_resolved":"","_integrity":"","_from":"file:atlas.js-mongoose-3.2.0-alpha.3.tgz","readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.2.0-alpha.3","_npmVersion":"6.4.1","_nodeVersion":"11.3.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-tuqRz4yFvRFvK5bx3PeNQBRBTPmC6AoSvWB9F6dA/1X3IbOYY5UZKp6Jz83XUQ+9gWZ+kiLopeAjZqcT9ZdjxA==","shasum":"2613e498056a873828560005ab7878a77ebd2a4d","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0-alpha.3.tgz","fileCount":25,"unpackedSize":56199,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcEqVMCRA9TVsSAnZWagAAoJMP/RDIvzktJ/r7OI7hBdcR\nrJ3FuBnfUYSf6YpdX6CepYb9iYcebS9pc9NWfRUenN4o7hOST5uRQepDkO7m\ncRxafEiK0PipT90/1YpE4AjEO9RhkS2uM8/Ttva7O96LmpF5nuTm9DV/ZdS0\ndAAmJoobIVIqd26uIGG6sRDVwiqaUSGINusubqlrg9COBC1XA4XC5taQXfVj\nstCQuIfZvXSb6De7uflXq39PR5oCVNBFZ0HRV1yD0E8duIkLZsUwEg5nXQjp\nh8a8l40iRSPJlVM4y+NDzW1Bh7eqW7wctIroMlFQhG9gTNvrHTg9eH1Cb1qX\nE3r5p1hpe4J9wZ6uXx5k/BmgRpMPQLoDg5oVZaLpokY7MG+2HFwIHXDVekEK\nXRztdUwnJQgAYyAnmXASiqQeE6nDAzyXlHNB3cdhR36Kisxl84finlV0Ftvg\na1CWqo4hV2TG6HzG4bGtWwHjzpM7tPSkjTNfuLM/t4MjlAqw1dzY5bb8/sZ9\nvdM+XkL7b+OdJy7LkRQJoX8QMIuOx5Jg4JGP5gOtMDBOzNrpbqFFUudfYr3O\nbbbxrnxooiAl5EcaXVK8NGBJWZJWyQ0enW6NL2iBOSFw4gLeh27FluCeaxSv\nh6Ai+TMhLHlWO+HdTRygnDI+/1SoNPIh8cjy/rpIt4VaQNvF4ro+85d2eTJw\nG5e0\r\n=K41A\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAuFLTsz6AqJihKh58wWbmFayONr0ZNtMAv+hoZbJIW2AiAdDaMzg6ekmdQqRXssxxPlXXcb63vx4VJ0MVvw08c3bw=="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0-alpha.3_1544725835627_0.3643891161873223"},"_hasShrinkwrap":false},"3.2.0-alpha.4":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0-alpha.4","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0-alpha.0","@atlas.js/service":"^1.2.0-alpha.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0-alpha.4","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"5a7ec5098e521b7d14d2ecdf584d1bef188c9bbf","_resolved":"","_integrity":"","_from":"file:atlas.js-mongoose-3.2.0-alpha.4.tgz","readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.2.0-alpha.4","_npmVersion":"6.4.1","_nodeVersion":"11.3.0","_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"dist":{"integrity":"sha512-j2UWVWeo+D4LaL2KNZiwhxBbUiopOQOxk1ezKvkruxfncqAkRygT8uxmjV59cqxA/V2cZtV/cn5gz46UeD1N8g==","shasum":"02f9b85c9175662b3a3343555ddcf14da0eae7d4","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0-alpha.4.tgz","fileCount":25,"unpackedSize":56199,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcGNckCRA9TVsSAnZWagAAYb4P/Al4CDb35KsulC/VDf9z\noAa+/9u/hO1BYr8E1IRX9PDGSuqSunMyR79X1kfo1K2XdBhOx4eQlLL6q+MT\nUaRM3ct6YL6W3OKcGRBWYKhmv4nX8UsfD20E3aHXtRxNt26sdUoA5tKdUvlj\nc0w7QFiFq8EyYpFPsNL1bh+Ph0X9Yc6ptN6QBWP5joUo0/LVA+NPyHfFT+nH\nZbIdUiTtCH8H0Hl7i3FRQhBMlOWZmfw5+VVNeJGku7aB1RzxUUg6M4F1XrYZ\nABMGxmD5aZ97pMQX1kZtG9E4hqzawxxQuCRKLr0uaL3KyAkKgcTHVPjS+yI0\n7L0gdiG8i/Qpi7yyw/I5h0Z5e4qarEYRNrytpJADRoeUM4rkX1ri+QiDHeEt\nY8C/90aCrLV4qcMjtky3GWDPoMTHtGusVGjxAdsgIQdYmbhjPmacnkcng4j5\nlAr3lmsjHriC1AkpZWhel96mZ406pDNaaxdt0bPchpG/4y5MZw8caY8FU/6q\nE4rfnMrwuAk+8uQPRX29bcS3czQvIW2AJ+1EqquDBKfAEduJ6kK43E6JrnSy\n1SgIisiuUy2jBuP7liU8GHVCsZWE0jX+RH60PZxKExLWVHyHu6vjAwMJMk11\njnynfx1QrET9IIBjEjwLnpV0DFJI54mKxINoD44Xn1HCfh38yO+EgxTWpXBF\nCRmo\r\n=e7sv\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCgRcPD/uVDdZvTwKQYgIXIVrW18/oAUTlB7CdigluNggIgODtAux/V1sFiOro2FwZEzwI4qUAU1tTSWr3LKnBu6Mk="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0-alpha.4_1545131811933_0.41963747898426096"},"_hasShrinkwrap":false},"3.2.0-alpha.5":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0-alpha.5","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0-alpha.0","@atlas.js/service":"^1.2.0-alpha.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0-alpha.5","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"8b27d87a507b5ce31392fc7c02b4b3f22b14a163","readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.2.0-alpha.5","_nodeVersion":"10.15.0","_npmVersion":"lerna/3.10.5/node@v10.15.0+x64 (linux)","dist":{"integrity":"sha512-wP25rC3dmVh0xsb73QSfha9P8rsJmyjXrB77wZuB6aEdqnTtwY5KXcXDkQOUEzSLoC12/HTe3rXCxqyvstIWtA==","shasum":"f70c370ff8e753f506d3e8772cb6ad5ecb375b17","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0-alpha.5.tgz","fileCount":25,"unpackedSize":56408,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcPvQkCRA9TVsSAnZWagAA2CcP/1buUwUNJBdPgojKCJw4\n2jGefojAYPWUYILKuoxKZLcQBr407kXWmfKCkfQoXs2mCE9uNRBHstEixouN\n0KY4OKsRtihYq0rx3DyPMG7kcJmM0pc6VkKG0sFNAhpbx/H47b8sA3BHVJKj\ndlYYcBj5TnT31BjzqvAKnQLaDKkcVP2VfnOySH3AbNuDbHuRdXUDtu6K+jJE\nURLa543IqnHTMIhDsg9UIr3u8rAFdKdnc90cRSMugyR6Pp3kfAG5jOGLbFhX\n34ef/e7mJQhfVXMZ807O057VvfLVRrhBFyjfyFyM8XrLxWfBI+zroOyeKHRW\n4Yo91tdhv9KSfFqpfkVTSAFlOFu2juxUJaRNko7lIZD4hKUNr5RUOmQbE2rF\n/e/B82HkiqaP/BSVcwjm4B0LIiCRSnbBJU1KN1v0ZVZyQzmlyc/di5HqDtHM\nLyKprDfyInzJEvB3tXuNaDbMj5eojgAf1EgFcdUKzFXHVob0bw/98DNuFfzX\n5VXlSmpAAVKPSCRZxu+rRHOrrNHy0jclTSgWE1qhg0FmbMz1I6nI0emQY/cg\nItyrm9kbH05QR9IYLqmK1QUDu9t/sZ+bYpWk/WOCH+AlIgQtw6VtXn3w7Kk0\nbOs7Gtm6F4wIWh6gd+VYZn0f3oSh1nSAtUc2Ve/u1Uc6Y3oYZEurd33PXKyb\nVomc\r\n=hYIg\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIF/whPysC+DfzQaWCprkBIGdiJSLWtkWN508MNo4gOFuAiEA0NNxOF0vW6ertWsMwj0OeC0wpBUsAuVrH/2b4iHcbGg="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0-alpha.5_1547629604145_0.13171323732117823"},"_hasShrinkwrap":false},"3.2.0-alpha.6":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0-alpha.6","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0-alpha.1","@atlas.js/service":"^1.2.0-alpha.1","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0-alpha.6","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"39c0427aa76e1003d5f4acf19cee927925ca0ad3","readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.2.0-alpha.6","_nodeVersion":"10.15.0","_npmVersion":"lerna/3.10.5/node@v10.15.0+x64 (linux)","dist":{"integrity":"sha512-lRHm8cxmInY2dgIlZStYlInam4jCrHAEWvqx1HmHyArGbYzZJKDcko5batIWC3eJlSPd/4NP4tzW3/Vye1ubGA==","shasum":"f561ab4b79c0955f8f0f23e9d331b6c6ca2d3776","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0-alpha.6.tgz","fileCount":25,"unpackedSize":56705,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcTt7NCRA9TVsSAnZWagAAOkkP/RHiHFyWmmtzLGu+MCtr\np/xOJ7xuXTuNl6ftABuSkLDTSllxC56iW9xhsU6I/RO0jSXVgocR3NkUwOyA\nNw1zqNls7cxhHQMJv1P9kPfIqiF2sxkBnO3BfSCF4Oyvw4rufnbR9RDJK/0d\nFLzkNBb160FwatWIObJSakS+3ApqNfppRnP4KQiRJqSneRZD5+yuCD6hVEur\nuWVC3ty1Irx/JHx+Z4nv2NxPWVw2VecUJqCnhpF/fMSKO0L08mHk076bwIxR\nY8LgM65y94lHYA97aHrPPiOSc7D41LXTy6y7tp9AFrCL5DE2uUaOkzY5H37P\nVVfnX855s9ZMZQwiLh1UWjh/a2beTduty8d/o/2n2vJHBYz2Bulnq/TLAY2Q\nMKZyIPDIYDLaJp/ngcexv1vz1K2fNDSBQwE0FXt8VP2efj30v2GUxyOtqNgT\n7fPgMO+8/0t8HPoP09bLXTqoGz6seg1LtokhErpD/Y4wUde6ez0FgVs0pB2m\nlpeXNVBL+v0T77mPjhI3JGzshpCoyoQW3m7RB6O5eFJqc4JQvsJ9IVAnWd9Z\nVHxA0eRYsObpcSPAC5kvxPCdekwFj0qH76svZEfV5MMw2aj0TW93kYHKf2o0\n7CnNlLg2T0qyh692wvmwoeBYx8UMZBCIRkT6v9yBYPaDbBwER1lAXio+4vFQ\n8RAO\r\n=L9mx\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIE1Uh8/LNC/kWG4EZHfaqiOcPpMAhj4Jj5LLpL+ofoEvAiA9hQh28YUMVaAeS3rTFy1Fw/20imIXKUFqKjoSiYGWyA=="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0-alpha.6_1548672717325_0.7167812835522405"},"_hasShrinkwrap":false},"3.2.0-alpha.7":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0-alpha.7","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0-alpha.1","@atlas.js/service":"^1.2.0-alpha.1","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0-alpha.7","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"20fa27bf205f83baaae14c5ef99c6ff8e007b214","readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","readmeFilename":"README.md","_id":"@atlas.js/mongoose@3.2.0-alpha.7","_nodeVersion":"10.15.0","_npmVersion":"lerna/3.10.5/node@v10.15.0+x64 (linux)","dist":{"integrity":"sha512-7xzWhatY2gAACpJXWzJb1ikKq06kxtxDufDrTJXd1kzhoXdT1vDr6kfnzh19H5uFuguK9SZJbnvuZ1GaEXU3jg==","shasum":"07dd9ea6f7f9951af8e9b2e366cd59e9613c76bb","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0-alpha.7.tgz","fileCount":25,"unpackedSize":56914,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcTuJzCRA9TVsSAnZWagAAnawQAJBikr0TuC6j57g9CrZM\n7AiZPfdRh18Lk0u7EVsBqQIODw8VBEXj6sR1QVMDomYnPm86bX0zHiaYb1EX\nXjfpu6pyVlLMDrUyUkqmUNXLgAQhE+8T9rfJobHlnGs7HNODQggOkOnrWAei\nMbrs+Gz7nrehOiNv4VNln6b6vjpXeH7i/xaETxDCVL80bRP7DVILVwgpFIaC\ndH9I6vyyC+obH2dDNvz4tncqswy+QaIOCsyEHp2FIhpSVnTECVKginD/Yq4x\nCgaLsnn06fJhy+00yQkn9AWdeNQ4qxydGPi7Oxzlc59fSXhprNi14wsVu/ma\n17DkYHrL7kVJ42hhOak9IuCmrs4QoVyFjHg+g3/zce3uWxy6GJIIeukxF/w2\nnNSUc3EsJHnC6ojPOLg96lbWzgY2JTO7LiA32LBk2998FkZXG7h+ZPc1Rnj9\nqpMOn1iq1zGJ5T0bLO54RZ0StfZyZAs+C4yJm4SoEt5FKPs169JUJhoSJzUO\nj2TJoGOZ4cZPEzdozhylGfHTbihA+MtaU0uaxHd9MKtHpBpydUF5APTngqCs\nuYMrkL1ny2X7OTDck5HpIBfC8lEnfFJVeLdNH3E2xAapBfJunyweHgDStXO2\nzmSESPVrrk1NELQ7lX26nlMTlJYSY8zUgR5BEO6nE/t4X+skyMK10vt4c1mG\nLJDB\r\n=WnIC\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD4A2kDMcULyn1xZvGImD4MdG8t03PaCaglV1kp/lRIRQIgdu0SHgM8mD0GG5movUfZD5h6RqRwaStCFmiV+GWfIdE="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0-alpha.7_1548673650842_0.00945399248631107"},"_hasShrinkwrap":false},"3.2.0":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.0","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0","@atlas.js/service":"^1.2.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.2.0","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"e67f1220a6aa157ef078f26075b6aa5bfad5ee18","_id":"@atlas.js/mongoose@3.2.0","_nodeVersion":"10.15.1","_npmVersion":"lerna/3.10.5/node@v10.15.1+x64 (linux)","dist":{"integrity":"sha512-yMy0hZCvxInxbUxDiWywLxM2XGLpv9+Rwew0nXAzHLt2glPd7tPNuiXxWpozybIkFyVL+FVlkiWQOnLN2sEPHw==","shasum":"a689d5700a897d61f2a09b4fb08c8c6edbbba27b","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.0.tgz","fileCount":25,"unpackedSize":57686,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcXWHoCRA9TVsSAnZWagAAIqcP/A986NYR7UHle1lCTiXs\n1ueGhwXekCi+ZKW7V5AMeL1DmTIv+VtrSE3QTo6H7yyuPn9xf7SzzPd34dSU\n9bqULkYJPKCh+RpRR/AaMJPAD+T4d6LSor0GVae2oqwnC7UZJt98e8kZlaCK\ne/iVjVT6xk2c97dq5u6CLlbnMQSfKGsJzVFZU8ZwYa3oTkZ6dW+Ws27WqlGQ\nQ0h+MHTa86t+SkUNLN8Tb2E0QwdU3NwH4nfh94oNY7VqUp+of6CaRkM3Pw8h\n6LMjumJIl8+jew4MHjQvAh5GgweJDwZtk210PAnU5YwHP02KbfJUdwhnQ/5g\nCu3idxUAuBiiou5udNJE3wa2jfjoKUvvr5XyL07GpzmomCZgmsT4/mUc84Yc\nuZD1nQ/k4VHD1PZxNS+n61GtOEu6//R4jMsdhSpAWMru7h7U3l+k7ZGNzgT0\nWjKX+ZKeh4OokoRUHWyunTdtJ5XfRP1TtEVoihR9f9U19Vy2ssfPMTihV2g7\nkcLOFSfb/prnW6VPiYB+/Hwz5eEBjGU4dDShZBf+VnfGSHL49C0DEHUtuuva\n8fk67Qyg0/h23gk5/k9o14Puj5PsolJAhr6c50Ud3ZeC4r3wrsZkv5Webhwe\nYmOYhpKEl+n3aaYg60MjanPgcUzz7Y0MMRc1vIdNcAJ+xHpkH6mEwZP77TYe\nx9ux\r\n=ekHO\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCNDi6Xjv1rhC/XeGemS6vg/hICizQfxTrMJCNWCZS37QIgbd8P1+LyVbBhUHEgKjAHiBQ68SNwA0ASAJqXS/Otrk4="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.0_1549623783789_0.014168174900876185"},"_hasShrinkwrap":false},"3.2.1":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.1","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.0","@atlas.js/service":"^1.2.0","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.3.0","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"5c97a07bd8836b5ec1324990def51e7a310154af","_id":"@atlas.js/mongoose@3.2.1","_nodeVersion":"10.15.1","_npmVersion":"lerna/3.13.0/node@v10.15.1+x64 (linux)","dist":{"integrity":"sha512-jWma1R4iTqEO9e1ZN2YwBa0qtLkm3KqyUlW/zbvWc+5fNph6h7i7jBB1wKDje4N5tH7h1JAEDcTUHO9CRe8scg==","shasum":"55609546f170286c5cd4eec6d3ecbd368d27daea","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.1.tgz","fileCount":25,"unpackedSize":57872,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcbUl+CRA9TVsSAnZWagAAfM4P/2dmROujLIx3T6arfP2O\ndObexYI9Mu9Y4W3L19bCLVhTKw+jPLt4MMj1OOaY9FbmObuyMhHKEExnCUJI\nQSprRtt00HaUkDSZ1buo7trzm73zRiY5Yzt5+Mh2DgVe2Dducs+NDbNaX73T\n9lbe+/hte/rYtwI04MwubYaf5LC5JAoC1jVosQP8/hLH4D56VAifmysKn65J\nUmqtIsOWxh6zqxWYFLvPPlLWsdoFBetNE1oIA/KlyaF0QOFsp/O5twJNxaeD\nDtRU+iVXsAU4trRzle1olsMdJ8Oef4bMWQ5y0SF6v7nIW0AxvEmT2k3G9Iav\nYc/u0oM8Bn88sg1HmXidDQBHcJP59vnFFgSRN8yBf/g5VGWpsFrRw1/94c8f\nctXWy4B+9sMoJndyC5LY99sz/6Y3vlygvQVCtDZslyJ7a1oLhcvo80WRqQKC\noG49RJjdDGRmXN8rQYUT8Jc0H84hhi7qd6NJYibqrLzKsTsBXIYD97i4W8Wp\ncweo2cBcJxyvtGhHGDcQCSeezOXl1+htcnOz1YK/l0PH2tdmK3Rb5p+Gv0ME\n0IB2eFWv4SAGy+6v+rthlONPgutCvSC0N1Zc2F81l/Srd0sHJFg5EOb6EsIY\nyQayCkcIogbBXn9tzpw+vb87gvXbHYzomEDa0Npi0HNFmy9EiF+9dQcX1opr\noVMs\r\n=TvAn\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIF+y0UsofmnbE2whcINdW1IsW7zKzFXy59oQZdCY8Ib5AiEAvseBgbU1uzfMuWbZ6asgUx5Ykh48uTats91+4JMnhMQ="}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.1_1550666109769_0.3710992540772382"},"_hasShrinkwrap":false},"3.2.2":{"name":"@atlas.js/mongoose","description":"Mongoose service for @atlas.js","version":"3.2.2","author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"contributors":[],"dependencies":{"@atlas.js/hook":"^2.1.1","@atlas.js/service":"^1.2.1","lodash":"^4.17.4","mongoose":"^5.0.0"},"devDependencies":{"@atlas.js/atlas":"^2.4.0","@types/mongoose":"^5.0.0"},"engines":{"node":">=8.3.0","npm":"^5.3.0"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"license":"BSD-3-Clause","main":"src","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"gitHead":"6c9ce4041de9f5c386b205e72c656443101327b0","_id":"@atlas.js/mongoose@3.2.2","_nodeVersion":"10.15.3","_npmVersion":"lerna/3.13.1/node@v10.15.3+x64 (linux)","dist":{"integrity":"sha512-HIlIsFLGiYZZEYfbZjO1zqP+FE7aLXPoocQ1oBk/mxGFvC9siRr9qMQV4krhvKyatYqxrfI16uEE2kwmF3EnCg==","shasum":"18225cad8d83a7070ec4ea573533fd0d4f7a25bb","tarball":"https://registry.npmjs.org/@atlas.js/mongoose/-/mongoose-3.2.2.tgz","fileCount":25,"unpackedSize":58058,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcpz0+CRA9TVsSAnZWagAAk+MP/1Y8lIpj2JVHIKmwG+Bn\n1Z6jEIYQu56XJxRktz55T6nuDQURmp5fLBvJnSyWnvkXDE21Mv/2n+6JhFtM\n7CAAFR2d3ilvh9a+pKokL1vRFHMUdQmVYEuQvjMGTgh6biF0igXqflEI4uCX\nWA6a/TH4PYLxC118tpIUFwnz5YCHJzePDY2cdIRRSSKKu3/EY656VqsAaDmR\nCkdU3bk7LdQ0yi55lAw4CIMkcm6/AkLFEF4omjDfEZtUfKmiMwsNkhGn79By\n5Q58gvLdgV2fwZBISrnV4kru46lnklQ843dnJ7XHZe8bz8aSoq0fTboLLf5S\nnjrb09yamqY7L5ahgzWpnnXGCy4+CIPhNJ78xSnLRsnZO5uTyhq99RK9N8Rx\nH+q3N4qtgm9IlUTlRQ6ngmGWpBX8iFCbSEZ92nlQ/GnhqsiXT8Y5d/LKbq6K\nRNcNT83QCAQseBDD4wPtRx4k8P8uBBTCy1JYxE/NMqS5NmRB/0wQOfS58hDM\ncAtv4Uhlqo4yAVc5s6EEzJLqBKhQJtsChKquoCzpzD+9D/NIZNArFO0y8efN\n4eRidd1DCn7baJcoS+BgTMPEgmHwFPc8gwLzME5E4qRT9nPNdPL2Gm4AjnGG\nbuCpdSidJUs9jyVBN/+HBnz9wpiuQs6G70sdP3fIfD4G6hi6IMxPDk8WY+xV\n8+tt\r\n=9emS\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCP/fALazYR4V8LnsYIPENrp+pcTUbFJot7z7Jd2MM2wgIhALyJO0gQ1OWueb+fFu7RiiY47+y9vc93exsRHA4gAPt2"}]},"maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"_npmUser":{"name":"robertrossmann","email":"robert.rossmann@strv.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mongoose_3.2.2_1554464062103_0.12400329672045629"},"_hasShrinkwrap":false}},"readme":"# @atlas.js/mongoose\n\nMongoose service for @atlas.js.\n\n## Installation\n\n`npm i @atlas.js/mongoose`\n\n## Usage\n\n### Service\n\nThe service configuration only accepts two properties: `uri` and `options` which are passed directly to the [`mongoose.connect(uri, options)`][mongoose-connect] method.\n\n```js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  config: {\n    services: {\n      database: {\n        uri: 'mongodb://127.0.0.1:27017/my-db',\n        options: {},\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\nawait atlas.start()\n\n// You have your mongoose client available here:\natlas.services.database\n```\n\n#### Accessing the Atlas instance\n\nWhen you add your `Schema` definitions to the service they get access to the Atlas instance as both a static property on the model and as an instance property on all instances of those models.\n\n```js\nconst User = new Schema({\n  /* your schema definitions go here */\n})\n\nUser.statics = {\n  doThisThing() {\n    // this refers to User, in other words, this === mongoose.model('user')\n    this.atlas\n  }\n}\n\nUser.methods = {\n  doThatThing() {\n    // this refers to an instance of User, in other words:\n    // this instanceof mongoose.model('user') -> true\n    this.atlas\n  }\n}\n\n// From elsewhere in your codebase...\nconst User = atlas.services.database.model('user')\nUser.toThisThing()\nconst user = new User()\nuser.doThatThing()\n```\n\n### ModelsHook\n\n#### Dependencies\n\n- `service:mongoose`: A mongoose service to load the models into\n\nYou can use this hook to load your mongoose model definitions from a particular module location.\n\n```js\n// models/user.js\n\n// You can import the necessary classes and definitions directly from the\n// @atlas.js/mongoose module instead of loading the mongoose lib\nimport { Schema, SchemaTypes } from '@atlas.js/mongoose'\n\nconst User = new Schema({\n  name: SchemaTypes.String,\n  email: SchemaTypes.String,\n})\n\nexport default User\n\n\n// models/index.js\nimport User from './user'\nexport {\n  User\n}\n\n// index.js\nimport * as mongoose from '@atlas.js/mongoose'\nimport { Atlas } from '@atlas.js/atlas'\n\nconst atlas = new Atlas({\n  root: __dirname,\n  config: {\n    hooks: {\n      models: {\n        // The path to the module from which all the database models should be\n        // loaded, relative to atlas.root\n        module: 'models'\n      }\n    }\n  }\n})\n\natlas.service('database', mongoose.Service)\natlas.hook('models', mongoose.ModelsHook, {\n  aliases: {\n    'service:mongoose': 'database',\n  }\n})\nawait atlas.start()\n\n// Now your models from the models/index.js module are loaded up!\nconst User = atlas.services.database.model('User')\n```\n\n## License\n\nSee the [LICENSE](LICENSE) file for information.\n\n[mongoose-connect]: http://mongoosejs.com/docs/api.html#index_Mongoose-connect\n","maintainers":[{"email":"robert.rossmann@strv.com","name":"robertrossmann"},{"email":"licenses@strv.com","name":"strvuser"}],"time":{"modified":"2022-04-04T16:08:34.158Z","created":"2017-08-16T08:42:57.692Z","0.1.0":"2017-08-16T08:42:57.692Z","0.1.1":"2017-08-16T13:55:29.520Z","0.1.2":"2017-09-02T12:28:37.547Z","0.1.3":"2017-09-22T08:07:02.930Z","0.2.0":"2017-09-26T11:35:09.424Z","0.3.0":"2017-09-27T08:50:31.882Z","1.0.0":"2017-10-24T20:48:31.366Z","1.0.1":"2017-11-27T09:54:23.993Z","1.1.0":"2017-12-13T11:56:34.215Z","2.0.0":"2018-02-15T14:29:10.485Z","2.1.0-alpha.a596c671":"2018-05-14T15:01:31.061Z","3.0.0":"2018-05-22T15:37:02.418Z","3.0.1":"2018-07-12T12:31:39.128Z","3.0.2":"2018-07-16T05:51:29.303Z","3.1.0":"2018-07-17T12:29:00.974Z","3.2.0-alpha.0":"2018-12-07T13:18:47.890Z","3.2.0-alpha.1":"2018-12-10T09:09:53.350Z","3.2.0-alpha.2":"2018-12-11T13:12:25.418Z","3.2.0-alpha.3":"2018-12-13T18:30:35.782Z","3.2.0-alpha.4":"2018-12-18T11:16:52.049Z","3.2.0-alpha.5":"2019-01-16T09:06:44.303Z","3.2.0-alpha.6":"2019-01-28T10:51:57.459Z","3.2.0-alpha.7":"2019-01-28T11:07:31.014Z","3.2.0":"2019-02-08T11:03:04.032Z","3.2.1":"2019-02-20T12:35:09.928Z","3.2.2":"2019-04-05T11:34:22.344Z"},"homepage":"https://github.com/strvcom/atlas.js/tree/master/packages/mongoose","keywords":[],"repository":{"type":"git","url":"git://github.com/strvcom/atlas.js.git"},"contributors":[],"author":{"name":"Robert Rossmann","email":"robert.rossmann@strv.com"},"bugs":{"url":"https://github.com/strvcom/atlas.js/issues"},"license":"BSD-3-Clause","readmeFilename":"README.md"}