Remove incorrect usage of threading.Lock().

Not sure what the intention was - but the Lock is created locally in the function so nothing else would be waiting on that particular lock.

At some point we may wish to revisit other usages introduced in 1bb04279216e0abf4e24b9299cccc06c10b9c0ac.
Improvements to loading help text from tools.

Do not convert rst to a mako template until needed, this is a costly operation and has the potential to speed update Galaxy start time. Move logic related to parsing of simple help text blocks out of tool and into the new tool parser interface and add implementation for YAML-based tools as well as unit tests for both. More advanced, multi-page tool help is still possible, workflows with the old tool form, but is only available to XML-based tools.
PEP-8 fixes for lib/galaxy/tools/search/__init__.py.
Bugfix and enhancement related to indexing tool help in tool search.

Added a config option for disabling indexing of tool config. This combined with the previous commit, shave over a second off (slightly more than 25%) Galaxy's startup time for the default toolbox on my laptop. Enable this option for functional tests - which will likely never care about seaching this index.

When I went to test this - I noticed that searching wasn't actually working for help messages - this is because tool.help is not a string but a mako template - so I switched it over to render the page and stick it in the whoosh index instead of probably some default to string object pointer or something.
Fix bug with watch tool config option parsing.
Code de-dup in workflow controller.
Refactor helper out for detailed encoding of a workflow for API.
Move building workflows from dictionaries into new WorkflowContentsManager.

Going to build up a WorkflowContentsManager that is reponsible for slightly more complex operations involving step logic, etc... and keep the WorkflowsManager focused on CRUD-like and sharing operations.
Refactor updating workflow contents out of mixin into manager.

Introduce an API endpoint for this operation with test case.
Move body of _workflow_to_dict to new WorkflowContentsManager.

Getting closer to killing UsesStoredWorkflowMixin.
Move more workflow logic out of controller into manager.

This logic for building up editor representation of the workflow.

Introduce concept of a workflow to dict style - with 'export' and 'editor' as first cracks.
Introduce yet another workflow to_dict style - 'instance'.

This is the style used by workflow 'show' - this consolidates all step handling to_dict style-logic from controller/base.py, controller/workflow.py, and api/workflows.py into the new WorkflowContentsManager - with API test cases for everything.
Allow implicit connections between workflow steps (no editor GUI yet).

This means steps that are not connecting an output of one step to the input of another. This could potentially address all sorts of untraditional (in a Galaxy sense) workflows where some sort of data is managed externally. The most important use I think I have heard discussed is that of data managers - this can be used in cases where data managers depend on one another (grab the fasta files in one step, index them in another) or workflows where a downstream analysis depends on index data populated via data managers in earlier steps.

Not really sure how to represent these in the workflow editor - but this is a power user feature anyway so hopefully that is not super pressing. The YAML to workflow DSL supports the operation (see test cases) so these power users (a euphemism for Dan I guess) can just use that for now.
Slightly improved error message for incorrect workflow connection uploads.
Remove another incorrect lock statement.
Fix bug in registry.py requiring the odd relative import of locally defined data type modules.