ORIONIS API REFERENCE

THE ORIONIS API

Build with clarity.

Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.

class documentation

class MonthlySuffixResolver(SuffixResolver): (source)

Constructor: MonthlySuffixResolver(at_time)

View In Hierarchy

Resolve log suffixes for monthly rotation windows.

Method __init__ Initialize the resolver with an optional rotation time.
Method getNextRotationTime Compute the next rotation datetime after the current time.
Method getSuffix Return the suffix string for the given datetime.
Class Variable __slots__ Declare the instance attribute slots reserved by this class.
Instance Variable at_time The time of day when rotation should occur. Defaults to midnight.
Instance Variable tz Tz produced by DateTime.getZoneInfo.
def __init__(self, at_time: time | None = None): (source)

Initialize the resolver with an optional rotation time.

Parameters
at_time:datetime.time or None, optionalThe time of day when rotation should occur. Defaults to midnight.
Returns
NoneThis method does not return a value.
def getNextRotationTime(self, current_time: datetime) -> datetime: (source)

Compute the next rotation datetime after the current time.

Parameters
current_time:datetime.datetimeThe current instant. Naive values use the resolver timezone.
Returns
datetime.datetimeThe datetime when the next rotation should occur.
def getSuffix(self, dt: datetime | None = None) -> str: (source)

Return the suffix string for the given datetime.

Parameters
dt:datetime.datetime or None, optionalThe datetime to generate the suffix for. If None, uses current local datetime.
Returns
strThe suffix in the format 'YYYY-MM'.
__slots__: tuple[str, ...] = (source)

Declare the instance attribute slots reserved by this class.

The time of day when rotation should occur. Defaults to midnight.

Tz produced by DateTime.getZoneInfo.