This site is maintained for archival purposes only. Eclipse projects have transitioned to GitHub and Eclipse GitLab. Use the Projects search tool to locate your project and access its latest code and issue tracker.
Bug 482086 - Support timestamp variations when computing aggregated qualifiers
Summary: Support timestamp variations when computing aggregated qualifiers
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Tycho (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Gunnar Wagenknecht CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-11-13 04:19 EST by Gunnar Wagenknecht CLA
Modified: 2021-04-28 16:51 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gunnar Wagenknecht CLA 2015-11-13 04:19:14 EST
When computing a build qualifier for a feature using the build-qualifier-aggregator mojo, Tycho currently only supports timestamps of included bundles and features that match exactly the format as specified in the configuration. However, when including 3rd party dependencies (eg., from Orbit) that isn't necessarily the case. Very often, dependencies use a different format.

A workaround is to "touch" the features in SCM.

Tycho should be smarter and discover timestamps in common formats. Scanning through the various Eclipse projects as well as Orbit, it seems that the following is very common:

- v201505121915
- v20121205-1250
- N20151009-1723
- 20150602-0950

Observations:
- sometimes there is a 'v' prefix, sometimes there isn't
- sometimes there is a build type prefix such as I, N, S, R
- sometimes the timestamp is separated by '-' (dash)
Comment 1 Eclipse Genie CLA 2015-11-13 04:25:06 EST
New Gerrit change created: https://git.eclipse.org/r/60297
Comment 3 Jan Sievers CLA 2015-11-16 04:22:32 EST
qualifier formats containing timestamps in the forms

yyyyMMddHHmm
yyyyMMdd-HHmm
yyyyMMdd

(i.e. with or without any prefix or suffix) are recognized by default now.

You can keep this open if you want to make timestamp formats configurable.
Comment 4 Gunnar Wagenknecht CLA 2015-11-16 04:41:28 EST
Let's wait with enhancing further till this functionality is actually needed.

Thanks for merging!
Comment 5 Jan Sievers CLA 2015-11-16 04:45:31 EST
thinking about it again, I agree we don't need configurable timestamps right now.

Since any prefix or suffix is allowed, the 3 qualifier patterns are covering a lot of cases now I think (at least all the formats I remember to have seen personally).

Also, to ensure versions are increasing with time, the pattern has to be generally in the format

year  month  day (hour minute)

the only thing I can imagine to vary are different (or more) separators between the segments, but as you said let's wait for an actual usecase, if any.

thanks for the patch!
Comment 6 Eclipse Genie CLA 2015-11-17 14:46:38 EST
New Gerrit change created: https://git.eclipse.org/r/60651
Comment 7 David Williams CLA 2016-04-13 16:15:43 EDT
BTW, if you want a large sample of real-world qualifiers in use, at least as part of Eclipse's Simultaneous Release repository, I create a report of the patterns used. This was mostly done purely out of my own interest, but you can see most patterns will be "handled". And, those that are not, are not very good "dates" anyway! (That is, do not appear to be "monotonically increasing" in any obvious way). So, not sure you could handle those, even if "configurable". 

Just providing the data, if interested. 

https://hudson.eclipse.org/simrel/job/simrel.neon.runaggregator.BUILD__CLEAN/lastSuccessfulBuild/artifact/aggregation/final/buildInfo/reporeports/reports/versionPatterns.txt