1. Homepage
  2. Programming
  3. COMP2432 Operating Systems - Group Project: Appointment Organizer

COMP2432 Operating Systems - Group Project: Appointment Organizer

Engage in a Conversation
APpointment OrganizerCOMP2432Operating SystemsHong KongPolyU

COMP2432 Group Project (2022/2023 Semester 2) CourseNana.COM

Project title: APpointment Organizer (APO)

Scenario

Nowadays, people are always busy. There are dates, meetings, gatherings and many other events and activities that have to be made and arranged. In order to avoid conflicts, people need a good assistant application to record and arrange those appointments, e.g. using PDA or phone organizer. In the Department of Computing, students John, Lucy, Mary and Paul are good friends and have formed a study group. They always have gatherings and other activities on the campus. However, due to the condensed classes and time tables in this semester, the gatherings cannot be arranged properly in most of the time. They have to check with one another for the availability of timeslots when they want to confirm with an appointment. It is very time-consuming and inefficient to make appointments in this “manual” approach. Knowing that you have learnt process scheduling from the subject COMP2432; maybe you can give them a hand to simplify their appointment bookings and organization problems. Furthermore, in future, you might want to further develop this APO and deploy within their mobile phones to carry out such scheduling and organizing functionalities, if you are interested. CourseNana.COM

Project Requirements

In this project, you will be given an opportunity to apply the theory of process scheduling you have learnt from COMP2432 to a daily-life scenario and produce the APpointment Organizer (APO). In general, APO may be designed with different modules with different functionalities. As a default arrangement, this project may be developed in five stages in the form of five parts (or up to six parts): CourseNana.COM

Part 1. Write a program that allows users to add details of appointment (date, time, duration, and/or callees) to the scheduler. Note that the one who initiates for the appointment is called the “user” or the “caller” and those other members involved in the appointment are called “callees”, making use of the terms in procedure call within a program. This program is referred to as the Input Module. Bear in mind that this application should allow batch input, i.e. reading in from files for data entries. It is recommended to store all meeting requests in a log file for future audit purpose (and in your case, debugging purpose). By the way, the application is developed to be used internally for the time being. If the result is satisfactory, you may consider promoting it to the public to use the application, e.g. publish it under Google Play. CourseNana.COM

Part 2. APO checks whether the timeslot(s) of the involved parties are available or reserved. That is, not only the user’s timeslot(s), but also those of the callees’, if any, would be checked 1 . APO sends messages to all callees to check for their availability and callees should reply the message no matter the timeslot(s) are available or not. If all parties are available, the appointment should be then confirmed2. Otherwise, the appointment would be rejected or rescheduled3. For example, consider the scenario that Paul calls for a meeting with Lucy and Mary. APO checks not only for Paul’s schedule but also the schedules of Lucy and Mary. The appointment would be accepted and confirmed only when all of them are available. Otherwise, the appointment would be rejected or rescheduled. Here, “rescheduling” is a bonus option. This appointment information should be reflected within the time table generated (see printSchd below under Implementation section) by all the users involved. Part 3. Extend the program developed in Part 2 with a scheduler to generate a timetable for all appointments (i.e. timeslots engaged or available). The scheduler might implement several scheduling algorithms similar to those covered in lecture 6. (In this project, you are asked to implement at least two. One of them should be the relatively straightforward First Come First Served.) This is called the Scheduling Kernel, within the Scheduling Module. That is the module to include all the scheduling algorithms that you have implemented. Part 4. Augment the program with the facilities to print appointment schedule for users in Part 2. Those rejected appointments should all be included and recorded in an output file, named “rejected.dat”. This constitutes the Output Module. CourseNana.COM

Part 5. Analyze the program with different scheduling methods for which you have tested. List out those advantages and disadvantages which can be read from the program implemented. Part 6. (Bonus up to 5%) Implement the automatic rescheduling algorithm(s) and discuss on the advantages and disadvantages of your rescheduling algorithm(s). You must form a group of 4 to 5 persons for the project. The project must be implemented using programming language C and it must be successfully executed on ANY ONE of Linux Servers (apollo or apollo2) in the Department of Computing. You will have to specify to us on which Linux server your project would be executed for our testing. Note that “gcc” or “cc” is the compiler that can be used in this project. CourseNana.COM

Implementation

User Interface

First of all, your program should provide a menu to allow the user to input appointments or command for the organizer. There are several input methods to be accepted by the system. The system should also show whether the appointment is accepted or rejected (print the reason if possible). Below is an example of some inputs and outputs as seen on a screen. CourseNana.COM

./apo 20230401 20230430 john mary lucy paul
~~WELCOME TO APO~~
Please enter appointment:
privateTime paul 20230401 1800 2.0
-> [Recorded]
Please enter appointment:
privateTime mary 20230402 2000 3.0
-> [Recorded]
Please enter appointment:
projectMeeting john 20230402 1900 2.0 paul mary
-> [Recorded]
Please enter appointment:
groupStudy paul 20230403 1800 2.0 john lucy
-> [Recorded]
Please enter appointment:
gathering lucy 20230404 1900 4.0 john paul mary
-> [Recorded]
…
…
Please enter appointment:
printSchd FCFS
-> [Exported file: Ggg_01_FCFS.txt]
…
…
Please enter appointment:
printSchd PRIORITY
-> [Exported file: Ggg_08_PRIORITY.txt]
Please enter appointment:
projectMeeting john 20230429 2000 2.0 lucy mary
-> [Recorded]
…
…
Please enter appointment:
printSchd ALL
-> [Exported file: Ggg_99_ALL.txt]
Please enter appointment:
endProgram
-> Bye!

Command Syntax and Usage

To execute the program Syntax CourseNana.COM

./apo YYYYMMDD YYYYMMDD u1 u2 u3 … e.g. ./apo 20230401 20230430 john mary lucy paul CourseNana.COM

Enter [./apo] to start the program where [YYYYMMDD] x 2 and [u1 u2 u3 …] are Start Date and End Date, and the Users of the application respectively. For example, APO will manage requests starting from April 1, 2023 (20230401) and ending at April 30, 2023 (20230430). In addition, [john mary lucy paul], are the users in this application. CourseNana.COM

Use CourseNana.COM

Note: This is the first instruction or command that should have been executed before the application could accept user requests and schedule those appointments. There are at least three users and the maximum number is ten. The system should return an error message if the number of users is not in the range 3 to 10. In addition, you need to convert the names to the standard format (i.e., first letter capitalized regardless of the input string) for all outputs. CourseNana.COM

For the time being, APO simply manage the timeslots from 18:00 to 23:00 and it is one hour one timeslot. In the other words, there are five timeslots per day. Upon further development, APO may have half hour as one timeslot. CourseNana.COM

Command CourseNana.COM

privateTime CourseNana.COM

Syntax CourseNana.COM

privateTime uuu YYYYMMDD hhmm n.n e.g. privateTime paul 20230401 1800 2.0 CourseNana.COM

Use CourseNana.COM

It is to add private time into a user’s time table. As in the example, it is to add a private time session for [Paul] on [April 1, 2023] starting at [18:00] and the duration is [2.0] hours. [uuu] – Caller [YYYYMMDD hhmm] – Date and time of the event, YYYY:Year (4 digits), MM:Month (2 digits), DD:Day (2 digits), hh:Hour (2 digits) and mm:Minute (2 digits). [n.n] – Duration of the appointment in hours (fixed point of one decimal place) CourseNana.COM

...... CourseNana.COM

This ends the program completely, upon collecting all the child processes and closing all the files. CourseNana.COM

To ease your work, we make the following assumptions: CourseNana.COM

  1. Input formats simply follow those in the examples.
  2. We will test the schedule for a period, from 1 to 31 May 2023 and the time is from 18:00 to 23:00. One time slot is an hour of time. That means there are 5 time slots a day. In addition, there is no appointment to be assigned on Sunday and Public Holiday.
  3. There are at least three users and at most ten.
  4. Usually, a “privateTime” entry has the highest priority and then it is a “projectMeeting”. The next one is “groupStudy”. The lowest one is “gathering”. If the APO applies “priority” as the scheduling algorithm, that priority information for appointments would be considered. For example, a project meeting may “displace” an already scheduled gathering so that the caller/callee involved would attend the meeting and the gathering would be canceled (or rescheduled).
  5. There are many implementation methods for the modules. The scheduler module may be implemented as a separate process, in the form of a child process created by the parent via fork() system call. The output module can also be a separate process. The scheduler may also be implemented as a separate program. If the parent is passing appointment details to a child scheduler, one should use the pipe() and associated write() / read() system calls. If the parent is passing information to a separate scheduler program, one could use the Unix shell “pipe” (denoted by “|”).
  6. If pipe() and fork() system calls are both used properly in the program, the maximum possible mark is 100% plus up to 5% of bonus points. On the other hand, if both system calls are not used in the program, only a passing mark would be awarded at best. Intermediate scoring will be given if only one system call is used, depending on the extent of usage.

Output Format

The “appointment schedule” and the “rejected list” may look like the following. Of course, you may have your own design for this report. CourseNana.COM


Period: 2023-04-01 to 2023-04-30
Algorithm used: FCFS
***Appointment Schedule***
. John, you have 999 appointments.
Date
Start
End
Type

People
=========================================================================

2023-04-02
19:00
21:00
Project Meeting
2023-04-04
19:00
23:00
Gathering
Mary Paul
…
…

- End of John’s Schedule =========================================================================
    Paul, you have 999 appointments.
    Date
    Start
    End
    Type

    People
    =========================================================================

    2023-04-01
    18:00
    20:00
    Private Time
    2023-04-04
    19:00
    23:00
    Gathering
    John Mary
    …
    …

- End of Paul’s Schedule =========================================================================
    …
    …
    …
    …

- End of Lucy’s Schedule =========================================================================
    …
    …
    …
    …

- End of Mary’s Schedule =========================================================================

......

Error handling

Although the program does not need to check for the correctness of the values that users input, some other error handling features are required in the application. For example, if the number of users is out of range (not between 3 and 10), APO should return a message to indicate that. CourseNana.COM

Documentation

Apart from the above program implementation, you are also required to write a project report that consists of following parts: CourseNana.COM

Get in Touch with Our Experts

WeChat WeChat
Whatsapp WhatsApp
APpointment Organizer代写,COMP2432代写,Operating Systems代写,Hong Kong代写,PolyU代写,APpointment Organizer代编,COMP2432代编,Operating Systems代编,Hong Kong代编,PolyU代编,APpointment Organizer代考,COMP2432代考,Operating Systems代考,Hong Kong代考,PolyU代考,APpointment Organizerhelp,COMP2432help,Operating Systemshelp,Hong Konghelp,PolyUhelp,APpointment Organizer作业代写,COMP2432作业代写,Operating Systems作业代写,Hong Kong作业代写,PolyU作业代写,APpointment Organizer编程代写,COMP2432编程代写,Operating Systems编程代写,Hong Kong编程代写,PolyU编程代写,APpointment Organizerprogramming help,COMP2432programming help,Operating Systemsprogramming help,Hong Kongprogramming help,PolyUprogramming help,APpointment Organizerassignment help,COMP2432assignment help,Operating Systemsassignment help,Hong Kongassignment help,PolyUassignment help,APpointment Organizersolution,COMP2432solution,Operating Systemssolution,Hong Kongsolution,PolyUsolution,