We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
  • Practice
  • Certification
  • Compete
  • Career Fair
  • Hiring developers?
  1. Practice
  2. Distributed Systems
  3. Client Server
  4. UDS Echo Server

UDS Echo Server

Problem
Submissions
Leaderboard
Discussions

This challenge tests your understanding of Sockets and Multi-Threaded programming.

Your task is to write a UNIX Domain Socket(UDS) server which can accept connection from 'N' clients. Each client will send text data over the socket. Read the data and send it back to the client. The server should be Multi-Threaded and should service all clients in parallel.
To support Multi-Threading you can use the POSIX thread library (C,C++) or the default threading library for other languages.

Communication Protocol

Read data from client and send the response back.
String "END" marks end of communication from a client. Send response "END" and disconnect the client.

Example request 1:

Client 1:
Hello World
END

Example response 1:

Client 1:
Hello World

Example request 2:

Client 2:
This is line 1
This is line 2
END

Example response 2:

Client 2:
This is line 1
This is line 2

Author

patilarpith

Difficulty

Easy

Max Score

10

Submitted By

2274

Need Help?


View discussions
View top submissions

rate this challenge

MORE DETAILS

Download problem statement
Download sample test cases
Suggest Edits
  • Contest Calendar
  • Blog
  • Scoring
  • Environment
  • FAQ
  • About Us
  • Support
  • Careers
  • Terms Of Service
  • Privacy Policy
  • Request a Feature