Slide 1

Slide 1 text

Java 21 Sean Sullivan Portland Java User Group October 24, 2023

Slide 2

Slide 2 text

๐Ÿ“ Java 21 at Netflix ๐Ÿ“ Getting ready for Java 21

Slide 3

Slide 3 text

Java 21 at Netflix โœ… Java 21 in production since October 6, 2023 โœ… mission critical application โœ… billions of requests

Slide 4

Slide 4 text

Java 21 at Netflix October 6, 2023 ๐Ÿ˜Ž

Slide 5

Slide 5 text

Validating Java 21 ๐Ÿ”ฉ Jenkins build โ— unit tests โ— functional tests โ— smoke tests

Slide 6

Slide 6 text

Validating Java 21 ๐Ÿค Canary testing โ— โ€œtest in productionโ€ โ— real production traffic โ— long running canaries โ— across multiple AWS regions

Slide 7

Slide 7 text

โ€œUse (unit, integration, smoke) testing and canary analysis to validate code before it is pushed to productionโ€ โ€œwe recommend the use of canary analysis. Canary analysis is an effective means to validate live traffic against new changes to a serviceโ€ ๐Ÿ“š Netflix Tech blog

Slide 8

Slide 8 text

๐Ÿค Canary analysis at Netflix

Slide 9

Slide 9 text

๐Ÿค Canary analysis at Netflix โ€œA canary release is a technique to reduce the risk from deploying a new version of software into productionโ€

Slide 10

Slide 10 text

๐Ÿค Canary analysis at Netflix โ€œA new version of software, referred to as the canary, is deployed to a small subset of users alongside the stable running version.โ€ โ€œTraffic is split between these two versions such that a portion of incoming requests are diverted to the canary.โ€

Slide 11

Slide 11 text

๐Ÿค Canary analysis at Netflix

Slide 12

Slide 12 text

๐Ÿค Canary analysis at Netflix โ€œThe quality of the canary version is assessed by comparing key metrics that describe the behavior of the old and new versions. โ€

Slide 13

Slide 13 text

๐Ÿค Canary analysis at Netflix โ€œIf there is significant degradation in these metrics, the canary is aborted and all of the traffic is routed to the stable version in an effort to minimize the impactโ€

Slide 14

Slide 14 text

๐Ÿค Canary analysis report โ— CPU utilization โ— Memory โ— Garbage collection โ— Requests per second โ— Error rate โ— Log diff

Slide 15

Slide 15 text

๐Ÿšง Getting ready for Java 21 ๐Ÿšจ GitHub Actions ๐Ÿšจ Gradle ๐Ÿšจ Lombok ๐Ÿšจ Netty

Slide 16

Slide 16 text

๐Ÿšจ GitHub Actions https://github.com/qos-ch/slf4j/pull/360

Slide 17

Slide 17 text

๐Ÿšจ Gradle https://github.com/sullis/microbenchmarks-java/pull/6

Slide 18

Slide 18 text

๐Ÿšจ Gradle

Slide 19

Slide 19 text

๐Ÿšจ Gradle

Slide 20

Slide 20 text

๐Ÿšจ Gradle

Slide 21

Slide 21 text

๐Ÿšจ Lombok https://projectlombok.org/changelog

Slide 22

Slide 22 text

๐Ÿšจ Netty Java 21 + Netty 4.1.98 + Epoll native transport

Slide 23

Slide 23 text

๐Ÿšจ Netty https://netty.io/news/index.html

Slide 24

Slide 24 text

๐ŸŽ† Final thoughts Use automated canary analysis to validate changes

Slide 25

Slide 25 text

The End