.NET API
JobLanes
Tracon.Abstractions.dllWell-known values and validation for job lane identifiers.
public static class JobLanesInheritance
Section titled “Inheritance”Inherited Members
Section titled “Inherited Members”object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Remarks
Section titled “Remarks”A lane is a plain string tag on a job (JobRecord.Lane); it
has no registry or lifecycle of its own, and it is not the job’s dispatch
identity (that is JobRecord.HandlerKey). Worker instances subscribe to a
subset of lanes (TraconSchedulingOptions.Lanes) to avoid
head-of-line blocking between unrelated kinds of work.
Fields
Section titled “Fields”Default
Section titled “ Default”The lane every job carries unless a different one is set explicitly.
public const string Default = "default"Field Value
Section titled “Field Value”Methods
Section titled “Methods”IsValidName(string?)
Section titled “ IsValidName(string?)”Checks whether name is a valid lane name: 1-64
characters, lowercase ASCII letters, digits, ., _, or
-, starting with a letter or digit.
public static bool IsValidName(string? name)Parameters
Section titled “Parameters”name string?
The candidate name.
Returns
Section titled “Returns”true if the name is valid.
Remarks
Section titled “Remarks”Uppercase letters are rejected, not normalized. Lane names are compared
ordinally everywhere (queries, worker subscriptions); allowing case
variants would let "Media" and "media" silently become two
different lanes, with the second one’s jobs never leased by a worker
that only knows about the first.
Resolve(string, string, IDictionary<string, string>?)
Section titled “ Resolve(string, string, IDictionary<string, string>?)”Resolves the lane a job is enqueued under, applying
TraconSchedulingOptions.LaneByHandlerKey when
lane is still JobLanes.Default, then validates
the result.
public static string Resolve(string lane, string handlerKey, IDictionary<string, string>? laneByHandlerKey)Parameters
Section titled “Parameters”lane string
The lane requested by the caller (JobRecord.Lane).
handlerKey string
The job’s handler key (JobRecord.HandlerKey).
laneByHandlerKey IDictionary<string, string>?
The configured key-to-lane map. May be null or empty.
Returns
Section titled “Returns”The resolved, valid lane name.
Remarks
Section titled “Remarks”Called from every IJobStore.EnqueueAsync implementation — the
one place every job, from every call site, passes through. A caller
that already set an explicit, non-default lane (an HTTP request body,
or a schedule’s own JobSchedule.Lane) is never overridden.
Exceptions
Section titled “Exceptions”The resolved name is not a valid lane name.