{"id":21909380,"url":"https://github.com/pbergstrom90/chattappsimulation","last_synced_at":"2025-03-22T07:49:48.983Z","repository":{"id":252779328,"uuid":"802005261","full_name":"PBergstrom90/ChattAppSimulation","owner":"PBergstrom90","description":"2 basic chatapplications for communication over UDP and/or TCP connection. May 2024.","archived":false,"fork":false,"pushed_at":"2024-10-28T15:07:31.000Z","size":50,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-27T08:12:13.750Z","etag":null,"topics":["chat-application","java","multicast","network","socket-io","tcp-client","tcp-server","udp"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PBergstrom90.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-17T10:34:38.000Z","updated_at":"2024-10-28T15:07:35.000Z","dependencies_parsed_at":"2024-10-28T17:36:40.978Z","dependency_job_id":"33d8acac-b1c7-4796-8b26-923ddddd9058","html_url":"https://github.com/PBergstrom90/ChattAppSimulation","commit_stats":null,"previous_names":["pbergstrom90/chattappexam","pbergstrom90/chattappsimulation"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PBergstrom90%2FChattAppSimulation","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PBergstrom90%2FChattAppSimulation/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PBergstrom90%2FChattAppSimulation/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PBergstrom90%2FChattAppSimulation/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PBergstrom90","download_url":"https://codeload.github.com/PBergstrom90/ChattAppSimulation/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244924766,"owners_count":20532874,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chat-application","java","multicast","network","socket-io","tcp-client","tcp-server","udp"],"created_at":"2024-11-28T17:17:15.341Z","updated_at":"2025-03-22T07:49:48.958Z","avatar_url":"https://github.com/PBergstrom90.png","language":"Java","readme":"# Chat Application\n\n## Overview\n\nThis repository contains two chat applications: `ChatAppTCP` and `ChatAppUDP`. Both applications allow multiple users to communicate in real-time via a graphical user interface (GUI). \n\n- **ChatAppTCP**: Uses the TCP protocol to ensure reliable communication.\n- **ChatAppUDP**: Uses the UDP protocol for faster, but less reliable communication.\n\n## Features\n\n- User registration and login.\n- Real-time messaging.\n- Display of connected users.\n- User-friendly GUI.\n- Server-side logging and control panel for the TCP application.\n\n## Requirements\n\n- Java SE Development Kit (JDK) 8 or higher.\n- Network connection.\n\n## Usage\n\n### ChatAppTCP\n\nThe TCP-based chat application provides a reliable messaging service, ensuring messages are delivered in the correct order and without loss.\n\n#### Server\n\n1. First, run `ServerMain.java`.\n2. Start the server using the \"Start Server\" button in the GUI.\n3. Monitor connected users and server status.\n4. Optionally, stop the server using the \"Stop Server\" button.\n\n#### Client\n\n1. Run `ClientMain.java`.\n2. Enter your username in the prompted dialog.\n3. The client connects to the server at `localhost` on port `8000`.\n4. Use the GUI to send messages and see the list of connected users.\n\n#### Directory Structure\n\n- `Client.java`: Manages the client's connection, sending and receiving messages.\n- `ClientGUI.java`: Provides the client's GUI.\n- `ClientMain.java`: Entry point for the client application.\n- `Server.java`: Manages client connections and broadcasts messages.\n- `ServerGUI.java`: Provides the server's GUI.\n- `ServerListener.java`: Handles communication with individual clients.\n- `ServerMain.java`: Entry point for the server application.\n- `User.java`: Represents a user and maintains a list of connected users.\n\n### ChatAppUDP\n\nThe UDP-based chat application provides a faster messaging service, but without the guarantees of message order and delivery.\n\n#### Client\n\n1. Run `Main.java` file to start up the client.\n2. Enter your username in the prompted dialog.\n3. The client connects to the server using multicast address `234.235.236.237` on port 8000.\n4. Use the GUI to send messages and see the list of connected users.\n\n#### Directory Structure\n\n- `GUI.java`: Provides the client's GUI.\n- `Main.java`: Entry point for the client application.\n- `NetworkReceiver.java`: Handles receiving messages from the server using UDP.\n- `NetworkSender.java`: Handles sending messages to the server using UDP.\n- `User.java`: Represents a user and maintains a list of connected users.\n\n## Notes\n\n- Ensure the server is running before starting the clients.\n- The TCP application is configured to connect to `localhost` on port `8000`. Modify the source code if a different address or port is required. The UDP application is using multicast for external communication.\n- Both TCP and UDP applications use the same `User.java` class for representing users.\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpbergstrom90%2Fchattappsimulation","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpbergstrom90%2Fchattappsimulation","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpbergstrom90%2Fchattappsimulation/lists"}