implemented Application and tested shutdown order