import sys
sys.path.append("../")

import server
import socket2event

#import yappi
#yappi.start()
controller = server.Controller(sys.argv[1:])
socket2event.boot_translation_service(controller)
controller.start()

try:
    import time
    while 1:
        time.sleep(1)
finally:
    controller.stop()
    #yappi.get_func_stats().sort("tsub").print_all()
