Add LogUtils for logging exception and fixed some issues