Support emitting analytical events from xblocks running in the LMS

XBlocks can and should use the "publish" method provided by the runtime to emit analytical events. In theory we could now start replacing calls to track_function with calls to publish, however, that migration is not handled by this change.

Fixes: AN-789
fix raw grade dump in standard instructor dashboard
Added test and cleaned up code formatting
Review based changes
Converting class method and attributes to private
Merge pull request #2613 from edx/bugfix/ichuang/idash-raw-grades-dump

fix raw grade dump in standard instructor dashboard
Merge pull request #3089 from mulby/gabe/publish

Support emitting analytical events from xblocks running in the LMS
this will allow for clientside javascript reporting
Merge pull request #3109 from edx/jarv/upgrade-newrelic-agent

this will allow for clientside javascript reporting
Modified ssl certificate authentication to handle next redirection
Makes small changes in lms and cms both so that user's go to the
original page they intended to if they weren't already logged in
Fix infinite redirect loop on logout caused by django caching