move files from state.go to bootstrap.go