Definitions and headers for threads added