941
I Use This!
Activity Not Available

News

Analyzed 5 months ago. based on code collected 5 months ago.
Posted about 1 month ago
Reza, please introduce yourself I am just a professional server-side Java developer, architect and consultant. I have been involved in the Java EE community for a long time (about 15 some years now). For folks interested, a long version of ... [More] my bio is on my LinkedIn summary. For most readers here, it's probably significant that I am the former official Java EE evangelist at Oracle and a long time contributor to Java EE JSRs in the JCP. My humble blog is here. I also try to do something useful with my personal Twitter account. As a relatively frequent speaker, I try to share pragmatic Java EE code on my GitHub account. Which application servers, tools or IDEs are you using? Like most Java developers I use a wide variety of things including Java EE, Spring, WebSphere, WebLogic, JBoss, GlassFish/Payara, Tomcat, Spring Boot, Eclipse and NetBeans. My clear favorites these days are Java EE, WildFly, WebSphere Liberty and NetBeans. I think WildFly Swarm is a really cool project. I am a little sad to say I had been a long time fan of GlassFish and to a lesser extent I still am. I think TomEE has a lot of yet unmet potential and could be a significant player if the right things are done. You are the chief Java EE Guardian. How big is the Java EE Guardians community? Who else is involved? I don't think there is actually a chief Java EE Guardian (and I hope there will never be). From the very start the core folks involved have had a gentleman's agreement to remain a very egalitarian community where everyone is treated absolutely equally. We try our best to operate under open collective consensus based decisions. It is certainly fair to say I am a key Java EE Guardian responsible for bringing our community and concerns to the open. It is also equally fair to say the core Java EE Guardians started their most important work together far before I had anything to do with it. I would say considering our age, the Java EE Guardian community is quite large. Our full list of supporters are always available on our web site. Without needlessly naming names, our support comes from fifty JUGs, about a dozen official Java Champions, forty some JUG leaders, many JCP members, bloggers, authors, speakers and educators. One name I think is fair to mention is James Gosling - the father of Java. Most importantly, many ordinary Java developers choose to support us. There are well over 3K signatures on our change.org petition to Oracle executives on Java EE. About 4K people follow us on Twitter. There are over 600 people subscribed to our Google Group account. There isn't a heavy Java EE vendor presence in our community. I think that's a good thing. None of this means we do not still need more support. The broadest possible support will help us achieve our mission faster, more effectively and ensure that the results of our efforts last a very long time. We are a grassroots organization. Our only job is to serve the best interests of the Java EE community. The most important voice that matters for us is the ordinary Java developer, particularly people that see the need to keep vendors on the Java server-side accountable for their words and actions. What is your opinion about the Microprofile? I think MicroProfile is a very important and timely initiative. The issue is that it is very difficult to separate hype from reality in microservices. I already see a number of clients struggling under the weight of vendor driven microservices hype. I fear a lot of these projects are headed towards needless failure by buying into hype driven products too quickly. Java EE is facing the same issue. There is a very real danger Java EE may wind up prematurely standardizing many features that in the end will not stand the test of time in a few years. The MicroProfile is a great way for Java EE vendors to pseudo standardize microservices features and market those features into their products without risking polluting Java EE too much with a bunch of yet unproven ideas (or worse, outright bad ideas that happen to be trendy for a moment). MicroProfile also serves as an important reminder to Oracle that it does not have a monopoly on standardization in server-side Java. If it fails to be a good steward for Java EE, an alternate standard can and will be naturally formed. Lastly, MicroProfile is a good antidote to some of the deliberately designed Java EE bashing some vendors engage in (I think we all know who these vendors and individuals are). They know fully well that Java EE tries to do the right thing by avoiding hype-driven features. They take advantage of this principled and disciplined standardization approach by continually claiming Java EE is "not relevant" because it does not immediately jump on the hype of the day. Things like MicroProfile are great because it allows vendors that embrace Java EE to still take part in the hype bandwagon in their products without destroying one of the core value propositions of standards as a critical insulator against vendor hype. My only current concern with MicroProfile is the potentially needless duplication of effort with what Oracle has announced for an accelerated Java EE 9. I hope the people involved with MicroProfile are keeping a cool head and properly negotiating and collaborating with Oracle, even if it is behind the scenes. Whether we like it or not, any standardization effort without a major vendor like Oracle is weaker, not stronger. It is also a Herculean and perhaps Quixotic task to try to re-create the JCP. Given an opportunity, I know Oracle has the resources to do the right thing for it's business and the community. Like anywhere else, there are plenty of idiots at Oracle. The way to make sure the idiots are not too empowered is by working with the right people still inside Oracle. Why Java EE is important? Java EE is so important it is very difficult to explain its full significance in the span of a single interview. As soon as time allows I plan to blog about this very topic soon. The topic is timely because it is very poorly understood by most developers and that's very dangerous, especially with certain vendors taking a deliberately anti-Java EE stance to advance their own proprietary business agendas - especially on the cloud. The most obvious critical function for Java EE is that it is the only open standard we have for server-side Java. That's been the case for a very long time and hopefully will remain the case for many more years. Without Java EE you have two very bad possibilities - one far worse than the other. The lesser of the two evils is a bunch of competitors that don't really collaborate and have basically incompatible products. In such a scenario developers are basically locked into a given vendor. If that vendor turns out to be the wrong choice for any reason you have to pay a very high cost of porting all the APIs your application uses. By far the most terrible situation is that the entire server-side Java ecosystem is left to the mercy of a single monopoly vendor with no viable competition. All this is even worse on the cloud since you are locked in not just at the API level but also at the infrastructure level. By contrast what Java EE enables is a set of uniform APIs that are shared across vendors and implementations. Vendors can effectively compete on implementations, quality of service, price and extensions. Developers are far freer to choose between vendors at will. This is the model that has enabled a robust server-side Java ecosystem for a long time. Developers should be genuinely frightened of what will happen to Java without an important competitive safeguard like Java EE in place. What is your opinion about JCP? I have worked inside the JCP for a very long time and honestly have only good things to say about it. I felt I had a real impact, people that really care collaborate openly on the expert groups and the rules that govern the JCP makes sure everything happens in an open, transparent way. This is in sharp contrast to open source projects I have seen. Such projects are open in name but in reality are completely controlled by a small set of committers (often even just a single dictatorial committer). By far the biggest problem with the JCP that I have seen is that not enough developers take the time to participate or care. That is not by any means to say that the JCP is perfect (let's face it - nothing in real life is). Oracle definitely needs to open up more and relinquish more control of the JCP and Java. Participating in the JCP and implementing Java standards needs to be easier. The only way any of this will happen is by participating and working with Oracle. Having a more open and vendor neutral Java is in the interest of every developer. It is worth the effort and worth trying. Oracle announced at JavaOne releases of Java EE 8 and Java EE 9 for the next two years. Did the announcement surprised you? The fact that Oracle would be forced to recommit to Java EE does not surprise me at all. The underlying long-term fundamental financial factors really made what Oracle had been doing for a few months quite mindless. It is the result of the over-empowered idiots at Oracle that I alluded to earlier. Hopefully these people have now learned their lesson and the right people inside Oracle have been empowered to do the right thing for the community and Oracle's business. What surprised me is the speed at which we were able to get Oracle to recommit. The problem with idiots is that it is hard to get them to admit they were wrong. It is possible these people were side-lined when decisions at Oracle were corrected once the right people with adequate authority figured out what was going on. How Java EE 8 is doing? What is the progress? At the moment Java EE 8 is looking quite good. Although we have not yet formally updated our public tracking data, anecdotally it looks like there is a significant up-tick in overall activity from Oracle. It may even be possible Java EE 8 will be delivered sooner than Oracle has promised. I think this is the right point to forgive Oracle's past mistakes and refocus on what they are doing right and can do right as the Java steward. That does not mean of course that we do not keep our ears and eyes open. Can you share any resources (blogs, etc feel free to promote yourself) with us? The best thing developers can do is stay tuned to the Java EE Guardian Twitter account and Google Group. Those are our main open coordination mechanisms. We need everyone's help to keep moving Java EE forward. No support is too big or too small. As we have shown already, the grassroots community working together can achieve remarkable things vendors can't even begin to imagine. Together humble server-side Java developers can ensure their interests are preserved above all. Reza, thank you for the interview! Real World Java EE Workshops [Airport Munich]> [Less]
Posted about 1 month ago
Java 8 comes with the Base64 class which supports Base64 encoding / decoding out-of-the-box: import java.util.Base64; import static org.hamcrest.CoreMatchers.is; import static org.hamcrest.MatcherAssert.assertThat; import org.junit.Test; public ... [More] class Base64Test { @Test public void encodeAndDecode() { final String rawString = "duke"; Base64.Encoder encoder = Base64.getEncoder(); byte[] encodedContent = encoder.encode(rawString.getBytes()); Base64.Decoder decoder = Base64.getDecoder(); byte[] decodedContent = decoder.decode(encodedContent); String decodedString = new String(decodedContent); assertThat(decodedString, is(rawString)); } } See you at Java EE Workshops at Munich Airport, Terminal 2 or Virtual Dedicated Workshops / consulting. Is Munich's airport too far? Learn from home: airhacks.io. Real World Java EE Workshops [Airport Munich]> [Less]
Posted about 1 month ago
I updated the list of my publications [1]. I’ve been astonished, how much articles I wrote beside the articles of this blog during the last few years. Most articles dealing about software development. Some of them describing NetBeans or dedicated features of this great IDE. I hope, I could provide a lot of useful information […]
Posted about 1 month ago
A developer has a favorite programming language: public class Developer { private int age; private String favoriteLanguage; public Developer(int age, String favoriteLanguage) { this.age = age; this.favoriteLanguage = ... [More] favoriteLanguage; } public int getAge() { return age; } public String getFavoriteLanguage() { return favoriteLanguage; } @Override public String toString() { return "Developer{" + "age=" + age + ", favoriteLanguage=" + favoriteLanguage + '}'; } } A team has more than one developers. Now we would like to know which programming languages are used by developers younger than 30. Collectors#partitioningBy expects a Predicate (filter) which "partitions" all developers into two buckets identified by a "boolean": import java.util.Arrays; import java.util.List; import java.util.Map; import java.util.stream.Collectors; import org.junit.Test; public class PartitioningByTest { @Test public void partitionByAge() { List team = Arrays.asList( new Developer(18, "java"), new Developer(20, "java"), new Developer(35, "javascript"), new Developer(50, "javascript"), new Developer(50, "logo")); Map> youngerThan30 = team. stream(). collect(Collectors.partitioningBy(d -> d.getAge() < 30)); System.out.println("Developers younger than thirty are using: " + youngerThan30.get(true).stream(). map(d -> d.getFavoriteLanguage()). collect(Collectors.toSet())); //Output: Developers younger than thirty are using: [java] System.out.println("Developers older than thirty are using: " + youngerThan30.get(false).stream(). map(d -> d.getFavoriteLanguage()). collect(Collectors.toSet())); //Output: Developers older than thirty are using: [logo, javascript] } } Related: Java 8 CompletableFuture Example See you at Java EE Workshops at Munich Airport, Terminal 2 or Virtual Dedicated Workshops / consulting. Is Munich's airport too far? Learn from home: airhacks.io. Real World Java EE Workshops [Airport Munich]> [Less]
Posted about 1 month ago
There are new archetype versions that make it easy to use the native presenters. What are the native presenters? What is a presenter? In DukeScript a presenter is a system that makes sure your Java application finds proper HTML rendering ... [More] environment. By default, when running on desktop, we use and recommend to use JavaFX WebView. However sometimes you don’t want the JavaFX bloat - sometimes you want to render as lightweightly as possible. With DukeScript webkit presenter, this is possible - on Linux and on Mac OS X. The ability is there for a few months, but now there also is a simple way to achieve that with the archetypes version 0.16. Here are the steps based on our command line tutorial: $ mvn archetype:generate \ -DarchetypeGroupId=com.dukescript.archetype \ -DarchetypeArtifactId=knockout4j-archetype \ -DarchetypeVersion=0.16 $ cd to_the_just_created_dir $ mvn install $ mvn -f client exec:exec That gives you the classical JavaFX WebView component. The component uses WebKit, but the rendering often suffers from JavaFX bugs. Moreover DukeScript is the “Lightweight JavaFX” - e.g. it doesn’t require all the JavaFX overhead. To see that with your own eyes, try a different presenter: $ mvn -Pbrowser-presenter -f client exec:exec See the difference? No JavaFX! This is a real browser (or browser component). The actual view differs on your system and configuration (see the README of the presenter project to find out more). The “browser presenter” just starts local HTTP server and let the browser connect to it. That is highly portable, but not as lightweight as it could be. However there is more: if you are on Linux or Mac OS X, you can also try the direct WebKit presenter: $ mvn -Pwebkit-presenter -f client exec:exec On Mac OS X the presenter shall work out of the box. On Linux you may need to install the WebKit component: $ sudo apt-get install libwebkitgtk-3.0-0 In any case you can see as lightweight presenters as you can get: no unnecessary libraries (like JavaFX) - just Java and WebKit connected with the smart glue of DukeScript. You can experiment with these presenters also from the NetBeans IDE. Follow the getting started tutorial and then you can easily invoke the presenters from a popup menu of the client project: Both “lightweight” presenters are released under GPLv3 license. You can play with them as freely as you want. For commercial usage you may want to contact DukeScript and obtain a license. Enjoy Java and WebKit! [Less]
Posted about 1 month ago
A developer has a favorite programming language: public class Developer { private int age; private String favoriteLanguage; public Developer(int age, String favoriteLanguage) { this.age = age; this.favoriteLanguage = ... [More] favoriteLanguage; } public int getAge() { return age; } public String getFavoriteLanguage() { return favoriteLanguage; } @Override public String toString() { return "Developer{" + "age=" + age + ", favoriteLanguage=" + favoriteLanguage + '}'; } } A team has more than one developers. Now we would like to group the developers by their favorite language. Collectors#groupingBy groups classes by properties out-of-the-box: public class GroupingByTest { @Test public void groupByFavoriteLanguage() { List team = Arrays.asList( new Developer(18, "java"), new Developer(20, "java"), new Developer(35, "javascript"), new Developer(50, "javascript"), new Developer(50, "logo")); Map> developersByLanguages = team. stream(). collect(Collectors.groupingBy(Developer::getFavoriteLanguage)); System.out.println(developersByLanguages); /* output: {java=[Developer{age=18, favoriteLanguage=java}, Developer{age=20, favoriteLanguage=java}], logo=[Developer{age=50, favoriteLanguage=logo}], javascript=[Developer{age=35, favoriteLanguage=javascript}, Developer{age=50, favoriteLanguage=javascript}] } */ Map favoriteLanguageByAverageAge = team. stream(). collect(Collectors.groupingBy(Developer::getFavoriteLanguage, Collectors.averagingInt(Developer::getAge))); System.out.println(favoriteLanguageByAverageAge); /* output: {java=19.0, logo=50.0, javascript=42.5} */ } } Related: Java 8 CompletableFuture Example See you at Java EE Workshops at Munich Airport, Terminal 2 or Virtual Dedicated Workshops / consulting. Is Munich's airport too far? Learn from home: airhacks.io. Real World Java EE Workshops [Airport Munich]> [Less]
Posted about 1 month ago
Java is #1 (17.278%, -4.19%), C is #2 (9.349%, -6.69%) and Go jumps from #54 to #13 (2.325%, +2.16%). [Source: TIOBE Index for January] See you at Java EE Workshops at Munich Airport, Terminal 2 or Virtual Dedicated Workshops / consulting. Is ... [More] Munich's airport too far? Learn from home: airhacks.io. Real World Java EE Workshops [Airport Munich]> [Less]
Posted about 1 month ago
The 1.2017 airhacks.tv was the most popular ever. 212 live viewers attended the 34th airhacks.tv with 20+ topics covered: Still not everything crystal clear? Start asking now: https://gist.github.com/AdamBien/4791c4a5e8f06b0b8772ab6df6772001 ... [More] See you at Java EE Workshops at Munich Airport, Terminal 2 or Virtual Dedicated Workshops / consulting. Is Munich's airport too far? Learn from home: airhacks.io. Real World Java EE Workshops [Airport Munich]> [Less]
Posted about 1 month ago
In Dutch they say, "Nieuwe kansen, nieuwe prijzen", at the start of the latest installment of a game show, lottery, etc. Well, each new year offers new opportunities, with new rewards, and here we are in 2017. I haven't blogged for a while, simply ... [More] because I've been too busy to do so. Oracle JET is taking up all my time. I've traveled a lot over the past months and that will continue, the first half of the year is almost completely booked full already. At the same time, there's NetBeans IDE or, should I say, "Apache NetBeans (incubating)", which is moving along really well. By that I mean everything in every sense, in that context, from the Apache process, to its continued development by Oracle engineers focused on supporting Java 9, to my continual promotion of it via demonstrations of how to use Oracle JET, to all kinds of dependencies that multiple large organizations have both on NetBeans as a development tool, tooling platform, and application framework. Oracle JET I must confess I'm really excited about Oracle JET, for being an open source, free, and library-based JavaScript toolkit. And, no, I'm not excited about just about everything in the world (you could not, for example, get me to promote vacuum cleaners; then again, on the other hand, if it were to be a really effective vacuum cleaner that was simply awesome and somehow open source, ok, well, never mind, I'd promote your open source vacuum cleaner and probably even for free) or even everything that my employer wants me to be excited about, i.e., there are enough things my employer has suggested I promote that I feel really lukewarm about and that didn't excite me enough to spend time understanding and promoting, simply because of not completely connecting to my areas of interest, etc. That's also something that's underhighlighted about Oracle as a whole—it is simply such a massive ecosystem of products that once you're connected to a part of it, you really do have a lifetime's worth of interesting work ahead of you. Oracle provides a lot of opportunity for learning and meaningfulness in that sense. Java Desktop So. Where does that leave my erstwhile enthusiasm for the Java desktop? Now that I'm a fullblown JavaScript enthusiast, spreading the gospel of browser-oriented development, have I simply dumped my many years of advocacy of the Java desktop?No, not at all. What I have done over the years is very simple and easy to understand—I have advocated tools and technologies for industrial application development. As opposed to what? Well, as opposed to game development, for example, which I've always considered a bit, well, trivial. I've always found it most interesting to focus on development that means something real, that makes a difference, whatever those phrases mean, as opposed to those that simply seek to entertain or that do little more than help fill time, though I don't want to necessarily pass moral judgement here either, since a lot of really skilled and artistic work is done in those areas, of course, at the same time. In general, I definitely prefer the complexities of solving problems for applications targeted for the back office, or behind the firewall, or in secure areas, over those targeted at non-technical end users.What does that mean, concretely, in terms of what I find meaningful, i.e., industrial application development? I have, and continue to do so, promoted the open source tools and technologies that, in my humble opinion, make sense when you're creating large enterprise solutions. Are you creating large applications in the areas of finance, human resources, logistics, and the like? Well, then, moving your data to "the Cloud" and your user interface to the browser, whether on mobile or desktop, makes perfect sense. (And the Oracle Cloud is truly comprehensive and stable, with a large ecosystem of knowledgeable experts and enthusiastic partners to help you. I know this, since I have interacted with many of them directly and personally over the past months.) Are you, on the other hand, creating large applications in the areas of bioinformatics, aerospace, and defense, where you want to make maximum use of desktop resources and graphic visualization and you have a lot of in-house Java desktop experience while the volatility of the JavaScript ecosystem is a real blocker for migration to the browser? Well, great, in that case, the Java desktop is perfect and you clearly need a lot more than Java toolkits such as JavaFX or Java Swing—you also need an application framework, module system, windowing/docking framework, and so on. In fact, you need the NetBeans Platform. Wait, am I saying that there's a place for both JavaScript and Java, for both browser and desktop? Yes, of course there is—"the right tool for the right job" is simply the best approach to anything. Therefore, my argument is that you shouldn't be "religious" about your choices, of course... Tools ...except for your tools. :-) Ultimately, you need a comprehensive and stable development environment to create your applications, regardless of where they are to be deployed. The best thing to do is to use open source tools and technologies, uniquely provided by NetBeans IDE, which is in the process of becoming an Apache project, which means that you can participate in its development process and roadmap far more than any other development tool in the history of development tools. Hurray, 2017 is going to be great and is filled with opportunities that all make sense and all have a logical place in unlocking data and turning it into actionable information that makes a real difference in people's lives.  [Less]
Posted about 1 month ago
My 2017 predictions: Back to insourcing: If you are pragmatic, software development is easier than ever. The only challenge is the deep understanding of the domain concepts and requirements (=the product thinking). Companies starting ... [More] to realize that if they outsource their core expertise, nothing remains left. They become a "gray mass" indistinguishable from their competition. I'm also expecting increased investments in internal teams. Java is fast, productive, mature and extremely popular. Therefore the year 2017 is going to be full of "Bashing On Java" articles like e.g. "Oracle finally targets Java non-payers" Writing negative articles about Java draws lot of attention and so traffic. Publishers are under pressure -- writing blog posts, articles and content targeted against the Java programming language increases traffic and is good for business. I expect to see the first failures of microservice projects accompanied by some negative press. There are many projects out there with trivial business logic deployed on an unnecessary high amount of independent deployment units. I would expect some backlash against Fat WARs, Ueber JARs etc. I don't see any benefits, just disadvantages. Mixing a big amount of barely changing dependencies at each build, with tiny amount of frequently changing business logic sounds like Cargo Cult to me. Finally the microservice movement increased the need for monitoring. I expect the first "data overflow exceptions". I observe the tendency to gather all possible metrics without thinking about their meaning. It reminds me of past projects which generated gigabytes of logs with only a little amount of contained information. Demise of JavaScript frameworks: JavaScript and HTML 5 standards are become more and more powerful. You can achieve a lot without any external dependencies. One could say: JavaScript development becomes more and more similar to Java EE. Projects become more pragmatic with more focus on users and less on fancy, but optional frameworks. "Brick and mortar" companies are going to recognize, that they requirements and scale differ from Netfix, Twitter, Facebook and Co. What works great for Netflix, might be an overhead for a regional company. JDK 9 is scheduled to 23rd March 2017. Particularly "senior" developers and architects are going to get really excited about Jigsaw. This will lead to proliferation of unnecessary modules. On the other hand Java 9 becomes even more interesting for microservice deployments. Companies will start to recognize, that Angular 2 is more similar to React, than to Angular 1. "Inclouding" :-) Hardware becomes less and less expensive and cloud management software becomes also available on premise. I'm expecting a slow trend towards private clouds. Java EE projects become more pragmatic. Already in 2016 it was relatively easy for me to let projects delete unnecessary patterns, indirections and modules. There are no arguments left against "Thin WARs", fast deployments, no setup and focus on the actual requirements See you at Java EE Workshops at Munich Airport, Terminal 2 or Virtual Dedicated Workshops / consulting. Is Munich's airport too far? Learn from home: airhacks.io. Real World Java EE Workshops [Airport Munich]> [Less]