update example to use shared client