Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature 431. Migrate to AG Grid and direct streaming #463

Closed
wants to merge 67 commits into from

Conversation

MytsV
Copy link
Contributor

@MytsV MytsV commented Aug 20, 2024

  • Developed a hook for streaming data directly and covered it with unit test
  • Developed a hook for throttling data (may be useful when implementing the dashboard)
  • Styled the AG Grid to fit the general theme of the app
  • Replaced the ComDOM implementation with the direct streaming for the RSE list page as a demo

There are still a lot of pending improvements to the table and generally the UI. I need a little time to come up with a new design to make more changes to the responsiveness and appearance.

MytsV added 28 commits August 16, 2024 13:09
This will let the component that uses the hook handle the error with more flexibility and accessibility
It is required if the streaming is used outside the AG Grid implementation
This will provide better flexibility in using it within UI
}

/*@layer base {*/
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MytsV any reason to keep these commented css styles here?

Copy link
Member

@maany maany Aug 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are storybooks able to pick up the ag-grid-rucio css file?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, that's still a WIP and something got left from connecting shadcn/ui. I'll review it when working on the toasts in this PR.

@MytsV any reason to keep these commented css styles here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are storybooks able to pick up the ag-grid-rucio css file?

Yes, and, luckily, without any additional setup!
image

@MytsV MytsV mentioned this pull request Aug 29, 2024
1 task
@MytsV
Copy link
Contributor Author

MytsV commented Aug 29, 2024

The basic parts for migrating to it everywhere are included here. On top of these changes, pages will be rebuilt
and covered by tests independently, as it proved hard to work with the current implementations.

This was referenced Aug 29, 2024
@MytsV
Copy link
Contributor Author

MytsV commented Sep 1, 2024

The new version of the streaming is the best of both worlds. While the previous implementation still experienced performance issues with receiving large amounts of data in a short time, ComDOM fetched it fast at least inside the worker. Therefore I decided to try it out with a worker and it turned out great. My idea was to make it as basic as possible, so there's less room for bugs. Communication between threads is done via messages instead of method calls.

There are no apparent issues neither with state management nor with loading at any rate. Benchmarks will be set up during the individual work on each page.

@MytsV
Copy link
Contributor Author

MytsV commented Sep 1, 2024

As the AG Grid styling doesn't use tailwind, it has to rely on a color mode observer to change it's theme together with tailwind components.

@MytsV
Copy link
Contributor Author

MytsV commented Sep 1, 2024

Current light vs dark theme of the table:
image
image

@MytsV
Copy link
Contributor Author

MytsV commented Sep 1, 2024

These are all the changes that relate only to the AG Grid integration. To proceed, I need to rewrite the current pages and cover them with tests as they aren't reliable. They will be built on top of this PR + #468 + #466. When the prettier configuration PR is accepted, I'll refactor everything.

@MytsV
Copy link
Contributor Author

MytsV commented Sep 1, 2024

I don't like how the code of streamWorker.js turned out and will refactor it, but currently I'm too scared to break something. So I'll cover some page with integration tests first :)

P. S. The unit tests for the hook had to go as they don't support web workers!

@MytsV
Copy link
Contributor Author

MytsV commented Sep 15, 2024

These changes are included in #477

@MytsV MytsV closed this Sep 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants