Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Build management(How to extend build management)
Build management [message #1693042] Tue, 21 April 2015 12:05 Go to next message
Alex Gor is currently offline Alex GorFriend
Messages: 159
Registered: November 2014
Location: Russia
Senior Member
Hello Colleague,

I cannot find any answer for the following question.

Current build management run build for all changed files. If file was not changed generator was not run for this file. Can I start uncoditionally build for my DSL source code? (this is request of my user)

Also I observed the following. If build failed due to internal error in generator, for example connection with internal database is lost. I can run build again only if change file.

I suppose for this purposes I shall to make my own implementation of Interface IXtextBuilderParticipant. Am I right? If I'm right how can I add this implementaion?

Thanks in advance
Alex
Re: Build management [message #1693085 is a reply to message #1693042] Tue, 21 April 2015 14:59 Go to previous messageGo to next message
Karsten Thoms is currently offline Karsten ThomsFriend
Messages: 762
Registered: July 2009
Location: Dortmund, Germany
Senior Member

Right, customize the IXtextBuilderParticipant. Derive from the default and register it into the UI module. You should be able to solve both of your issues then.

Need professional support for Xtext, EMF, Eclipse IDE?
Go to: http://devhub.karakun.com
Twitter : @kthoms
Blog : www.karsten-thoms.de
Re: Build management [message #1693088 is a reply to message #1693085] Tue, 21 April 2015 15:11 Go to previous messageGo to next message
Alex Gor is currently offline Alex GorFriend
Messages: 159
Registered: November 2014
Location: Russia
Senior Member
Thank you

I add my simple implementation of BuildParticipant, but due to lack of documentaion. Javadoc contains only method signature. I cannot undertstand which metnod schould be used for mark that given resource snoild be complietd in next time. I observed that all exception is processed in method
protected void addMarkerAndLogError(URI uri, Throwable e). 


My scenario is doGenerate contains complicated logic. In case any internal error is occured. I should notice user about problem and when problem will be fixed. Mentioned resource should recompiled.

[Updated on: Mon, 27 April 2015 09:26]

Report message to a moderator

Re: Build management [message #1693667 is a reply to message #1693088] Mon, 27 April 2015 11:00 Go to previous message
Alex Gor is currently offline Alex GorFriend
Messages: 159
Registered: November 2014
Location: Russia
Senior Member
I found out the following in version 2.7.3 BuildParticipant.build only if resource is chanhed. it is correct behaviour in most cases. But In my case if user have internal error in code generation. User need to fix this error. In my case internal error means different third party events, for example lost conection with internal database. When mentioned issue is fixed( e.g. connection was restored). User should be able to run building again, but user is not be able to do new biuld because of resource is not changed. Also I found out that build decsions is made in BuildManager class. Are there way to extend this behaviour?

[Updated on: Mon, 27 April 2015 11:17]

Report message to a moderator

Previous Topic:Antlr grammar for content assist
Next Topic:Completion with Enum
Goto Forum:
  


Current Time: Fri Apr 26 01:40:38 GMT 2024

Powered by FUDForum. Page generated in 0.03098 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top