App::K...rverRef(3pm)

πŸ’– App::KGB::Client::ServerRef πŸ’–

okay bestie, welcome to the manual page for App::KGB::Client::ServerRef (that's a 3pm perl module page, if u were wondering) β€” it's the little object in the KGB client fam that represents a remote KGB server instance. She's basically the friend who handles all the talking-to-the-server stuff so u don't have to. 🫢


✨ NAME ✨

App::KGB::Client::ServerRef β€” a server instance in the KGB client. literally her whole job. πŸ’…


🌸 SYNOPSIS 🌸

use App::KGB::Client::ServerRef;
my $s = App::KGB::Client::ServerRef->new(
    {   uri      => "http://some.server:port/",
        password => 's3cr1t',
        timeout  => 5
    }
);

$s->send_changes( $client, $protocol_ver, $commit, $branch, $module, { extra => stuff } );

$s->relay_message( $client, $message, [ { opts } ] );

look at her go 😭 so clean


πŸ¦‹ DESCRIPTION πŸ¦‹

App::KGB::Client::ServerRef is used inside App::KGB::Client to point at remote KGB server instances (yes, the plural is real, she's a whole squad of servers okay).

She encapsulates:

  • sending requests to the remote server πŸ“¨
  • maintaining protocol encapsulation πŸ”’
  • authentication πŸ”‘

that's it. that's the vibe check. she's the main character of "talking to the server" energy. πŸ‘‘


πŸŽ€ CONSTRUCTOR πŸŽ€

  • new β€” the usual constructor bestie. Accepts a hashref of initializers. that's it, no cap.

πŸ’œ FIELDS πŸ’œ

  • uri (mandatory ⚠️) β€” the URI of the remote KGB server. Something like "http://some.host:port/". u literally cannot skip this one, she needs to know where to go.
  • proxy β€” this is the SOAP proxy used to communicate with the server. If u omit it, it defaults to the value of the uri field with "?session=KGB" appended. so like, it builds itself, iconic behaviour honestly.
  • password (mandatory ⚠️) β€” the password, used for authentication to the remote KGB server. don't leak it bestie πŸ™ˆ
  • timeout β€” specifies the timeout for the SOAP transaction, in seconds. Defaults to 15 seconds. so she's patient but like, not that patient.
  • verbose β€” be verbose about communicating with KGB server. she'll narrate everything. very "and then I saidβ€”" of her.
  • dry_run β€” perform all processing, but do not communicate with the server. she does the whole routine and then just... doesn't send it. rehearsing in the mirror fr fr. πŸ’€

πŸ”₯ METHODS πŸ”₯

  • send_changes (message parameters) β€” transmits the change set and all data about it, along with the necessary authentication hash. If an error occurs, an exception is thrown. ⚠️ no soft-launching errors here, she will throw.

Message parameters are passed as arguments, in this exact order:

  1. Client instance (App::KGB::Client)
  2. Protocol version (or 'auto' β€” she'll figure it out, she's smart like that ✨)
  3. Commit (an instance of App::KGB::Commit)
  4. Branch
  5. Module
  6. Extra β€” this is a hash reference with additional parameters.
  • relay_message(client, message [, options hash ]) β€” sends a message to the server for relaying. passing it along like a good bestie passing the gossip πŸ’Œ
  • send_changes_v2($info) β€” a method implementing a different protocol version.
  • send_changes_v3($info) β€” another method implementing a different protocol version.
  • send_changes_v4($info) β€” and yet another method implementing a different protocol version.

(they're all just the "Methods implementing different protocol versions" crew β€” v2, v3, v4, one signature each: $info. she speaks every dialect πŸ—£οΈ)

  • send_changes_soap($message) β€” helper method sending commit information via SOAP. Dies on any error or SOAP FAULT. ⚠️ dramatic exits only, honestly.
  • send_changes_json($message) β€” helper method sending commit information via JSON-RPC. Dies on errors. ⚠️ same energy, different protocol. slay.

🫢 reminder bestie: uri and password are mandatory, timeout defaults to 15 seconds, and send_changes throws on error β€” so wrap her in an eval if u can't handle the drama. πŸ’…

that's the whole page πŸŽ€ documented in perl v5.40.1, dated 2026-07-10, from the App::K...rverRef(3pm) page of the User Contributed Perl Documentation. go forth and talk to ur servers, u got this πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from