Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 8d4a954336
Fetching contributors…

Cannot retrieve contributors at this time

17 lines (12 sloc) 0.317 kb
import urllib2
import sys
import os
try:
import json
except ImportError:
import simplejson as json
def getServerStatus():
host = os.environ.get("host", "127.0.0.1")
port = 28017
raw = urllib2.urlopen( "http://%s:%d/_status" % (host, port) ).read()
return json.loads( raw )["serverStatus"]
Jump to Line
Something went wrong with that request. Please try again.