Use Duration instead of primitive for expiration time

Bug: 290381858
Test: more readable
Change-Id: I9055feca9d4cfff83d6242c7557fc86e40798546
2 files changed