It is updated to solve error answers from API
WSConnectorAbstract.php was updated
- possibility to recall to API when getting error in answer (default $maxNumberOfTriesToCallApi = 3)
- possibility to connetc to reserve nodes (after $maxNumberOfTriesToCallApi tries recall you can connect to reserve nodes)
Use
<?php
namespace My\App\Commands;
use GrapheneNodeClient\Commands\DataBase\CommandAbstract;
use GrapheneNodeClient\Connectors\ConnectorInterface;
class GolosWSConnector extends WSConnectorAbstract
{
/**
* @var string
*/
protected $platform = self::PLATFORM_GOLOS;
/**
* max number of tries to get answer from the node
*
* @var int
*/
protected $maxNumberOfTriesToCallApi = 3;
/**
* wss or ws servers, can be list. First node is default, other are reserve.
* After $maxNumberOfTriesToCallApi tries connects to default it is connected to reserve node.
*
* @var string|array
*/
protected $nodeURL = ['wss://ws.golos.io', 'wss://api.golos.cf'];
}
Github or packagist with MIT license. Author @t3ran13
It is better with each commit
@transisto add it to steemtools.com please