Python Forum
features for asynchronous command execution class
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
features for asynchronous command execution class
#1
i'm writing a class to execute commands in a pool that limits the number of processes that can be started concurrently. single commands and command pipelines can be executed. the number of commands in a pipeline is counted as the number of processes. it can't know if some command runs more than one process. commands are given to it in a .cmd() method and they are started in the order given, delayed to keep the total number from exceeding the limit. pipelines may not be longer than the limit. no indication is given to the caller about command completion, but i am planning to make a more advanced class in the future that includes that. the other method is .join() to wait for the queue of commands to all complete. the limit for number of processes is given when the instance is created. commands are a list (or tuple) of separated tokens (command name and arguments, str, bytes, or bytearray). a command pipeline is a list (or tuple) of commands.

does anything like this already exist? i have looked at multiprocessing.pool and has nothing like this.

i am also interesting in any suggestions for features i should include in the class i am creating or the future version of it.
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Key features of Python Frameworks JahnviK 0 748 Sep-24-2022, 06:09 AM
Last Post: JahnviK
  features examples by release costa_shul 2 2,497 Sep-06-2020, 11:35 AM
Last Post: costa_shul
  Interesting new features in python3 Kebap 8 5,872 Jul-05-2017, 03:53 PM
Last Post: nilamo

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020