3

I am using laravel 5.1 with jenssengers mongodb. I am unusre if the connection to the mongodb & mysql is closed when not in use.if not what is the way i can close the connection.

Sameer Sheikh
  • 499
  • 1
  • 6
  • 16

1 Answers1

0

I believe the connections would be closed when not in use, you can use db.currentOp() to see whats running or hung up at the DB end.

db.currentOp().inprog.forEach(
  function(op) {
    if(op.secs_running > 5) printjson(op);
  }
)

Reference - http://blog.mongolab.com/2014/02/mongodb-currentop-killop/

Brij Raj Singh - MSFT
  • 4,903
  • 7
  • 36
  • 55