added time_to_live parameter in stored query CRUD