Skip to content

Business Dashboard UI: implement background retry to check for latest state #23968

Closed

Description

@severinbeauvais

The Filings UI dashboard is deprecated. This should be implemented in the new Business Dashboard UI instead.

See spike (description and comments) for details.


Previous Description (may be obsolete)

Currently in Filings UI, the To Do list polls the tasks endpoint 5 times, 1 second apart, to check if a pending task has changed to a new state. If it has, all dashboard data is reloaded. This handles slow external processing (eg, pay).

We have a similar issue with pending filings in the Recent Filing History list, and we could implement a similar polling mechanism for the filings endpoint.

However, we also have an issue with Active businesses sometimes still showing as Historical and vice-versa (ie, business state) due to slow back-end processing.

To solve this quickly, we could implement a global background retry to check if the tasks/ filings/ business state have changed since the dashboard was loaded. The idea is to call a new Legal API endpoint (see #24195) that would provide the "last changed timestamp", which the UI would compare with its original timestamp to determine if some business data had changed since it last loaded.

We would poll maybe 5 times, one second apart. This would catch slow Filer updates such as historical <--> active, filed and pending filings, etc. This would not catch changes beyond the 5 second retry period.

Instead of bluntly reloading the entire dashboard, we should first display a modal telling the user that there is newer data to display and click a button to refresh.

Sample messages:

  • "Changes have been applied to your record. Click OK to refresh your dashboard."
  • "There have been changes applied to your ledger. Click OK to display the most up to date information."

This more general polling mechanism would be a lot less complex to implement than the existing To Do list (and it's actually pretty clean, design wise, imho).

This polling is a work-around to the issue of the dashboard loading while data is being updated. A re-design of UI-API calls, or an alternative technology (server push? WebSocket?) could also solve the root issue.

This is just an idea and this ticket needs to be approved by PO and UX team.

Activity

  1. added
    bug
    Entities Team
    and removed
    bug
    on Oct 22, 2024
  2. changed the title [-]Copy of Filings UI: spinner should pre-empt action button[/-] [+]Filings UI: implement background retry to check for latest status[/+] on Oct 22, 2024
  3. changed the title [-]Filings UI: implement background retry to check for latest status[/-] [+]Filings UI: implement background retry to check for latest state[/+] on Oct 22, 2024
  4. vikas-gov commented on Oct 24, 2024

    @vikas-gov
    Collaborator

    @OlgaPotiagalova to review based on key priorities

  5. severinbeauvais commented on Oct 24, 2024

    @severinbeauvais
    CollaboratorAuthor

    It occurred to me that, if we had a simple, light endpoint to fetch just the last "modified date-time", then the dashboard could actually poll the BE once a minute to look for changes (thus acting more like a live dashboard). On the other hand, there is a very low probability of anything data changing (maybe FE filings or involuntary dissolution state, or maybe some things like limited restoration expiring). Probably we don't need to poll every minute at the moment, but it would be nice to have the option (design) to do that if needed.

  6. added
    Entities - Data Migration
    and removed
    Entities Team
    on Oct 30, 2024
  7. added
    Entities Team
    and removed
    Entities - Data Migration
    on Oct 30, 2024
  8. severinbeauvais commented on Nov 5, 2024

    @severinbeauvais
    CollaboratorAuthor
  9. 30 remaining items

  10. severinbeauvais commented on Jan 3, 2025

    @severinbeauvais
    CollaboratorAuthor

    Jacqueline - that's for @Rajandeep98 to say, since she's presently working on this ticket, but I think she could defer that part until then.

    Can you give up a sneak peek of what you're proposing?

  11. jacqueline-williams-549 commented on Jan 3, 2025

    @jacqueline-williams-549

    @Rajandeep98 I have created some design options for this, but I would typically wait for Tuesday to review with the Design Team. Since this ticket is in progress, will it be a blocker to wait until then?

    @severinbeauvais @Rajandeep98 I've designed 4 options, it would be helpful if you could let me know what makes the most sense from a technical perspective. When an update is detected by the system, I assume the easiest thing to do is to present a snackbar since it will float on top of the other elements.

    Design Workspace

  12. Rajandeep98 commented on Jan 10, 2025

    @Rajandeep98
    Collaborator

    @jacqueline-williams-549 this is the toast message styling which already exists, lmk if you want me to change anything or if it looks good for now.
    image.png

  13. severinbeauvais commented on Jan 10, 2025

    @severinbeauvais
    CollaboratorAuthor

    Can we make this Toast shorter and wider, maybe on a single line?

  14. jacqueline-williams-549 commented on Jan 10, 2025

    @jacqueline-williams-549

    @Rajandeep98 Yes I agree, if we can make it a single line that would be great and if we could also make the button text blue (1669BB)
    Also could you tell me if the font size is 0.875 rem/14px?

    Screenshot 2025-01-10 at 11.13.18 AM.png

  15. severinbeauvais commented on Jan 10, 2025

    @severinbeauvais
    CollaboratorAuthor

    @jacqueline-williams-549 , what do you think about the 'X' button in the toast? It allows the user to ignore it, but the toast pops up again on the next poll (could be in 1 sec, 10 sec or 1 min). We don't want users to ignore this, right?

    Also, what are you thoughts about putting the toast at the top of the page instead?

  16. jacqueline-williams-549 commented on Jan 10, 2025

    @jacqueline-williams-549

    I like the idea of putting it at the top of the page. I think it will be less easy to ignore that way. Design team would like us to allow a way to close it so we should keep the X - but could we put it inside of a button?

    Business Dashboard.jpg

  17. severinbeauvais commented on Jan 10, 2025

    @severinbeauvais
    CollaboratorAuthor

    Rajan, would you like a new ticket for the changes above, and possibly auto-refresh as I mentioned to you? Or, we could re-estimate this ticket to a "5".

    My goal is to get something usable merged and deployed asap, and make any significant updates in another ticket later.

  18. jacqueline-williams-549 commented on Jan 10, 2025

    @jacqueline-williams-549

    If we use the X icon for now instead of the button, it could look something like this

    Screenshot 2025-01-10 at 12.20.18 PM.png

  19. Rajandeep98 commented on Jan 13, 2025

    @Rajandeep98
    Collaborator

    image.png

  20. Rajandeep98 commented on Jan 13, 2025

    @Rajandeep98
    Collaborator

    every 1 second until the 10 second mark
    every 10 seconds until the 1 minute mark
    every minute until the 30 minute mark
    every hour thereafter
    @severinbeauvais hey sev, this is new schedule

  21. jacqueline-williams-549 commented on Jan 13, 2025

    @jacqueline-williams-549

    This looks great, thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Entities TeamUX Assuranceenhancement

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions