Opened 2 years ago

Last modified 21 months ago

#23752 new enhancement

Use Java 8 features in all of Metrics' Java products (Summary ticket)

Reported by: iwakeh Owned by: metrics-team
Priority: Medium Milestone:
Component: Metrics Version:
Severity: Normal Keywords: metrics-2018
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:


The new features of java 8 should be used. This ticket starts collecting the features and approaches we want to use and comments should add and discuss the various topics one per comment in order to have the tickets for the various products simply refer to a comment number (if possible).

Child Tickets

#24870enhancementnewmetrics-teamUse java 8 date-time functionality in Onionoo
#25309enhancementnewmetrics-teamUse java8 datetime classes in bridgedesc module
#25442enhancementnewmetrics-teamUse java8 datetime classes throughout
#28859enhancementclosedkarstenUse Java 8 date-time functionality in ExoneraTor

Change History (12)

comment:1 Changed 2 years ago by iwakeh

Use java.time.* classes for date and time parsing and processing. Some examples are in the patches for #22428 and #22983. More can be found in the java.time package description.
(See and

comment:2 Changed 2 years ago by iwakeh

Use functionality (cf.
Here we should also think about where the parallelization would be most beneficial.

comment:3 Changed 2 years ago by iwakeh

Use java 8 methods from 'Files' wherever useful, e.g., lines, walk, newBufferedReader, readAllLines etc.

Last edited 2 years ago by iwakeh (previous) (diff)

comment:4 Changed 2 years ago by iwakeh

Use java.util.Base64 instead of other classes for de/encoding.

comment:5 Changed 2 years ago by iwakeh

Use Optional wherever appropriate instead of null values.

comment:6 Changed 2 years ago by iwakeh

Make use of new functionality in java.util.concurrent (for example in #21751 together with parallel streams).

comment:7 Changed 2 years ago by iwakeh

Keywords: metrics-2017 added

comment:8 Changed 2 years ago by iwakeh

Use java.util.Optional especially for optional values in metrics-lib api, for example, the problems in #24012 et al. could have been prevented. Optional (used in the right places) provides more maintainable and readable code.

comment:9 Changed 23 months ago by iwakeh

After implementing parallelization using streams check back with the improvements achieved resemble the data from ticket #21751.

comment:10 Changed 23 months ago by iwakeh

Removed, b/c this comment was meant for #24036.

Last edited 23 months ago by iwakeh (previous) (diff)

comment:11 Changed 22 months ago by iwakeh

For Onionoo see (as one example) #16553 comment:22 following.

comment:12 Changed 21 months ago by iwakeh

Keywords: metrics-2018 added; metrics-2017 removed

Will be completed in 2018.

Note: See TracTickets for help on using tickets.