add port number in cache file name to avoid conflicts

This commit is contained in:
Lotfi zaouche 2020-06-30 10:30:24 +00:00
parent 68764f9e08
commit 27b35fce50
5 changed files with 9 additions and 4 deletions

View File

@ -154,6 +154,7 @@ sub manage_selection {
my ($self, %options) = @_;
$self->{cache_name} = "parity_ethpoller_" . $self->{mode} . '_' . (defined($self->{option_results}->{hostname}) ? $self->{option_results}->{hostname} : 'me') . '_' .
(defined($self->{option_results}->{port}) ? $self->{option_results}->{port} : 'default') . '_' .
(defined($self->{option_results}->{filter_counters}) ? md5_hex($self->{option_results}->{filter_counters}) : md5_hex('all'));
my $result = $options{custom}->request_api(url_path => '/stats');

View File

@ -223,6 +223,7 @@ sub manage_selection {
my ($self, %options) = @_;
$self->{cache_name} = "parity_ethpoller_" . $self->{mode} . '_' . (defined($self->{option_results}->{hostname}) ? $self->{option_results}->{hostname} : 'me') . '_' .
(defined($self->{option_results}->{port}) ? $self->{option_results}->{port} : 'default') . '_' .
(defined($self->{option_results}->{filter_counters}) ? md5_hex($self->{option_results}->{filter_counters}) : md5_hex('all'));
my $results = $options{custom}->request_api(url_path => '/tracking');

View File

@ -158,6 +158,7 @@ sub manage_selection {
my ($self, %options) = @_;
$self->{cache_name} = "parity_restapi_" . $self->{mode} . '_' . (defined($self->{option_results}->{hostname}) ? $self->{option_results}->{hostname} : 'me') . '_' .
(defined($self->{option_results}->{port}) ? $self->{option_results}->{port} : 'default') . '_' .
(defined($self->{option_results}->{filter_counters}) ? md5_hex($self->{option_results}->{filter_counters}) : md5_hex('all'));
my $query_form_post = [ { method => 'eth_mining', params => [], id => "1", jsonrpc => "2.0" },

View File

@ -57,6 +57,7 @@ sub manage_selection {
my ($self, %options) = @_;
$self->{cache_name} = "parity_restapi_" . $self->{mode} . '_' . (defined($self->{option_results}->{hostname}) ? $self->{option_results}->{hostname} : 'me') . '_' .
(defined($self->{option_results}->{port}) ? $self->{option_results}->{port} : 'default') . '_' .
(defined($self->{option_results}->{filter_counters}) ? md5_hex($self->{option_results}->{filter_counters}) : md5_hex('all'));
my $query_form_post = [ { method => 'parity_versionInfo', params => [], id => "1", jsonrpc => "2.0" },

View File

@ -131,6 +131,7 @@ sub manage_selection {
my ($self, %options) = @_;
$self->{cache_name} = "parity_restapi_" . $self->{mode} . '_' . (defined($self->{option_results}->{hostname}) ? $self->{option_results}->{hostname} : 'me') . '_' .
(defined($self->{option_results}->{port}) ? $self->{option_results}->{port} : 'default') . '_' .
(defined($self->{option_results}->{filter_counters}) ? md5_hex($self->{option_results}->{filter_counters}) : md5_hex('all'));
my $query_form_post = [ { method => 'parity_versionInfo', params => [], id => "1", jsonrpc => "2.0" },