authgear / authgear/authgear-server

Refactor to define events in the interaction intents

Open
#1,764 0 comments 0 reactions 0 assignees View on GitHub
cooldown/enhancement
Dominant language
Go
Stars
2k
Forks
125
Avg merge
2d 17h
Merged PRs (30d)
32

Description

#### Current problems

Currently the non-blocking events are dispatched in nodes, but in some scenario we may want to skip some of the events. e.g. `NodeDoCreateIdentity` will need to skip the create identity event when it is user signup / anonymous user promotion flow. Now we check the graph in the node to determine these cases which add unnecessary dependency to the node.

#### Suggested solutions

Refactor to make the nodes independent to the graph. Each flow should have its own intent, the events should be defined in the intent.

Contributor guide

Open the contributing guide

Research direction

Start by tracing NodeDoCreateIdentity and the interaction flows that dispatch its non-blocking events. Read how nodes currently depend on the graph and how intents are represented. Done means each flow defines its own events in its intent, nodes are independent of the graph, and the signup or anonymous-promotion flow can skip the create identity event.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
authentication, backend
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.