Why Developers Should Care About CMS

See the original posting on DZone Python

As developers, we’ve got a strong handle on how to manage and deploy our code assets. Yet every one of us, at some point in our application build has said, “What about this text? What about these images? Where do these belong?” That’s pretty universal. Nearly every single application today has content in it. Be it a web app or a native app; it’s full of strings, images, icons, media, and other classes of content.

This content doesn’t really belong in our code base — because it’s not code. These non-code assets make us as developers pretty uneasy. We know that at some point a business user is going to ask us to make a change to one of those strings and we’re going to spend hours of build and deploy cycles to handle a 30-second code change. We know that at some point we’re going to need to translate that content. We know at some point we’re going to replace this UI with another one. We know all these things  — and we know leaving that content, even if it’s abstracted into a string table or a resource bundle, is going to come back to haunt us; no matter the abstraction: it’s part of the build, developers need to update it. Developers and systems folks need to deploy it.  

OpenTracing JAX-RS Instrumentation

See the original posting on DZone Python

In the previous demo, we demonstrated how to instrument a Spring Boot app using OpenTracing, a vendor-neutral standard for distributed tracing. In this article, we are going to instrument a Java API for RESTful Web Services (JAX-RS), and show you how to trace the business layer and add custom data to the trace.

Demo Application

Creating a JAX-RS app from scratch can be a time-consuming task, therefore, in this case, we are going to use Wildfly Swarm’s app generator. Select JAX-RS and CDI dependencies and hit the generate button.

JMiddleWay for Web Applications

See the original posting on DZone Python

The Why

My intention is to provide a middleware framework which can be used to add REST APIs without worrying about involving several technologies and their various versions.  The user can define the architecture with JMiddleWay as the middleman between its UI and back-end services. You can choose the UI and back-end technologies of your choice and add the necessary code to JMiddleWay to integrate with your architecture.

The What

The best way to get to know the technology is to build a prototype with it. And that’s exactly what I did and what I will present in this post. JMiddleWay lets you create your own middleware quickly and add required REST APIs easily. You can plug in your authentication module and configure how and where your middleware should log. Though fairly simple, the example highlights the most common annotations you’ll need to build your own REST API.

On Helping IBM Offer Support for Node.js

See the original posting on DZone Python

Rocket Software has been working with IBM for more than 25 years, so when IBM announced plans to offer Node.js support for IBM i, the Rocket team immediately began rewriting our ALM Ops Portal application to transform it into a Node.js application. I wouldn’t be surprised if Rocket was the first company to do that – but we definitely won’t be the last!

XMLSERVICE is a service that runs on IBM i, and it allows users to run both SQL queries and native commands and programs. Users activate XMLSERVICE by sending it an XML document describing the command, program, or SQL query they wish to run. The results are returned in an XML document and can be invoked either through DB2 stored procedures or a REST interface.

Introduction to D3.js

See the original posting on DZone Python

D3.js is a JavaScript library used to render amazing charts based on data. It can be used to visualize stats and find patterns, show the comparison between two or more time-series data, draw the data in real-time as it happens (for example, data generated by various sensors or internet traffic), and even create cool dynamic art on web pages. How you use this library just depends on one’s imagination. To view a huge catalog of charts drawn by this library one can visit the official website of D3.js.

D3 is not a pre-built library composed of particular charts; instead, it’s a tool that can be used to create various charts — any chart you can envision). It uses SVG (Scalable Vector Graphics) to draw the charts along with HTML and CSS. With D3 a dataset of tens of thousands of objects can be represented graphically easily. If you design your custom chart and you want to use a module in other charts then you can also create a module to reuse in other projects.

Web Scraping in Java Using jsoup and OkHttp

See the original posting on DZone Python

Web scraping is a fundamental skill that is extremely useful for data collection and automating tasks. The following examples will show how we scrape sites such as wrapbootstrap and themeforest to populate the HTML/CSS Theme Templates page. We will be using jsoup for DOM parsing and OkHttp for HTTP. Although jsoup is capable of handling HTTP for us we prefer to stick with OkHttp in case we need anything more complex than a simple GET request, such as special headers and cookies. Why learn two libraries when one will do?


We like to start simple, so we are only gathering four fields’ title, URL, image URL, and the number of downloads, if available.

Sass Tutorial: A First Look at Writing More Maintainable Styles

See the original posting on DZone Python

Learning how to use HTML, CSS, and the basics of JavaScript can be fairly simple. Almost anyone can produce a small, functional website providing you know how to use Google and have some patience.

However, if you bump the scale of that website up about 10x, add in another developer and create multiple variants – each with their own unique functionality and styles – your code is going to become a hassle to maintain and new hires are going to have a nightmare trying to figure out your codebase. 

Will JavaScript Pass the Test of Time?

See the original posting on DZone Python

For the last four years, I have been working on projects that employ a JavaScript-based client framework and leverage a RESTful API on the backend. With the client frameworks primarily centered around AngularJS and ReactJS, the transition away from MVC-based frameworks (Struts, Spring MVC, and Seam) was a significant change for me. Based upon the challenges and benefits with the current state of JavaScript, I began to wonder if these frameworks will pass the test of time. Then, I decided to take a step back and ask the bigger question, "will JavaScript pass the test of time?"

The Challenges

When I first began using JavaScript and the AngularJS framework, I found some challenges on my journey.

Real-World Angular Series, Part 1a: MEAN Setup and Angular Architecture

See the original posting on DZone Python

Introduction: What We’ll Build

This tutorial series will teach you how to build a real-world MEAN stack application, covering everything from ideation and data modeling to production deployment.

We will not be building your run-of-the-mill to-do app. In order to learn the ins and outs of production-level JavaScript web application development, we’ll build an app to create and RSVP to events. With our RSVP app, an administrator will be able to create, update, and delete events. Other users will then be able to RSVP to events. Our RSVP app’s features will include the following (and more):

How to Write a Lock-Free Queue

See the original posting on DZone Python

Update: I did mention that lock free data structures are really hard to write, it looks like there might be some issues that haven’t been addressed in the implementation of this LF Queue that we’re referencing. The rest of the analysis is still valid and hopefully useful to you, just know there’s actually more that needs to be done, don’t try to use that code for a mission critical application out of the box.

It’s said that locks keep honest people honest. In programming, locks keep multi-threaded programs honest by ensuring only one thread can access a resource at a time. Why would we want to get rid of locks then? In this post, I’ll revisit the queue that I wrote in C and instead look at a “lockless” queue implementation. We’ll talk about atomicity and the tradeoffs when choosing one strategy or the other, and end with some ways to write “lock-free” Ruby code. Prepare to unlock your imagination!

Looking at Applications Differently

See the original posting on DZone Python

Spending time with a user experience (UX) designer earlier this year, our discussion focused on a different way of looking at applications. My goal with this article is to share these thoughts in order to provide an alternative view for your new application design or conversion.

The Traditional Application

In the past, one of the initial design tactics for a new or converted application is to gain an understanding of the data model that will be utilized. There is always an understanding of what the application will be required to do, but understanding what needs to be ultimately persisted, and the underlying structure, are typical early design topics.

Exceptionally Bad Exception Abuse

See the original posting on DZone Python

I was reading Nick Hodges’ Coding in Delphi again last night (insomnia). In chapter 1 on Exception Handling, he opens talking about how not to use exceptions. It got me thinking about some of the atrocious exception usages I’ve seen. I thought I would share a few examples beyond the usual exception sins.

The Try/Except/Raise Pattern

The documentation on the Try/Except pattern says that all the code after the Except block gets ran because the exception is handled. Additionally, you can call Raise during the handler to send the exception further up the call stack.

Pure CSS3 LavaLamp Menu

See the original posting on DZone Python

I think that you have already seen various animated menus with the LavaLamp effect (based on jQuery plugin). Today I would like to tell you how to repeat the same behavior only with CSS3 (without any JavaScript). I had to use CSS3 transitions in our menu (to animate elements). So, if you are ready, let’s start.

Here are samples and downloadable package:

1 2 3 4 5 78