Attention is currently required from: pespin.
dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35659?usp=email )
Change subject: Introduce ue_fsm ......................................................................
Patch Set 1: Code-Review+1
(5 comments)
Patchset:
PS1: I have worked that through, in particular the gen_statem implementation was interesting. Now I know how to implement an FSM in erlang.
File src/gsup_server.erl:
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35659/comment/85f97299_d0507... PS1, Line 53: ues = sets:new() the other record members have a comment, maybe we should add a comment for member "ues" too? (it probably refers to multiple UEs)
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35659/comment/31f1f8b8_f393c... PS1, Line 119: {reply, error, not_implemented}. This function is deprecated?
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35659/comment/138d5469_3ecaf... PS1, Line 283: find_gsups_ue_by_imsi(Imsi, State) -> ("gsups" stands for GSUP-Server I guess.)
File src/ue_fsm.erl:
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35659/comment/10836e2c_58ff5... PS1, Line 83: {stop, Err, Data} Maybe a default case would be a good idea? I just mentioning this since
https://www.erlang.org/doc/man/gen_statem.html
mentions:
"Postponing an event corresponds to not matching it in a receive statement, and changing states corresponds to entering a new receive statement."
So if auth_handler:auth_request() returns something different than {ok, _} or {error, _}, maybe {foo, _} for example, then the event would be accidentally postponed?