setTTL method must call a function callback