class PlaceOS::Model::OAuthToken::ChangeFeed(T)

Overview

Persistence backing for the auth.cr AuthlyAdapter::TokenStore. Each row records the metadata of a single OAuth2 access or refresh token; the revoked_at column lets the auth service mark a token invalid without rotating signing keys.

See migration 20260519100000000_add_oauth_tokens.sql for the column rationale (notably: most columns are nullable so a revoke for a never-stored refresh token can still leave a marker).

Included Modules

Defined in:

Constructors

Instance Method Summary

Constructor Detail

def self.new(id : Int64 | Nil | Nil = nil, parent : T.class = T.class) #

Instance Method Detail

def next #
Description copied from module Iterator(PlaceOS::Model::OAuthToken::ChangeFeed::Change(T))

Returns the next element in this iterator, or Iterator::Stop::INSTANCE if there are no more elements.


def on(&block : Change(T) -> Nil) #

Method expects a block which will get invoked with Change(T) parameter on change events received from EventBus


def stop #
Description copied from module Iterator(PlaceOS::Model::OAuthToken::ChangeFeed::Change(T))

Shortcut for Iterator::Stop::INSTANCE, to signal that there are no more elements in an iterator.