Table of Contents

Struct SceneServerData

Namespace
FishMMO.Database.Data
Assembly
FishMMO-DB.dll

Scene server registration data transfer object.

public struct SceneServerData
Inherited Members

Constructors

SceneServerData(long, string, DateTime, string, int, int, bool, double)

public SceneServerData(long id, string name, DateTime lastPulse, string address, int port, int characterCount, bool locked, double pulseAgeSeconds)

Parameters

id long
name string
lastPulse DateTime
address string
port int
characterCount int
locked bool
pulseAgeSeconds double

Fields

Address

public readonly string Address

Field Value

string

CharacterCount

public readonly int CharacterCount

Field Value

int

ID

public readonly long ID

Field Value

long

LastPulse

public readonly DateTime LastPulse

Field Value

DateTime

Locked

public readonly bool Locked

Field Value

bool

Name

public readonly string Name

Field Value

string

Port

public readonly int Port

Field Value

int

PulseAgeSeconds

Seconds since LastPulse, measured by the database clock at the moment the row was read. Never negative.

public readonly double PulseAgeSeconds

Field Value

double

Remarks

The only form of the pulse a reader in another process can judge liveness by. last_pulse is stamped by the database clock, and the reader's own host clock may disagree with it by any amount: comparing LastPulse with DateTime.UtcNow measured the gap between two clocks as much as the age of the pulse, so a world server whose host ran a minute fast treated every scene server as dead, and one running a minute slow kept routing players to a crashed one. The age is taken inside the statement that reads the row, where both ends are the same clock.