command factory rebuild