Comments (4)
Hi @ivankrister, does the error persist or does it eventually go away? By default, MongoDB Atlas uses the mongodb+srv
protocol in its connection string, which instructs the driver to do a DNS lookup on the given hostname to get the initial list of servers to connect to. The error you're encountering is an error reported by your operating system. Did you confirm that the same connection string was used in tinker and the web application where it works?
from laravel-mongodb.
Yes, @alcaeus i confirm that im using same connection in my web and tinker im using mongodb+srv protocol in my connection and i call config('database.connections.mongodb') in my tinker and web it gives similar result, but error still exists in tinker when fetching data
from laravel-mongodb.
For me its the other way around, From tinker It works, but calling from routes it throws the below error.
No suitable servers found (serverSelectionTryOnce
set): [connection error calling hello on 'xxxxx.docdb.amazonaws.com:27017'] {"userId":11,"exception":"[object] (MongoDB\Driver\Exception\ConnectionTimeoutException(code: 13053): No suitable servers found (serverSelectionTryOnce
set): [connection error calling hello on 'xxxxx.docdb.amazonaws.com:27017'] at /home/forge/default/vendor/mongodb/mongodb/src/functions.php:520)
@ivankrister is the issue fixed?
from laravel-mongodb.
@lokesh-zersys the error you are receiving is likely unrelated and has a very different root cause.
I've also noted that you're using DocumentDB, so please contact AWS support for any issues you encounter as it's not supported by the MongoDB driver. Thanks.
from laravel-mongodb.
Related Issues (20)
- NOTIFIABLE NOT WORKING, Cannot access offset of type MongoDB\BSON\ObjectId in isset or empty in HOT 1
- MorphTo relation won't work when eager load if target model has different primary key HOT 1
- [BUG] hasMany and hasOne relation not working with ObjectId HOT 2
- toSql() Alias from toMql() HOT 4
- [Feature Request] Add enum collection cast HOT 1
- MongoDB\Driver\Exception\BulkWriteException: not primary in /app/vendor/mongodb/mongodb/src/Operation/Update.php:209 HOT 2
- Polymorphic One to One (MorphOne) Relationship [Feature Request] HOT 3
- BelongsToMany detach() doesn't remove id from both collections
- Transaction level not working when use closure
- Unique Rule ignoring fails
- morphOne $model (mysql) -> relation (mongo)
- how it's will work with laravel passport with crearting issue not able to generate personal access token or password HOT 1
- updateOrCreate does not create DB entries HOT 9
- PHPStan errors after 4.3.0 upgrade HOT 1
- How I use laravel passport with this mongodb package ? As I creating Apis for my project so I require passport package. HOT 1
- `createOrFirst` is not triggering `creating` nor `created` model events HOT 8
- [Feature Request] getChanges() not supported HOT 4
- updateOrCreate -> createOrFirst doesn't work as expected HOT 3
- Memory leak when setting nested keys using dot notation HOT 3
- [Feature Request] Use transaction in AWS DocumentDB HOT 1
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 laravel-mongodb.