Data source

Initial changes to make data-source work.