RUBY-775 Move some serialization-related logic and state to NewRelicService

Specifically, move responsibility for these two things into NewRelicService
(from NewRelic::Agent::Agent):

1. Transformation of StatsHash objects into the MetricData array format
   that the collector wants.
2. Caching of numeric metric IDs sent back by the collector.
RUBY-775 Add a new NewRelic::Agent.record_metric API

This method replaces the get_stats* and record_data_point family of methods, which are
not thread-safe. Calls that previously looked like this:

    NewRelic::Agent.get_stats('foo/bar').record_data_point(12)

... will now look like this

    NewRelic::Agent.record_metric('foo/bar', 12)

The point of this change is to enable locking around record_metric so that multiple
threads may record metrics simultaneously without corruption or data loss.
RUBY-775 Add a way to determine whether transaction name has been set
RUBY-775 Adjust record_metric API, and add increment_metric API

The public-facing record_metric API will not accept an options hash or a block.
If called from within the context of a traced transaction, it record both a
scoped (with the scope being the current transaction name) and unscoped metric.

To accomodate the relatively common increment-only use case, a new public-facing
increment_metric method has been added.
RUBY-775 Public custom metric recording APIs should not create scoped metrics

Recording to scoped metrics with the scope equal to the current transaction name
was considered, but decided against because of the fact that scoped metrics with
scope names equal to the transaction name would interfere with transaction
breakdown graphs. Specifically, custom metrics might not represent time-based
measurements, and even if they do, we have no current mechanism to cause their
timings to be subtracted from the exclusive time of the parent metrics.
Renamed test for the cross_app_monitor to match the file
Add a workaround for JRuby 1.7.2's outdated net/protocol
Merge pull request #27 from newrelic/ben/stats-engine

Add (currently unused) thread-safe metric recording methods
RUBY-1024 fixed and simplified WebFrontend/QueueTime metric recording
RUBY-1024 make sure not to define the queue time constants more than once
RUBY-1024 make sure not to define the queue time constants more than once
RUBY-1024 changelog and version for 3.5.7 beta