osate / osate2

Open Source AADL2 Tool Environment
http://osate.org
Eclipse Public License 2.0
39 stars 8 forks source link

Aadl2SemanticSequencer Should Use Editing Domain of Resource Set #1063

Closed philip-alldredge closed 6 years ago

philip-alldredge commented 6 years ago

An issue with how the Aadl2SemanticSequencer handles annexes in related to the graphical editor has been found. The issue is that the graphical editor uses its own resource set and editing domain when performing changes. The reason for this is that it uses live resources and often manipulates the contents of the resource set and it is intended to avoid conflicts with other users of the resource set. When an xtext document is open, an editing domain should not be used because then xtext doesn't use editing domains.

However, the Aadl2SemanticSequencer uses the registered OSATE editing domain in all cases. If editing an xtext document then this doesn't cause an exception because a transaction is not required. However, if the document is not opened then not using the graphical editor's editing domain results in an exception due to a transaction not being active.

The recommended solution is to use the editing domain associated with the semantic object. If an editing domain does not exist, then one should not be used.

lwrage commented 6 years ago

What do I need to do to reproduce the exception?

philip-alldredge commented 6 years ago
philip-alldredge commented 6 years ago

To clarify, although the issue mainly affects the experimental GE plugins, it also is critical to an unreleased plugin which is under active development.

lwrage commented 6 years ago

I am a bit reluctant to merge the fix before the 2.3.2 release next week because I don't know if it could have side effects elsewhere. It looks OK to me, but that doesn't guarantee anything. Is it a OK for you if it's not in 2.3.2?

On Thu, Feb 22, 2018 at 10:33 AM, philip-alldredge <notifications@github.com

wrote:

To clarify, although the issue mainly affects the experimental GE plugins, it also is critical to an unreleased plugin which is under active development.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/osate/osate2-core/issues/1063#issuecomment-367718631, or mute the thread https://github.com/notifications/unsubscribe-auth/AAty5x2a66uwg2dwUKt9y1rXR9rfsOW0ks5tXYjUgaJpZM4SMsrH .

philip-alldredge commented 6 years ago

I think that will be fine. The sequencer doesn't seem to run unless the annex object is modified. I'd prefer to get it in shortly after the release though.

lwrage commented 6 years ago

Yes, it would go in right after the release.