add signal handler API