Automated software refactoring with OpenRewrite and OpenAI
The software industrial revolution has arrived. Software is now 80% open source and third-party and 20% proprietary code that stitches it together into business-critical applications. We are challenged with the ongoing evolution of increasingly large and diversely composed codebases and ecosystems. Dependencies change frequently and evolve at their own pace. Security vulnerabilities can be introduced at any time by anyone. Not updating regularly leads to critical
bugs, performance, and security issues. In this talk, we’ll introduce OpenRewrite, an open-source, automated refactoring and
dependency management technology born at Netflix in 2016. It’s built on manipulating the Lossless Semantic Tree (LST) representation of code with recipes (programs) that result in 100% accurate style-preserving code transformations. It is a rule-based, authoritative system.
We’ll also show you how this system can benefit from the suggestive authorship of generative code AI. We can leverage the OpenAI API to assist with code transformations in OpenRewrite recipes. However, there is a tradeoff between creating recipes faster with OpenAI versus
accuracy of the recipe because of the probabilistic nature of generative AI and the potential for hallucination. Developers will have to be more diligent checking the transformed code in these instances. We will also show how OpenAI can be used to process the LST, performing in code
classification problems and providing natural language descriptions of errors.
USEFUL LINKS
OpenRewrite on GitHub: https://github.com/openrewrite/rewrite
Documentation: https://docs.openrewrite.org/
OpenRewrite community Slack:
https://join.slack.com/t/rewriteoss/shared_invite/zt-nj42n3ea-b~62rIHzb3Vo0E1APKCXEA
Jonathan and Olga’s personal calendar: https://calendly.com/moderne
More about Moderne: https://www.moderne.io/
BIOS
Jonathan Schneider is Co-founder and CEO at Moderne, which automates software refactoring at scale. He founded OpenRewrite, an auto-refactoring tool, at Netflix and went on to found the Micrometer project as a member of the Spring Team. Jonathan is the author of “SRE with Java Microservices” (O’Reilly).
Olga Kundzich is Co-founder and CTO at Moderne, which automates software refactoring at scale. She has extensive experience building enterprise software solutions. Previously, she worked as a technical product manager at Pivotal, focused on application delivery and
management solutions (e.g., Spinnaker), and was a lead software engineer and manager at Dell EMC, working closely with enterprise users on implementing data protection practices.