add ttl option for writes