MSC Exam For Feature Use: Non-Preemptive and Preemptive Scheduling Algorithm
MSC Exam For Feature Use: Non-Preemptive and Preemptive Scheduling Algorithm
Operating system
Networking
Data base
Software engineering
Avoiding deadlock
Usually, the simplest and most efficient way to avoid deadlock is to ensure
that resources are always acquired in some well-defined order.
Now, in an example such as our database locking example (1), this ordering could
boil down to a programming policy. So long as all programmers know and apply
the policy of acquiring the locks in some well-defined order, you'll avoid deadlock.
For hopefully obvious reasons, we must release locks in the opposite order to that
in which we acquired them, and should release them in a finally clause:
Answer
Tasks are usually assigned with priorities. At times it is necessary to run a certain task that has a higher
priority before another task although it is running. Therefore, the running task is interrupted for some time
and resumed later when the priority task has finished its execution. This is called preemptive scheduling.
Operating system - pre-emptive and non-preemptive scheduling - Jan 07, 2010 at 15:00 PM by Vidya Sagar
Preemptive scheduling: The preemptive scheduling is prioritized. The highest priority process should
always be the process that is currently utilized.
Non-Preemptive scheduling: When a process enters the state of running, the state of that process is not
deleted from the scheduler until it finishes its service time.
NEXT>>
Layered architecture enables teams to work on different parts of the application parallely with minimal
dependencies on other teams.
Different components of the application can be independently deployed, maintained, and updated, on
different time schedules.
Layered architecture also helps you to test the components independently of each other.
There might be a negative impact on the performance as we have the extra overhead of passing
through layers instead of calling a component directly.
Development of user-intensive applications can sometime take longer if the layering prevents the use
of user interface components that directly interact with the database.
The use of layers helps to control and encapsulate the complexity of large applications, but adds
complexity to simple applications.
Changes to lower level interfaces tend to percolate to higher levels, especially if the relaxed layered
approach is used.
There might be a negative impact on the performance as we have the extra overhead of passing
through layers instead of calling a component directly.
Development of user-intensive applications can sometime take longer if the layering prevents the use
of user interface components that directly interact with the database.
The use of layers helps to control and encapsulate the complexity of large applications, but adds
complexity to simple applications.
Changes to lower level interfaces tend to percolate to higher levels, especially if the relaxed layered
approach is used.
subject fact
divide and conquer has definition The principle of dividing something large into
smaller units, so it can be dealt with more easily
has benefits
Separate people can work on each part. The original development work can
therefore be done in parallel
An individual software engineer can specialize in his or her component and become
expert at it
When one part needs to be replaced or changed, it can hopefully be done without
having to replace or extensively change other parts