In this podcast, Max Rydahl Andersen, distinguished engineer at RedHat and the creator of JBang discusses how continuously learning from other ecosystems and adopting new tools allows you to simplify your thinking and systems. This will increase the developer joy of the coders and further obtain safer and more robust systems.
Key Takeaways
- Generative AI will allow more people to create code, even if they don’t have "classical" programming skills, but that also creates the problem of having faulty systems on a bigger scale.
- Exploring other programming ecosystems than the ones that you are normally using, will allow you to have a different perspective, simpler at points.
- Targeting to have a faster Java framework, inspired by Python and node.js Quarkus was built with the idea of doing most of the things at build time.
- In order to adopt a different paradigm, you need to have an open mind and explore different ecosystem, rather than being resistant to change.
- We should accept that some things can be simpler than what we are used to.
Subscribe on:
Transcript
Olimpiu Pop: Hello everybody. I am Olimpiu Pop, a Java veteran editor for InfoQ, but I typically write about data and machine learning. Tonight, we are together with Max Rydahl Anderson, talking about how we can complicate our lives as software developers, principals and other roles we might have, especially now in the era of AI. And let's hear it from Max. Max, who are you, and what projects are you currently working on?
Max Rydahl Andersen: Hey, yes, I'm Max. Max Rydahl Anderson, as you perfectly pronounced.
Olimpiu Pop: Almost.
Max Rydahl Andersen: I worked in the software industry for, I don't know, 25 years. 20 or so of them have been in professional open source, started in JBoss, then Red Hat and I began in Hibernate. I've done the SIEM and tooling. I spent 10 to 15 years in Eclipse tooling and had IntelliJ tooling, VS code, and that kind of thing. And then I was off for a few years to do other stuff and go. And then, I took a year break, which triggered a lot of things we talked about today, like realising... getting away from all the complexity and realising, man, it's complex when you come back. And what I've lately been doing is I'm a co-lead on Quarkus, and my side project is called JBang. Both of them are about making it fun to develop Java again, so to speak.
The basics of Software Engineering are more crucial than ever in the Gen AI Age [01:53]
Olimpiu Pop: Okay, thank you for the introduction. That's an awe-inspiring path you walked, and it's not even ... Getting started, right? So, nowadays, everything is about AI. If you put on a chocolate AI, it'll become more popular. How does that change the way we used to build applications?
Max Rydahl Andersen: So that one is fun. So, on the one hand, I think what's happening is fantastic, and when I saw it the first time, I was like, "Wait, what is this?" And to see a lot of opportunities in it. I'm pro-AI, but I'm anti-the AI hype. So, this AI will enable many interesting ways to interact with IT and allow many people who did not before to use IT to utilise it better. And I'm not another person who thinks that "Oh, this AI will remove our jobs", at least not in the term because as more people can use computers, the back end needs to do more. And I have this ... I think I tweeted this out at some point. I said, "If AI disappears tomorrow, the world will continue to work. But if Java disappeared, the world will stop".
Because all this stuff that AI does is interacting with these systems out there. Today, it might be a change in the future, but it's very much the thing. So I'm frustrated about all the hype that says that you can do everything if you can just do AI. You need to understand system thinking and engineering to do it well.
Olimpiu Pop: Let me conclude somehow with what I heard from you. Mainly, it's a tool, another tool in our toolbox.
Max Rydahl Andersen: Yes.
Olimpiu Pop: But we still need the basics.
Max Rydahl Andersen: Yes.
Generative AI Will Complement Or Improve the Existing Tools, not replace them [03:59]
Olimpiu Pop: System thinking, critical thinking. And the interesting part is the fact that we have to be product developers now. It's something that I have always preached about, but people are like, "Okay, I know Java, or I know JavaScript, and it's more than enough". Now, we need to understand everything between you and the customer and the system because that will be the thing that will allow you to build a system that needs to be done. And then, obviously, you can just do some stuff with generative AI, but you still have to create the box or the guardrails for that.
Max Rydahl Andersen: Yes, to me, the AI is definitely a tool, but I compare it to ... When SQL came around to access databases, it's a thing that people use everywhere now in all different systems, all different ways to access data. It's kind of been a standard way to get data. And LLMs or AI I think is this tool that yes, if you only think about prompt engineering, like you've had this chat view on it, then it's definitely a tool you can use to learn stuff with. But once you start applying it, you also realize, "Oh, I can use this to get started writing my email. I can use it to write my code, I can use it to write my workflow. Oh, I can use it in doing stuff for me, which are boring tasks".
Well, anyway, for me, this thing, it will enable people to do more. Therefore, it's not AI who's going to take the work away from you, it's someone else who is using AI to do your job better. It's just leveling up what we can do and enable way more people to participate in software development, which is amazing but also super scary because it means now that people before, there's a natural filter because they had all these good ideas but couldn't execute and they need to go find someone who could turn it into code. That filter is no longer there. You can literally just ... Over time, there'll be AIs that can help people with crazy ideas get implemented and some of them will build amazing things.
But man, there'll also be even more people creating stuff that is horrible and unmaintainable and perform really bad. And that's why I keep saying that you still need to have a good understanding of how things work. And at least as far as I can see, all the limits of LLMs lies in ... it's not going to come with like new ideas, but it is going to help someone with good ideas to maybe get some other ideas and get some, "Hey, there's something related to this and therefore execute faster". It's a very interesting concept. Yes, and to me, I think it's going to be a tool we use everywhere, but I'm bullish on the, "Oh, it's going to remove all the developers".
Because remember when the mobile first came around like, hey, now everyone is going to do mobile apps and desktop is no longer. But if anything else, yes, we have all mobile phones now, but we have even more desktop apps and even more powerful software that runs locally.
Olimpiu Pop: Yes, I agree with what you're saying is that currently it seems that the mobile apps, and even, if you look at mobile tablet and the laptop or PC or whatever, the whole ecosystem, you do different things for different stuff. I don't know, maybe I'll just text you a plain message, but if I need to write a more comprehensive message, probably I'll just still pick the full keyboard to do it. And that's my feeling also with the LLMs, they are very good at particular tasks or how I envision them is another entry point for your application. It's a simple way of interacting and that's something that you have to build on top and obviously, crunching other numbers and allowing us to keep up with all the information that comes.
Max Rydahl Andersen: Yes, 100% and another analogy is the stuff, remember when there's only assembly code or even punch cards, very few people can do it, but the system was, there's more and more IT, we got assembler then we got high level languages. Every time we expanded the number of people who could do this stuff. And every time we say, now it's simpler, so we don't need ... We can do more with less people, but we're still growing and growing and growing and there'll be more and more demand and AI is literally just doing the same thing. At least that's the way I see it.
Taking time off and experimenting with different ecosystem, allows you to see things differently [08:27]
Olimpiu Pop: I agree with that. There are some things that they'll be useful for and I like it. For instance, one scenario that I'm looking currently at is using LLMs for configuring some complex IoT applications because it's a pain and that will allow us to make things a lot easier and more secure. But obviously, there are steps that are validating those things implemented separately. But given that now, we are sure that we'll have a job tomorrow, and you still need to write code, let's go back to the other projects that you're involved with. What we are discussing is that we as a branch, as a craftsmanship, we have a tendency of complicating things and theoretically, we should make things a lot simpler. And that's something that I know that you strongly believe in.
Max Rydahl Andersen: Yes, so one thing is I said I spent 15, 20 years in the industry. And then, I took a year off and I remember the first thing that ... When I started, I said, I'm not going to go and use computer for three months or six months even. And on my first day I fell and broke my ankle so I couldn't do anything. So I actually had to use something and said, no, I'm not going to go and look at Java. Let me try something else. I did Python in my old life so to speak. And I went back to that and I actually did some home assistant IoT stuff and I realized, "Oh, this is actually fun". It was like there's some pleasure in this non-type safe world, but I also like, man, it's also complicated, but it was fun.
And then, I had a year off, didn't do much Java, but I heard about my friends in Red Hat who were looking at this project that looked at Java differently. But I was like, "Nope, I won't touch it. I'll hear what it does but won't touch it". So I came back a year later, and had to go and install Java, learn how to run the build tools and maybe even do that stuff again. And I was just, "Man, what have we created?" So one of those things was I came back and I worked on a project called Quarkus then, and what Quarkus does is it came out of, "Hey, Java is dying, or that was at least the theory becaus,e oh, we can't run in the cloud". And we looked at why you can't run in the cloud.
And that's because it runs on these less resource machines and Java is kind of built for having access to many cores and lot of memory. And we talked to a dedicated team, how you just make it faster, just make Java faster, it'll be fine. But I say, well, the best way to make Java faster is to have less classes because what takes time is every class coming up. And if you do a Hello World or something else, it starts very fast and doesn't use muscle memory. But even better was that we realised, "Hey, the same application runs" and a lot of Jakarta EE or Java EE at the time, Spring apps, Wildfly, Seam, they were basically building on booting up the VM, doing a lot of compression at runtime and then wire things up automatically.
Like we call this simple? Simple and powerful, but in reality, you're basically doing the same thing again and again. And every little dynamic thing, every little small thing was cool and useful, but we were basically doing what's called a thousand paper cuts, like every little ... Totally, we just piled up these things. And in Quarkus, the approach we take there is like let's just do everything at build time or move everything at build time. And then, suddenly, when you do everything on build time, all the parsing and handling of confirmation, we can throw away and leave behind the result. And then suddenly, you get a JVM starting up in milliseconds or less than a second and then you can apply it native image on top and then it goes in faster.
And that flipping things around and not dragging in all the complexity we built over the last 25 years, was an eye-opener for me because suddenly I was like, "Wait, oh yes, we should just do stuff at build time" and off we go. And then, on top of that, so this gave us good runtime performance, which was the main thing that I think people know Quarkus for now. And also, what was interesting back then, but on top of that, because we were so fast at doing this stuff and we did build time, we have this information about the product, we can do stuff at development time too. So we actually could do hot reload or live reload. You get this, let's say the Python PSP experience because you can just kind of experiment, which is a thing, we are not that used to in Java.
And that was an eye-opener for me that suddenly we can do this. Where before, my past of tool experience was, "Oh, I have to write a IDE plugin that does the live reload or handle this stuff". And we were fairly popular, but it wasn't until I actually went away from the tooling space and realized, "Yes, we had 100,000 whatever users per month on this stuff back in whatever year it was". But I realized we had way more people using EAP and WildFly. I realized most people never got to have that benefit of quick turnaround because it requires to install an IDE and a specific plugin and again, bringing it back to the runtime, this makes the runtime a bit more complicated. But for the user it's a much simpler experience. It's like, it just works. And that's a big thing for me at least. Yes.
The New Generation of Application Frameworks (micronaut and quarkus) reinvision the way Java should work faster and to improve the developer experience [14:16]
Olimpiu Pop: I remember a presentation that Holly Cummins gave a couple of years back, months back, I don't remember exactly when. And I resonated with her experience and she was mentioning that like you, like me at a given point of time, we left Java behind and we did something else. We used another ecosystem. And the powerful stuff was that you can see the results relatively quick. For instance, in JavaScript or in HTML or Node.js or whatever, you just refresh, and everything was just popping up. And then, looking at how Quarkus is approaching that, or let's not hold it only for Quarkus, but let's call it the third generation of web frameworks. Because if you look at it, we used to have the heavyweights of the enterprise Java back in the day, the AGBs and so on so forth.
And then, you had Spring that wanted to be a Spring, but now, it felt more heavyweight and now the Spring seems to be the heavyweight, the champion. And then, you have the Davids coming behind the scenes, the Quarkus, the Micronauts that are trying to do the things differently and it actually makes sense and it's closer to what we started putting in the modular system. So we take with us only what we actually need and when we need it. And on top of that, it's also the ecosystem where you're just writing the tests, you save them and in behind the scenes the validation is happening. So now, it's something that is more fluent, it's closer ... For me, maybe to continuous deployment mentality that's more popular nowadays.
Max Rydahl Andersen: Yes. The continuous testing as we call it, or we have it under the name of Developer Joy. You should feel like you can just experiment and try things out. And we talked about AI for example, this is a thing that when we started doing this thing, we had the hot reload, we had the continuous testing. We added dev services with this notion of if you haven't configured anything, let's say you added a Postgres dependency or a Kafka dependency or something, because of Quarkus, we only add stuff you need. We can derive that you want this and if you haven't told us what you wanted to connect to, like Postgres, we'll just create one for you. So this is where we use test containers or we call it dev service, which users test containers to start up either a dark container or even a native image and then again, it lets you get started very quickly.
And the latest thing we've done here is actually in the AI space, just to talk about AI again. In Quarkus with the LangChain4J and stuff enabled, again, it can do all this thing like hot reload, continuous testing, native image, that stuff, but it also comes with, if you set up your AI service with OpenAI or what's the next or Azure or whatever, we have a chat UI for you in the dev UI. So you don't even have to write code or try it out. You can actually try it out indirectly in the dev UI. But if you are more to local models using Olova, we'll actually fetch that model for you and off you go. So the same kind of automatic setup we can derive from what you have included and what you have configured or rather what you hadn't configured.
This is like, I've tried to explain it bunch of times and I'm probably also failing at it again because what I tend to see is some people get it, but it's only when people actually try it out and they realise, "Oh, this magic happens". It is really fun to see that people who are used to using EAP, Spring, any other framework in the last 20 years in Java, they expect it to be hard. So people, they don't even try out the dev mode because they want to use the Maven build and they used to do Maven build, run the jar, Maven build run the jar. And in the beginning, there was people who were visibly upset on Twitter and whatever it was there that, "Hey, you are doing this hard reload stuff, I want to do tester and development first".
And that's where we came from ... We made a continuous testing so you can do both testing first and this exploration. My point is that the people ... even today we can get to ... most people that use Quarkus, sees all this stuff and then, all the good stuff, but there's a lot of people who just use Quarkus as if it's any other old system and they never actually realize the power that's in Quarkus because they just use it as they used to use any other complex setup.
Forgot the old paradigms and ways of working and approach new tools and philosophies open-minded to face a revolution [18:58]
Olimpiu Pop: So we should come more open-minded to change the old paradigms because one of the things that come with, let's say more tenured software developers like you, like me, that you are above 20 years experience in the field. I am a bit below under that, but more or less around 20 years in the field, we are quite proud of the shortcuts that we know with our ID and the way how we build this stuff.
Max Rydahl Andersen: Yes, we have what I call survivor bias, but to use this stuff we had to do all these complicated things and therefore you should do it too. And when someone comes up with a simpler solution, it is hard to realize, "Oh wait, this is actually better". And given the rural situation and how fast-paced thing is, I don't blame people for missing it because there's just limited time to try things out. But it is something I'll remind people about again and again, just give it a try and see how it works. And I heard multiple times now where people who had this user case where they had some PHP and some JavaScript and a few other things and it was getting to be a mess and they tried to roll Quarkus in and suddenly they realized, "Oh, we can actually do all the stuff you're doing there in Quarkus and all the hot reload".
And that was because it was people who were not used to Java, they just tried using it as they were used to in JavaScript and stuff and they were like, "Oh actually I can actually do this". And they get all the benefit of a Java ecosystem and all the stuff is there and everyone is happy.
Olimpiu Pop: Yes, I agree with that, but there is always the right thing that is usually on the medicine that is very, very small and not everybody sees it. And in my experience, it's very nice when everything happens magically but point, there are those, the 99 percentile when things are not working as you expect and then, you have to go into a debug mode. What happens with those simple, because actually what ... all the simple stuff that we are mentioning, they are very complex behind the scenes, but it was built so well that it allows us to build simple stuff. What happens in that particular case? Will we drop the tool and then, run for the old one or what's your experience in that?
Max Rydahl Andersen: I can say what kind of mentality or approach we take in Quarkus is because there is machinery behind it. You're doing build-time emulation, there's bytecode generation. As an end user, you don't have to realize it, but sometimes you hit a wall and you get exposed to some of this stuff. So one thing we try to tend to do is anything ... like exceptions been in around Java since forever but since forever, how many versions was it that Java has just NullPointerException and no explanation of the context. It was added in '21 or '20, I can't remember. At some point, they added the, NullPointer because variable X is null, right? Simple little piece of context makes a world of difference. Imagine if that had been around like 20 years ago and we do the same thing in Quarkus.
Any exception we find where we just say, error. We try to add that little bit of context to help you, similar if you run in dev mode, because that's the thing we can with Quarkus. We can run in dev mode so we can actually handle errors differently than in part mode. So when an error occurs in production, we will kind of hide it because you don't want to leak detail through a running system. But in dev mode we know it's not running live and we'll actually give you the exception. And in the recent version, we actually even extract the source code so you can see it on screen like this is where the issue is and you can click on the source and go over. Again, all this, without any IDE installed. And we just try and enable people to be able to solve the issues with context and in some cases, we even go and explain this is the kind of code you need to write or look for these annotations.
And then we try and make sure that it's easy to find all the debug tools that are there, enable logging kind of thing. And the speed of how fast we can restart, makes it so that you might have an error but you can try 50 different things in 50 seconds where before it might be able to take, like you do three or four things and it'll take a whole day and yes, that speed in itself enables much more debuggability, is that a word?
Olimpiu Pop: It is now. We just coined it so we have it on tape.
Max Rydahl Andersen: Yes.
Having Reliable Runtime Environments With Comprehensible Exception Handling will Make Your Software Run Anywhere, even devices roaming the Ocean Floor [23:45]
Olimpiu Pop: Just thinking about what you mentioned about the exception and the way Java handles the exceptions. I am reminding myself about what James Gosling was saying a couple of years back in Andrup, at Devoxx Belgium. He was saying, " Everybody is complaining about why we have typed exceptions in Java? Why must we put a catch exception everywhere and wrap everything in that? And then, he was just saying that when he initially started building it, it was thought about embedded software and that embedded software was running on the floor of the ocean. He said, okay, it wasn't that easy to go and just press the reset button on those submarines under the sea. So that was the reasoning, and I felt that that's how we usually do.
It's like the pictures were this is how we thought about it like software developers, but this is how they user use it and even Java was using that way. Now, my feeling is that it's moving in a different rhythm. The community is more involved and with this bi-early cadence it's much easier. But how is it is to maintain such a cadence? Because on the other side, when you're building simple stuff, as you said, it might be a pain in the back.
Max Rydahl Andersen: Yes. Man, it was a turning point for Java when they moved to the six months release cadence because they did get into a mode of "Oh, things can now evolve and change", which was super frustrating in early days. It took forever to get stuff going in Java. And in JBoss, in Hibernate and in WildFly, we've had to do tons of workarounds because of the limit, like the JVM was just not moving. For example, the whole async IO in Java came fair enough ... it came fairly late and when it came, it was subpar compared to Netty and other ways to do things. So Java has always been good because of a really stable OpenJDK and the ability to hook things in and rewire things. So it could be innovation in the higher layers. Now, we've got multi-line strains, we've got records. We've got streams. I'm missing a few virtual threads.
All those are definitely helping. And in Quarkus we've picked up all of them, but we have to realize that the people we are selling to, the people that actually are paying our salaries. They are companies who do not afford to update to latest, greatest everywhere, especially on the JVM level because that's considered part of the OS. So the funny thing is that people really want to stay back on the old version of Java, but they're fine upgrading to a newer version of the framework because people are used to it, later. And that leaves us in a funny situation that right now, we've moved to ... our base is Java 17. But we recommend Java 21, but here in a few months, Java 25 is coming out. And in normal cases, they'll be fine.
But in Java 25, they've done a few things. Not just in 25, I mean, between 21 and 25, they've removed something like security manager, which actually makes it so that parts of the Java ecosystem just cannot run on 25 anymore. It's going to be fixed but it's going to take some time. But I mean that even if we wanted to move up to 21, we still will have parts of the Java ecosystem that could just not run on 25. So even if we want to move to 25, we can't because this still works for ... So all that stuff will still exist. But we've done this in Quarkus that we do basically releases every month, like multiple times a month actually. We do a minor every month and sell micros depending on bug fix and that kind of thing.
And that has allowed us to have fast iteration, but we have a stable version called LTS release. So we kind of do what is done in Java, like this tip-and-tale system, but we are not doing what the OpenUK team is telling us to do or for pushing last year was this, do have a release on the latest version of Java, have a version of Quarkus that runs ... That has a baseline of 25 and then just maintains an old one for 21 for example. That requires just too many resources to make happen. So instead, what we do is we survive by using older version of Java in the framework, but we can still support newer stuff like 21. Virtual threads were supported even when we were on Java 11, we had support for Java 19 virtual threads. Java 14 records were supported before we moved up from Java 11.
Whatever the new specs are, we will have support for them, but we won't be able to use them ourselves in Quarkus and that's the price we pay so we can be on the edge but also, still support the older ... I'm not going to say older, but slower moving systems.
Legacy systems need to be updated faster than before, to avoid their exploitation by using AI [29:05]
Olimpiu Pop: In those places that usually make the world spin, because I worked in finance for an extended period of time and I was surprised that people were still happy with software that they bought 10 15 years ago because it was doing the job that they always did and it was just incredible.
Occasionally, when there was some kind of regulation change, they came and asked for an update, but mainly because they needed that feature. But the things are working. I call them the plumbing systems, you don't care about the plumbing underneath your house as long as it's working as expected, but you'll definitely care when the water is just popping out.
Max Rydahl Andersen: Yes, that's just the reality of things, right? We have all the versatile Quarkus to be known in production and we help them, but Quark is still ... All things considered, still a new kid on the block.
Olimpiu Pop: Yes. The new kid on the block.
Max Rydahl Andersen: So we still have the benefit of being able to move up, but we are introducing like LTS and longer LTS and over time, it'll get longer. But we've been very aggressive of not guaranteeing a version of let's say Quarkus 32. We'll not add any new features to it. We'll maintain and do security fixes to a certain level, but all new developments move up because it is a new world. We are encouraging developers and companies to no matter what, build your infrastructure and UCI so you can do this continuous testing. So updating should not be a problem for you. We believe that will cost less to develop and it'll be cheaper to maintain, but eventually, some project will be like, "Hey, we can't keep updating, we'll just stay on this long-term, so forth, and then they'll also not need any new features.
That's fine, we'll just keep maintaining that. Yes, this is the thing I think is exciting over the last 20 years is that software companies, even the older legacy ones are getting into the mindset of being able to update more aggressively, which is a thing. With the whole AI phrase, I'm still waiting for ... Everyone talks about all the cool stuff AI can do, but if you can do that, it can also exploit CVEs way faster than anything else. So being able to upgrade is going to be a key thing.
Olimpiu Pop: Yes, definitely. But getting back to the initial point of our discussion about simple versus complex.
Max Rydahl Andersen: Yes.
Java Devs Fought So many Battles with complexity, that they don’t see Love, Peace and Quiet Life when they see it [31:30]
Olimpiu Pop: Now, we discussed about the frameworks and it's obviously the new generations are a lot simpler than what used to have and it seems that the simplicity is moving forward and forward, but then, let's look at the other ways of doing stuff like you are the father of JBang as well.
Max Rydahl Andersen: Yes.
Olimpiu Pop: JBang, my feeling is that it's a love-hate relationship. I know people that love it and then, the other ones that are like, "Oh, max did this thing and it's a pain in the neck because of security, blah blah blah, blah, blah, blah, blah". Is JBang a simpler thing or it adds complexity?
Max Rydahl Andersen: Well, the way I think about it, there's so many Java devs who've kind of fought so many battles of complexity, that they just can't trust peace, love, and joy when they see it, right? When it's peaceful and quiet, you just can't believe that this is true. It has to be complex. The way I see it is JBang is just enough Java and you can say I've removed stuff that was often never needed or rather ... I haven't added stuff unless someone found a need for it. So JBang started again, this came up from being gone a year and coming back and I had to learn Java again. I was like, this is horrible. How can we do this to people? So this was basically ... This was like Java 8 was the new thing back then. And I hadn't done real Java since Java 6 at the time.
So I had to learn on streams and other stuff. I knew what they were, but I haven't used them. So I said, Hey, let's just try and have a side project for a while. And I saw someone using our built system, was using Kotlin scripts like K script I think it's called. And they basically just writing Kotlin because it small single scripts because they could maintain ... The Java people knew how to do that. And I looked at the code, I was like, this is just Java, why don't we make that work in Java? And that's where it started. And it was like, "Oh, when I built it was like, wait, I can now experiment". Those that don't know, Jbang is ... The original idea was a single Java file and you can add declare dependency in the top like slash steps log for J, slash steps walkers, whatever. And I was like, "Oh wait, I can now experiment. I can try new libraries in seconds".
Rather than star dot E. New job project, find dependency ... I could just literally just boot up from it. And then Taco, who's my partner in crime and later version of JBang, started adding this automatic downloading of the ADK. So you didn't even have to have Java installed before starting with JBang. So this whole having to pick which version of Java you download. It doesn't matter. You just go and get adoption of time or Temurin, the latest version. And now, you could start with Java with just having notepad on the machine, which is a good old Java back in 20 years ago. Then the next thing was I can actually install the VS code Java editing for you. So suddenly JBang was not just able to explore new Java libraries.
But I could give it to a student and I could install and enable Java anywhere, whether that was on my grandma's PC or my new laptop or some cloud IDE out there because they were just these simulant and it just grew from there, That JBang is nothing but a wrap around Java C and Java and JShell for those who want to do interactive stuff. And I just kept that principle. So the cool thing is almost anything that the Java team has come up with, I either already had in JBang or can assimilate to JBang. So JBang works from Java 8 to Java ... the latest early access version. It could honestly work back to Java 6 or even older, but it starts being hard to compile stuff in that range. But fundamentally, it is a very thin layer on top.
And it's funny, this love hate thing, some people love it, some people hate it because it doesn't come with a default six nested directories for source main Java IO, Acme green, XYZ. I can just have one file and this can be small script or it can be a full end microservice written in Caucus. I like it and I'm biased, but-
All the hacks and tricks of other software ecosystems like Node and Python were used as inspiration to make Jbang the easiest system to bootstrap in the world [36:05]
Olimpiu Pop: That's the magic of the world. We have to live with each other even if we have different opinions, right? So JBang would be a proper tool to just bootstrap yourself if you want to do Java development, as long as you have an internet connection more or less, and then just run it and then everything will just work out of the box.
Max Rydahl Andersen: I have this claim, in Caucus, you have to claim that if you find out that Caucus is slower than spring, that's a bug because fundamentally it cannot be the way it's architecture. And with JBang, I'd say if you find any development environment in the world that is easier to install than this one, I consider that a bug. I'm a heavy user of Python. I'm heavy user of Node.js and well, I'm not saying here, but for front end development I've used it and go. And all those tricks and tools they use to do things, I've applied to JBang. So it just becomes so easy to set up and it can self bootstrap, but this is the fight I'm fighting. People are saying, JBang is not part of Java, so I can't use it. And I'm like, Maven is not part of Java or Gradle is not part of Java. You use that.
That's because people are like, that's what I'm used to. You look at Python PIP install is not part of ... Well it is now, but PIP started as something that's outside Python. NPM packs managers are not part of the original Node.js setup. It's funny. People just, no, this doesn't fit into the complexity of Java and therefore it's kind of an outcast.
Olimpiu Pop: Yes, well that's usually the way ... there are the people that are pioneers. And then, if you look at the hype cycle as well, then you have the really early adopters, but most of the people are in the middle. They're either late adopters or they are just waiting for the scale to be in the other direction.
Max Rydahl Andersen: Yes.
Olimpiu Pop: How did you build JBang so that you ensure that things are safe but also simple? Because simple, it's obviously they are.
Max Rydahl Andersen: Well, that's the thing. We can still do more, but JBang itself is using the Maven resolver itself. So anything that the Maven Resolver does to security is there. So JBang doesn't do anything that is outside normal Maven, so to speak. One thing I haven't enabled yet, but I do want to get to is shard, like verifying of the shard signature, but Maven today, and even Gradle doesn't do that by default because it slows things down. But stuff that JBang does that is unrelated to Maven is, for example, I can say JBang a file on disk. Again, no different than you can do with Java. You can say Java, single file Java, it will run what's on disk. So that's no less or worse than Java.
But then I can use a URL, JBang URL. And people go like, "Oh, I can run random stuff on internet", but if you go look, JShell actually also can run URLs. People don't know. You can go to JShell HPS something. There's no check whatsoever in doing that. In JBang, we have this notion of trusted URLs so that the first time you go and get it will ask you, is this a thing you trust? And you say yes, then it's fine.
Olimpiu Pop: So that means that you have to whitelist it more or less, right?
Max Rydahl Andersen: Yes. It's kind of like, if you ever use VS code and it opens a URL, it says, do you trust this link? And then you say yes. And then from that point on, you can access that just fine. You can also trust the whole domain and that kind of thing. So I have that kind of notion. So in that sense, I feel like it's safer than even NPM and PIP and other stuff out there. And I'm sure there's stuff you might have missed and stuff, but I encourage people if they see there's a security concern, do open it. But as far as I know, we are not doing anything, not done anywhere else. And the places we could do stuff, we've added stuff in. This is the fun thing. People realize, what's it called, this supply chain attack.
That you can add stuff like, "Hey, you can patch a Maven plugin". If you somehow can get that released to a repository that you're billing from, then boom, you have an attack vector. And people look at JBang and they realize, "Oh, I can do any kind of stuff here". But that's because it's so easy to do where it's just as easy in Maven or Gradle to do things like there's a lot of other products, I guess reproducers just attach to the project and even me, I just look quickly and go, "Okay, I'll just run it". But anyone could have put some code in there that are tricky. So I'm getting more and more cautious about that. But the world of software is a dangerous place to live, let's just say.
Always learn from other ecosystems and improve the way how you work. Use inspiration from everywhere [41:00]
Olimpiu Pop: Fair enough. One last thing that you think that we as an industry are doing too complex things when there are simple alternatives?
Max Rydahl Andersen: Well, again, for me, we started a bit in the beginning, but it's something that's on my mind again and again, is this thing that just because there is this hype, people are just attracted to it like moths from somewhere and they don't realize that, hey, you know what? There's actually already stuff out there that can do this stuff. Combine the two instead, you'll a better result. But also at the same time, I also very much aware of applying it to myself. Being like, "Hey, I'm so used to things, how it works in Java, remember to go look and how it is actually in the Python land and see how it is". Because there is actually also simplicity over there. There's a reason why it's so big. So just as I've said, hey don't diss Java and diss the Java ecosystem, it can actually be simplified and be good.
There's still stuff to learn from that new world. There's complexity everywhere. There's also some place hidden in some of these new places coming up.
Olimpiu Pop: So just listening to you, one metaphor was coming over and over in my head, or maybe it's not a metaphor, it's more a comparison, is that whenever I was working with JavaScript and my colleagues from JavaScript side were coming and they're like, "Check out this new thing with, I don't know, Nest.js or whatever other new stuff". And I said, "Yes, well that's dependency injection and it's in Java for ages or mappers, or arms like hibernate". Well, that's already existing for a long time, but my feeling is that also this old dog, that Java and that's therefore forever can learn new stuff from the newer generations. And that's very nice to see these symbiosis in the ecosystem.
Max Rydahl Andersen: A hundred percent. The day we don't learn from others and improve them there, that's the day that Java dies and that's why I think Java is very much alive because we keep learning and keep adapting. It's a different world and we can definitely learn and improve and we are. At least, I'm trying to do my best in helping in that space.
Olimpiu Pop: Great. Thank you, Max, for the time. Thank you for sharing all these thoughts. Any last things that you would like to share?
Max Rydahl Andersen: Well, if you find some of this stuff interesting, definitely check out Quarkus and explore. Try it out at least. And yes, for JBang, anyone who's doing Java, whether it's with Quarkus or Spring or Micronaut or Python or Kotlin or Groovy and-
Olimpiu Pop: Whatever other things are there.
Max Rydahl Andersen: JBang actually has a place to do because ... Give it a try. Tell me what you think, even if you don't like it. Learn from it, every time.
Olimpiu Pop: Great. Thank you for taking the time, Max. Thank you everybody. And just make sure that you listen to the In InfoQ podcast. We have great things to share.
Mentioned: