Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge upstream changes #5

Merged
merged 39 commits into from
Jan 15, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
641e37d
Update sqlserver.py
PedroMiguelFigueiredo Nov 21, 2014
bf023ee
Update postfix.yaml.example
Xon Jan 13, 2015
6566809
Add proxy settings on agent info display
degemer Jan 13, 2015
1f854bf
Change Forwarder info output to look like Collector output
degemer Jan 13, 2015
32aa900
Add hidden proxy username and password to info display
degemer Jan 13, 2015
f3866a5
Add proxy settings on Windows info display
degemer Jan 13, 2015
44891f5
Hide length of proxy username and password
degemer Jan 13, 2015
b35f7bc
Refactor activemq_xml check
Jan 14, 2015
0a2e17c
Fix build error (missing None check when no proxy data is given)
degemer Jan 14, 2015
019a5f8
Move to new docker-based CI Travis builds
LeoCavaille Dec 23, 2014
51e31ec
[postgres] Replication metrics only available >= 9.1
LeoCavaille Jan 14, 2015
ecedb87
Only build master and forked branches
LeoCavaille Jan 14, 2015
33ed5c9
Fix a KeyError for Windows agent when using a proxy without authentif…
degemer Jan 14, 2015
fe441b0
Modernize marathon plugin
Jan 14, 2015
4c367b5
Merge pull request #1292 from DataDog/quentin/display-proxy-info
Jan 14, 2015
c0a5016
Fix busted status code and integrate changes with exceptions
Jan 14, 2015
677417f
Fix host tagging for external Elasticsearch clusters.
conorbranagan Jan 6, 2015
912908c
is_external should always be cast as a bool
LeoCavaille Jan 14, 2015
3b4a0ea
Fix as per @LeoCavaille 's review
Jan 14, 2015
727d904
Merge pull request #1282 from DataDog/conor/es-external
LeoCavaille Jan 14, 2015
154339c
Merge pull request #1295 from DataDog/remh/activemq_xml_refactoring
Jan 14, 2015
c50f77e
Merge pull request #1293 from DataDog/leo/docker_travis
LeoCavaille Jan 14, 2015
4cc84b1
Allow configuring of SNMP to ignore non-increasing OIDs. Fixes #1231.
sethrosenblum Dec 5, 2014
2ff9966
Cast properly new ignore_nonincreasing_oid option to bool
LeoCavaille Jan 14, 2015
f298832
Use a temporary file for df output to avoid PIPE limits.
conorbranagan Jan 14, 2015
012550c
Merge pull request #1294 from DataDog/conor/subprocess-pipe-limit
Jan 14, 2015
06a4839
Merge pull request #1281 from DataDog/snmp_ignore_increasing_oids
LeoCavaille Jan 14, 2015
f910715
Merge pull request #1296 from gphat/modernize-marathon-plugin
LeoCavaille Jan 14, 2015
63c2aba
Merge pull request #1214 from PedroMiguelFigueiredo/patch-1
Jan 15, 2015
f191bc7
Bump version to 5.2.0
Jan 15, 2015
7241078
Fix syntax..
Jan 15, 2015
39d430a
Make sure that required settings are in the dict object
Jan 15, 2015
d18beda
[netowrk] freebsd: '-W' in netstat for full names
kernel-mustard Sep 24, 2014
060d670
Merge pull request #1300 from DataDog/leo/bsd_netstat
LeoCavaille Jan 15, 2015
a97a213
Add check for fluentd
takus Aug 19, 2014
06e8255
[fluentd] Improved test suite, fails if fluentd is DOWN
LeoCavaille Jan 15, 2015
d8f0bcb
Merge pull request #1301 from DataDog/leo/fluentd
LeoCavaille Jan 15, 2015
20312d8
Merge pull request #1288 from Xon/patch-1
Jan 15, 2015
2fc27dd
Merge pull request #4 from DataDog/master
Jan 15, 2015
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,5 @@ packaging/build/
packaging/root/
Vagrantfile
.vagrant/*
embedded/*
.pip-cache/*
65 changes: 59 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,68 @@
sudo: false

branches:
only:
- master
- /^\d+\.\d+\.x$/ # release forked patches branch

services:
- couchdb # FIXME see ci/couchdb

cache:
bundler: true
directories:
- $HOME/.pip-cache
- $HOME/embedded

language: python
python:
- "2.6"
- "2.7"

matrix:
fast_finish: true

env:
global:
- CONCURRENCY=2
- NOSE_FILTER="not windows"
- INTEGRATIONS_DIR=$HOME/embedded
- PIP_CACHE=$HOME/.pip-cache
- SKIP_CLEANUP=true
- VOLATILE_DIR=/tmp
matrix:
- TRAVIS_FLAVOR=default
- TRAVIS_FLAVOR=cache,gearman,database,ssh
- TRAVIS_FLAVOR=cassandra,tomcat,jmx # JMX testing machine / need the other ones before
- TRAVIS_FLAVOR=elasticsearch,network,sysstat,webserver
- TRAVIS_FLAVOR=mongo
- TRAVIS_FLAVOR=elasticsearch ES_VERSION=1.4.2
- TRAVIS_FLAVOR=elasticsearch ES_VERSION=1.3.7
- TRAVIS_FLAVOR=elasticsearch ES_VERSION=1.2.4
- TRAVIS_FLAVOR=elasticsearch ES_VERSION=1.1.2
- TRAVIS_FLAVOR=elasticsearch ES_VERSION=1.0.3
- TRAVIS_FLAVOR=elasticsearch ES_VERSION=0.90.13
- TRAVIS_FLAVOR=cassandra
- TRAVIS_FLAVOR=sysstat
- TRAVIS_FLAVOR=redis REDIS_VERSION="2.8"
- TRAVIS_FLAVOR=redis REDIS_VERSION="2.6"
- TRAVIS_FLAVOR=redis REDIS_VERSION="2.4"
- TRAVIS_FLAVOR=memcache
- TRAVIS_FLAVOR=postgres PG_VERSION="9.4.0"
- TRAVIS_FLAVOR=postgres PG_VERSION="9.3.5"
- TRAVIS_FLAVOR=postgres PG_VERSION="9.2.9"
- TRAVIS_FLAVOR=postgres PG_VERSION="9.1.14"
- TRAVIS_FLAVOR=postgres PG_VERSION="9.0.18"
# FIXME: cannot enable gearman on Travis right now
# because it needs boost
# - TRAVIS_FLAVOR=gearman
- TRAVIS_FLAVOR=tomcat # JMX testing machine / need the other ones before
- TRAVIS_FLAVOR=mysql
- TRAVIS_FLAVOR=couchdb
- TRAVIS_FLAVOR=snmpd
- TRAVIS_FLAVOR=apache
- TRAVIS_FLAVOR=nginx
- TRAVIS_FLAVOR=lighttpd
- TRAVIS_FLAVOR=haproxy
- TRAVIS_FLAVOR=ssh
- TRAVIS_FLAVOR=fluentd

# Override travis defaults with empty jobs
before_install: echo "OVERRIDING TRAVIS STEPS"
Expand All @@ -20,14 +71,16 @@ before_script: echo "OVERRIDING TRAVIS STEPS"

script:
- bundle install
- 'ls -al $HOME/embedded'
- 'rake ci:run'

after_failure:
- echo "Logs from installation process come here / DEBUG LOGS"
- cat /tmp/ci.log
- bash -c "if [[ \"$TRAVIS_FLAVOR\" =~ \"mongo\" ]]; then cat /tmp/mongo.log; fi"
- bash -c "if [[ \"$TRAVIS_FLAVOR\" =~ \"mongo\" ]]; then cat /data/mongod1/mongo.log; fi"
- bash -c "if [[ \"$TRAVIS_FLAVOR\" =~ \"mongo\" ]]; then cat /data/mongod2/mongo.log; fi"

after_error:
- echo "Logs from installation process come here / DEBUG LOGS"
- cat /tmp/ci.log

notifications:
hipchat:
Expand Down
23 changes: 15 additions & 8 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -26,24 +26,31 @@ pull request.

Required:
- python 2.6 or 2.7
- Rake
- bundler

Clone the repository
```
# Clone the repository
git clone git@github.com:DataDog/dd-agent.git
```

Crete a virtual environment and install the dependencies:
```
# Crete a virtual environment and install the dependencies:
cd dd-agent
bundle install
rake setup_env
````

Activate the virtual environment:
```
# Activate the virtual environment
source venv/bin/activate

# Lint
rake lint

# Run a flavored test
rake ci:run[apache]
```

## Test suite

More about how to write tests and run them [here](https://github.com/DataDog/dd-agent/blob/master/tests/README.md)

# How to configure the Agent

If you are using packages on linux, the main configuration file lives
Expand Down
36 changes: 23 additions & 13 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,37 @@
require 'rake/clean'

# Flavored Travis CI jobs
require './ci/cache'
require './ci/apache'
require './ci/cassandra'
require './ci/database'
require './ci/couchdb'
require './ci/default'
require './ci/elasticsearch'
require './ci/fluentd'
require './ci/gearman'
require './ci/jmx'
require './ci/haproxy'
require './ci/lighttpd'
require './ci/memcache'
require './ci/mongo'
require './ci/network'
require './ci/mysql'
require './ci/nginx'
require './ci/postgres'
require './ci/redis'
require './ci/snmpd'
require './ci/sysstat'
require './ci/ssh'
require './ci/tomcat'
require './ci/webserver'

CLOBBER.include '**/*.pyc'

desc "Run tests"
task :test, [:attrs] do |t, args|
attrs = args.attrs ? "-a #{args.attrs}" : ""
cmd = "nosetests #{attrs}"
sh cmd
# Travis-like environment for local use

unless ENV['IS_TRAVIS']
rakefile_dir = File.dirname(__FILE__)
ENV['TRAVIS_BUILD_DIR'] = rakefile_dir
ENV['INTEGRATIONS_DIR'] = File.join(rakefile_dir, 'embedded')
ENV['PIP_CACHE'] = File.join(rakefile_dir, '.pip-cache')
ENV['VOLATILE_DIR'] = '/tmp/dd-agent-testing'
ENV['CONCURRENCY'] = ENV['CONCURRENCY'] || '2'
end

desc 'Setup a development environment for the Agent'
Expand Down Expand Up @@ -64,7 +74,7 @@ end

desc "Lint the code through pylint"
task "lint" do
sh("find . -name \\*.py -type f -not -path \\*tests\\* -exec pylint --rcfile=.pylintrc --reports=n --output-format=parseable {} \\;")
sh %{find . -name '*.py' -type f -not -path '*venv*' | xargs --max-procs=$CONCURRENCY -n 1 pylint --rcfile=./.pylintrc}
end

desc "Run the Agent locally"
Expand All @@ -73,9 +83,9 @@ task "run" do
end

namespace :ci do
desc 'Run Travis CI flavored tests'
desc 'Run integration tests'
task :run, :flavor do |t, args|
fail "Failing because this is supposed to run on Travis" unless ENV['TRAVIS']
puts "Assuming you are running these tests locally" unless ENV['TRAVIS']
flavor = args[:flavor] || ENV['TRAVIS_FLAVOR'] || 'default'
flavors = flavor.split(',')
flavors.each { |f| Rake::Task["ci:#{f}:execute"].invoke}
Expand Down
Loading