change put to add, make retries configurable