Creates a process pool of n processes

Assignment Help C/C++ Programming
Reference no: EM132255746

P1. Consider that a TCP server is designed in the following manner:

– Server creates a process pool of N processes. Each process can create a pool of T threads. Each thread accepts a connection on a shared listening descriptor.

– Whenever a process completes processing CPP number of clients across all its threads, server terminates that process and adds a new process to the pool. This is to avoid accumulation of memory leaks in the process.

– Thread processes client's request as per the chat protocol described here: Client can send three messages JOIN <name>, LEAV and CHAT <targetname> <msg>. In JOIN message, client sends its nickname and in CHAT message it sends the nickname of the person to whom it needs to be delivered and the contents. When server receives a CHAT message, it sends the message on the socket matching the nickname.

Server accepts port no, N, T and CPP as command line parameters. For the above requirements, write a program to implement the server.

You can use any language to implement it. Program should print meaningful output for every event.

Deliverables:
– well documented source code with README on how to run it
– screen recording of the demo with explanation
– pdf file explaining design decisions

Verified Expert

The solution file is implemented in net beans and report generated in ms word which has the source code of the server, client, and cthread.The program is implemented TCP server creates a process pool of N processes. Each process can create a pool of T threads. Each thread accepts a connection on a shared listening descriptor. Whenever a process completes processing CPP number of clients across all its threads, the server terminates that process and adds a new process to the pool. The client can send three messages to JOIN, LEAV and CHAT. In JOIN message, the client sends its nickname and in CHAT message it sends the nickname of the person to whom it needs to be delivered and the contents. When the server receives a CHAT message, it sends the message on the socket matching the nickname. The report has source code, class diagram use case diagram and the screenshot of program output.

Reference no: EM132255746

Questions Cloud

Determine the cash balance per Oriole Limited books : The reconciled cash balance from June's bank reconciliation is $18,340. Determine the cash balance per Oriole Limited's books
What are the credit spreads on the short term bonds : What are the credit spreads on the short term and longer term bonds? Do they seem compatible with the ratings of the bonds?
Which facts lead you to believe that you will need fewer : Which facts lead you to believe that you will need fewer drivers next year? What other information would you want to make a more accurate forecast?
Discuss how a newer entrepreneurial venture might differ : Discuss how a newer entrepreneurial venture might differ from a more mature, intrapreneurial venture in its approach to social media.
Creates a process pool of n processes : Create a process pool of N processes. Each process can create a pool of T threads. Each thread accepts a connection on a shared listening descriptor
How could mcdonalds be a real threat : Why McDonald's is not a real threat? How could McDonald's be a real threat?
What would net income and return on assets be for the year : Division B is able to make only $28,800 on sales of $329,000. Based on the profit margins (returns on sales), which division is superior?
Differentiate short term from long term problems : Identify criteria against which you evaluate alternative solutions (i.e. time for implementation, tangible costs, acceptability to management)
Discuss the culture of the united arab emirates : Discuss the culture of the United Arab Emirates , and India using Hofstede's cultural dimensions.

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Create program that uses functions and reference parameters

Create program that uses functions and reference parameters, and asks user for the outside temperature.

  Write a program using vectors and iterators

Write a program using vectors and iterators that allows a user to maintain a personal list of DVD titles

  Write the code required to analyse and display the data

Calculate and store the average for each row and column. Determine and store the values for the Average Map.

  Write a webservices application

Write a webservices application that does a simple four function calculator

  Iimplement a client-server of the game

Iimplement a client-server version of the rock-paper-scissors-lizard-Spock game.

  Model-view-controller

Explain Model-View-Controller paradigm

  Design a nested program

How many levels of nesting are there in this design?

  Convert celsius temperatures to fahrenheit temperatures

Write a C++ program that converts Celsius Temperatures to Fahrenheit Temperatures.

  Evaluate and output the value in the given base

Write C program that will input two values from the user that are a Value and a Base with which you will evaluate and output the Value in the given Base.

  Design a base class shape with virtual functions

Design a base class shape with virtual functions

  Implementation of classes

Implementation of classes Chart and BarChart. Class barChart chould display a simple textual representation of the data

  Technical paper: memory management

Technical Paper: Memory Management, The intent of this paper is to provide you with an in depth knowledge of how memory is used in executing, your programs and its critical support for applications.

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