I am using `prisma` with `mongo` and seeing this e...
# prisma1-community
s
I am using
prisma
with
mongo
and seeing this error. What does this mean?
Copy code
{"key":"error/unhandled","requestId":"local:ckd6os1k9014w079041w6lx4y","clientId":"default_default","payload":{"exception":"com.mongodb.MongoSocketReadException: Exception receiving message","query":"query ($where: SubSiteVisitsWhereInput) {\n  subSiteVisitses(where: $where) {\n    id\n    websiteId\n    lang\n    nimpressions\n    day\n    first\n    last\n    impressions {\n      ts\n      ip\n    }\n  }\n}\n","variables":"{\"where\":{\"day\":\"2020-07-29T00:00:00.000Z\",\"lang\":\"ta\",\"websiteId\":32}}","code":"0","stack_trace":"com.mongodb.internal.connection.InternalStreamConnection.translateReadException(InternalStreamConnection.java:543)\\n com.mongodb.internal.connection.InternalStreamConnection.access$1200(InternalStreamConnection.java:74)\\n com.mongodb.internal.connection.InternalStreamConnection$5.failed(InternalStreamConnection.java:500)\\n com.mongodb.internal.connection.AsynchronousSocketChannelStream$BasicCompletionHandler.failed(AsynchronousSocketChannelStream.java:252)\\n com.mongodb.internal.connection.AsynchronousSocketChannelStream$BasicCompletionHandler.failed(AsynchronousSocketChannelStream.java:220)\\n sun.nio.ch.Invoker.invokeUnchecked(Invoker.java:128)\\n sun.nio.ch.UnixAsynchronousSocketChannelImpl.finishRead(UnixAsynchronousSocketChannelImpl.java:430)\\n sun.nio.ch.UnixAsynchronousSocketChannelImpl.finish(UnixAsynchronousSocketChannelImpl.java:191)\\n sun.nio.ch.UnixAsynchronousSocketChannelImpl.onEvent(UnixAsynchronousSocketChannelImpl.java:213)\\n sun.nio.ch.EPollPort$EventHandlerTask.run(EPollPort.java:293)\\n sun.nio.ch.AsynchronousChannelGroupImpl$1.run(AsynchronousChannelGroupImpl.java:112)\\n java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)\\n java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)\\n java.lang.Thread.run(Thread.java:748)","message":"Exception receiving message"}}
[INFO] Opened connection [connectionId{localValue:49, serverValue:519612}] to 122.42.142.32:27017
[WARNING] Got socket exception on connection [connectionId{localValue:48, serverValue:519450}] to 122.42.142.32:27017. All connections to 122.42.142.32:27017 will be closed.
[INFO] Closed connection [connectionId{localValue:48, serverValue:519450}] to 122.42.142.32:27017 because there was a socket exception raised by this connection.
r
Hey @Suhail 👋 Have you used Heroku to deploy the Prisma server?
s
No. Simple deployment using the prisma docker
r
I still think suspect this is a memory issue. Could you increase the jvm heap size to 6 GB and check again?
s
Oh okay.
I am dealing with huge documents. Are there any other optimizations that I should know about?
Would increase in the heapsize also require increasing the RAM? I am on 8GB RAM as I mentioned.
r
I think it would be better to increase the heap size to 8 GB and the RAM to 12GB as you're working with huge documents
The main issue you're facing is the lack of memory
s
These issues are not there if I directly connect to Mongo. Is there a way to justify such high memory requirements?