Comments (3)
@wizardone I'm so sorry for the slow reply! I think this might be solved by changing MyApp.Repo
to MyApp.Repo.pool()
I forget when that got changed, but we clearly need to update it in our docs. I'm going to close it for now b/c I'm pretty sure that's the problem, but please let me know if this isn't it. I'll try to reply sooner next time!
from mongodb.
@wizardone Just added a fix to the Readme which hopefully clarifies this:
Using with MongoDB Ecto
If you're using Mongo with the MongoDB Ecto library, where you have it defined in your config/runtime.exs like this:
config :my_app, MyApp.Repo,
url: "mongo connection url"
You'll want to do reference mongo like this:
Mongo.find(MyApp.Repo.pool(), collection, %{_id: %{"$in" =>"some_ids"}})
from mongodb.
@scottmessinger Thank you for answering. I'm afraid I don't fully remember what the problem was, but I'm pretty sure that I had to specify the pool
somewhere, so it was probably that. Good on updating the docs 👍
from mongodb.
Related Issues (20)
- Configuration for tests? CONTRIBUTING.md needed HOT 4
- How to disable server-side javascript operation as configuration HOT 2
- Is there a way to detect bad credentials? HOT 1
- Method that checks if connection is alive?
- `Mongo.insert_many` does not `continue_on_error` when it encounters a `Mongo.WriteError` HOT 1
- System.stacktrace/0 is deprecated, use __STACKTRACE__ instead HOT 2
- Ability to query a mongodb view? HOT 3
- Up to date releases/tags HOT 1
- Unable to connect to Atlas due to DNS connectivity issues HOT 3
- :crypto.hmac/3 is undefined HOT 1
- Bring this repo back to life! HOT 15
- Support multiple mongo repos HOT 1
- Review documentation / examples etc
- Remove start_mongo.bash, stop_mongo.bash; establish agnostic test setup HOT 1
- list_indexes returns compound keys in a Map, which makes it impossible to reason about the order of the keys HOT 2
- ElixirLS Dialyzer Issues HOT 2
- Calling Mongo when using mongodb_ecto how to get the topology_pid HOT 4
- DNS issue when connecting to mongodb on DigitalOcean with a mongodb+srv url string HOT 3
- Question: When will mongo v6 be supported? HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mongodb.