Rewrite tree iteration
Add field cursor support for metadata