Updates to gitignore files for random tmp files being generated
Switch to database session handling.