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 option to prioritise requests in the queue #362

Open
jiajunhui opened this issue Feb 25, 2022 · 6 comments
Open

Add option to prioritise requests in the queue #362

jiajunhui opened this issue Feb 25, 2022 · 6 comments

Comments

@jiajunhui
Copy link

Is there a way to get the length of the current queue and whether there is a way to jump the queue? For example, I want to improve the priority of some commands.

@philips77
Copy link
Member

Hello, in the current version you may only clear the queue using

@philips77 philips77 changed the title Are there any methods related to queue operation? Add option to prioritise requests in the queue Mar 16, 2022
@NordicSemiconductor NordicSemiconductor deleted a comment from jiajunhui Mar 16, 2022
@philips77
Copy link
Member

Hello,

I'm thinking of a method to enqueue to the front of the queue. Would that help you? Modification of the order of the already enqueued packets seems dangerous.

@philips77
Copy link
Member

Related: #218

@philips77
Copy link
Member

I was thinking about the feature request. Adding something like enqueueFirst() would also imply adding similar methods with await() and suspend() in the ktx module, but some issues may arise there. Let's say someone is using suspend() methods, which end when the request end. If a user then calls suspendFirst() or alike, the manager could have already taken next request. I'll need to think more about it.

@NordicSemiconductor NordicSemiconductor deleted a comment from jiajunhui May 4, 2022
@LuoPeiQin
Copy link

This is very useful to me, is there any development plan for this feature now?

@philips77
Copy link
Member

Currently not. May I ask why do you need this method? What is the use case. We may consider changing priorities.

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

No branches or pull requests

3 participants