summaryrefslogtreecommitdiffstats
path: root/tests
AgeCommit message (Collapse)Author
2021-04-14Spelling tests (#10920)Josh Soref
2021-04-14Add a plugin for the system clock synchronization state (#10895)Vladimir Kobal
Co-authored-by: Joel Hans <joel.g.hans@gmail.com>
2021-04-05Spelling build (#10428)Josh Soref
* spelling: alleviate Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: available Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: berkeley Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: cannot Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: centos Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: context Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: continuously Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: correlate Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: defaults Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: dependencies Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: dependency Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: different Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: doesn't Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: example Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: forbidden Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: necessary Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: nightly Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: normally Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: notification Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: overridden Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: packet Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: program Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: prompted for Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: proxyadmin Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: red hat Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: relative Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: script Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: scriptlet Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: somewhere Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: spinning Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: substitution Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: success Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: successfully Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: sysadmin Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: tarball Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: telemetry Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: temporary Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: timeout Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: unsupported Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: updates Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: useful Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * spelling: way Signed-off-by: Josh Soref <jsoref@users.noreply.github.com> * Update kickstart script checksums in documentation Co-authored-by: Vladimir Kobal <vlad@prokk.net>
2021-01-07Docs housekeeping for SEO and syntax, part 1 (#10388)Joel Hans
* First pass to get the script working right * Finish adding analytics tags
2020-09-10Correctly fix handling of CI Slack notifications. (#9902)Austin S. Hemmelgarn
2020-08-27Ensure Arch Linux images are up to date in CI before running checks. (#9825)Austin S. Hemmelgarn
2020-06-03Add a random offset to the update script when running non-interactively. (#9245)Austin S. Hemmelgarn
* Revert "Revert "Introduce a random sleep in the Netdata updater (#9079)" (#9161)" This reverts commit e92d2ce7a155a33ee6b0acfd928f357251c02c69. * Add option to updater to disable randomized delay. Primarily intended for CI, also useful for automated deployment tools like Ansible. * Use correct paths in CI. * Mke variable name match option name.
2020-05-26Revert "Introduce a random sleep in the Netdata updater (#9079)" (#9161)James Mills
This reverts commit cea8a3fcbb3b48fce545d19bce2b5cf920c6794d.
2020-05-26Introduce a random sleep in the Netdata updater (#9079)James Mills
* Introduce a random sleep in the Netdata updater * Only sleep if we're not a tty (e.g: cron) and use a random interval between 30m-60m * Set lower bound to 1s * Disable random sleep / netdata-updater splay in lifecycle tests
2020-05-11Enable support for Netdata Cloud.Andrew Moss
This PR merges the feature-branch to make the cloud live. It contains the following work: Co-authored-by: Andrew Moss <1043609+amoss@users.noreply.github.com(opens in new tab)> Co-authored-by: Jacek Kolasa <jacek.kolasa@gmail.com(opens in new tab)> Co-authored-by: Austin S. Hemmelgarn <austin@netdata.cloud(opens in new tab)> Co-authored-by: James Mills <prologic@shortcircuit.net.au(opens in new tab)> Co-authored-by: Markos Fountoulakis <44345837+mfundul@users.noreply.github.com(opens in new tab)> Co-authored-by: Timotej S <6674623+underhood@users.noreply.github.com(opens in new tab)> Co-authored-by: Stelios Fragkakis <52996999+stelfrag@users.noreply.github.com(opens in new tab)> * dashboard with new navbars, v1.0-alpha.9: PR #8478 * dashboard v1.0.11: netdata/dashboard#76 Co-authored-by: Jacek Kolasa <jacek.kolasa@gmail.com(opens in new tab)> * Added installer code to bundle JSON-c if it's not present. PR #8836 Co-authored-by: James Mills <prologic@shortcircuit.net.au(opens in new tab)> * Fix claiming config PR #8843 * Adds JSON-c as hard dep. for ACLK PR #8838 * Fix SSL renegotiation errors in old versions of openssl. PR #8840. Also - we have a transient problem with opensuse CI so this PR disables them with a commit from @prologic. Co-authored-by: James Mills <prologic@shortcircuit.net.au(opens in new tab)> * Fix claiming error handling PR #8850 * Added CI to verify JSON-C bundling code in installer PR #8853 * Make cloud-enabled flag in web/api/v1/info be independent of ACLK build success PR #8866 * Reduce ACLK_STABLE_TIMEOUT from 10 to 3 seconds PR #8871 * remove old-cloud related UI from old dashboard (accessible now via /old suffix) PR #8858 * dashboard v1.0.13 PR #8870 * dashboard v1.0.14 PR #8904 * Provide feedback on proxy setting changes PR #8895 * Change the name of the connect message to update during an ongoing session PR #8927 * Fetch active alarms from alarm_log PR #8944
2020-04-14Docs: Standardize links between documentation (#8638)Joel Hans
* Trying out some absolute-ish links * Try one out on installer * Testing logic * Trying out some more links * Fixing links * Fix links in python collectors * Changed a bunch more links * Fix build errors * Another push of links * Fix build error and add more links * Complete first pass * Fix final broken links * Fix links to files * Fix for Netlify * Two more fixes
2020-04-14Explicitly include libffi on ArchLinux CI tests. (#8699)Austin S. Hemmelgarn
The `make` command depends on it but does not pull it in as a dependency. This isn't likely to affect user systems in most cases as they will almost certainly have Python installed, which also depends on libffi and pulls it in correctly. This is a workaround for an upstream bug in Arch.
2020-04-03Change all https://app.netdata.cloud URLs to https://netdata.cloud to ↵Markos Fountoulakis
restore connectivity with netdata cloud.
2020-03-31Improve the behavior of claiming (#8516)Andrew Moss
The default cloud url has been updated to app.netdata.cloud ready for the release. The claiming process now checks the current user executing claiming and refuses to perform the claim for the wrong user. If the current UID is 0 then claiming proceeds but the file ownership is adjusted to be the correct netdata user. The default expected user is `netdata` unless the script can identify the user from the current configuration. After the claiming script is executed the CLI is used to reload the claiming state.
2020-03-14Migrate Tests from Travis CI to Github Workflows (#8331)James Mills
* Migrate Tests from Travis CI to Github Workflows * Use GHA path filters * Make a unit test fail * Run new cmocka based unit tests * Revert "Make a unit test fail" This reverts commit 15500c59e4d49cb478ef27289de0366a543815c5. * Make a cmocka unit test fail * Work around a bug in libbson-1.0 on Ubuntu 18.04 * Add DCMAKE_BUILD_TYPE=Debug to make dbengine tests pass * Upload LastTest.log to GHA Artifact storage * Revert "Make a cmocka unit test fail" This reverts commit 920f56a03d0479bec1a67dc8c242df189f702177. * Remove Artifacts Validation stage
2020-03-10Bulk add frontmatter to all documentation (#8354)Joel Hans
* Bulk add frontmatter * A few extra edge cases
2020-03-06Fixed dependency names for Arch Linux. (#8334)Austin S. Hemmelgarn
* Fix package names for Archlinux. * Use a specific implementation of netcat on Arch. * Use install-required-pacakges.sh from local branch instead of master. * Use local copy of kickstart.sh instead of downloading it.
2020-01-27Docs: Overhaul of installation documentation (#7841)Joel Hans
* Initial commit to bring new branch up to speed with previous work * Initial commit to bring new branch up to speed with previous work * Pass through for grammar and typos * Pass through for grammar and typos * First additions * Improvements to installation page plus new separate kickstart page * Lots of new pages, lots of improvements * Continued work * Fixing the install grid * Added methods to nav * Fix typo and add kickstart to nav * CSS cleanup * Various cleanup * Cleanup on update/uninstall pages * Add responsiveness to install grid * Update checking of the kickstart files MD5 checksusm. This updates the CI script used to verify the MD5 checksums of the kickstart files as being correct in the documentation to use the new locations for the respective checksums. This is more involved than a simple path update because the existing script assumes that both checksums are listed in the same file, which is no longer the case. Any future updates that move the location of the checksums just need to modify the lines in tests/installer/checksums.sh that start with `check_checksum` to point to the correct files. * Added Alpine package for James * Add packages to top of installation page * Fix for Chris * Telemetry fixes * Trying to fix CI * Changing checksums * Fix CI checks for kickstart checksums. The changed wording was confusing the code that parsed the checksum out of the documentation, this fixes the code to handle this new wording correctly. * Update kickstart-static64 checksum * Update 64 checksum Co-authored-by: Austin S. Hemmelgarn <ahferroin7@gmail.com>
2020-01-18Do not alert the #automation channel on checksum failures that will fail a ↵James Mills
PR in CI anyway (#7733)
2020-01-16Move the script for installing required packages into the main repo. (#7563)Austin S. Hemmelgarn
* Move the script for installing required packages into the main repo. Based on discussion with Costa. Most of what this script is actually used for directly is in the main repo anyway, so it makes more sense to have it there so that any changes get reviewed properly. * Fix typo in RPM package build setup.
2019-12-16updater_checks.sh: Fix issue with ↵Konstantinos Natsakis
ca-certificates-mozilla-2.34-lp151.2.6.1.noarch in OpenSUSE 15.1
2019-11-11Makefile.am files indentation (#7252)Konstantinos Natsakis
* Use 4 spaces for indentation of non-recipe lines in Makefile.am files * Be more consistent in the use of space before = in Makefile.am files
2019-11-04Building a fuzzer against the API (issue #7163) (#7210)Andrew Moss
New testing tool for the web API. We are calling this a "fuzzer" until a better name is suggested. This tool reads the swagger definitions of the API and parses the format of the requests and responses. The tool can generate randomized requests, which are sent to a netdata host, and then validate the json responses against the schema defined in the swagger. A traditional fuzzer only produces a single bit of information about each test (did the target system crash). This tool verifies that the call into the API produced a valid response structure, which produces more information about the correct functioning of the host. This current version performs a small sweep through the API calls as that is sufficient to find some incorrect response codes, and for testing the URL parser in the next issue (#7229) . A future update (in the next sprint) will add options to perform a deeper scan that brute-forces the parameter-space of the API, and combine it with our standard approach to stress-testing.
2019-09-29Common pattern for web and alarms together with two bug fixes (#6783)thiagoftsm
* script_pattern: Fix script and bring pattern This commit fixes the error given by shellckeck on stress.sh and brings a pattern for the other scripts, no less important its given the possibility to change the url from outside of the scripts * script_pattern: shellcheke Correct the request.sh after to change it to avoid warning errors from shellchecker * script_pattern: Remove of garbage value With this PR I am removing the garbage value of a script * script_pattern: Restore color These 3 scripts changed in this commit was not restoring the terminal color, this commit fixes this
2019-09-27Create a template for all dimensions (#6560)thiagoftsm
* health_connection: Comments inside Health Config To try to understand better what is necessary to change and where it is necessary to change anything inside the health, I commented the functions inside this file" " * health_connection: Comments about Health in other files This commit brings the rest of the comments that were missed for health" * health_connection: Comments on health_log I had to append more comments on health_log * health_connection: Create a new variable New variable is created to work with foreach * health_connection: Fix new option and doc The first implementation of the 'foreach' had a problem, this fixes the error. This commit also brings the updates for the documentation * health_connection: Understanding health This commit is to save the place that I am working, it has the map to understand all the alam process * health_connection: Update map I changed the position of the error message to identify the correct place to add new alarms * health_connection: End of simple alarm This commit finishes what is necessary to bring the same lookup for different dimensions in one unique line * health_connection: Documentation and template steps This commit brings the documentation missed for template and comments to help in the next step of apply a template to create an alarm. * health_connection: Restoring After some tests, it was detected that the alarms were not working as expected * health_connection: Fix bug and bring dimension to template This commit brings a fix for an old Netdata bug, before this the Netdata always tried to create a new entry in an index with the same id raising an error. It also brings the possibility to use 'foreach' in template * health_connection: Fix cmake compilation There was a problem with cmake compilation fixed by this commit * health_connection: shell script Finilize the shell script to test the PR * health_connection: Remove debug message During the development, I used some messages to understand the code this commit removes the last message * health_connection: Fix bugs This commits fix bugs reported by tests * health_connection: Alarm working This commit brings the necessary change for the alarms work, but it is missing the unlink from the newest list * health_connection: Template code written This commit finishes the creation of alarm from template, but it was not tested yet. * health_connection: Remove comments I am removing the comments from this PR to bring back late * health_connection: Remove lines Another commit to restore the files before they to be commented * health_connection: New alarm and remove messages I am bringing a new alarm to test template with SP and removing comments used during the development * health_connection: Functional test review After to review the functional test script, it was necessary to small adjust to test all the features available with the new version * health_connection: Free structure I am moving the free list for the correct place, the previous place was not safe * health_connection: ShellCheck This commit fixes the problems with shellcheck * health_connection: FIx hash This commit fix the hash calculation that was using wrong input * health_connection: Fix message error The system was showing a wronge message, because when we have foreach the alarm created with templated is added in a second stage to the index * health_connection: Fix documentation In this commit I am fixing the grammar of the previous doc and bringing two examples * health_connection: Fix examples This commit fix the last two examples that was brought in this PR * health_connection: Fix example doc When I brought the correct grammar in the last commit, I lost a mark * health_connection: Grammar fix Fixing grammar of the documentation * health_connection: Memory leak This commit fixes the memory leak that was present in the PR * health_connection: Reload This commit fix the problem that the alarms were not linked after to receive a SIGUSR2 * health_connection: False Positive from codacy Codacy was given a false positive, I changed the function to avoid it. * health_connection: dead code Remove dead code from the code. * health_connection: Memory Leak Remove memory leak when clean simple pattern * health_connection: Script format With this commit I am formatting the last message to return for the default color on terminal * health_connection: Script format 2 With this commit I am formatting the last message to return for the default color on terminal * health_connection: Script format 3 With this commit I am formatting the error message to return for the default color on terminal
2019-09-25check for curl to not get wrong error message (#6931)Timo
2019-09-17Cppcheck fixes (#6386)Andrew Clayton
* collector: cgroups: Fix a cppcheck warning Cppcheck was throwing the following warning in collectors/cgroups.plugin/cgroup-network.c [collectors/cgroups.plugin/cgroup-network.c:233]: (warning) Assignment of function parameter has no effect outside the function. Did you forget dereferencing it? One of the arguments to switch_namespace() is 'const char *prefix', in this function we were checking if prefix was NULL and if so setting it (local scope wise) to "". While this wasn't technically incorrect in this context. It is also unnecessary as the prefix variable is only passed to the proc_pid_fd() function where the same check happens, so we can simply remove the offending line. Signed-off-by: Andrew Clayton <andrew@zeta.digital-domain.net> * tests/profile: Remove somewhat redundant code cppcheck was throwing a warning in benchmark-line-parsing.c [tests/profile/benchmark-line-parsing.c:648]: (warning) Unnecessary comparison of static strings, this comes from (void)strcmp("1", "2"); in main() That is amongst a group of three function calls preceded by the comment // cache functions But then test1() which uses strcmp() is called twice anyway with the timing result of just the second one used, so the dummy strcmp() call would seem superfluous. I would say the same is true for the call to strtoull() (void)strtoull("123", NULL, 0); as that is also used in test1(). I actually ran this benchmark with and without the calls to all three functions, i.e // cache functions (void)simple_hash2("hello world"); (void)strcmp("1", "2"); (void)strtoull("123", NULL, 0); With the above functions being called test1() average time = 7801604 test2() average time = 1333162 Without those three function calls test1() average time = 7779905 test2() average time = 1321438 Those are the averages of three runs. test1() uses strcmp() & strtoull() and test2() uses simple_hash2(), so in that run, not calling the three functions initially was actually quicker. Subsequent runs of each show similar numbers with each edging the other out, however the difference is in the noise. Signed-off-by: Andrew Clayton <andrew@zeta.digital-domain.net>
2019-09-03Fix clear notification missing (#6638)thiagoftsm
* alarm_clear: Mapping In this PR I mapped all the necessary steps to discover the solution for the ISSUE 6581 * alarm_clear: Documentation and fixes This commit fixes the problem that were present in Netdata and it also updates the documentation of the functions and Netdata. * alarm_clear: shell script The original implementation did not have a shell script, here I begin to fix this * alarm_clear: shell script It is necessay to verify why make is not producing the same binary than cmake and finish the changes in the script * alarm_clear: adjust in health.c I rewrote the health.c to be more readable, but I discovered the problem I had in the last few hours were due kernel update * alarm_clear: script changes In this commit I am bringing the final version of the script that test the alarm repetition * alarm_clear: script fix and remove comments IN this commit I am fixing the shellcheck errors and removing some debug messages that were present in the code while I was developing * alarm_clear: Format The health.c had wrong tabulation, this PR brings back the pattern of space as tab for this file * alarm_clear: Script The script was using killlall that is not more present in all Linux distribution this commit removes this and bring the new way to stop Netdata * alarm_clear: return to previous tabulation I am bringing back the old tabulation here and I will create a new PR exclusively for this * alarm_clear: Remove comments I am removing comments from this PR to keep the focus in the major problem * alarm_clear: Remove comments 2 I forgot one comment * alarm_clear: New variable I am appending a new variable in the check before the rebase, because the health.c changed in other file has a direct relationship with what I did here until now * alarm_clear: Fix clear repetition With this last commit, I am bringing a new way to raise the clear alarm, but it is not repeating more with this fix, it displayed one time when it is cleaned and it will display the message again, if and only if, the alarm was raised.
2019-08-15fix_compilation_test: Eliminate git messages (#6660)thiagoftsm
When it was the merge of different PRs related to web server, there was a garbage in the Makefile this PR removes this garbage
2019-08-15Fix Markdown Lint warnings (#6664)Promise Akpan
* make remark access all directories * detailed fix after autofix by remark lint * cross check autofix for this set of files * crosscheck more files * crosschecking and small fixes * crosscheck autofixed md files
2019-08-09netdata/packaging: Bare OS validations (#6574)Paul Emm. Katsoulakis
* netdata/packaging: complete the list of bare OS validations, to be extra sure all cases are covered * netdata/packaging: centos 6 has a different release file * netdata/ci: [ci skip] no centos 8 yet * netdata/ci: [ci skip] dont run for Debian 7 - its dead * trigger travis * netdata/ci: remove Debian 8 as bats not available with the standard repos - we will revisit our strategy on how we execute tests anyway
2019-08-01Fix crash in malloc (#6583)thiagoftsm
* Server Crashing: URL search path The system was setting NULL in an address without to have the values * Server Crashing: URL script After to fix the SSL, the script were not 100% compatible, so I am bringing the solution here * Server Crashing: Fixes reported in the issue related a possible NULL value to be kept and wrong variable * Server Crashing: Readable code and missing if It was a missing if yet, so I changed it, no less important I inverted the check order inside if to be more readable
2019-07-25Fix parsing SSL ACL along with others (#6468)thiagoftsm
* sslstream: ACL parser It was noticed in the issue 6457 that the some ACLs were not parsing correctly when they were along SSL acl, this commit fixes this' * sslstream: remove comments This commit removes the comments that were present while I was testing the code * sslstream: Tests This commit adds ACL tests to check the Netdata response to them * sslstream: Tests Fix the extension to upload the files * sslstream: more tests In this commit I am bringing more tests, including the ssl tests' * sslstream: leading space Remove leading space from variable that was creating problem with shellcheck * sslstream: glob Remove special character from script * sslstream: Makefile The Makefile diretives were pointed to wrong files * sslstream: Missing stream encrypt This commit solves the problem of the stream not be encrypted, but it is not the final solution, because the parser made is incomplete. * sslstream: Finish encrypt channel This commit brings the step that I was missing, the complete encryptation in the communication between Master and Slave * sslstream: Fix argument in script After the latest tests, it was verified that two arguments given to a function inside the script were not correct, with this PR I am fixing this! * sslstream: Fix argument in info Instead to call a function to deliver an integer I was passing a size_t value. Only cmake showed this, but not in my clion! :/ * sslstream: Fix redirect When we were having different SSL configuration, the system were not applying the option for all * sslstream: Update documentation Our documentation was not clear about the rules according our code so I am updating the text to explain for the users * sslstream: Adjust script With this last commit, I am adjusting the tests to avoid false positive * sslstream: Missing elif The previous commit had a missing elif in the shell script * sslstream: Split ports Before this commit Netdata was having SSL as a global option, now it has as a real ACL. * sslstream: reduce context The stream variable will not be affected in the master side, it is only necessary on the slave side, so I am reducing the context of it * sslstream: Force SSL When the user has certificate and he does not set any SSL flag, it is necessary to append the SSL=force flag * sslstream: Default flag It is necessary to have a default flag when the SSL flags are not SET * sslstream: remove comments Remove comments from the scrip * sslstream: moving flag It is better the flag to be set inside socket instead everytime there is a new connection * sslstream: documentation Fix a sentence in the web/server/README.md
2019-07-25Url parser refactoring (#6247)thiagoftsm
* URL_parser_review comments 1 * URL_parser_review restoring web_client.c * URL_parser_review restoring url.h * URL_parser_review restoring web_client.h * URL_parser_review restoring inlined.h * URL_parser_review restoring various * URL_parser_review commenting! * URL_parser_review last checks! * URL_parser_review registry! * URL_parser_review codacy errors! * URL_parser_review codacy errors 2! * URL_parser_review end of request! * URL_parser_review * URL_parser_review format fix * URL_parser_review restoring * URL_parser_review stopped at 5! * URL_parser_review formatting! * URL_parser_review: Started the map of the query string when it is necessary * URL_parser_review: With these adjusts in the URL library we are now able to parser all the escape characters! * URL_parser_review: code review Fixes problems and format asked by coworkers! * URL_parser_review: adjust script The script was not 100% according the shellcheck specifications, no less important it was a direct script instead a .in file * sslstream: Rebase 2 It was necessary to change a function due the UTF-8 * sslstream: Fixing 6426 We had a cast error introduced by other PR, so I am fixing here * URL_parser_review Change .gitignore to avoid considering a script file.
2019-07-01Easily disable alarms, by persisting the silencers configuration (#6360)thiagoftsm
This PR was created to fix #3414, here I am completing the job initiated by Christopher, among the newest features that we are bring we have JSON inside the core - We are bringing to the core the capacity to work with JSON files, this is available either using the JSON-C library case it is present in the system or using JSMN library that was incorporated to our core. The preference is to have JSON-C, because it is a more complete library, but case the user does not have the library installed we are keeping the JSMN for we do not lose the feature. Health LIST - We are bringing more one command to the Health API, now with the LIST it is possible to get in JSON format the alarms active with Netdata. Health reorganized - Previously we had duplicated code in different files, this PR is fixing this (Thanks @cakrit !), the Health is now better organized. Removing memory leak - The first implementation of the json.c was creating SILENCERS without to link it in anywhere. Now it has been linked properly. Script updated - We are bringing some changes to the script that tests the Health. This PR also fixes the race condition created by the previous new position of the SILENCERS creation, I had to move it to daemon/main.c, because after various tests, it was confirmed that the error could happen in different parts of the code, case it was not initialized before the threads starts. Component Name health directory health-cmd Additional Information Fixes #6356 and #3414
2019-06-28Revert "Easily disable alarms, by persisting the silencers configuration ↵Pavlos Emm. Katsoulakis
(#6274)" This reverts commit 60a73e90de2aa1c2eaae2ebbc45dd1fb96034df2. Emergency rollback of potential culprit as per issue #6356 Will be re-merging the change after investigation
2019-06-27Easily disable alarms, by persisting the silencers configuration (#6274)thiagoftsm
* Alarms begin! * Alarms web interface comments! * Alarms web interface comments 2! * Alarms bringing Christopher work! * Alarms bringing Christopher work! * Alarms commenting code that will be rewritten! * Alarms json-c begin! * Alarms json-c end! * Alarms missed script! * Alarms fix json-c parser and change script to test LIST! * Alarms fix test script! * Alarms documentation! * Alarms script step 1! * Alarms fix script! * Alarms fix testing script and code! * Alarms missing arguments to pkg_check_modules * SSL_backend indentation! * Alarms, description in Makefile * Alarms missing extern! * Alarms compilation! * Alarms libnetdata/health! * Alarms fill library! * Alarms fill CMakeList! * Alarm fix version! * Alarm remove readme! * Alarm fix readme version!
2019-06-12netdata/packaging: Add option for slack messages to be pushed on alternative ↵Paul Emm. Katsoulakis
channel, than the default. Push all info to #automation, make #ci-status error reporting only (#6268) I 'll be monitoring closely the change - it is related to our CI and does not directly affect our customers
2019-06-09netdata/packaging: Add more distribution validations (#6235)Paul Emm. Katsoulakis
* netdata/packaging: Add more distribution validations As an attempt to increase our coverage in testing and to guarantee cross-distribution stability, we choose to extend our baseline tests across all currently supported distributions. We run the stable to current transition test, to maximize scenarios coverage. The missing distributions from the bare OS runs, are covered on the Artifacts validations stage * netdata/packaging: adjust update lifecycle test to be more agile 1) use required packages during setup, to guarantee all stuff there cross-distro 2) add opensuse on entry point script 3) Only bats and curl will be installed prior to the tests. The rest are from the deps script * netdata/packaging: Use the right id for version checking, its opensuse-leap not opensuse * netdata/packaging: small adjustments 1) move deps script outside the bats process 2) don't install curl, we expect it to be there 3) fix tumbleweed tag, it was wrong (duh) * netdata/packaging: wrong place, trigger depedency after curl and bats install. Also, blind install for weird archlinux case missing grep * netdata/packaging: missed one more OS identifier * netdata/packaging: Handle alpine case * netdata/packaging: unattended execution flags * netdata/packaging: its a never ending story.. early install of bash for alpine, to get our job done then * netdata/packaging: fix docker runs - multiple commands should be within the container, just using && doesn't send them to the container, second command rather runs on the host * netdata/packaging: Run sh for the main test script, then trigger bash install within for alpine so that the rest of the process runs smoothly
2019-06-07Revert "New URL parser (#6070)"Pavlos Emm. Katsoulakis
This reverts commit 58b7d95a7ec9c576f8a06bbab07f755846b5349a. --- As agreed with @thiago and @cakrit we revert URL parser changes, to buy the time on a more detailed investigation ---
2019-06-06New URL parser (#6070)thiagoftsm
* URL_parser 3 * URL_parser rebase 2! * URL_parameter parsing 3 * URL_parameter parsing 4 * URL_parameter parsing 5 * URL_parser alarms * URL_parser finish the basic structure * URL_parser codacity fixes! * URL_parser scripts! * URL_parser codacy! * URL_parser rebase 3! * URL_parser host fixes! * URL_parser host fixes 2! * URL_parser fix spaces! * URL_parser error message! * URL_parser Christopher requests! * URL_parser alarms fixed! * URL_parser health fixed! * URL_parser rebase 4! * URL_parser C fix write format! * URL_parser fix bugs due cache!
2019-06-04netdata/packaging/ci: Add lifecycle checks to bare operating system ↵Paul Emm. Katsoulakis
installations (#6209) * Introduce more tests on bare OS, to block possible dependency issues in the code * Move bare OS tests on their own stage, to get direct visibility upon possible dependency issues * Limit bare OS runs on pull requests and cron, to avoid messing with people's development runs. We can catch dependency or peculiar build issues during PRs * Rushed it, we now running on different distros, adjust the repository clean up * Centos7 adds quotes on the ID, lets strip them out * Still, you need to add the required packages for testing on debian/ubuntu * curl also required * We 'll be using 16.04 as default distro, not 14.04 * Add an irrelevant shellcheck error, probably raised depending on bash version as we didnt have it with 14.04 * The job needs to run as root, add sudo
2019-06-04Simplify health cmdapi tester - no setup/cleanup needed (#6210)Chris Akritidis
2019-05-22Add more metrics to the tests (#6074)Chris Akritidis
2019-05-19netdata/packaging/ci: Make slack lib fail loud when parameters are brokenPavlos Emm. Katsoulakis
2019-05-19netdata/packaging/ci: Fix slack integrationPavlos Emm. Katsoulakis
2019-05-16Initial script for API load testing (#5892)Chris Akritidis
* Initial script for API load testing * Test only example chart * Saner tests * Add comments
2019-04-29Fix lifecycle script (#5918)Paul Emm. Katsoulakis
* netdata/packaging/ci: stronger validations during install, add some comments, change validation of CWD * netdata/packaging/ci: Add a lifecycle test to validate update from stable to latest works smooth -> Add updater BATS script that does the trick for installing stable then migrating to latest using current code and not nightly -> Integrate with travis -> Rename /code to /netdata in travis, scripts will eventually expect the TLD of repo to be actually named netdata, so test will start failing later -> Introduce a flag on the updater, so that it doesn't download the tarball, but it rather works with a local pre-defined directory. If a user wants to override the update process, so that it runs with a different repository he just needs to export NETDATA_LOCAL_TARBAL_OVERRIDE with the desired repo directory * netdata/packaging/ci: Add required packages for it to run
2019-04-18Pipeline redesign master (#5885)Paul Emm. Katsoulakis
* netdata/packaging/ci: [WIP] Redesign packaging release * netdata/packaging/ci: Add explicitly os definition, also remove sourcing of slack, its already done and rename before_install -> install * netdata/packaging/ci: fix stray stage name * netdata/packaging/ci: style * netdata/packaging/ci: fix syntax for yaml * netdata/packaging/ci: Try removing this, doesnt seem to make much sense to be there (for now) * Revert "netdata/packaging/ci: Try removing this, doesnt seem to make much sense to be there (for now)" This reverts commit ad5556a3ccf6c11ebc9026942af8013d4d0ea666. wow travis - this is weird * netdata/packaging/ci: a few more changes * netdata/packaging/ci: This is totally experimental, will adjust after i test it * netdata/packaging/ci: Reinstate original design - the problem i am trying to solve is more travis-related and fundamental on the way travis works * netdata/packaging/ci: i wonder.. * Revert "netdata/packaging/ci: i wonder.." This reverts commit a160df4fcac866375e8319bf200f47263b2bcaa3. * netdata/packaging/ci: Fix broken items * netdata/packaging/ci: docker images are built and published independently. As long as tagging has taken place earlier, during packaging * netdata/packaging/ci: Following hints from https://github.com/travis-ci/travis-ci/issues/4681 and the mayhem triggered from this change So we adding the compiler, to see if it will get travis to build the right matrix. then linter broke on addons for some weird reason, so remove addons->apt->update too * netdata/packaging/ci: Now do the rest of the changes, since with addition of compiler, things got worse * netdata/packaging/ci: Ok, as expected the workaround from them did not work. Lets get creative though and assume they exclude what they added, so lets do that for os * netdata/packaging/ci: test slack * netdata/packaging/ci: Bring the modified slack script on this branch * netdata/packaging/ci: Add a few more slack messages * Fix empty stage occurrence * netdata/packaging/ci: Another set of restructure changes, explained below 1) Publish release -> Publish for release (minor rename for clarity) 2) Add some more work on the make dist testing (temp folder for root and for now just validate the existence of the tarball) 3) Add some more slack notifications (that is still beta, will have to properly refine once we are done with changes of the flow) 4) Restructure the release process, finally a) relase.sh becomes draft_release.sh and changelog_and_tag_release.sh, basically splitting up the steps into meaningful independent blocks b) Adjust the pipeline, now we run 'changelog_and_tag_release.sh' to get the latest changelog and tag the release, then we run artifacts submission and draft release generation on github still more things to re-check on this step, it will become clearer once i get it up to speed to run on my local repos end to end * netdata/packaging/ci: Fix wrong path usage * netdata/packaging/ci: Update webhook URL * netdata/packaging/ci: Update stage config as proposed by the fix from travis team * netdata/packaging/ci: Another round of restructuring, after 1-1 comparison with old version Briefly: 1) Publish for release stage will only run when there is a TAG defined (To be tested though, but thats the idea). The code previously had the releaser.sh script that did exactly that, if tagger script failed, it would stop process. Now we have distributed the processing in clear chunks and we pick up the process based on shared info that travis or the environment provides 2) Rename <<Create release (only on special commit msg)>> to a more appropriate name, we are not really creating release there its more complicated 3) Move the labeler execution to the packaging step, since publishing now not happening all the time. Previously we hacked this by exit 0 with the tagger and allow the labeler (which was the second part of the execution) to run. 4) before_install in the publishing stage is wrong. We only need this as before_deploy before deploy execution. That is where we use it, really. 5) Rename changelog_and_tag_release.sh to generate_changelog_and_tag_release.sh, just to be clearer. No problem with slightly longer file names 6) Do not let generate_changelog_and_tag_release.sh execute if GIT_TAG is not defined, just exit quietly with a message and a success code 7) Remove the tagger from the generate_changelog_and_tag_release.sh, its confusing to shove it in there. Pull it out and let it run on a clear step from the pipeline but within the same machine to make sure it shares environment with generate_changelog_and_tag_release.sh (So it has to be within the same job) This is it mostly, keep in mind that the nightly and release parts are not tested yet. After this commit, there will be more code that will allow me to execute all the flows on my pipeline and fully test and adjust the workflows as needed * netdata/packaging/ci: Add more notifications, adjust the existing ones too * netdata/packaging/ci: Add safeguards for beta, do a rename too 1) rename generate_changelog.sh -> generate_changelog_for_nightlies.sh, just to provide clarity on the usage. Note: we will simplify this later, this was a workaround that raised a bug on release after refactoring nightlies. We will have to clean this up properly once we merge the new pipeline flow 2) Add checks based on TRAVIS_REPO_SLUG to identify when we running on personal repo and abort mission critical actions like deploying or generating changelogs Note: The deployment step for now will simply fail, due to the lack of the necessary encryption keys on the environment. At a later iteration, we should have beta buckets on GCS and also beta repositories on Docker to properly test our publishing capability on our beta stack * netdata/packaging/ci: Refactor README.md -- still half way there, will resume when i am done with testing * netdata/packaging/ci: At this stage make the scripts harder to run, add checks to bypass tested execution. * netdata/packaging/ci: Seems that adding the install tag within the stage, kind of overriding the outer install pull out install items from packaging to the main install, no point to isolate two packages, just install all required all the time * netdata/packaging/ci: tag obviously cant work at that step, moving it down to the jobs and i need to recheck if the syntax is applicable for travis too * netdata/packaging/ci: So the jobs in a list dont share the environment, lets see if we do it otherwise. also remove the tag check, not work as expected * netdata/packaging/ci: Add another way to check the RC condition * netdata/packaging/ci: experimental - check conditions on message * netdata/packaging/ci: Introduce an alternate master branch for t