You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Not sure if I'm doing something wrong but I cannot get any other event than KeycloakEventType.Ready ({type: 'Ready', args: true}).
Following this example, I expect, for instance, to see AuthLogout and AuthSuccess events getting dispatched on logout/login to raise an explicit isConnecting flag.
Bug Report or Feature Request (mark with an x)
- [x ] bug report
Versions.
Keycloak: v19.0.2
Angular 19
Repro steps.
The standalone example reproduces this behavior.
The log given by the failure.
Only KeycloakEventType.Ready ({type: 'Ready', args: true}) is dispatched.
Desired functionality.
It should report all states in KeycloakEventType enum.
The text was updated successfully, but these errors were encountered:
I'm using the something like the following snippet to understand the sequence: effect(()=>{ const evt = this.#keycloakStatus(); console.log([AUTHSRV] ${new Date().getTime()} -- ${evt.type}-- ${JSON.stringify(this.#client)} ); ...
I'm then running a simple login on the keycloak client which successfully executes a sign in.
I saw the follwoing events so far. On sign in :
KeycloakEventType.Ready ,
KeycloakAngularInit
On refresh , I caught the following:
TokenExpired,
AuthRefreshSuccess
On Logout:
KeycloakEventType.Ready ,
KeycloakAngularInit
The issue seems to be that some events are lost during the context switch between initial page load (app server) , sign in page (Keycloak server) then back to page load (app server) which also re-runs initialization. Reload also happens on Logout so that signal state is also missed.
On sign in, keycloak will cache the state on the local browser and on the 2nd init it finds and loads it from there, basically authenticating the user.
I'm currently detecting the Ready state, then inspecting the authenticated status. I'm not sure this is the intended way of using it though :)
Not sure if I'm doing something wrong but I cannot get any other event than
KeycloakEventType.Ready
({type: 'Ready', args: true}
).Following this example, I expect, for instance, to see
AuthLogout
andAuthSuccess
events getting dispatched on logout/login to raise an explicitisConnecting
flag.Bug Report or Feature Request (mark with an
x
)Versions.
Repro steps.
The standalone example reproduces this behavior.
The log given by the failure.
Only
KeycloakEventType.Ready
({type: 'Ready', args: true}
) is dispatched.Desired functionality.
It should report all states in
KeycloakEventType
enum.The text was updated successfully, but these errors were encountered: