 So, thank you for being here, and I'm Alex Fiestas, I'm a first-over hacker from Barcelona, and for the last eight years now, or something like that, I've been working in this community you might have heard of called KD, and specifically, yeah, seven to eight, something like that, and specifically I have been working in all things related to the desktop, right, creating a desktop itself to desktop applications, which is quite the contrast because in the last two years, I've been working in the completely opposite side of the spectrum. I've been working in this company called IOS, that, for example, KD is owned by the community, right, KD is owned by us. IOS is owned by Telefonica, which is not quite the same. In KD, I used to do most league desktop applications. IOS is a kind of company where everything is web, everything is cloud, and everything is trendy. And finally, in KD, we only do free software, and at IOS, at least until seven months ago, we only did proprietary, almost only did proprietary software. So that actually, that huge range of things have given me a special perspective when it comes to desktop and web applications. So let's start with defining what desktop applications are. And this one actually is quite easy, right? So a desktop is a form factor for a computer. Usually, you have a screen, a keyboard, and a high definition pointing device, like a mouse or a Wacom tablet or whatever. And that, for example, is shown if you're trying, if you have tried to use a desktop application in a touch interface, it kind of doesn't work. Because, well, you don't have that precision, for example. Or at the other way around, a touch application for the desktop, some of times you are missing shortcuts, which is one of the most important things in the desktop. So this one is easy enough. Let's go to the web. Let's try to define the web. That's actually a bit of a harder challenge, because the web seems to engulf so many things, like websites and video games and whatnot, that people think it's hard to grasp what the web is. But in reality, it's actually quite easy. The web is just any application or content that you can use in your web browser. And the web browser is actually super important. For example, if there is anybody in the room is still using Internet Explorer or Internet Explorer 6, your web experience is going to suck. Your web experience is going to be years behind the one that people using modern browsers will have. You are not going to have SVGs. You are not going to have videos. Or, well, videos without making your fun go at 100% revolutions. And 3D and many other things that you can do with modern web. Desktop applications, now that we know what they are, let's dig a little bit deeper. And just a warning, this is all my point of view. So, of course, it's really opinionated. If you don't agree, well, raise your hand maybe at the end, and we can talk about it, or grab me somewhere. So desktop applications. They have been with us since the desktop was invented, right? So many, many years ago. I probably wasn't born or still was a little baby. They are really, really robust, either because they are using technologies that have been with us for as many years as the desktop, or because lots of QA has been done into that. Lots of users have used these applications, and now they are really, really polished. Applications like this, for example, you have Microsoft Office, you have Visual Studio, which just mentioned a few proprietary ones. In the open source realm, we have many as well. We have Firefox, we have, which is a web browser, we have LibreOffice, and many others. And that's really, really good. It's not that easy to find super complex feature-rich applications that are as robust as desktop applications. They are really fast. And when I say fast, I mean that in the abstraction layer they work on, as in they are really, really close to the computer. And that allows them to be really fast. You can find desktop applications in really, really tiny computers. It's not that easy to find other kind of applications in there. And it's actually a feature, right? Depending on what you want to do with your application or where you want to deploy it, you need to do it using desktop technologies. Then there are a huge variety of them. It's enormous. You have from the series of games like Minesweeper or something like that to really complex video games with virtual reality and whatnot. And basically whatever is trending, whatever, like the cutting-edge technologies are usually in the desktop first. For instance, virtual reality, right? You don't have virtual reality in other places right now. And that goes for everything, right? You have text editors. You have text editors that are just plain text. And you can do anything with them to Microsoft Office, which is in the other side, which you can do even programming in there, I think, with macros and whatnot. So, you know, you have a good offer. And you have access to everything, right? You have access to almost every part, any tiny part of your computer. You have access to Bluetooth devices. You have access to the GPU. You have access direct access to the network, so you can do cool things like discovering and things like that. And that's really, really powerful as well. And when it comes to tiny pieces, like the Internet of Things right now or something like that, it's really important to have access to all those buses and interfaces provided by the computer. But, well, there are also a list of bad things, right? For example, it's really difficult to reproduce the same application that you are developing everywhere. One of the reasons behind this is that the desktop started in different places at the same time, each or they copy each other. But, basically, you have Windows and you have Mac and you have Linux, which are the biggest players, and they don't like to talk with each other. So, when you create an application, if you want to make that application exactly the same everywhere, you have to do a lot of things. And, of course, we have Qt, and this is QtCon, and Qt is basically an engineering approach to this problem, right? And they have tried to lower the cost of developing the same application everywhere, but still desktop application sucks in this regard. Then you have distribution, which is one of the biggest flaws in desktop applications. If you want to distribute your desktop application, you are distributing it to a really complex system, like, well, Windows, Linux, or Mac, and so many things can go wrong. And I think that you might have seen bugs of the kind like, yeah, application is not working. And then you do some checking, and it turns out that the configuration folder is read only. Who the hell puts the configuration folder as read only? But these things can happen, right? Because the whole operating systems are so stateful, are full of things that can change and that can break you. And it's really difficult. And not only that, but the medium where you have or that you use to distribute your applications is not the friendliest of them. For example, for normal Windows application, you would go, arrive to some website usually, download an installer, then you will install it and go through a wizard that is going to ask you all sort of complicated questions, and then you will finally execute it. And this is super complicated compared with other workflows that I'm going to explain afterwards. Updates, updates suck, and that's it. Each application is going to implement their own way of updating, especially for Windows. It's the case. So each application is going to have a different policy to distribute updates. And not only that, but most of the times you relay on the user to click the update button. And that actually makes life difficult. For example, to do A, B testing and things like that. You cannot control which users are using what version. It just sort of happens. It's anarchy out there. You might have users using a version that you released four years ago, and you cannot do anything with it. In the Linux ecosystem is even worse because as a developer, you don't even control the distribution system. And yeah, I'm sorry, distribution guys. Don't look at me with those faces. But that's reality, right? I mean, and this has happened to me personally that I use and invest my time to fix a bug that was really complicated. I'm so proud, finally fix it. And then it takes me 1.5 years until it reaches the user. And that's just not acceptable. And this is actually a case not only in Linux. This happens everywhere. In OS X, you have to go through the Apple Big Brother eye, right? And they have to put the stamp off. I want this in my store. So the same thing happens. You have a critical bug. You want to release it. You want to distribute it. And you can't. And finally, the desktop is clearly behind in some trends and some things that are really needed for modern software development. For example, analytics. There is no unified way of having analytics of your app. And as well, you have applications that have developed their own system. But the cost of doing such a thing is huge. And actually, I cannot think of a straightforward way of having analytics in Qt. And when I say analytics, I mean, I want an analytics off. The user has been here. From here, it has jumped to here. Then most, move the most sponsored this way. And this kind of information. And since you cannot have that, then your further development are basically blind. You're trying to ask questions rather than to see data. And ask is wrong. I mean, if you ask a user what do you want, you're probably doing it wrong. You shouldn't ask that question. Anyway, let's go to the web. So if when I say web, you are thinking on my blog or you are thinking of a simple website, then you are doing it all wrong. The web has evolved since then. And you can do many, many, many things. And there are key features that are the features that are making the web so well, the de facto standard is to develop anything. One of them is that it was designed to be reproduced. It was designed to be a standard. And yes, when there is a standard, there are people that are not going to follow the standard. That's how life is. And there are people that for whatever reason, they will try not to follow the standard and to make life harder to you. But the success of the web has made it so you have so many solutions for this that you are not even going to notice. Nobody is fighting these days with these works in Internet Explorer. It doesn't work in Chrome or something like that. You have libraries. You have tools that help you for this. And we have to keep in mind that there are at least 3.5 billion webs. That's a shit ton of a lot of money that is being pure every moment into the web. And basically, this money goes directly to engineers. And what's what we do, right? We try to solve problems lowering the cost even more and even more. So that's de facto. The web is reproducible. And you grab the web. And that web is going to be exactly the same everywhere almost. The web is stateless. When you load the web, that web most of the time starts with zero state. And it was designed this way. Later on, some state has been added. You have cookies and whatnot. But the design principle was stateless. And this basically makes it so if you have any problem with the web, in the worst case scenario, you just click refresh. It reloads everything. Reloads the state from a scratch. Boom. Fix. And yeah, because it's a stateless and because it was designed to be reproducible, then the distribution is perfect. And even more, it was designed with a server client in mind. So basically, if you have an application, you have three billion people already connected to the internet or something like that, four billion. So basically, if you have a web, whatever, and you have 3.5 billion users that will be able to access it and execute it exactly the same way you design it. So not everything is not the web is not the land of unicorns and rainbows and shiny things, right? There are also bad things. One of the bad things is that the web is sandbox. And this is good for security, but it's also really, really bad and inconvenient. For example, since it's sandbox, since the web can only see whatever the browser allows the web to, you don't have access to Bluetooth. And you have to wait until some big companies such as Google implement some kind of bridge between the web and Bluetooth, it's actually happening by the way. And until two years ago or something like that, you did not have access to the webcam or to the microphone and to many other things. And not only that, but you have a resource limit. You have a, I think in Chrome, it's a gigabyte of RAM and 200 megabytes of local storage. So you are really limited by this sandbox. And depending what you want to do, you simply can do it with a web. For that, by the way, there are these hybrid monsters, which are becoming quite popular. But let's not talk about them. They are slow. The abstraction layer where the web is, is way higher than desktop applications usually. So basically, to draw the same thing, let's say to draw a straight line, way more CPU instructions are required, way more work needs to be to happen in comparison with a desktop application usually again. And what happened with my slides? And well, and that's, that's actually inconvenient, right? If you have, for example, an embedded, a small computer or internet of things, the web is really, really slow for that. And your small computer is probably not going to be able to, to handle it. And then this is actually a hidden gem with most people, I don't think they usually think of this. And it's that when it comes to free software applications, the web is really, really far behind. For example, in the desktop, we have LibreOffice, right? That is kicking some ass and that can compete with Microsoft Office. You don't have a free software web that can compete with Google Docs. Not yet. We are working on it. There are, for example, web ODF and other things, but still we are not there. And this is actually a problem. It's a problem because users don't find good alternatives. And while there is this trade-off, right? Of freedom and privacy versus features. And that's always the trade-off users are going to find. And if we don't offer good, featureful web applications, then those users are going to remain using Google Docs or whatever. And well, so to that, this is what we say. If we are lacking feature-rich complex applications into the web, we don't use the desktop applications, which I said they are really robust and lots of millions of euros and whatever currency have been put into them, like LibreOffice. And so we can compete with developed web alternatives. And this is what we have done at Open365. We've done this with email. We wanted to compete with Outlook and with Gmail. And we couldn't find any good web alternatives. So we ended up using K-mail, actually. We grabbed K-mail as we used it on Kiddie and put it on a web. And we did the same with LibreOffice, basically. We have presenter, spreadsheet, and writer on the web. So there are a few ways of doing this. I'm going to go quickly. You have Nackle, which is a Chromium-only solution, which basically executes the application and it sandboxes it in the same sandbox as the web, right? So you have that added limitation. But, well, they are really fast because they are almost as fast as if you would execute them outside. And they are killing it. And actually, they are killing it because this thing is happening. ASM.js, which is the predicated world, and WebAssembly, which is the new feature thingy. And WebAssembly is actually kind of cool. Basically, you compile your application to a subset of JavaScript. And they are optimizing that subset of JavaScript for it to be as fast as possible. And they are also adding missing primitives that JavaScript is basically not able to, for example, when it comes to do parallel tasks, JavaScript sucks. And it was not designed for that. And they are adding something. Because, well, your video game or key develop there or your IDE, they are going to use threads and you need those. And then you have the solution we went on, which is execute these applications in the server and grab just the interface and bring the interface to the browser. And just do that. So the heavy lifting is done by the server. And then you have, like, something that gets the interface and puts it on the web. We chose this solution because either of the above are actually possible right now. I mean, if you optimize your application, maybe you can get it to work. But they are not generic enough solutions. So how we've done it quickly, we are using containers. That's what makes sense. We are going to have hundreds, hopefully thousands of users using these apps and we don't want these apps messing with each other. So we are using containers. That's really nice. And they don't add an overload. And they are really, really convenient. Then for bringing the interface to the web, we are using this protocol called Spice that is created by an ice wheel company and then bought by Red Hat, which basically is a protocol that supports primitives. For example, draw rectangle, draw straight line, merge these two big maps, draw big maps and these sorts of operations. And it also supports actually sending video, which is question. There is a component called Spice X server, which translates X to Spice. Yes. So basically the applications are executed in a container. The applications connect to an X server via socket. And this X server offers the Spice. And that's the conversion. And, well, the missing link, which is what we developed, is a Spice web client, right? So we said that web is whatever can be executed in a browser and this is what we were missing, some way of putting this into the web browser. So you do what we do with the virtual guests in the computer, but instead of using Spice, you put it in the web? Yeah. And that's actually the point is because if you had to distribute a Spice client, that would be really inconvenient, right? Because the user will have to add some kind of plugin, next, next, next, install it, then you run into all the problems they mentioned. So by doing it web, you just forget about all of this. Everything is open source. Pure JavaScript. Well, JavaScript, HTML and whatnot. And everything is open source. You can go to this GitHub URL, download whatever you want. We also open source, like the entire open 365. So you will see a bit of noise, like microservices, plugins for rabbit, MQ, which is an implementation detail. We are using each other for chat and whatnot. But, well, if you want only the Spice component, then look for Spice and you will find it. And finally, let's do a demo. Which is always the most interesting part, isn't it? Let's see. So let's start by LibreOffice. Well, this is another presentation I did in last academy. And this is basically LibreOffice. This is running offline. And as you can see, you can see the picture, like the huge image loading because, well, it's really huge. I'm running this in high DPI on. Well, that's what happens. And, well, you can see all the widgets, more or less, how it responds. Oops, I clicked in a link or something. So this is LibreOffice. And this one is KeyDevelop. This is actually the first time I do it to check how it works. And because we are at QtCon, I thought that we should have a KeyGasKeyDe on Qt application, right? And, well, this is KeyDevelop. I don't know if you can appreciate that there is no lag. And when you put this on a server, the lag doesn't change almost. The Spice was actually designed to work well when there are high latencies. And it automatically, well, implementation details. Ask me later if you are interested. So this question, since you're using Spice, would be able to emulate even the virtual machines that you export using the virtual plans, like you use Spice as the protocol to look for the virtual machines? No, we have a few pieces written in Node.js that orchestrate all of this. So you have a small microservice and you say, hey, I'm Alex, give me KML. And then it prepares everything. What's a full Spice client? So the Spice basically defines how to draw things, define some things like Clipboard, which we support. You have shared Clipboard. And some things we don't, for example, USB, because the sandbox in the browser doesn't allow you to escape that. Two questions were, what happens when I say for open files? And the other question is, what about sound? Let's start by the letter one. Sound, yes. Right now, I don't have any application, but yeah, we do support sound. And Spice offers two codecs. We offer, we support one, which is what the desktop supports. And actually, what's kind of annoying, because I would start, like, when we started, you would get the KDE sounds around and, well, KDE sounds are not the best. And save, that you have to do it, depending on how you do it. For example, since we are using containers for everything, what we do is we open a small door to the user file system. So it's a user network platform, has a file system. And through WebDAF, in this case, we mount the file system inside. And that's how you have access to your files. And in Open 365, we are using C file, which is kind of a non-cloud thing, but, well, we found it to be better. Let's not talk about that. And basically, in C file, you have an application for your phone, an application for your desktop, you install, you can synchronize files and all that. So you have your files in the cloud. So that's mostly it. Something I would love to see, and I will completely help, and I'm looking at users, KDE store and all that, would be lovely to have demo.kde.org. And you can click on there and get your application for five minutes so the user can measure around with or whatever. Yeah. I mean, that would be really, really nice. Well, since you're a KDE store guy, some numbers, actually, we have 200,000 users. We have had up to, I don't know, a few thousands K-mail opens at the same time. And the bill is less than 300 euros a month. So, yeah. Yeah, yeah. Maybe. Yeah. I mean, the K-mail, the biggest problem it has is RAM memory. And when it comes to servers, RAM is really cheap. And you buy a cheese and they give you RAM for free. That's how cheap it is. So, since RAM is cheap, then it doesn't use that much, CPU. Any other question? No. No. I noticed the people, like the deal with spies, they are working on this. And, but so far, they can't. Any other questions? Okay. So, if you have any questions you want to ask now for some reason, I will be around. Just speak to me. Thank you.