Interface JsonType

All Known Subinterfaces:
RequestResult
All Known Implementing Classes:
Append, AppendEvents, BooleanResult, BulkUpdateDocuments, CancelSchedule, ClaimSegment, ClaimSegmentResult, Command, CompleteMessageEvent, ConnectEvent, CreateAuditTrail, DeleteCollection, DeleteDocumentById, DeleteDocuments, DeleteEvents, DeleteValue, DisconnectEvent, DisconnectTracker, ErrorResult, GetAggregateIds, GetAggregateIdsResult, GetDocument, GetDocumentResult, GetDocuments, GetDocumentsResult, GetDocumentStats, GetDocumentStatsResult, GetEvents, GetEventsResult, GetFacetStats, GetFacetStatsResult, GetPosition, GetPositionResult, GetRelationships, GetRelationshipsResult, GetSchedule, GetScheduleResult, GetSearchHistogram, GetSearchHistogramResult, GetValue, GetValueResult, HandleMessageEvent, HasDocument, IndexDocuments, MoveDocumentById, MoveDocuments, PauseTrackerEvent, ProcessBatchEvent, Read, ReadFromIndex, ReadFromIndexResult, ReadResult, RepairRelationships, Request, RequestBatch, ResetPosition, ResultBatch, Schedule, SearchDocuments, SearchDocumentsResult, SetRetentionTime, StorePosition, StoreValueIfAbsent, StoreValues, StoreValuesAndWait, StringResult, UpdateRelationships, VoidResult

public interface JsonType
Marker interface for all low-level request and response types in the Fluxzero protocol.

Each implementation of JsonType represents a command, query, or result that can be sent to or received from the Fluxzero Runtime. These types are serialized using polymorphic JSON with the type discriminator, enabling dynamic dispatch and flexible message routing.

Serialization

Implementations of this interface are serialized with @JsonTypeInfo and @JsonSubTypes annotations, allowing automatic deserialization on both the Java SDK and Runtime side.

Metrics Logging

Implementations may override toMetric() to emit a smaller, structured representation of the object to the metrics log for observability and auditing. This is especially useful for requests or results that carry large or sensitive payloads.

Examples

See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    default Object
    Converts this object into a compact metric representation for logging or monitoring.
  • Method Details

    • toMetric

      default Object toMetric()
      Converts this object into a compact metric representation for logging or monitoring.

      Used by the Fluxzero Java SDK to avoid logging large payloads directly while still tracking platform usage.

      Returns:
      a safe and compact object suitable for serialization to the metrics log