Currently, org.apache.jasper.compiler.Generator#generateCommentHeader writes the current timestamp using `new Date()` into the comment header, which makes builds keeping sources non-reproducible, because the timestamp changes with each precompile. There should be an option to disable or override this timestamp or maybe it can be removed completely?
I would favor to remove it completely. It adds zero benefit.
The date was added to the .java file to aid trouble shooting JSP compilation issues and remind system admins that the last modified time of the file will reflect the last modified time of the JSP source rather than the time the file was generated. As far as I recall this wasn't requested by users but was something we added proactively when we started changing the last modified time although it would be worth a trawl through the archives to confirm my recollection. I'm not against removing it entirely. I've done a fair amount of debugging of JSP generation and I don't recall using it. If we wanted to be cautious we could probably remove it when precompiling but leave it when compiling on demand.
+1 to at least removing it from a precompile.
Fixed in: - 10.0.x for 10.0.0-M10 onwards - 9.0.x for 9.0.40 onwards Disabled for pre-compiled files. Retained for on-the-fly compilation.