LogoLogo
English
English
  • Diarkis Help Center
  • Overview of Diarkis
  • Getting Started
    • Diarkis Server Template
    • Diarkis Client SDK
    • Tutorials
      • 1. Launch Diarkis Server in Local Environment
      • 2. Perform Connectivity Check with Test Client
      • 3. Implement Custom Command
      • Connect to Server from Diarkis Client
    • Samples
  • Diarkis Modules
    • Room Module
      • Set Up Room Module on Server
      • Room Sample
        • room_broadcast
      • Utilizing Room Module from Client
      • Additional Features of Room
    • MatchMaker Module
      • Set Up MatchMaker Module on Server
    • Field Module
      • Set Up Field Module on Server
    • P2P Module
      • Set Up P2P Module on Server
      • P2P Sample
    • DM (Direct Message) Module
      • Set Up DM Module on Server
    • Notifier Module
      • Set Up Notifier Module on Server
    • Session Module
      • Set Up Session Module on Server
    • Group Module
      • Set Up Group Module on Server
  • Diarkis Server
    • Launch Diarkis Server in Cloud Environment
      • AWS
    • Launch Diarkis Server on Windows Environment
    • MARS Server
    • UDP Server
    • TCP Server
    • HTTP Server
    • Metrics API
    • Inter-server Communication - Mesh
  • Diarkis Client
    • Runtime Library
      • Diarkis RUDP
    • Diarkis Module
      • Initialization and Termination of Diarkis Module
      • Customization of Diarkis Module
      • Logging System of Diarkis Module
      • Migration
      • Threads of Diarkis
    • Samples
      • C++
        • room_broadcast
        • directmessage_simple
        • group_sample
        • matching_and_turn
        • matchmaker_ticket
        • p2p_rudp_sample
        • session_simple
      • Unreal Engine Plugin
        • FieldWalker
      • Unity Plugin
        • FieldWalker
          • HowToReplicatePosition.md
  • Diarkis Tools
    • Diarkis CLI
      • Procedures to Switch to Diarkis CLI v3
  • References
    • API Reference
    • Release Notes
      • v1.0
      • v1.0.1
      • v1.0.2
      • v1.0.3
      • v1.0.4
      • v1.0.5
      • v1.0.6
  • Support
    • License and Billing
Powered by GitBook
On this page

Was this helpful?

  1. Diarkis Modules

DM (Direct Message) Module

Diarkis DM – One-to-One Server-Relayed Messaging Module

Overview

Diarkis DM (Direct Message) is a lightweight, server-relayed communication module designed for one-to-one message exchange between users without requiring session initialization or room membership. It enables direct packet-based communication by referencing the recipient’s unique user ID, offering a fast and simple mechanism for private messaging.

Technical Overview:

  • Direct User Addressing: Messages are sent by specifying the recipient’s user ID, eliminating the need for room discovery, matchmaking, or group registration. This enables instant, ad-hoc communication between known users.

  • Server-Relay Architecture: Unlike Diarkis P2P, which attempts direct peer connections, Diarkis DM uses a server-mediated relay path, routing messages through one or two Diarkis servers to reach the destination client. This ensures message delivery across NAT-bound and firewall-restricted networks without requiring hole punching or NAT traversal.

  • Message Routing and Path Efficiency: The relay path is dynamically determined based on user distribution within the cluster. Diarkis attempts to minimize server hops, but multi-server relaying (up to two hops) is supported to ensure reliable delivery across distributed server infrastructure.

Usage Considerations:

  • Optimized for One-to-One Communication: While technically capable of sending messages to multiple recipients, Diarkis DM is not optimized for multicast or broadcast. For use cases involving multiple users (e.g., chat rooms, game lobbies, or team coordination), Diarkis Room or Diarkis Field is recommended.

  • Latency and Frequency Constraints: Due to its server-relay design, Diarkis DM is not ideal for high-frequency, low-latency data exchange. Applications requiring real-time synchronization or rapid event exchange should consider Diarkis P2P or server-side modules that offer lower-latency characteristics.

For integration guidelines and detailed API specifications, refer to the Diarkis Server API Reference.

PreviousP2P SampleNextSet Up DM Module on Server

Last updated 1 month ago

Was this helpful?