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

Add an indictor when queries are pending to vgplot mosaic clients #550

Open
domoritz opened this issue Oct 4, 2024 · 9 comments
Open

Add an indictor when queries are pending to vgplot mosaic clients #550

domoritz opened this issue Oct 4, 2024 · 9 comments
Labels
good first issue Good for newcomers

Comments

@domoritz
Copy link
Member

domoritz commented Oct 4, 2024

As discussed in #506 (comment).

We probably don't want to show an indicator when the request is only a few ms (so the UI doesn't flash).

@Danish-Dsouza
Copy link

I will take this one. Should I just use setTimeout() to delay the indicator when it would show for less than a few ms?

@domoritz
Copy link
Member Author

We will have to review the whole implementation but setTimeout is probably a component of it.

@Danish-Dsouza
Copy link

Got it. I'm not going to mess with the MosaicClient itself but simply add queryPending() implementations in each input type and plot if that's okay.

@domoritz
Copy link
Member Author

Hmm, I think that's maybe not enough since you would need to constantly pull to get updates. Maybe we should implement it as a signal.

@Danish-Dsouza
Copy link

Any suggestions on how I could go about doing that? The signal would have to be global across the mosaic instance right? Presumably it would originate from the co-ordinator?

@domoritz
Copy link
Member Author

I was imagining a signal per client.

@jheer
Copy link
Member

jheer commented Oct 21, 2024

I would recommend using queryPending (in conjunction with queryResult / queryError) to start. I don’t see why you’d need to constantly pull?

MosaicClient is too general for a full solution so I agree that subclasses should be responsible for this. Might make sense to provide an intermediate abstract class that “knows” more about the rendering for better reuse.

@Danish-Dsouza
Copy link

Danish-Dsouza commented Oct 22, 2024

@jheer Neat, that's the implementation I had in progress. I'll make the PR soon. Could I be assigned?

@domoritz
Copy link
Member Author

We don't need to assign issues. Just go ahead with a pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants