# A Modeling Method of Agents and SOA in Advanced Avionics System Based on AADL
## 3 Agents and SOA Modeling Method Based on AADL
### Modeling Method for SOA  
In the service-oriented architecture of avionics systems, various functional units are encapsulated as services through specific interfaces and protocols, and services have specific functions, which can be provided to other services or applications for use. SOA enables distributed deployment, composition, and reuse of services, eliminating differences in hardware platforms, operating systems, and programming languages. This loosely coupled and architecturally flexible architecture is difficult to describe with traditional static architecture modeling methods. If this process is described using a static architecture modeling approach, all services and applications need to be modeled and coexist with the overall system architecture, and repeated services need to be modeled repeatedly. This static architectural model cannot accurately describe the actual process by which SOA executes application. An SOA can be defined as  
\[B=(X_{B},\;Y_{B},B_{B},S_{B},\;K_{B},\;U_{B}), \tag{4}\]  
where \(X_{B}\) is the input set and \(Y_{B}\) is the output set of the SOA;  
\[B_{B}=\{B_{B1},\;B_{B2},B_{B3},\;\ldots\;,B_{Bn}\}, \tag{5}\]  
where \(B_{B}\) is the application set of SOA; \(B_{Bn}\) denotes nth application. \[S_{B}=\{s_{B1},\;s_{B2},\;s_{B3},\;\ldots\;,s_{Bn}\}, \tag{6}\]  
where \(S_{B}\) is the service set of SOA; \(S_{Bn}\) denotes nth service. \[K_{B}=\{k_{B1},\;k_{B2},\;k_{B3},\;\ldots\;,k_{Bn}\}, \tag{7}\]  
where \(K_{B}\) is the set of invocation relationships between applications and services; \(k_{Bn}\) denotes the invocation relationship between nth application and corresponding services. \[U_{B}=\{u_{B1},\;u_{B2},\;u_{B3},\;\ldots\;,u_{Bn}\}, \tag{8}\]  
where \(U_{B}\) is the set of application requests; \(u_{Bn}\) denotes the request to nth application. Representing component configurations and connections in the system, the modes in AADL can be triggered by set events, data, or messages to switch from source mode to  
Figure 4: AADL model of an agent. target mode. These characteristics of modes can model SOA better than traditional static architecture models. In the modeling process of SOA, the service in set \(S_{B}\) is first represented by process components. Since application will invoke one or more services, it is represented by the system component. System components can contain multiple process sub-components, which are used to represent the relationship between application and service. Next, the modes are used at the system level, and different modes of system components are used to represent different applications in set \(B_{B}\). Because the modes of system components can represent the configuration and connection of components in the system, the components and configuration relationships contained in different modes of system components are also different. System-level modes can be used to represent invocation relationships in set \(K_{B}\) between applications and services. Based on this, the application request in \(U_{B}\) is represented with a trigger condition for the mode transition, such as an event, data, or message, and the SOA system invokes the services and completes the application according to the application request. The trigger condition can enable the transition of the system component from the source mode to the target mode, that is, from the original application to the target application. For example, in an SOA system, there is application X with two services A and B, application Y with three services A, C and D, and application Z with three services B and D. After service X is executed, the system receives service request Y and executes it. After service Y is executed, the system receives service request Z and executes it. To model this process using the proposed method, the service architecture in these applications should be described first, that is, the process component configuration in the system component. Then, the mode component is used to describe the target services executed by the system after receiving the service request.