update JsonProtocol to serialize all value types

* moved some Query logic into onTransition
implement findPosting in Term