exception catching and dbinput and httpoutput first versions added