Giter Site home page Giter Site logo

Comments (7)

patrickkaleta avatar patrickkaleta commented on September 28, 2024 1

I've finished the implementation and deployed it onto the CSIS server. Users now can see messages like this, when they are in the Study-step and the calculation is ongoing (of course they are not going to see all 3 at once):
status messages-new

More details about this feature in the readme.

What still needs to be fixed is the problem with the sorting of the batchjobs that I get from Emikat. Only after this sorting is working, the CSIS helpers module will be able to generate meaningful status messages.

from csis-helpers-module.

patrickkaleta avatar patrickkaleta commented on September 28, 2024

One possible way how to do it:

  • add a new field Calculation Status to the Study group (0 => not active, 1 => running)
  • the Emikat trigger in the csis helpers module will set this field to 1 if the calculation has been triggered
  • add a new JS, which we would only include on all the Study-pages (not the GL-pages!), that would repeatedly pull the current status from Emikat via REST if this new field is set to 1 and print the result on the screen
    • if Emikat returns that the calculation is still running, re-sent request after e.g. 30 seconds
    • if result shows an error or success, print that error/success (tell user what to do next) and set via REST the Calculation Status of this study back to zero (inactive)

from csis-helpers-module.

DenoBeno avatar DenoBeno commented on September 28, 2024

from csis-helpers-module.

DenoBeno avatar DenoBeno commented on September 28, 2024

@humerh : as discussed earlier today, can we access some view that will return us the status & progress information?

E.g. something like this:

  • Status: on hold (waiting for other processes to finish) | in progress | finished | error
  • Progress: N/M - shows which step is currently processed. E.g. if there are 23 steps, then this could be 17/23
  • ** message** optional - a message that we could show to the user. E.g. indication on what is currently processed or the error that occured.

from csis-helpers-module.

patrickkaleta avatar patrickkaleta commented on September 28, 2024

Status update

Most of this feature is already implemented in this branch (still need to update the calculation field of the study after calculation in Emikat has finished + properly phrase the messages for the users). Once it's all done, I will merge and deploy it to our CSIS server.

One problem I encountered is that the SortBy parameter doesn't seem to work on Emikat-side.
batchjob-order-wrong

Even when you try to access the endpoint via Swagger and set the SortBy parameter to "OBJECT_ID=DESC", it will ignore this parameter and return the batchjobs in (for me) no apparent order.

This is a crucial problem. I need the most recent batchjobs first, because I then iterate over them until I find the "initial" batch job that triggered the current (re-)calculation. That's how I separate relevant batch jobs from possibly older batch jobs from previous calculations.

@humerh please take a look at this sortBy parameter.

from csis-helpers-module.

patrickkaleta avatar patrickkaleta commented on September 28, 2024

Ok, batch jobs are now always sorted in ascending order, however we need them in descending order.

@humerh can you please check again if the sorting parameter is handled correctly in Emikat or if the syntax I'm using is correct?

This is an example of a request I'm making:
https://service.emikat.at/EmiKatTst/api/scenarios/3233/feature/tab.AD_V_BATCH_IN_QUEUE.1710/table/data?rownum=20&filter=SZM_SZENARIO_REF=3233&sortby=OBJECT_ID=DESC

That's the relevant part for the sorting: ...&sortby=OBJECT_ID=DESC

No matter if I change it to "ASC" or omit it completely, the batch jobs always stay sorted in ascending order.

from csis-helpers-module.

patrickkaleta avatar patrickkaleta commented on September 28, 2024

Thanks to @humerh I now configured the sortby parameter correctly and batch jobs are now sorted the way we need them. Closing this issue now.

from csis-helpers-module.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.