add cache and regex json array check