Copyright (c) 2007-2019 Wind River Systems, Inc. and others. Made available under the EPL 2.0
Agent portion made available under your choice of EPL 2.0 or EDL v1.0 dual-license.
Direct comments, questions to the tcf-dev@eclipse.org mailing list
This is a brief description of the TCF agent prototype implementation.
The agent is implemented in C. The code mostly uses POSIX APIs to improve portability.
The agent is implemented as an event driven program. The main event queue is handled by a single thread – the event dispatch thread. Some sub-systems are using other threads locally, but will never call other sub-systems using these threads. Instead an event will be placed on the main event queue to handle the inter sub-system communication.
Main program parses command line options and initialized sub-systems
Files:
This module handles registration of command and event handlers. It is called when new messages are received and will dispatch messages to the appropriate handler. It has no knowledge of what transport protocol is used and what services do.
Files:
Implements input and output stream over TCP/IP transport and UDP based auto discovery.
Files:
This module defines generic input and output stream interfaces and supporting library functions.
Files:
The breakpoint services implements a global breakpoint list.
Files:
This module implements the run control service. It builds uses the context module to do low level control of contexts. It implements a “safe queue” which contains events that that should be processed then executable contexts are suspended. Incoming TCF messages are suspended while the safe queue is non-empty and are resumed when the last safe queue entry is handled.
Files:
This module provides system level monitoring information, similar to the UNIX top or Windows task manager.
Files:
This service is used to do end-to-end self test from the host to the target.
Files:
This module handles process/thread OS contexts and their state machine. All ptrace() handling is isolated to here.
Files:
This module implements the main event queue dispatch and queuing. All events are processed by a single thread. Any thread can queue new events.
Files:
The module allows a user to interact with agent. Current implementation of command line interpreter is incomplete.
Files:
This module defines agent error codes in addition to system codes defined in errno.h
Files:
Exception handling. Functionality is similar to C++ try/catch.
Files:
The module contains utility functions for parsing and generating of JSON text. TCF standard services use JSON as messages format. See JSON - Preferred Marshaling for JSON description.
Files:
Utilitity module to support double linked lists.
Files:
Machine and OS dependend definitions. This module implements host OS abstraction layer that helps make agent code portable between Linux, Windows, VxWorks and potentially other OSes.
Files:
Provides local versions of malloc(), realloc() and free().
Files:
Proxy service should allow tunneling of TCF messages to another target on behalf of a client. This service intended to be used when a client has no direct access to a target.
Files:
Test application is used by Diagnostics service to run various tests.
Files:
The module implements logging and tracing that is mostly intended for debugging of the agent.
Files: