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

Refine resource's queue discipline #20

Closed
Enchufa2 opened this Issue Nov 23, 2015 · 9 comments

Comments

Projects
None yet
2 participants
@Enchufa2
Member

Enchufa2 commented Nov 23, 2015

  • Add priorities.
  • Preemption?
@Bart6114

This comment has been minimized.

Member

Bart6114 commented Dec 1, 2015

ideally different levels of priorities
where a higher "level number" equals a higher priority

e.g.

t0<-
  create_trajectory() %>%
  seize("operator", 1, priority=2) %>%
  timeout(3) %>%
  release("operator", 1)

Bart6114 added a commit that referenced this issue Dec 7, 2015

@Bart6114 Bart6114 closed this Dec 7, 2015

@Bart6114

This comment has been minimized.

Member

Bart6114 commented Dec 7, 2015

woops, didn't mean to close it 😬

@Bart6114 Bart6114 reopened this Dec 7, 2015

@Enchufa2

This comment has been minimized.

Member

Enchufa2 commented Dec 7, 2015

Nice! BTW, merge the latest developments of the master branch in your tree, please. For instance, I introduced the Boost library and I created a new header devoted to standardise the use of efficient containers (vector, queues, map, set...) through macros.

@Bart6114

This comment has been minimized.

Member

Bart6114 commented Dec 7, 2015

nice^2

I'll try to do the merge this evening

@Bart6114

This comment has been minimized.

Member

Bart6114 commented Dec 7, 2015

check 8a23121 for a start with testing FIFO processing (and implementation)

@Bart6114

This comment has been minimized.

Member

Bart6114 commented Dec 7, 2015

moved compare func into the struct (tx, a lot more elegant) e2d2822

haven't had time to look into in in detail but couldn't get your suggestion working on the simple FIFO ordering when priorities are equal (for example, std::sort also doesn't guarantee preserving order of equal elements).

Enchufa2 added a commit that referenced this issue Dec 7, 2015

Merge pull request #32 from Bart6114/dev-bart
merging initial priority queue developments into dev-main (#20)
@Enchufa2

This comment has been minimized.

Member

Enchufa2 commented Dec 7, 2015

You are right. Definitely, we need the arrived_at secondary key (and my tests suggest that the priority queue performs similarly to the previous FIFO queue 👍). As a consequence, I had to use priorities to ensure that releases go before seizes (see ac74e22 and this test).

Now, what about preemption? It is a far more complex task. 😬 I'm going to merge the current changes into the master branch before continuing with this.

Enchufa2 added a commit that referenced this issue Dec 7, 2015

Merge pull request #33 from Bart6114/dev-main
Latest developments on #20 and some fixes
@Bart6114

This comment has been minimized.

Member

Bart6114 commented Dec 8, 2015

Let's close this and discuss the preemption (which will be a far bigger challenge 😀) in #34

@Bart6114 Bart6114 closed this Dec 8, 2015

@Enchufa2 Enchufa2 added this to the v3.1.0 milestone Dec 8, 2015

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