Coit132229 applied distributed systems assignment

Assignment Help Programming Languages
Reference no: EM132495036

COIT132229 Applied Distributed Systems

Assignment - Java Client/Server Application

Objectives
This assessment item is designed to test your understanding in Java TCP networking, Java Object Serialization/Deserialization, threading, file reading and writing using a client/server application development.

Assessment task
CQU aquatic centre offers swim facility to current students and their families. Entry to the swimming centre is accessible through any of the three automatic doors by keying in a registered student number followed by a 4-digit pin code preferably set to the year of birth. Each entry is charged a flat fee and the time should be persisted to a log file with two fields (student number space separated with entry date and time). Because of the flat fee structure, the entry details can be shared among family members. The system should accommodate both existing users with authentication and provide registration for new users. Administrator role is not relevant and will be discussed in the second assignment. The application should be implemented as a client/server model using java TCP sockets. The client program handles all the data entry and menu selections (1. Current Student 2. New Student 3. Exit). Current student should only be prompted for a student number and a pin code. New student registrations should be prompted to provide relevant details (Student number and a Pin Code). Appropriate error messages (Student exists, Un- Registered Student, Invalid Pin, Welcome or Student Created) should be received from the server after processing and displayed on the client. Student number is alphanumeric but cannot be empty. The client should create an instance of relevant type before sending to the server program for processing and storage. Every 3 minutes the contents from the data structures stored on the server need to be persisted to the text files. The server program should have the capability to concurrently handle multiple client connections (Thread-per-connection). Existing records are to be read and loaded from the provided text files ("studententry.txt" and logentry.txt"). When these text files do not exist, the system should handle this event and create new files.

Coding and Design
You can use the following class descriptions as a guideline for your design.
(At minimum two java files should be used)
Student: This class should implement serializable (Refer to figure 1).
LogEntry: This class should implement serializable and comparable interface to use an inbuilt java Collections.sort() method. (Refer to figure 1).
Example) SimpleDateFormat formatter = new SimpleDateFormat("dd/MM/yyyy-HH:mm:ss");
WriteToFile: This class persist all the contents from the data structures to the text files.
TCPClient: This class handles the data entry with suitable menus and interacts with the user. This program creates an instance of (Student /LogEntry / String) on user selection before sending it to the server. Socket,

ObjectInputStream and ObjectOutputStreamfor for TCP Connection should be used. The program should allow the client to enter the details for multiple entries.

TCPServer: This server loads existing records from the text files ("studententry.txt" and "logentries.txt") to appropriate data structures preferably an ArrayList. A timer function should be used to regularly schedule the contents of the ArrayList to be written to the two text files every 3 minutes. The "logentries.txt" should contain entries sorted by the student number. The server program should be running indefinitely ready to communicate with all future clients.

Your program should check user inputs for potential error and allow user to re-enter details where appropriate. The source code should be formatted properly following good programming practice (appropriate variable names, indentation, comments, etc....)

Report
Include an end user instruction and test manual. Run the program and take screenshot of program outputs for all tests with annotations. The test should demonstrate that your TCPServer can accept connections from more than one TCPClient. Provide screenshots of your "studententry.txt" and "logentry.txt".

Attachment:- Applied Distributed Systems.zip

Reference no: EM132495036

Questions Cloud

Find the slope and y-intercept of the regression line : Find the slope and y-intercept of the regression line. What is the equation of the regression line in this problem?
Assignment - Client-Server Synchronization : Concurrent and Parallel Programming Assignment - Client/Server Synchronization, Griffith College Dublin, Ireland. Manage the draw or to save ticket data to file
What is the probability that exactly 3 of those games : If 4 Colonials games are chosen at random, what is the probability that exactly 3 of those games are won by the Colonials?
MGT213 The Project Lifecycle Assignment : MGT213 The Project Lifecycle Assignment help and solution, Southern Institute of Technology - assessment writing service -Define the scope of project management
Coit132229 applied distributed systems assignment : COIT132229 Applied Distributed Systems Assignment help and solution, Java Client/Server Application - assessment writing service
Computing the annual payment : You need to accumulate $108,455 for your son's education. You have decided to place equal year-end deposits in a savings account for the next 15 years.
Evaluate project by using irr decision rule : Suppose your firm is considering investing in a project with the cash flows shown below, that the required rate of return on projects of this risk class is 8 pe
What is the value per share of firm a : Firm B has 6,500 shares of stock outstanding at a price of $25 a share. What is the value per share of Firm A after the acquisition?
What is the stock intrinsic value-grace corporation : Grace Corporation common stock has a par value of $25 and recentlyn paid a dividend of $3.16 per share. The firm's dividends have grown from $1.50 to $3.16

Reviews

Write a Review

Programming Languages Questions & Answers

  Write a haskell program to calculates a balanced partition

Write a program in Haskell which calculates a balanced partition of N items where each item has a value between 0 and K such that the difference b/w the sum of the values of first partition,

  Create an application to run in the amazon ec2 service

In this project you will create an application to run in the Amazon EC2 service and you will also create a client that can run on local machine and access your application.

  Explain the process to develop a web page locally

Explain the process to develop a Web page locally

  Write functions

These 14 questions covers java class, Array, link list , generic class.

  Programming assignment

If the user wants to read the input from a file, then the output will also go into a different file . If the user wants to read the input interactively, then the output will go to the screen .

  Write a prolog program using swi proglog

Write a Prolog program using swi proglog

  Create a custom application using eclipse

Create a custom Application Using Eclipse Android Development

  Create a application using the mvc architecture

create a application using the MVC architecture. No scripting elements are allowed in JSP pages.

  Develops bespoke solutions for the rubber industry

Develops bespoke solutions for the rubber industry

  Design a program that models the worms behavior

Design a program that models the worm's behavior.

  Writing a class

Build a class for a type called Fraction

  Design a program that assigns seats on an airplane

Write a program that allows an instructor to keep a grade book and also design and implement a program that assigns seats on an airplane.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd