add logging support, add form and uri support, read patterns from pattern.cfg