Check Flow Latency Analysis is not computed for feature group connections
Closed this issue · 2 comments
ataraskewich commented
Summary
Check Flow Latency Analysis is not computed for feature group connections
Expected behavior
connections/flows through aadl feature groups should produce a report when "Check Flow Latency" analysis is executed
Actual behavior
The latency report is not generated
Steps To Reproduce
- Instantiate Air_Vehicle.impl
- Select Analyses --> Timing --> Check Flow Latency
- Use analysis defaults
- Verify no report is created
package Embedded_Computer_Architecture
public
feature group EventDataExchanges
end EventDataExchanges;
system Air_Vehicle
end Air_Vehicle;
system implementation Air_Vehicle.impl
subcomponents
cockpit: abstract Cockpit;
mission_System: system Mission_System;
sensor: system Sensor;
connections
ms_to_cockpit: feature group mission_System.p1 -> cockpit.p1;
sensor_to_ms: feature group sensor.p2 -> mission_System.p2;
flows
Sensor_Flow: end to end flow
sensor.flowSource ->
sensor_to_ms ->
mission_System.flowPath ->
ms_to_cockpit ->
cockpit.flowSink;
properties
Latency => 100 ms .. 200 ms applies to Sensor_Flow;
end Air_Vehicle.impl;
abstract Cockpit
features
p1: feature group inverse of EventDataExchanges;
flows
flowSink: flow sink p1;
properties
Latency => 0 ms .. 25 ms applies to flowSink;
end Cockpit;
system Mission_System
features
p1: feature group EventDataExchanges;
p2: feature group inverse of EventDataExchanges;
flows
flowPath: flow path p2 -> p1;
properties
Latency => 100 ms .. 100 ms applies to flowPath;
end Mission_System;
system Sensor
features
p2: feature group EventDataExchanges;
flows
flowSource: flow source p2;
properties
Latency => 0 ms .. 25 ms applies to flowSource;
end Sensor;
end Embedded_Computer_Architecture;
Desktop (please complete the following information):
- OSATE Version: v2.11
- Operating System: Windows 10
lwrage commented
This is a bug: running flow latency analysis on the model causes an exception:
java.lang.ClassCastException: class org.osate.aadl2.impl.FeatureGroupTypeImpl cannot be cast to class org.osate.aadl2.ComponentClassifier (org.osate.aadl2.impl.FeatureGroupTypeImpl and org.osate.aadl2.ComponentClassifier are in unnamed module of loader org.eclipse.osgi.internal.loader.EquinoxClassLoader @31f1f002)
at org.osate.analysis.flows.FlowLatencyAnalysisSwitch.mapConnectionInstance(FlowLatencyAnalysisSwitch.java:542)
at org.osate.analysis.flows.FlowLatencyAnalysisSwitch.mapFlowElementInstance(FlowLatencyAnalysisSwitch.java:208)
at org.osate.analysis.flows.FlowLatencyAnalysisSwitch.analyzeLatency(FlowLatencyAnalysisSwitch.java:191)
at org.osate.analysis.flows.FlowLatencyAnalysisSwitch.invokeOnSOM(FlowLatencyAnalysisSwitch.java:1234)
at org.osate.analysis.flows.FlowLatencyAnalysisSwitch.invokeOnSOM(FlowLatencyAnalysisSwitch.java:1047)
at org.osate.analysis.flows.handlers.CheckFlowLatency.analyzeInstanceModel(CheckFlowLatency.java:158)
at org.osate.ui.handlers.AbstractInstanceOrDeclarativeModelReadOnlyHandler.analyzeInstanceModelInMode(AbstractInstanceOrDeclarativeModelReadOnlyHandler.java:126)
at org.osate.ui.handlers.AbstractInstanceOrDeclarativeModelReadOnlyHandler.doAaxlAction(AbstractInstanceOrDeclarativeModelReadOnlyHandler.java:101)
at org.osate.ui.handlers.AbstractInstanceOrDeclarativeModelModifyHandler.processAaxlAction(AbstractInstanceOrDeclarativeModelModifyHandler.java:58)
at org.osate.ui.handlers.AbstractAaxlHandler.actionBody(AbstractAaxlHandler.java:181)
at org.osate.ui.handlers.AaxlReadOnlyHandlerAsJob$ActionAsJob.runInWorkspace(AaxlReadOnlyHandlerAsJob.java:115)
at org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java:43)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
lwrage commented
The fix is available in the nightly build at https://osate-build.sei.cmu.edu/download/osate/testing/products/