Kotlin 1.4 Online Event Recap

Malvin Sutanto
Wantedly Engineering
10 min readOct 16, 2020

Kotlin 1.4 Online Event, as the name suggests, is a 4-day online event (from 12 Oct to 15 Oct 2020) that focuses on talking about new features that are introduced in the Kotlin 1.4. This event was live-streamed on YouTube, so it’s free for everyone, and they also have recorded sessions and slides available on the event’s page. Most of the speakers are people from JetBrains who are directly involved with the development of the Kotlin language and libraries.

Viewers were able to interact with the live-stream in multiple ways. They can ask questions about the talk using YouTube chat, Q&A forms, and a Twitter hashtag of #kotlin14ask, and these questions will then be answered during the live stream. Then, there’s also QuizQuest, a series of mini-tests to check what we’ve learned from the talks. There are different prizes to be won and some of the prize categories are active until 26 Oct 2020. There’s also a virtual booth where you can have a discussion with people from the JetBrains team, though this has limited availability.

This year, we were able to participate in the Kotlin 1.4 Online Event and in this article we want to talk about our summary of the event. There were a lot of good sessions, and summarizing them will be difficult. There will be a lot of important points that are not covered, so we encourage you to watch the recorded sessions if you’re interested. We will also include the YouTube link for each talk.

Talks from Day 1 - General Overview

Opening Keynote

The Kotlin Team

Opening Keynote by the Kotlin team.

The first event of the day is the opening keynote from Andrey Breslav, the project lead of Kotlin language, and the Kotlin team. They talked about the journey of Kotlin, the announcement of the new release cadence, the current state of Kotlin and the recent 1.4 updates to the language on performance and quality improvements. He also talked about the current focus of the Kotlin team, the new Kotlin compilers, their effort on server-side kotlin, and their vision of Kotlin Multiplatform.

Staying in Touch

Egor Tolstoy

Staying in Touch by Egor Tolstoy.

The next session talked about how we can contribute to the Kotlin language. The community can contribute by submitting Pull Requests on GitHub, reporting issues through YouTrack, sharing feedbacks of EAP, participating in user reviews through kotl.in/interview, answering questions in StackOverflow, and many others (see: kotl.in/contribute). Egor also mentioned that we can enable sharing of anonymous usage statistics to help JetBrains analyze and prioritize features, which currently is only enabled by 8% of all developers who’re using IntelliJ. He also outlined how important community feedback is when prioritizing features in Kotlin language.

New Language Features in Kotlin 1.4

Svetlana Isakova

New Language Features in Kotlin 1.4 by Svetlana Isakova.

This session talked about the new language features that were introduced to 1.4 updates, the content of this talk is very similar to language features and improvements section of What’s New in 1.4 updates. In this session, Svetlana also mentioned the new type inference algorithm that is available due to the new compiler included in 1.4, unified exception type for null checks, and also new modes for generating default methods in interfaces when targeting Kotlin/JVM.

Quality and Performance — Kotlin 1.4 in IntelliJ IDEs

Anton Yalyshev

Quality and Performance — Kotlin 1.4 in IntelliJ IDEs by Anton Yalyshev.

In this session, Anton Yalyshev talked about the performance and quality improvement of Kotlin 1.4 plugin. Majority of developers downtime is due to UI lags (31%) and indexing (28%) and Kotlin 1.4 plugin fixed a lot of UI freezes, deadlocks, and improved the CPU/Memory consumption to make development smoother. Kotlin 1.4 plugin also reduced plugin exceptions by 1.5–2x, improved the stability of the debugger, formatter, and refactoring, and also introduced a new debugger for coroutines. He further touched on the future improvements to the plugin. Lastly, he announced that Kotlin IntelliJ plugin repository will be moved into the IntelliJ platform repository for a faster development cycle.

A Look Into the Future

Roman Elizarov

A Look Into the Future by Roman Elizarov.

In our opinion, this is the most interesting session of the day. Roman’s talk about the future of Kotlin is divided into 2 broad sections, near future and distant future. Near future section addressed KMM and JetBrains commitment to support newer Java APIs like Java Records and Sealed classes. While distant future section showed previews of how Kotlin language might evolve in the future with new operators and language features like namespace extension, multiple receivers and decorators for functions, private/public property type, immutability, and inline classes. He also discussed how JetBrains evaluated Kotlin language APIs design and features.

Talks from Day 2 - Libraries

Coroutines Update

Vsevolod Tolstopyatov

Coroutines Update by Vsevolod Tolstopyatov.

Day 2 opened with a talk on updates to coroutines by Vsevolod Tolstopyatov. He touched on the new coroutines debugger and simplified coroutines stack trace in IntelliJ IDEA. Then, he talked about various updates to Kotlin Flow since 1.3, the introduction of StateFlow and SharedFlow, and the background behind these classes, and JetBrains’ philosophy on adding new operators to Flow. The new coroutine updates also benefit Android projects (with 30% reduced DEX size, better start time and memory/CPU consumption) and Java projects (with integration with blocking calls, BlockHound, and JDK 9 java.util.concurrent.Flow). Lastly, he touched on their plan for the future of coroutines, like the stability of certain features, and time-specific operators such as debounce or throttle, and more.

kotlinx.serialization 1.0

Leonid Startsev

kotlinx.serialization 1.0 by Leonid Startsev.

The next talk is “kotlinx.serialization 1.0” by Leonid Startsev. In this session, he discussed why JetBrains created kotlinx.serialization and how it differs from other JSON parsing libraries, and then showed how serialization APIs in kotlinx.serialization looks like. Then, he also talked about the stable features in 1.0 like @Serializable annotation and polymorphic serialization, and features that are experimental in 1.0, such as custom serial formats and protobuf serialization. He also mentioned new features that are new to 1.0 release, and what are their plans for kotlinx.serialization library. Finally, he showed how we can integrate kotlinx.serialization into our projects, and how to upgrade from previous versions of kotlinx.serialization.

News From the Kotlin Standard Library

Svetlana Isakova

News From the Kotlin Standard Library by Svetlana Isakova.

Svetlana talked about the new functionalities and changes to the Kotlin standard library. In Kotlin 1.4, the Kotlin team tried to make the naming of functions to be more consistent, for example, by adhering to naming conventions, such as running*, *orNull, *Indexed, *IndexedOrNull. 1.4 also introduced a new collection type ArrayDeque (a double-ended queue implemented with a circular buffer) and a couple of new functions for optimised bit manipulation. She also mentioned a couple of changes that make working with the standard library in multiplatform projects easier, such as stack trace and exception handling. Then, she also talked about new experimental functionalities like collection builders and time measurement APIs, and how @OptIn and @RequiresOptIn annotations behave.

Introducing DateTime

Ilya Gorbunov

Introducing DateTime by Ilya Gorbunov.

In this session, Ilya Gorbunov introduced kotlinx.datetime library, an official library from JetBrains to work with date and time in Kotlin. In this library, there are 2 flavours of time, Instant and LocalDate (and LocalDateTime), and depending on your purpose you’ll prefer one over the other. He also talked about how they differ and example use cases, such as preserving timezone data or daylight saving issues. Then, he gave a few examples of how Kotlin APIs have influenced the APIs of the library. Finally, he also touched on its interoperability with each platform’s date-time implementation, their plans with kotlinx.datetime, and the importance of the community feedback in shaping this library.

Talks from Day 3 - Android and Multiplatform

State of Kotlin in Android

Florina Muntenescu

Sate of Kotlin in Android by Florina Muntenescu.

The first session of day 3, from Florina Muntenescu, talked about the impact of Kotlin language on Android apps development. She shared statistics of how android app has improved since adopting Kotlin and also explained what the recent Kotlin 1.4 update brought; like improved tooling performance (incremental annotation processor, IDE performance, instant execution) and features for library authors (explicit API mode, KSP, and R8 support for Kotlin metadata). She highlighted that coroutines are the recommended solution for asynchronous programming and they integrate nicely with JetPack libraries. She also mentioned how Google is committed to develop and push Kotlin forward, from adopting a Kotlin-first approach on Android, working on open source projects (like gRPC and Protobuf), adoption of Kotlin in Google’s apps, improved documentation and learning resources, etc.

It’s Time for Kotlin Multiplatform Mobile

Ekaterina Petrova

It’s Time for Kotlin Multiplatform Mobile by Ekaterina Petrova.

Ekaterina Petrova talked about the current frameworks that we can use for cross-platform programming (Rect Native, Xamarin, etc) and explained how KMM is different from those frameworks. Kotlin multiplatform allows developers to share parts of the code between iOS and Android, such as data/business logic. She presented some illustrations of how we can share code through sample architecture and layers, and she also gave sample build files that we can use in a typical KMM project. She also showcased the available toolings around KMM, such as Android Studio plugin, CocoaPods integration, etc. Then, she also showed how KMM works seamlessly in the iOS ecosystem, from interoperability with Objective-C/Swift, integration with Cocoapods, to running and debugging iOS application in Android Studio. Finally, she also shared a few resources to learn more about KMM: kotl.in/kmm, kotl.in/kmm-doc, kotl.in/kmm-cases, and kotl.in/kmm-plugin.

Kotlin/JS in 1.4 and Beyond

Sebastian Aigner

Kotlin/JS in 1.4 and Beyond by Sebastian Aigner.

In this session, Sebastien Aigner talked about the state of Kotlin/JS in 1.4. He introduced the new Gradle plugin for Kotlin/JS and multiplatform projects, and the deprecation of previous kotlin2js and kotlin-dce-js plugins. This new plugin includes a fully managed local yarn installation to allow working with npm dependencies, and also adds support for Webpack bundles. Kotlin 1.4 also improved the interoperability with other web technologies, such as TypeScript, decoupling of browser APIs from Kotlin releases, and accessing Node.js APIs through kotlin-nodejs. Then, he presented the future of Kotlin/JS with the new alpha IR compiler for reduced bundle size, support for ES6 modules, better interoperability with @JSExport annotation, and auto-generated TypeScript definitions. Finally, he briefly gave an update on the state of Kotlin and WebAssembly.

Diving into Kotlin Multiplatform

Dmitry Savvinov

Diving into Kotlin Multiplatform by Dmitry Savvinov.

One of the most technical talks of the event, “Diving into Kotlin Multiplatform” by Dimitry Savvinov talked about the internal workings of multiplatform library publishing in 1.3 and how Kotlin 1.4 uses intermediate source sets to allow the new multiplatform library publishing format and hierarchical project structure. He also described the .klib format and .kotlin_metadata files, how Gradle metadata helps with Kotlin project’s dependency management, and how Kotlin toolchain automatically infers common code in native dependencies. Most of the contents in this talk are internal APIs, so it can change without prior notice and we are not supposed to rely on its implementation. If we do want to rely on these internal APIs implementations, we should let JetBrains know of our use case.

Talks from Day 4 - Kotlin for Server-Side

Server-side Development with Kotlin

Anton Arhipov

Server-side Development with Kotlin by Anton Arhipov.

Day 4 talks are a bit different as most of the talks were actually live instead of recorded. The first talk is an update on server-side development with Kotlin, where Anton Arhipov listed out most popular frameworks that we can use to build server-side apps with Kotlin. Included in this list are the very popular Spring framework, a framework by JetBrains called Ktor, and many other polyglot frameworks (a full list of frameworks is available at https://kotlin.link/). He also shared multiple companies that are currently using Kotlin for their back-end and how it impacted their development, like JetBrains Space, Atlassian Jira, Expedia Group, Adobe, and many more. Then he also touched on how Kotlin is enabling cloud-native application using serverless technologies like Kotless.

The State of Kotlin Support in Spring

Sébastien Deleuze

The State of Kotlin Support in Spring by Sébastien Deleuze.

In the next session, Sébastien Deleuze talked about the recent updates in Spring framework that allows better compatibility with Kotlin language. He mentioned that Spring initialzr now supports setting up a new project with Kotlin, and the sample code in Spring framework documentation is now also available in Kotlin. He also explained the differences between Spring frameworks and programming model (annotations vs Kotlin DSL) that are available in Spring, first-class support for coroutines, Kotlin multiplatform support, RSocket supports, and null safety. He later continued with a discussion of GraalVM and did a quick demo of Spring 2.4 running on GraalVM. He also briefly touched on future topics like functional Spring with KoFu and JaFu.

Ktor - Past, Present, and Future

Hadi Hariri

Ktor — Past, Present, and Future by Hadi Hariri.

In this talk, Hadi Hariri talked about Ktor, a multiplatform framework by JetBrains for creating web applications. He explained how Ktor came about and what are the inspirations for Ktor. Currently, JetBrains is investing quite a lot in Ktor, with more developers, better site, blog, and documentation. JetBrains is also committing to 3 major/minor releases yearly and monthly patch releases, and proper deprecation cycle. He then also gave an example of how the structure of a Ktor application on the server-side looks like and then continued with a live demo of using different features inside Ktor. Lastly, he gave a glimpse of how Ktor will evolve in the future, such as improved onboarding and developer experience, better feature parity between client and server components, and increased performance.

Serverless Development with Kotlin and Kotless

Vladislav Tankov

Serverless Development with Kotlin and Kotless by Vladislav Tankov.

In the last talk of the event, Vladislav Tankov talked about Kotless, a serverless framework for Kotlin. He started by discussing the pros and cons of a serverless framework, and how Kotless deal with these drawbacks. He later described features that are included in Kotless, different supported frameworks (Ktor, Spring, and Kotless’ DSL), cloud platforms (AWS, with support for GCP and Azure in the works), runtimes (Kotlin/JVM and GraalVM, with Kotlin/JS in development), and also a feature to help local development using local cloud emulation. He later explained how kotless works in general and how it integrates with different cloud technologies, like AWS DynamoDB, and then continued with a short demo of Kotless in action, and finally discussed what are their plans with Kotless. However, he mentioned in the Q&A session that Kotless is currently not ready for production use.

Summary

This year is the first time that this event is held fully online due to the ongoing global pandemic and we would like to commend JetBrains for the successful event. We also think that the interactions on YouTube live and chat, and the way questions are selected during the Q&A sessions brought up a lot of interesting and insightful discussions.

Since we are using Kotlin only for Android and Multiplatform Mobile, not for JS and backend, our summary on JS and server-side events might be slightly off. However, we can say that we enjoyed all the talks and our personal favourites are “Looking into the Future”, “Coroutines Updates”, and “It’s time for Kotlin Multiplatform Mobile”.

Through this event, we learnt that the community plays a big part in shaping the language, and Kotlin’s conciseness and expressiveness made a lot of developers try (and stay with) the language. We hope that there will be more events like this in the future and maybe we can attend those events in person.

--

--