Janik von Rotz

Build a Java 3-tier application from scratch – Part 3: Object-relational mapping

Welcome to third part of my 3-tier application tutorial. Within this and the next part we are going to develope simple webservice that communicates with the database and maps Java objects to data tables. We will create a controller that communicates with our MySQL database using the EclipseLink ORM to abstract this process.

Here’s a picture of what we want to achieve. A simple webservice that’s serves depending on the url an array of json data.

Java 3-tier webservice

Read More...



Build a Java 3-tier application from scratch - Part 2: Model setup

Last time we’ve set up our basic project structure with gradle. This time we are going to create the models aka our Java classes. Below is uml diagram showing all classes, interfaces and their relationship.

3-tier java application Classmodel

Read More...



O3M 60 - Nooice

Nooice means nice noise. That’s all about it.

Read More...



Create WordPress admin user with sql only

If you don’t have access to you WordPress website anymore, but still can update the MySQL database. You can easily add a new admin user with this sql script:

USE <database>;
 
SET @username = '<username>';
SET @password = MD5('<password>');
SET @fullname = '<Firstname Lastname>';
SET @email = '<login@example.com>';
SET @url = '<http://example.com/>';
 
INSERT INTO `wp_users` (`user_login`, `user_pass`, `user_nicename`, `user_email`, `user_url`, `user_registered`, `user_status`, `display_name`) VALUES (@username, @password, @fullname, @email, @url, NOW(), '0', @fullname);
 
SET @userid = LAST_INSERT_ID();
INSERT INTO `wp_usermeta` (`user_id`, `meta_key`, `meta_value`) VALUES (@userid, 'wp_capabilities', 'a:1:{s:13:"administrator";s:1:"1";}');
INSERT INTO `wp_usermeta` (`user_id`, `meta_key`, `meta_value`) VALUES (@userid, 'wp_user_level', '10');

Get the latest version of this snippet here: https://gist.github.com/25d9f243fc20532cb1b5

Read More...



free SSL for everybody

Let’s Encrypt is the latest initiative by the Internet Security Research Group (ISRG). Their goal is simple, every site on the internet has to be SSL secured.

They want to achieve that by serving an open certificate authority (CA) and also provide a tool to set up a secured site the easiest way possible.

And now the big deal about this, their service is free of charge!

If this is really a thing, it will be a disaster for the SSL economy. As you might know SSL certificates are everything else than cheap. So good luck to every company that relays on selling SSL certificates as their core competence.

Read More...



O3M 59 - Shut up and Chill

Another week of hard work awaits you. If you’re stressed and loose track of your daily business, try to take some time out and listen to this relaxing playlist.

Read More...



Build a Java 3-tier application from scratch - Part 1: Introduction and project setup

Welcome to my first post of the Java 3-tier application tutorial. In this tutorial I will tell show how you can develope a Model-View-Controller based Java desktop and server application using the latest tools and frameworks.

Read More...



Michio Kaku on solar revolution

For those who don’t know him, Michio Kaku is great speaker and scientist. Via http://bigthink.com/ he shares his big ideas about how things works and how the future looks like. Recently I really enjoyed his thoughts about the solar power revolution and it’s cause. You should definitely check it out!

Read More...



O3M 58 - Soulero

Have a nice weekend with Soulero!

Read More...



Superb Java development with Gradle, Hibernate, FlywayDB, JavaFX and Eclipse – Part 2

As promised here’s the sequel to my last tutorial: Part 1

This time we create a basic rich application with JavaFX. It will be quite simple, but still a good example to show how you can structure a complex project according to MVC.

Read More...



29