Merge pull request #264 from cprice-puppet/bug/master/duplicate-collected-resources

Bug/master/duplicate collected resources
Update changelog for 0.11.0

Signed-off-by: Deepak Giridharagopal <deepak@puppetlabs.com>
Merge pull request #265 from grimradical/changelog-0.11.0

Update changelog for 0.11.0
(#15748) Better logging of malformed relationships

If puppet generates a catalog that’s malformed, we output an error
message like so:

    Can't find resource Rvm_system_ruby['ruby-1.9.3-p0'] for relationship

While it tells you one part of the problem, it doesn’t display the full
relationship edge (making it hard to triangulate where the error is).

We now display a message that includes both resources involved in the
edge, what their relationship is supposed to be, and which parameter is
attempting to create this edge.

Signed-off-by: Deepak Giridharagopal <deepak@puppetlabs.com>
Merge pull request #267 from grimradical/feature/master/15748-better-logging-for-missing-resources

(#15748) Better logging of malformed relationships
Move aside old heap dumps prior to daemon startup

The JVM can't successfully write out a heap snapshot if a file already
exists at the target location (which is stupid, but them's the breaks).
This commit adds logic to our init scripts to move any pre-existing heap
snapshot out of the way prior to starting the daemon. This means that we
retain one previous heap snapshot, but that should help during
situations where an OutOfMemoryError prompted an immediate service
restart (to restore operations), but we'd still like a heap dump for
forensic analysis.

Signed-off-by: Deepak Giridharagopal <deepak@puppetlabs.com>
Merge pull request #268 from grimradical/bug/master/15645-remove-prev-heapdump

Move aside old heap dumps prior to daemon startup
Add support for a test configuration file

This commit adds support for a configuration file to be used
during unit test runs.  At present, the only thing that you
can define in the config file is a function that returns
a map of database settings.  There is a default configuration
file provided, which simply returns the same database settings
that we were using before (an in-memory hsql database with
a random UUID).  However, it also provides instruction for
creating a local override of the default config file, including
an example of how to configure your tests to run against
postgres instead of hsql.

This commit also tweaks the with-test-db fixture to call
a database-cleanup function prior to running the database
migration.  This cleanup function drops all of the tables
if they exist, so that each test can start with a fresh db.
Autoformat test/scf/storage.clj for indentation fixes

The previous commit changed a lot of the nesting of the
code in this file because it introduced several new
"deftest" calls, in order to work properly with the
with-test-db fixture.  This commit simply attempts to
clean up the whitespace / indentation of the file.
Initial implementation of puppetdb report processor

Needs more tests.  Currently, the server side does nothing
but log a pretty-printed version of the report.  I believe
that the data structure that is being sent up for the report
is complete, though--I've doublechecked it (by hand) against
several YAML reports on disk and I believe that all of the
fields are present.
Fix some order-dependent test failures

The way we set up the class variables for
Util::Puppetdb#server/port allows the possibility of some
order-dependent test failures.  This fixes the tests, but
we might want to look for a way to get rid of those
variables to avoid additional occurrences of this problem.
initial schema for resource-events
Renamed http/resources.clj to resource.clj for consistency
First test passes... needs cleanup and generalization of sql transform
functions
Refactored some of the wire-to-sql stuff
cleaned up some comments
Added a second resource event (skipped) to the tests.  Moving on to
attaching inserts to report processor.
working on end-to-end report submission / storage.  currently
failing on datetime crap.
Submission seems to be working.
General cleanup, removed debug statements, etc.