Artur Marciniec - Fotolia

Amazon CodeGuru uses machine learning to improve code

With Amazon CodeGuru now generally available, developers can write higher-quality, cost-efficient Java code. The service uses machine learning to find and fix bugs.

AWS has made its CodeGuru tool generally available for developers. The tool, initially released in preview at the AWS re:Invent conference last December, uses machine learning to make recommendations on how developers can improve the quality of their code quality, as well as identify an application's most expensive lines of code.

"CodeGuru helps you improve your application code and reduce compute and infrastructure costs with an automated code reviewer and application profiler that provide intelligent recommendations," said Danilo Poccia, chief evangelist for the EMEA region at AWS, in a blog post. "Using visualizations based on runtime data, you can quickly find the most expensive lines of code of your applications. With CodeGuru, you pay only for what you use."

CodeGuru has two main components: CodeGuru Reviewer and CodeGuru Profiler.

CodeGuru Reviewer improves code quality by scanning for critical issues and identifying bugs. The managed service then recommends ways a developer can fix these issues.

Meanwhile, CodeGuru Profiler helps programmers find an application's most expensive lines of code. It finds and helps eliminate code inefficiencies, improves performance and lowers compute costs by examining an application's runtime behavior and providing instructive visualizations, according to AWS.

AWS CodeGuru taps into an existing niche

"While some large organizations have already built internal ML [machine learning] tools similar to Amazon CodeGuru, this product now allows smaller teams that may not have the resources to build similar internal tools access to these ML tools," said Kathleen Walch, an analyst at Cognilytica in Ellicott City, Md. "This can help give them a leg up by saving resources, man hours and money."

AWS' internal teams used CodeGuru Profiler on more than 30,000 production applications and saved "tens of millions" of dollars in compute and infrastructure costs, Poccia said.

While some large organizations have already built internal ML [machine learning] tools similar to Amazon CodeGuru, this product now allows smaller teams that may not have the resources to build similar internal tools access to these ML tools.
Kathleen WalchAnalyst, Cognilytica

Artificial intelligence is changing every aspect of the future of work, and developers are no exception, said Holger Mueller, an analyst at Constellation Research.

"Helping developers to deliver more high-quality code and being aware of their code quality is key to achieve higher productivity and developer velocity," he said. "That matters immensely as there's always more software to write, and enterprises are looking to finally fulfill their next-generation automation dreams."

Meanwhile, for code reviews, developers commit their code to the repository of their choice, such as GitHub, GitHub Enterprise, Bitbucket Cloud or AWS CodeCommit. CodeGuru Reviewer opens a pull request and automatically starts evaluating the code using machine learning models.

If CodeGuru Reviewer finds an issue with the code, it will add a human-readable comment to the pull request that identifies the line of code and recommends a fix. CodeGuru Reviewer also provides a pull request dashboard.

One of the most frustrating things for developers can be debugging code, which can take hours to diagnose the problem and cause significant downtime and delays depending on the what the problem is, Walch said.

"By using ML to help with this step, it's a great example of how AI can be used as an augmented intelligence tool assisting the human developer," she said. "While this doesn't replace the human coder, the ML tool can provide intelligent recommendations for improving code quality, debugging issues and recommending fixes saving many man-hours."

Companies including Atlassian, EagleDream, DevFactory, RENGA and YouCanBook.me are early users of CodeGuru, AWS said.

Dig Deeper on Software design and development

Cloud Computing
App Architecture
ITOperations
TheServerSide.com
SearchAWS
Close