Documentation

This page contains an architecture overview of TEA along with a description of each component.

TEA Components

TEA is built up of various building blocks depending on each other. The image shows a layer model of the TEA architecture. These are the components (more thorough description below):

  • TEA Core: The core components of TEAs task execution engine. Everything in here is independent of any UI component. Although a basic headless application is included, the actual product for headless execution (which also allows to access UI bundles through the headless presentation engine) is included in TEA Core UI.
  • TEA Core UI: Contains integration into the Eclipse IDE (UI parts) as well as the headless execution product.
  • TEA LiveView: Contains a view that allows visualization of progress and status (errors, warnings, ...) of TaskChains and individual Tasks.
  • TEA EASE Integration: Integrates Eclipse TEA and Eclipse EASE projects in both directions. It is possible to execute EASE scripts as TEA Tasks, as well as executing TEA TaskChains from EASE Scripts. Along with the E4 Event Bridge in the TEA Core UI component, arbitrarily complex interactions between TEA and EASE are possible.
  • TEA Build Library: A collection of Tasks and TaskChains which integrate JDT/PDE/Maven and add build orchestration on top of all that. The included CleanBuildAllProjects TaskChain can be used out of the box to build any workspace containing plug-in projects. Note that the default implementation ignores Package-Import dependencies between bundles though.
  • TEA Build Library LcDsl Integration: Contains a collection of Tasks and TaskChains that allow to generate various P2 related artifacts from LcDsl launch configurations. For instance the contents of a feature can be derived from the (automatically generated) list of dependencies from an LcDsl launch configuration.

TEA Architecture Overview

TEA Core

TEA Core contains support for basic Task and TaskChain concepts. These are the classes and areas clients using TEA will most likely get in touch, or can use as starting points. Note that a lot of those classes contain nested annotations related directly to that class/interface.

  • Task Execution Control
    • org.eclipse.tea.core.TaskExecutionContext: All Tasks need to be added to an execution context by a TaskChain implementation
    • org.eclipse.tea.core.services.TaskChain: Service interface that needs to be implemented by all TaskChains. Note that all TaskChains must be registered as OSGi service to be picked up by TEA. The easiest way to achieve this is to use declarative services through the @Component annotation
    • All annotations in org.eclipse.tea.core.annotations: Relevant for implementing TaskChains mostly.
  • Headless application & Lifecycle
    • org.eclipse.tea.core.services.TaskingLifeCycleListener: Allows to react to general Task and TaskChain related events.
    • org.eclipse.tea.core.services.TaskingHeadlessLifeCycle: Allows to react to events relevant only for headless execution
    • All annotations in org.eclipse.tea.core.annotations.lifecycle: Relevant for implementing lifecycle extensions which can react to TEA events in the system.
  • Configuration
    • org.eclipse.tea.core.services.TaskingConfigurationExtension: Service interface to be implemented by all configuration extensions. A configuration extension is a POJO that is available for injection with all annotated fields automatically prefilled from either a headless.properties file or the Eclipse preferences of the used Eclipse (headless.properties has precedence if present).
  • Statistics
    • org.eclipse.tea.core.services.TaskingStatisticsContribution: Allows to contribute additional data to statistics that are reported (if configured) to a specific server. Statistics are reported by POSTing (HTTP) statistics as JSON serialized objects.
  • Logging
    • org.eclipse.tea.core.services.TaskingLog: The destination for all log messages that Task implementations wish to write. The output is redirected either to stdout in the headless case or the Tasking Console in the Eclipse Console View when used in the IDE
  • Progress Tracking
    • org.eclipse.tea.core.services.TaskProgressTracker: Allows to explicitly influence progress reporting as well as cancellation checks by Tasks. TEA defaults to estimating the progress of a Task based on historic execution times if TEA Core UI is available

TEA Core UI

TEA Core UI contains extended support for Task and TaskChain concepts related directly or indirectly to UI. For instance the headless application/product allows to access Eclipse UI bundles even without real UI (still requires an X11 display to be set though). These are the classes and areas clients using TEA will most likely get in touch, or can use as starting points. Note that a lot of those classes contain nested annotations related directly to that class/interface.

  • Dynamic IDE Menu
    • org.eclipse.tea.core.ui.annotations.TaskChainUiInit: a TaskChain may contain a method with this annotation to provide UI to the user in case the TaskChain is run from the IDE. Can be used to dynamically configure Tasks in the TaskChain
    • The Dynamic Menu represents a Tree of TaskChains based on the metadata (description, icon, etc.) annotated on the TaskChain using the annotations provided in TEA Core
  • Advanced Headless Application
    • The advanced appliation and the associated product (use the product if in doubt!) provide headless execution capabilities for code that is otherwise actually UI bound. Some of Eclipse' functionality that is handy in a headless environment is UI bound for various reasons.
    • There is no way/need to interact from code with this advanced application, it is a seemless extension to TEA Cores basic headless application.
  • E4 Event Bridge
    • The event bridge converts all lifecycle events fired by TEA Core to E4 events (topic: org/eclipse/tea/*)
    • The events can be used by any other Eclipse component. For instance it is possible to run EASE scripts as reaction to TEA lifecycle events.
  • TEA Console
    • The TEA Console is a special console in the standard Eclipse Console View, which allows to display any output produced by TEA Tasks.
  • Eclipse Preference Integration
    • Provides a preference page in the Eclipse Preferences dialog which allows to change (and store) values for org.eclipse.tea.core.services.TaskingConfigurationExtension implementations
    • Use both when running Tasks from the IDE as well as when running headlessly as a fallback to the headless.properties file.
  • Progress Estimation
    • Service that automatically estimates the progress of Tasks based on historical execution time data. If available, this is the default for all Tasks, and must be explicitly overruled - see TEA Core