Experimenting with improved compile units caching that skips desugar/transformation step for definitions that haven’t changed.

Use ‘compile-units-cache=true’ in application.ini to try this feature (trunk version).

Submitted by Danny Groenewegen on 8 July 2012 at 12:43

On 29 November 2012 at 11:12 chris melman tagged 1.3.0

On 15 January 2013 at 14:15 Elmer van Chastelet removed tag 1.3.0

On 19 September 2013 at 14:51 Elmer van Chastelet tagged compiler-cache

On 19 September 2013 at 14:54 Elmer van Chastelet commented:

There is a bug that is probably caused by cuc: When I rebuild researchr using cuc, I am unable to sign out on the website. This issue was fixed after a clean build.

Edit: Got it reproduced, just by rebuilding with cuc set to true. Also, another symptom is that I get an empty confirmation mail when I change my email-address in my account in a cuc-enabled build of researchr:

[14:59:16 researchr] home:  principal: Elmer Test/110dedf5-0c11-4723-XXXXX
[14:59:17 researchr] ERROR Problem occurred in template call: elements()
[14:59:17 researchr] ERROR java.lang.RuntimeException
template lookup failed for name: confirmEmailChangeEmailEmailChange_ta0EmailChange
	at org.webdsl.lang.Environment.getTemplate(Environment.java:38)
[14:59:17 researchr] ERROR Problem occurred in template call: elements()
[14:59:17 researchr] ERROR java.lang.RuntimeException
template lookup failed for name: confirmEmailChangeEmailEmailChange_ta0EmailChange
	at org.webdsl.lang.Environment.getTemplate(Environment.java:38)


On 8 October 2013 at 12:11 Elmer van Chastelet tagged 1.3.0

On 7 November 2013 at 10:18 Elmer van Chastelet commented:

Above issues are fixed.
The idea is to enable compile-unit caching by default in the next release. We might disable, or make the cuc reporting cleaner during compilation.


On 20 November 2013 at 21:05 Elmer van Chastelet commented:

New issue:
AC action rules seem to be discarded in non-clean build when template changed. Also, the compiler log reports unused rule in subsequent builds.

Edit: might also apply to AC rules in general, not only action rules.

rule template someTemplate( ) {
	true
	rule action doSomething() { //action button is visible in second build
		false
	}
}

template someTemplate( ){
  action doSomething(){ return; }
  form{
    submit doSomething(){ "change this text and rebuild" }
  }
}

On 21 November 2013 at 11:24 Danny Groenewegen commented:

You also mentioned that the conditional visibility of navigates based on their ac rules does not work correctly with compile units cache. The ac rule for a page should be considered part of its signature, since the navigate call changes when the ac rule changes. In the current implementation of compile units cache we need to keep the page ac rules in the AST when any template content is changed to avoid this problem. A more thorough fix would be to collect ac rules in the declare step instead of during desugaring/transformations.


On 11 December 2013 at 12:11 Elmer van Chastelet commented:

Added test-web-twice which now gets invoked on the buildfarm, running all tests twice.


On 24 January 2014 at 16:16 Elmer van Chastelet commented:

Changing a template argument from v : Ref<XXXXX> to v : XXXXX (not sure whether it needs to be an ajax template) causes runtime class-cast errors. Clean build fixes this:

[24 Jan 16:11:17 conference] ERROR Problem occurred in template call: addEventToSlotsSet_ProgramSlot_(schedule.slots)
[24 Jan 16:11:17 conference] ERROR java.lang.ClassCastException
webdsl.generated.templates.RefArg_addEventToSlotsSet_ProgramSlot__1_editProgramSchedule_ta9List_ProgramSlot___ProgramSchedulepc0 cannot be cast to java.util.Set
	at webdsl.generated.templates.addEventToSlotsSet_ProgramSlot__Template.storeArguments(addEventToSlotsSet_ProgramSlot__Template.java:52)

On 28 February 2014 at 10:18 Elmer van Chastelet commented:

Changing the types in function arguments seems to get ignored. E.g. I changed a signature from function maxLength( lists : [[Entity]] ) : Int to function maxLength( lists : [[ProgramSlot]] ) : Int, because of another bug, but compilation kept failing in java compilation phase.

Log in to post comments