Skip to content

IbrahimIF/Car-Park-App

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Car-Park-App

This repository contains the implementation details for the WLFB Car Park Application, a multi-threaded client-server system developed as a core assessment for the CS3004 Network Computing module. The primary objective of this project is to simulate a car park management system that dynamically tracks the number of available spaces as cars enter and leave.

The WLFB Car Park (WCP) system models a car park with two distinct entrances (EntA, EntB) and two exits (ExA, ExB). The system is designed to demonstrate key concepts in network computing, including client-server communication, multi-threading, and concurrency control using locking mechanisms.


image


Core Functionality:

Client-Server Architecture: The application is built upon a robust multi-threaded client-server model.

Car Park Management: The server maintains the current number of cars in the car park and the available spaces.

    The car park is assumed to have five spaces for simplified testing.

Entrances (EntA & EntB):

    Each entrance is implemented as a separate client with its own simple integer queue representing waiting cars.

    Check_space: Clients can query the server for the current car park space.

    Add_car: Clients instruct the server to add a car to the car park (if space is available), removing it from the entrance queue. Cars will queue if the car park is full.

Exits (ExA & ExB):

    Each exit is also implemented as a separate client.

    Remove_car: Clients instruct the server to remove a car from the car park, reducing the car count by one.

Server:

    Manages the car park's state (number of cars) as a shared integer variable.

    Responds to client requests (space checks, adding/removing cars).

    Locking mechanisms are critically employed to ensure data integrity and thread safety across all client operations.

    No user interface is required or implemented.

Key Dates

Distribution Date: October 10, 2023

Submission Deadline: December 01, 2023 (11:00 AM)

Feedback By: December 15, 2023

Technologies and Tools Utilised:

My Skills


About

A multi-threaded Java client-server application demonstrating a car park management system for the CS3004 Network Computing module.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages