What are the Slack Archives?

It’s a history of our time together in the Slack Community! There’s a ton of knowledge in here, so feel free to search through the archives for a possible answer to your question.

Because this space is not active, you won’t be able to create a new post or comment here. If you have a question or want to start a discussion about something, head over to our categories and pick one to post in! You can always refer back to a post from Slack Archives if needed; just copy the link to use it as a reference..

(Untitled)

UKGT7RC7P
UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet
Β«1

Comments

  • UQ958DA4U
    UQ958DA4U Posts: 232 πŸ§‘πŸ»β€πŸš€ - Cadet

    I would love this come to fruition!

  • unfortunately, that would require an entirely different implementation of the state machine πŸ˜•

  • but for sure an interesting concept

  • Andriy Netseplyayev
    Andriy Netseplyayev Sprykee Posts: 519 πŸ§‘πŸ»β€πŸš€ - Cadet

    Let’s have a discussion in the comments! I also added my 5 cents. I do like state machine, and I don’t always like step engine implementation, but I’m afraid state machine won’t help here, although sounds temting

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet

    can just be steps that declare dependencies

  • Andriy Netseplyayev
    Andriy Netseplyayev Sprykee Posts: 519 πŸ§‘πŸ»β€πŸš€ - Cadet

    regarding the implementation - it could be implemented as a separate spryker-shop module, but yes - current state machine is a β€œzed” module

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet

    no need to integrate into the existing state machine(s)

  • do you have a use case?

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet
    edited May 2020

    any checkoutout procedure that branches based on user choices / quote (there are lots in the wild)

  • Andriy Netseplyayev
    Andriy Netseplyayev Sprykee Posts: 519 πŸ§‘πŸ»β€πŸš€ - Cadet

    state machine in it’s current implementation will bring lots of redundancies into the process, with it’s timeouts, cron jobs, state history and so on.. Probably, you would need another state machine there..

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet
    edited May 2020

    but not off hand πŸ˜„ only the relatively trivial example in the idea and vague recollections of writing a VoIP checkout 10 years ago πŸ˜„

  • the question is: how complex can this really get in real life scenarios

  • the more i think about it, the less.i think it is a good idea πŸ˜„

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet

    a step "engine" should be modelled as a graph - you have steps that depend on other steps

  • validation complexity simply explodes when you have many ways that can lead to the current state and you allow to randomly visit prior states

  • sounds like a bug engine πŸ˜„

  • UQ958DA4U
    UQ958DA4U Posts: 232 πŸ§‘πŸ»β€πŸš€ - Cadet

    "randomly visit prior states" is not required here. Defined paths but just more complex paths.

  • why not start different step engines then?

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet

    because you could branch at arbitrary points

  • exactly

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet

    so you can't just choose a correct linear progression to start with

  • anyway

  • Unknown
    edited May 2020

    this would make for a fun whiteboard session and maybe even a hacknight topic

  • U01470E4XTJ
    U01470E4XTJ Posts: 12 πŸ§‘πŸ»β€πŸš€ - Cadet

    I think we would need to discuss an exact checkout flow example cause you can achieve quite a lot by manipulating Step postConditions and just skip steps you do not require

  • Unknown
    edited May 2020

    a little bit of cheating in the step factory can also allow dynamic configuration

  • but would be a bit hacky

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet
    edited May 2020

    the original point is that you can't skip steps. You have to run through them, so I think at least the possiblity of disabling steps would be a start, anyway - but a graph based system would seem to fit closer to real life (depending on use case) but the linear flow fits into the graph flow anyway.

  • Unknown
    edited May 2020

    how hard can that be? (famous last words πŸ˜‚)

  • U01470E4XTJ
    U01470E4XTJ Posts: 12 πŸ§‘πŸ»β€πŸš€ - Cadet

    the only thing I am missing is checking for postCondition at Spryker\Yves\StepEngine\Process\StepCollection.php::getNextStep() so you do not need to go to next step if the postCondition is already met and skip to next one

  • UKGT7RC7P
    UKGT7RC7P Posts: 538 πŸ§‘πŸ»β€πŸš€ - Cadet

    it will redirect to that step before checking it though