Latest posts from Codename One.
Blog
Search the blog
Smaller Simpler Maven Projects
Opening a new application should show you the application. A directory full of platform modules makes you learn the build’s structure before you have written a screen. Last week we added smaller Gradle projects. Maven now starts small too. The application archetype defaults to the root POM and common, with no platform modules. You can still run the simulator and build the target apps. This closes our weekly release series. ...

PGO for Faster Apps and Generational/Adaptive GC
Your native compiler can optimize an app more effectively when it knows which code actually runs. Profile-guided optimization, or PGO, gives it that information. The build service runs an instrumented version of your application, records its execution and uses the profile to compile the binary your users receive. PGO is now a Pro and Enterprise cloud-build feature for iOS, native macOS and native Linux. You enable it with a build hint; the service handles the extra compilation and training. It is a way to improve native performance without rewriting application logic or managing a profiling pipeline yourself. ...

Try Real Java in Your Browser, Compiler Errors Included
A playground should tell you whether your Java works. A Java-like interpreter can instead teach you which Java it happens to understand. That difference becomes annoying as soon as you paste a record, a lambda or an example with a tricky generic type. We rebuilt the Codename One Playground around our in-tree Java compiler. Your code becomes class files, then the ParparVM translator turns those classes into JavaScript inside the page. The running app loads them and updates the preview. Compilation does not send your source to a server. ...

How Do You Test Spring Compatibility?
The Codename One backend is not Spring compatible. We use similar syntax to ease migration and porting, but familiar annotations do not tell you whether the ported application behaves the same way. Tests do. Write those tests in the original Spring application first. Capture the behavior your clients depend on, get the tests passing, then bring the same assertions to Codename One. Here, compatibility means that your application’s behavior survives the move. It does not mean that Codename One implements the Spring framework. ...

Update DB Schema in Production with Flyway like Syntax
The database on your laptop has today’s schema. The database on a customer’s phone might be six releases old. Both have to work after the next update, and deleting the customer’s data is not a migration strategy. Codename One now uses the same migration engine for client databases and the native backend. It follows Flyway-style versioned scripts and history, with build-time registration so the scripts travel inside the app or server. This continues our weekly release series and supplies the tables behind yesterday’s security stack. ...

Easy Full Stack Authentication and Login in the Style of Spring
Three requests leave your app just as its access token expires. If each refreshes independently, the first exchange can invalidate the refresh token the other two are about to use. A login feature becomes a race between requests. This week’s security work joins the Codename One client and backend around those transitions. The client can coordinate renewal, the server can rotate tokens, and tests can verify what happens after a real request is refused. ...

Android on iOS, Web & Desktop Efficiently and for Free
We are not the first to bring Android to iOS. Earlier projects brought Android’s runtime along with the application. Dalvik was built for Android, including a just-in-time compiler (JIT) that ordinary iOS apps are not permitted to use. Disabling it removes an important source of Dalvik’s performance. Dalvik was designed around interpretation and JIT compilation, not ahead-of-time compilation (AOT), so taking away the JIT leaves an interpreter rather than an optimized native app. ...

Don't Order Fish on Monday. Don't Release on Friday
Anthony Bourdain’s famous warning about Monday fish was a warning about the supply chain behind the menu. In his 1999 essay, he described seafood bought for the weekend still being served on Monday. Knowing how the kitchen worked changed what he would order. Developers have a similar rule: never release on Friday. If something breaks, you have just made plans for everyone’s weekend. It is excellent advice that we have ignored for years. ...

Do You Want Your Web App to Feel Like a Native App?
You can give your Codename One web app the same desktop theme family as your users’ operating system: Aqua on macOS, Fluent on Windows, or Adwaita on Linux. Menus can sit above the app in HTML, with commands such as File and View visible instead of tucked into a mobile overflow menu. That gives you a browser version of your app that fits more comfortably on a desktop. The JavaScript port now supports both choices, and the same theme work reaches the Certificate Wizard you use to sign your apps. ...

Connect Your App to Your Enterprise Traces
Your customer taps “Place order.” The request crosses your app, an API gateway, a native backend, a payment service and a database. Your operations team needs to see that path in the same tracing system it uses for the rest of the company. Neither the client app nor a compiled Java server should disappear from that picture. I wrote a book on debugging, so I am probably more opinionated about this than most people: in 2026, production diagnosis should not depend on somebody searching a pile of logs with grep and guessing which lines belong together. ...

Do You Prefer Gradle?
You can now choose Gradle for a Codename One project. Start with fewer files, add platform directories when you need native code, or create a standalone backend without a mobile app attached. A smaller project is easier to browse and leaves less scaffolding competing for space in an LLM’s context. I like Maven XML. I know it is verbose. I also spent enough time at Sun Microsystems staring at deeply scripted, heavily patched make files to develop a lasting suspicion of clever build systems. ...

Can You Tell the Difference Between These iOS Tab Bars?
Watch how the two tab bars respond to the recorded taps, holds, drags and changes of direction. Can you tell which one is UIKit and which one is drawn by Codename One? That is a more useful test than a still image. Your users feel the delay before a selection moves, the way the glass follows a finger and the settling motion after release. A tab bar can have the right colors and still feel wrong in your hand. ...