Fixed json stream serialization