middleware

subtree prefix is same with dirname