Sync

add sync functionality