Add fd state tracking to json/mongo formats