7 months ago
Im using prisma and since to use prisma you need mongodb replicaset - Im using this template:
https://github.com/railwayapp-templates/mongo-replica-set
But I can't figure out how to connect it to my project
0 Replies
7 months ago
connect to Mongo1's url
Error: MongoDB error
Kind: Server selection timeout: No available servers. Topology: { Type: ReplicaSetNoPrimary, Set Name: rs0, Max Set Version: 1, Max Election ID: 7fffffff0000000000000001, Servers: [ { Address: mongo2.railway.internal:27017, Type: Unknown, Error: Kind: I/O error:
No such host is known. (os error 11001), labels: {} }, { Address: mongo3.railway.internal:27017, Type: Unknown, Error: Kind: I/O error: No such host is known. (os error 11001), labels: {} }, { Address: mongo1.railway.internal:27017, Type: Unknown, Error: Kind: I/O error: No such host is known. (os error 11001), labels: {} } ] }, labels: {}
0: schema_core::commands::schema_push::Calculate `from`
at schema-engine\core\src\commands\schema_push.rs:27
1: schema_core::state::SchemaPush
at schema-engine\core\src\state.rs:504
@monorail.proxy.rlwy.net:__MY_PORT/railway?retryWrites=true&w=majority&authSource=admin&replicaSet=rs0
7 months ago
when developing locally you would want to use the public url with direct connect enabled
7 months ago
the one with the yellow icon
I did this, with the same url as before (as I have already been using the public one)
Error: MongoDB error
Kind: Server selection timeout: No available servers. Topology: { Type: ReplicaSetNoPrimary, Set Name: rs0, Max Set Version: 1, Max Election ID: 7fffffff0000000000000001, Servers: [ { Address: mongo2.railway.internal:27017, Type: Unknown, Error: Kind: I/O error:
No such host is known. (os error 11001), labels: {} }, { Address: mongo3.railway.internal:27017, Type: Unknown, Error: Kind: I/O error: No such host is known. (os error 11001), labels: {} }, { Address: mongo1.railway.internal:27017, Type: Unknown, Error: Kind: I/O error: No such host is known. (os error 11001), labels: {} } ] }, labels: {}
0: schema_core::commands::schema_push::Calculate `from`
at schema-engine\core\src\commands\schema_push.rs:27
1: schema_core::state::SchemaPush
at schema-engine\core\src\state.rs:504
7 months ago
you need to use direct connect mode
7 months ago
that would be a client setting
7 months ago
please reference the clients documentation, we are not able to provide coding support here