added a Cookie facade class
fixed session shutdown event
added a global Event object to the Event facade
setup a shutdown event to send cookies