plink is a persistence link layer with minimal addition to your existing code