Added optional cache name

Also fixed predicate not set