moved all global variables to a dedicated namespace