a lot of logging and structure change