public sealed class SourceTransferOne player's transfer, from the realm that still owns them.
Remarks
Doc 27 § The overlap as a state machine a test constructs and drives — the same shape ShardLifecycle, PlayerLeaseState and GateService took, and for the same reason: § Testing asks for every abort path, injected, and nobody injects a source realm dying at t5 against three live processes.
⚠ Nothing here talks to anything. It is fed events — the orchestrator answered, the client arrived, the target acked — and asked what to do next. The realm supplies the I/O and RealmDirectory supplies the grain calls, which is what keeps ADR-016's rule a property of where this is driven from rather than a promise made inside it.
⚠ The player is authoritative here until Phase reaches Committed. Every abort leaves them playing, and there is no state in which two realms both believe they own them — the lease epoch is the boundary and LeaseTaken is the only edge that crosses it.
Fields and properties (15)
public PlayerKey PlayerWho is moving.
public string DestinationWhich map they asked for.
public string ReasonWhy — a portal, a party join, a drain.
public DateTimeOffset StartedWhen it began.
public TransferPhase PhaseWhere it has got to.
public TransferAbort AbortWhy it did not happen, once it has not.
public ShardId TargetWhich shard, once the orchestrator has said.
public long LeaseEpochThe epoch the target will take.
public TransferPrepare? PrepareWhat the client was told, once it has been.
public long CommitTickThe tick the player stops existing here, once chosen.
public DateTimeOffset? FinishedWhen it finished, either way.
public bool DoneWhether it is over.
public bool StillOursWhether the player is still this realm's to simulate.
public TimeSpan OverlapHow long the overlap lasted — doc 27 § Tick rebasing's OverlapDuration.
public TimeSpan CommitLatencyHow long the commit took, once it has.
Methods (10)
public SourceTransfer(PlayerKey player, string destination, DateTimeOffset now, TransferDeadlines? deadlines = null, string reason = "")Starts one.
public bool Placed(ShardId shard, TransferPrepare prepare, long epoch, DateTimeOffset now)The orchestrator named a shard. t1.
public bool TargetReady(DateTimeOffset now)The target pre-reserved a slot and is expecting them. t2.
public bool ClientReady(DateTimeOffset now, long atTick)The client has the map, the session and the first snapshot. t4.
public bool LeaseTaken(long epoch, DateTimeOffset now)The lease moved to the target. The atomic moment. t4.
public bool HandoffAcknowledged(DateTimeOffset now)The target applied the payload and said so. t5 → t6.
public bool Stop(TransferAbort reason, DateTimeOffset now)Gives up.
public bool Step(DateTimeOffset now)One turn of the clock. Gives up on whatever has run out of time.
public TransferCommit? Commit()What to send the client at t5, once there is something to send.
public override string ToString()Returns a string that represents the current object.
Used by (7)
- RealmHostVixen.Live.Realm
- RealmTransfersVixen.Live.Realm
- SourceTransferTestsVixen.Live.Transfer.Tests
- TransferFleetVixen.Live.Realm.Tests
- TransferMetricsVixen.Live.Transfer
- TransferMetricsTestsVixen.Live.Transfer.Tests
- TransferOracleTestsVixen.Live.Realm.Tests