fix the circular dependency between filter and port