Pass ctx for logging purpose
Handle Dynamic and static rules