A public forum for discussing the design of software, from the user interface to the code architecture. Now closed.
Object ConcreteThread creates a ProcessControl object.
Object ConcreteThread run a ThreadProc function as a thread.
Object ConcreteThread communicates with ThreadProc via a ProcessControl object.
ThreadProc is using a Service object.
Service object has methods (functions) that might block.
ServiceMonitor can unblock these methods.
A time limit is defined for the run of a function that might block.
Before the function execution begins the time is taken.
To determine whether a blocking function is exceeding it’s time limit, the current time minus the start time is compared to the time limit.
There is going to be an object, responsible for measuring time.
Its suggested name is “Watch”.
Here are four options for locating this Watch object in the system.
1. In ThreadProc function. This thread is blocked. Will another thread be able to access the Watch object while the thread is blocked?
2. As a member of the service object. This object is also located in the blocked thread.
3. In a data structure in the ServiceMonitor. The ServiceMonitor must know all the Service objects. It has its own thread for the sole purpose of releasing blocking functions.
ps sorry i coudn't post the sequence diagram here...
thought for joel... maybe some sort of file upload should be available.
Sunday, September 10, 2006
This topic is archived. No further replies will be accepted.Other recent topics
Powered by FogBugz