def _gevent_patch():
try:<EOL><INDENT>assert gevent<EOL>assert grequests<EOL><DEDENT>except NameError:<EOL><INDENT>logger.warn('<STR_LIT>')<EOL>return MULTITHREAD<EOL><DEDENT>else:<EOL><INDENT>monkey.patch_all()  <EOL>return GEVENT<EOL><DEDENT>
Patch the modules with gevent

    :return: Default is GEVENT. If it not supports gevent then return MULTITHREAD
    :rtype: int