Skip to content

Commit

Permalink
Merge pull request #818 from fomars/develop
Browse files Browse the repository at this point in the history
netort up, docs, thread_safe_property
  • Loading branch information
fomars committed Nov 25, 2019
2 parents 4f14bcd + 189ef81 commit f244ce4
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 30 deletions.
4 changes: 2 additions & 2 deletions docs/conf.py
Expand Up @@ -52,9 +52,9 @@
# built documents.
#
# The short X.Y version.
version = '1.11'
version = '1.12'
# The full version, including alpha/beta/rc tags.
release = '1.11.2'
release = '1.12.6'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
33 changes: 22 additions & 11 deletions docs/config_reference.rst
Expand Up @@ -64,8 +64,8 @@ ShootExec
:nullable:
True

Influx
======
InfluxUploader
==============

``address`` (string)
--------------------
Expand All @@ -83,13 +83,9 @@ Influx
---------------------
*\- (no description). Default:* ``mydb``

``grafana_dashboard`` (string)
------------------------------
*\- (no description). Default:* ``tank-dashboard``

``grafana_root`` (string)
-------------------------
*\- (no description). Default:* ``http://localhost/``
``histograms`` (boolean)
------------------------
*\- (no description). Default:* ``False``

``labeled`` (boolean)
---------------------
Expand Down Expand Up @@ -266,11 +262,26 @@ Pandora

``expvar`` (boolean)
--------------------
*\- Toggle expvar monitoring. Default:* ``True``
*\- (no description). Default:* ``False``

``pandora_cmd`` (string)
------------------------
*\- Pandora executable path. Default:* ``pandora``
*\- Pandora executable path or link to it. Default:* ``pandora``

``report_file`` (string)
------------------------
*\- Pandora phout path (normally will be taken from pandora config). Default:* ``None``

:nullable:
True

``resource`` (dict)
-------------------
*\- dict with attributes for additional resources.*

``resources`` (list)
--------------------
*\- additional resources you need to download before test. Default:* ``[]``

Android
=======
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Expand Up @@ -20,7 +20,7 @@
'psutil>=1.2.1', 'requests>=2.5.1', 'paramiko>=1.16.0',
'pandas==0.24.2', 'numpy==1.15.4', 'future>=0.16.0',
'pip>=8.1.2',
'pyyaml>=4.2b1', 'cerberus==1.3.1', 'influxdb>=5.0.0', 'netort>=0.7.1',
'pyyaml>=4.2b1', 'cerberus==1.3.1', 'influxdb>=5.0.0', 'netort>=0.7.4',
'retrying>=1.3.3', 'pytest-runner', 'typing'
],
setup_requires=[
Expand Down
30 changes: 14 additions & 16 deletions yandextank/plugins/NeUploader/plugin.py
@@ -1,7 +1,7 @@
import logging

import pandas
from netort.data_manager import DataSession
from netort.data_manager import DataSession, thread_safe_property

from yandextank.plugins.Phantom.reader import string_to_df_microsec
from yandextank.common.interfaces import AbstractPlugin,\
Expand Down Expand Up @@ -40,22 +40,20 @@ def start_test(self):
self.is_test_finished = lambda: -1
self.reader = []

@property
@thread_safe_property
def col_map(self):
if self._col_map is None:
self._col_map = {
'interval_real': self.data_session.new_true_metric,
'connect_time': self.data_session.new_true_metric,
'send_time': self.data_session.new_true_metric,
'latency': self.data_session.new_true_metric,
'receive_time': self.data_session.new_true_metric,
'interval_event': self.data_session.new_true_metric,
'net_code': self.data_session.new_event_metric,
'proto_code': self.data_session.new_event_metric
}
return self._col_map

@property
return {
'interval_real': self.data_session.new_true_metric,
'connect_time': self.data_session.new_true_metric,
'send_time': self.data_session.new_true_metric,
'latency': self.data_session.new_true_metric,
'receive_time': self.data_session.new_true_metric,
'interval_event': self.data_session.new_true_metric,
'net_code': self.data_session.new_event_metric,
'proto_code': self.data_session.new_event_metric
}

@thread_safe_property
def data_session(self):
"""
:rtype: DataSession
Expand Down

0 comments on commit f244ce4

Please sign in to comment.