Etcd
view release on metacpan or search on metacpan
lib/Etcd.pm view on Meta::CPAN
say "message is: ".$etcd->get("/message")->node->value;
# Stats API
# See Etcd::Stats for more info
say "leader is: ".$etcd->stats("leader")->{leader};
=head1 DESCRIPTION
This is a client library for accessing and manipulating data in an etcd
cluster. It targets the etcd v2 API.
This module is quite low-level. You're expected to have a good understanding of
etcd and its API to understand the methods this module provides. See L</SEE
ALSO> for further reading.
=head1 METHODS
=head2 new
my $etcd = Etcd->new( %args );
This constructor returns a new Etcd object. Valid arguments include:
=over 4
=item *
C<host>
Hostname or IP address of an etcd server (default: C<127.0.0.1>)
=item *
C<port>
Port where the etcd server is listening (default: C<4001>)
=item *
C<ssl>
Use SSL/TLS (ie HTTPS) when talking to the etcd server (default: off)
=item *
C<http>
A C<HTTP::Tiny> object to use to access the server. If not specified, one will
be created
=back
=head2 server_version
my $version = $etcd->server_version;
Queries and returns the server version as a string.
=head1 ENDPOINTS
Individual API endpoints are implemented in separate modules. See the documentation for the following modules for more information:
=over 4
=item *
L<Etcd::Keys> - Key space API
=item *
L<Etcd::Stats> - Stats API
=back
=head1 SEE ALSO
=over 4
=item *
L<HTTP::Tiny> - for further HTTP client configuration, especially SSL configuration
=item *
L<https://github.com/coreos/etcd> - etcd source and documentation
=item *
L<https://coreos.com/docs/distributed-configuration/etcd-api/> - etcd API documentation
=back
=head1 SUPPORT
=head2 Bugs / Feature Requests
Please report bugs or feature requests through the issue tracker at
L<https://github.com/robn/p5-etcd/issues>. You will be notified automatically
of any progress on your issue.
=head2 Source Code
This is open source software. The code repository is available for
public review and contribution under the terms of the license.
L<https://github.com/robn/p5-etcd>
git clone https://github.com/robn/p5-etcd.git
=head1 AUTHORS
=over 4
=item *
Robert Norris <rob@eatenbyagrue.org>
=item *
Matt Harrington
( run in 0.802 second using v1.01-cache-2.11-cpan-524268b4103 )