<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Javaee on Micha Kops&#39; Tech Notes</title>
    <link>https://www.hascode.com/tags/javaee/</link>
    <description>Recent content in Javaee on Micha Kops&#39; Tech Notes</description>
    <generator>Hugo -- 0.147.8</generator>
    <language>en</language>
    <copyright>Copyright © 2010 - 2025 Micha Kops. #213243b1d6e8932079e09227d3f3ed0c806cd0c9</copyright>
    <lastBuildDate>Sun, 18 Jan 2015 00:00:00 +0100</lastBuildDate>
    <atom:link href="https://www.hascode.com/tags/javaee/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Performance Testing a Multiuser Web Application with JMeter and Maven</title>
      <link>https://www.hascode.com/performance-testing-a-multiuser-web-application-with-jmeter-and-maven/</link>
      <pubDate>Sun, 18 Jan 2015 00:00:00 +0100</pubDate>
      <guid>https://www.hascode.com/performance-testing-a-multiuser-web-application-with-jmeter-and-maven/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;When there is the need to create load tests or performance tests for an application, Apache JMeter is a handy tool and set up with ease.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following short tutorial I’d like to demonstrate how to configure JMeter to log into a Java EE web application with multiple users specified in a CSV file, how to generate some basic reports and how to integrate JMeter into a mavenized build using the JMeter Maven Plugin.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Marrying Java EE and BDD with Cucumber, Arquillian and Cukespace</title>
      <link>https://www.hascode.com/marrying-java-ee-and-bdd-with-cucumber-arquillian-and-cukespace/</link>
      <pubDate>Wed, 07 Jan 2015 00:00:00 +0100</pubDate>
      <guid>https://www.hascode.com/marrying-java-ee-and-bdd-with-cucumber-arquillian-and-cukespace/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Having written about the basics of using Cucumber in a Java project in my last blog article, I now would like to demonstrate how to use a similar setup in a Java EE web project with Arquillian and the Cukespace library.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following tutorial, we’re going to write a full Java EE web application and add BDD-style tests to the project so that we’re able to test our business layer on the one hand and the user interface on the other hand using Arquillian Drone and Selenium.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Java EE: Setting up and Testing Form-Based JDBC Authentication with Arquillian and Maven</title>
      <link>https://www.hascode.com/java-ee-setting-up-and-testing-form-based-jdbc-authentication-with-arquillian-and-maven/</link>
      <pubDate>Sun, 21 Dec 2014 00:00:00 +0100</pubDate>
      <guid>https://www.hascode.com/java-ee-setting-up-and-testing-form-based-jdbc-authentication-with-arquillian-and-maven/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Especially when it comes to testing, setting up a decent environment for a secured Java EE web application isn’t always an easy thing to do.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following tutorial I’d like to demonstrate how to create a secured web application using form-based authentication and a JDBC realm to fetch users and roles and how to run the application in an embedded container for testing and development.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Additionally I’d like to show how to write and run integration tests to verify the security setup using a setup of Maven, Embedded GlassFish, Arquillian, jUnit and rest-assured.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Creating different Websocket Chat Clients in Java</title>
      <link>https://www.hascode.com/creating-different-websocket-chat-clients-in-java/</link>
      <pubDate>Sun, 09 Nov 2014 00:00:00 +0100</pubDate>
      <guid>https://www.hascode.com/creating-different-websocket-chat-clients-in-java/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Having written two articles about different websocket based chat server implementations in Java, I was recently asked how an implementation of the client side would look like in Java.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;That’s why I added this article to demonstrate how to create a websocket chat client applications within a few steps with the Java API for Websocket.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following tutorial, we’re going to write a text-based chat client for the console first and afterwards we’re going to program a chat client with a graphical user interface, implemented in JavaFX.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>JAX-RS Server API Snippets</title>
      <link>https://www.hascode.com/jax-rs-server-api-snippets/</link>
      <pubDate>Sun, 28 Sep 2014 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/jax-rs-server-api-snippets/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Because a lot of my current projects are using JAX-RS in different versions I’d like to write down and share some frequently used snippets for implementing RESTful web-services with the JAX-RS specification here.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&#34;sect1&#34;&gt;
&lt;h2 id=&#34;_using_regex_in_path_expressions&#34;&gt;Using RegEx in Path Expressions&lt;/h2&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Sometimes we need to extract multiple parameters from a path expression e.g. in the following example where year, month and day are fragments if the path.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;listingblock&#34;&gt;
&lt;div class=&#34;content&#34;&gt;
&lt;pre class=&#34;highlight&#34;&gt;&lt;code class=&#34;language-java&#34; data-lang=&#34;java&#34;&gt;@GET
@Path(&amp;#34;/orders/{year:\\d{4}}-{month:\\d{2}}-{day:\\d{2}}&amp;#34;)
@Produces(MediaType.TEXT_PLAIN)
public Response getOrders(@PathParam(&amp;#34;year&amp;#34;) final int year, @PathParam(&amp;#34;month&amp;#34;) final int month, @PathParam(&amp;#34;day&amp;#34;) final int day) {
	return Response.ok(&amp;#34;Year: &amp;#34; + year + &amp;#34;, month: &amp;#34; + month + &amp;#34;, day: &amp;#34; + day).build();
}&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Java EE 7 JMX Reports with Yammer Metrics</title>
      <link>https://www.hascode.com/java-ee-7-jmx-reports-with-yammer-metrics/</link>
      <pubDate>Tue, 26 Aug 2014 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/java-ee-7-jmx-reports-with-yammer-metrics/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;There are several ways to aggregate and report application performance indicators in a Java application. One common way here is to use Java Management Extensions (JMX) and MBeans.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;The Yammer Metrics Library eases this task for us and simplifies the aggregation of different reports.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following tutorial, we’re going to set up a full Java EE 7 web application by the help of Maven archetypes and we’re running the application on WildFly application server that is downloaded and configured completely by the WildFly Maven Plugin.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Java EE 7 Database Migrations with Liquibase and WildFly</title>
      <link>https://www.hascode.com/java-ee-7-database-migrations-with-liquibase-and-wildfly/</link>
      <pubDate>Thu, 31 Jul 2014 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/java-ee-7-database-migrations-with-liquibase-and-wildfly/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;I have written about other database migration frameworks before but in this article I’d like to cover the Liquibase framework in combination with WildFly as Java EE 7 compatible application server.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following tutorial, we’re going to write a full Java EE 7 book store application with a few steps and with Liquibase on board to create the database structure and insert example data into the database.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Thanks to the WildFly Maven Plug-in we even do not need to download and configure the application server but let Maven and the plug-in do the work for us.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Java EE: Logging User Interaction the Aspect-Oriented Way using Interceptors</title>
      <link>https://www.hascode.com/java-ee-logging-user-interaction-the-aspect-oriented-way-using-interceptors/</link>
      <pubDate>Mon, 26 May 2014 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/java-ee-logging-user-interaction-the-aspect-oriented-way-using-interceptors/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Using dependency injection and aspect-oriented mechanisms like interceptors allow us to separate cross-cutting-concerns in our Java enterprise application, to control global aspects of our application and to avoid boilerplate code.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following short tutorial we’re going to create an aspect-oriented logger to protocol the initiating user, class and method called and the parameters passed to the method and finally we’re adding this interceptor to a sample RESTful web-service by adding a simple annotation.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Creating a Chat Application using Java EE 7, Websockets and GlassFish 4</title>
      <link>https://www.hascode.com/creating-a-chat-application-using-java-ee-7-websockets-and-glassfish-4/</link>
      <pubDate>Tue, 13 Aug 2013 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/creating-a-chat-application-using-java-ee-7-websockets-and-glassfish-4/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Java EE 7 is out now and so I was curious to play around with the new specifications and APIs from in this technology stack.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;That’s why I didn’t hesitate to add yet another websocket-chat tutorial to the existing ones on the internet in favour of gathering some experience with this technology and a possible integration using a GlassFish 4 server, the new Java API for JSON Processing for data serialization combined with custom websocket encoders/decoders and finally adding some Bootstrap and jQuery on the client side.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Handling Feature Flags in a Java EE Application using Togglz</title>
      <link>https://www.hascode.com/handling-feature-flags-in-a-java-ee-application-using-togglz/</link>
      <pubDate>Wed, 26 Jun 2013 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/handling-feature-flags-in-a-java-ee-application-using-togglz/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Feature flags are a common technique, often combined with continuous deployment and delivery and they allow us to rollback a specific feature, to create A/B tests or to rollout a specific feature for a specific test group, a specific amount of users or dedicated systems.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following short examples I’d like you to demonstrate how easy it is to implement feature flags with the Togglz framework with a few steps in a Java EE environment.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Easy Database Migrations using Flyway, Java EE 6 and GlassFish</title>
      <link>https://www.hascode.com/easy-database-migrations-using-flyway-java-ee-6-and-glassfish/</link>
      <pubDate>Sun, 28 Apr 2013 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/easy-database-migrations-using-flyway-java-ee-6-and-glassfish/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Database migrations often are a necessity in the application development and maintenance life-cycle.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Whenever we need to apply changes to the database structure, insert new data fragments and in doing so want to be sure that this all happens with some control and versioning.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;The following tutorial shows how implement this for a simple Java EE 6 web application to be run on a GlassFish application server in a few quick steps using the Flyway framework, an eager initialized Singleton EJB and some Maven wiring.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Task Scheduling in Java EE 6 on GlassFish using the Timer Service</title>
      <link>https://www.hascode.com/task-scheduling-in-java-ee-6-on-glassfish-using-the-timer-service/</link>
      <pubDate>Fri, 22 Jun 2012 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/task-scheduling-in-java-ee-6-on-glassfish-using-the-timer-service/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Creating cronjobs or scheduled service executions is made really easy in Java EE 6. Scheduled tasks may be created in a programmatic style or simply by adding some annotations to an EJB.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following tutorial we’re creating some simple scheduled tasks and let them run on an embedded GlassFish instance using the Maven Embedded GlassFish plugin..&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&#34;sect1&#34;&gt;
&lt;h2 id=&#34;_java_ee_6_maven_project_from_archetype&#34;&gt;Java EE 6 Maven Project from Archetype&lt;/h2&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;First of all we’re creating a new maven-ized project using one of the appropriate jee6 Maven archetypes&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Java EE 6 Development using the Maven Embedded GlassFish Plugin</title>
      <link>https://www.hascode.com/java-ee-6-development-using-the-maven-embedded-glassfish-plugin/</link>
      <pubDate>Tue, 20 Sep 2011 00:00:00 +0200</pubDate>
      <guid>https://www.hascode.com/java-ee-6-development-using-the-maven-embedded-glassfish-plugin/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Today we’re going to take a look at the Maven Embedded GlassFish Plugin and how it allows us quick creation of GlassFish server instances in no time and Java EE 6 application deployment.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;imageblock&#34;&gt;
&lt;div class=&#34;content&#34;&gt;
&lt;img src=&#34;logo.png&#34; alt=&#34;logo&#34;/&gt;
&lt;/div&gt;
&lt;div class=&#34;title&#34;&gt;Figure 1. GlassFish + Maven&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;With a few lines of configuration in your Maven’s pom.xml we’ve got a running GlassFish instance and are able to redeploy our application fast by pressing enter in our console.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In the following tutorial we’re going to build a Java EE 6 Web Application with a stateless session bean and a web servlet and finally deploy – and redeploy the application using the Maven GlassFish Plugin.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Creating a sample Java EE 6 Blog Application with JPA, EJB, CDI, JSF and Primefaces on GlassFish</title>
      <link>https://www.hascode.com/creating-a-sample-java-ee-6-blog-application-with-jpa-ejb-cdi-jsf-and-primefaces-on-glassfish/</link>
      <pubDate>Tue, 08 Feb 2011 00:00:00 +0100</pubDate>
      <guid>https://www.hascode.com/creating-a-sample-java-ee-6-blog-application-with-jpa-ejb-cdi-jsf-and-primefaces-on-glassfish/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Java EE 6 is out and it indeed offers an interesting stack of technologies. So in today’s tutorial we are going to build a small sample web application that builds on this stack using Enterprise JavaBeans, Java Persistence API, Bean Validation, CDI and finally Java Server Faces and PrimeFaces.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;The application we’re going to develop is a simple blog app that allows us to create new articles, list them and – finally delete them. We’re also covering some additional topics like JSF navigation, i18n, Ajax-enabled components and the deployment on the GlassFish application server.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Creating a REST Client Step-by-Step using JAX-RS, JAX-B and Jersey</title>
      <link>https://www.hascode.com/creating-a-rest-client-step-by-step-using-jax-rs-jax-b-and-jersey/</link>
      <pubDate>Thu, 25 Nov 2010 00:00:00 +0100</pubDate>
      <guid>https://www.hascode.com/creating-a-rest-client-step-by-step-using-jax-rs-jax-b-and-jersey/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Often in a developer’s life there is a REST service to deal with and nowadays one wants a fast and clean solution to create a client for such a service.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;The following tutorial shows a quick approach using JAX-RS with its reference implementation, Jersey in combination with JAX-B for annotation driven marshalling between XML or JSON structures and our Java-Beans.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&#34;sect1&#34;&gt;
&lt;h2 id=&#34;_prerequisites&#34;&gt;Prerequisites&lt;/h2&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;The following stuff is needed to run the following examples and code samples&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
    <item>
      <title>Using PrimeFaces to pimp up existing Java Server Faces / JSF 2 Applications</title>
      <link>https://www.hascode.com/using-primefaces-to-pimp-up-existing-java-server-faces-/-jsf-2-applications/</link>
      <pubDate>Sun, 14 Nov 2010 00:00:00 +0100</pubDate>
      <guid>https://www.hascode.com/using-primefaces-to-pimp-up-existing-java-server-faces-/-jsf-2-applications/</guid>
      <description>&lt;div id=&#34;preamble&#34;&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;In this tutorial we’re going to modify an existing Java Server Faces / JSF 2 web application by adding rich UI components to the existing layout.&lt;/p&gt;
&lt;/div&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;Our tool of choice here is the PrimeFaces framework. It offers a wide range of interesting, customizable and (several) Ajax-enabled components that blend very well with JSF1+2 and also a solid documentation that allows a quick integration into existing projects.&lt;br/&gt;&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&#34;sect1&#34;&gt;
&lt;h2 id=&#34;_project_setup&#34;&gt;Project setup&lt;/h2&gt;
&lt;div class=&#34;sectionbody&#34;&gt;
&lt;div class=&#34;paragraph&#34;&gt;
&lt;p&gt;For this tutorial we’re going to reuse the web application from my JSF2 Tutorial “&lt;a href=&#34;../java-server-facesjsf-2-tutorial-step-1-project-setup-maven-and-the-first-facelet/&#34;&gt;Java Server Faces/JSF 2 Tutorial – Step 1: Project setup, Maven and the first Facelet&lt;/a&gt;” – the source code is available at &lt;a href=&#34;https://github.com/hascode/hascode-tutorials/src/tip/jsf2-tutorial-part1/&#34;&gt;GitHub.org&lt;/a&gt;.&lt;/p&gt;
&lt;/div&gt;</description>
    </item>
  </channel>
</rss>
