java functions for server logging