library discoverd-client
A PHP client for Flynn's Discoverd.
sroze/discoverd-client
A PHP client for Flynn's Discoverd.
- Thursday, November 20, 2014
- by sroze
- Repository
- 1 Watchers
- 3 Stars
- 34 Installations
- PHP
- 0 Dependents
- 0 Suggesters
- 0 Forks
- 0 Open issues
- 2 Versions
- 0 % Grown
Discoverd PHP client
This PHP library is a PHP client for Flynn Discoverd API which is based on a custom RPC server that supports JSON., (*1)
Installation
Require the package sroze/discoverd-client
in your composer.json
file and update dependencies:, (*2)
{
"require": {
"sroze/discoverd-client": "~0.1.0"
}
}
Usage
Note: The client is able to automatically detect the Discoverd address based on the environment if your application is running on Flynn., (*3)
<?php
use SRIO\Discoverd\Client;
// Create the Discoverd client
$client = new Client();
// Get informations about the service named "pg"
$serviceName = 'pg';
$result = $client->subscribe($serviceName);
// You can also call any method on RPC server
$client->call('Agent.Register', array(
'Name' => 'anyservice',
'Addr' => '1.2.3.4:5678'
));
dev-master
9999999-dev
A PHP client for Flynn's Discoverd.
Sources
Download
MIT
The Requires
php
client
flynn
discoverd
0.1.0
0.1.0.0
A PHP client for Flynn's Discoverd.
Sources
Download
MIT
The Requires
php
client
flynn
discoverd