Skip to content

Commit 1c3051d

Browse files
committed
Add README.md
1 parent 0dc1106 commit 1c3051d

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

README.md

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# Taskmaster
2+
3+
The Taskmaster library is a queue oriented thread management library written in Java. This project will help developers create serial queues of tasks that need to be accomplished in order.
4+
5+
6+
# Introduction
7+
8+
## Taskmaster
9+
The Taskmaster class is the API into this library. It can be set up with a few different configurations that make it customizable to the situation in which it should be used.
10+
11+
### Thread count
12+
13+
The most widely used option will be the number of threads. By default, the taskmaster will only use a single thread for executing tasks which is not efficient. Each use case will be different, but in general the thread count should not exceed the number of queues while being as close to as many as possible.
14+
15+
## Queues
16+
17+
Queues are responsible for keeping the order and status of pending tasks. They are generated from the developer created Taskmaster instance. Once a queue has been created from the taskmaster instance, a developer can add tasks to them. Tasks will be executed in a first in - first out pattern.
18+
19+
If there is a priority task that must be completed as soon as possible, the task can be submitted directly to the head of the queue. Once the Taskmaster instance is ready to submit a new task to a be executed, this will be the next task taken from that queue.
20+
21+
### Limited Queues
22+
23+
Limited queues are just like regular queues except they are created with a finite number of tasks. These queues are created with all of their tasks at creation. Once all the tasks are completed, the queue itself closes and the taskmaster will remove it from its memory.
24+
25+
## Tasks
26+
27+
Tasks are the basic building blocks to be submitted to queues. The Task class itself is abstract with a single abstract method that needs to be implemented, the `onExecute()` method. This method will be called once a thread has picked up the Task to be ran.
28+

0 commit comments

Comments
 (0)