Commit Graph

21 Commits

Author SHA1 Message Date
Doug Szumski 0aa392a527 Support setting statsd metric aggregation interval
This adds support for setting the statsd metrics aggregation interval
as part of Monasca setup. Setting this interval is useful for users
calculating rates from statsd metrics.

Story: 2005063
Task: 29607
Change-Id: I22f5f1700c438245fd7e98deb40d706358349b6c
2019-02-21 14:23:21 +00:00
Craig Bryant 50824d1170 Add max batch size for writing to API
Add configurable maximum size of batches of measumrement to write
to Monasca API. Prevents killing Monasca API in memory limited
configurations. The default is no limit.

Change-Id: I2bf84501cc51c24843d7c3befd8f9dd42f010f0c
Story: 2001434
2018-01-03 22:53:53 -07:00
Michael Worley 730b77a637 Configurable logrotate in agent
Story: 2000997
Task: 4179

Change-Id: I2e38b1f0a94209c4d38b50e192b35a141b582424
2017-05-02 13:25:10 -07:00
Jakub Wachowski 8413abd66b Fix log dir configuration for agent
Change-Id: Id711813b2235492b2d6ab8200e727a418a137b12
2017-03-24 14:40:22 +01:00
Jenkins 9599bb4912 Merge "Add global_delegeated_tenant field to agent config" 2017-01-25 17:08:29 +00:00
Jenkins 8615610f1c Merge "Add service_type, endpoint_type & region_name querying Keystone Catalog" 2017-01-16 09:22:58 +00:00
Ryan Bak c725999359 Add global_delegeated_tenant field to agent config
This will allow deployments of the monasca-agent to monitor systems
belonging to users without needing the credentials of the user, such
as monitoring Trove instances.

Change-Id: I7233e44fd5abe25744c19f24984bddb2e8018dae
2017-01-10 11:21:34 -07:00
Pablo Rodriguez 0556ea6888 Add service_type, endpoint_type & region_name querying Keystone Catalog
Monasca URL is pulled from Keystone Service Catalog when not given
explicitly in agent.yaml, but only the URL with service_type=monitoring
and endpoint_type=publicURL will be retrieved.

These two options together with the region_name have been included in
the agent.yaml template and may be configured by monasca-setup, so that
the KSClient object is initialized with such keywords. This client will
retrieve the URL from Catalog accordingly.

Change-Id: Icfbfa7c46db648e3d3c27f8e5c72d02957c778f1
Closes-Bug: #1625573
2016-10-19 11:32:08 +02:00
Artur Basiak f79a238844 Add config option
Add config option monasca_statsd_port to configure statsd port
via monasca-setup.

Fixes-Bug: #1628401
Change-Id: Ie7b517f06f7b93e5929776ab4a77a388458e3b4b
2016-10-05 05:02:20 +00:00
Ryan Brandt 19592e7953 Add monasca-setup options max_buffer_size and backlog_send_rate
Change-Id: I4391cf7b9e67d8195191694f3317b8cf3c326acc
2016-09-15 16:06:43 -06:00
Ryan Brandt 443f2b1111 Allow limiting the agent buffering on measurements instead of messages
Size of messages may vary based on the number of metrics the
agent is generating, limiting by measurements will be more stable.

Store messages as json strings when queuing to save space

Change-Id: If6dc0a272a26ac951a5d8823dafd32cab69a3981
2016-09-14 13:24:45 -06:00
Craig Bryant 68d6a7a0f2 Make plugin collection time warning value configurable
Allow the value of sub_collection_warn to be configurable using
monasca_setup. However, use the name plugin_collect_time_warn
as the configuration option since that is easier to understand

Change-Id: I769ec9dd1dcfb1fba5a6da9b59cf03376707c4a6
2016-06-28 16:56:43 -06:00
Craig Bryant 3248ea503e Use multiple threads to run the plugins
This is to handle the case of long running plugins that
added together can exceed the collection frequency. Running
the plugins on multiple threads should bring the collection
time down close to the longest running plugin

A Thread pool is created and used if the new parameter
collector_threads is greater than 1

Due to the Global Interpreter Lock, this will only work well
if the checks are I/O bound which seems to be the case so far

Changed the logging messages to reference plugins instead of
checks to match the usage in docs/Agent.md

Plugins are run in reverse order of last collection time.
Plugins that are still running at the end of a collection cycle
are skipped in the next cycle. If all of the pool threads are
blocked too long by plugins, the collector will exit

Plugins are always run in the thread pool even if pool_size is
1 so that the other changes above still work

Change-Id: Ib50f7fe50a26c949a0066baa3d73ff4a25a8de84
2016-06-27 09:00:47 -06:00
Michael James Hoppal 6be2ba9700 Up the sub_collection_warn default value to 6
Change-Id: Ia8cac81cc9b0679c53ec8101db63a9a80d13a221
2016-04-05 13:06:20 -06:00
Kaiyan Sheng 9650aafe35 Fix Directory Check in Agent
Remove name, pattern and recursive in directory check to make
directory check only checks for the size of the target directory
(not file size)

Add directory detection plugin to automatically generate
directory.yaml file

Change-Id: I10fde0a4ed43f62c310045bccccb3a66e07542e1
2016-02-26 16:03:39 -07:00
Kaiyan Sheng 36e64968c1 Add collector_restart_interval in agent.yaml
Add collector_restart_interval in agent.yaml
Fix a table format in agent documentation
Add boundary check for the value of collector_restart_interval
Delete --collector_restart_interval and --sub_collection_warn
from monasca-setup

Change-Id: I909e392ed04bc5b2aebc5875860dd6725a00711f
2016-02-25 17:35:43 -07:00
Kaiyan Sheng dc16d7b0ef Display collection time for each check
Add collection time in millisecond for each check in log file (DEBUG).
If the collection time for a single check is larger than the threshold value
for warning (5second as default), a warning message will be created in log file.

Change-Id: Ieb4949fbdd6b3db79de13b52abe2a367afceaa9e
2016-01-14 09:25:49 -07:00
Joachim Barheine 22f606face add support for (user-) domain_id/name
Change-Id: I51f770274cbbf6af24c9515af3b87f4af00bcd70
Closes-Bug: 1488562
2015-08-25 16:33:06 +00:00
Craig Bryant 1fdb5d5e05 Ensure password field is valid yaml
Adding double quotes around the password field handles the problem when
password is something like !h2hboJC8p

Change-Id: Ic62f3c0ed46ca9142b7f6e869fd54dcb206626e4
2015-07-08 16:29:20 -06:00
Tim Kuhlman 1a73f3425b Modify the agent and setup to accept custom plugins
For the agent I just modified to the config to use the new standard location for custom checks.
For monasca-setup I added automatic plugin detection.
Fixed config compare so order changes don't register as a config change.

Change-Id: I7ab17c894bb0496e30d7f5aa5a1b1cf9684bdf87
2015-05-04 11:37:54 -06:00
Gary Hessler f9fd9c5a30 Converted the agent config file to yaml to match the plugin config files
Converted the config file to yaml and updated the config processing logic to match.
Cleaned up some deprecated config item processing.

Change-Id: I8c5d9ad841b22d20825608ac9f2c82d8011b04f0
2015-03-02 18:36:15 -07:00