Core Java APIs and programming techniques
Technologies related to Java APIs (application programming interfaces) and JDK (Java Development Kit) form the cornerstone of modern, enterprise-grade software development. Here we explore all the Java features that make the JVM great through programming tutorials, real-world code samples and expert opinions from Java champions.
Top Stories
-
Video
01 May 2024
Java's default constructor tutorial
They say you don't get anything for free, but in the world of software development, Java developers can use the default constructor without paying any price. Continue Reading
-
Tip
01 May 2024
Use sealed classes in Java to control your inheritance
Need to limit the number of possible subclasses in your codebase? Here comes Java's sealed classes to your rescue. Continue Reading
-
Tip
29 Apr 2024
Know how and when to use blockchain vs. distributed ledgers
Blockchain and distributed ledgers are similar but not quite synonymous. Learn their differences and how they are used, including together, for transactions and data storage. Continue Reading
-
Tip
11 Apr 2024
Speed up Python and NumPy by avoiding the conversion tax
Data and memory transfers in Python come with a hidden performance tax. Here's how to use NumPy for optimal performance by avoiding jumps across a hidden line of conversions. Continue Reading
-
Tip
09 Apr 2024
5 code refactoring patterns, with examples
First-time finished code is rarely elegant or maintainable. Refactoring helps keep a growing codebase maintainable and extendable over time -- as long as you know where to stop. Continue Reading
-
Video
09 Apr 2024
Top REST API URL naming convention standards
There is no official REST URL naming standard. However, these 15 RESTful API naming conventions will help you create highly interoperable web services. Continue Reading
-
Blog Post
08 Apr 2024
Worlds toughest core Java interview question
The trickiest Java interview question ever asked? In five words or less, explain the red 'x' the Eclipse IDE displays at the end of the provided Java code snippet. Continue Reading
-
Video
04 Apr 2024
10 constructor types in Java
How many different types of Java constructors could you name? The Java spec names 10. Generic, canonical and anonymous Java constructor types just might be new to you. Continue Reading
-
Video
04 Apr 2024
How Java 17 records work
Devs aren't using Java 17 records nearly enough. With the power to clean up your code and make your apps faster, Java records should be the norm and not the exception. Continue Reading
-
Video
01 Apr 2024
How to use Git's 'set upstream push' command
Need to fix the 'no upstream branch' error message? Then you need to run the 'git set upstream push' command. Here's how. Continue Reading
-
Tutorial
27 Mar 2024
How the saga design pattern in microservices works
When a sequence of steps must be performed to support an operation, the microservices saga design pattern is a perfect fit. Continue Reading
-
Definition
25 Mar 2024
Spring Framework (Spring)
The Spring Framework (Spring) is an open source software development framework that provides infrastructure support for building Java-based applications on any deployment platform. Continue Reading
-
Video
19 Mar 2024
Learn Maven tutorial for beginners
Apache Maven is the Java world's most popular build tool, and if you're a Java developer, it behooves you to learn it. This Maven tutorial will make you an expert in a hurry. Continue Reading
-
Video
12 Mar 2024
Full Java constructors tutorial
How well do you know how Java constructors work? This quick Java constructors tutorial teaches you about defaults, overloading, initializing and parameterizing constructors in Java. Continue Reading
-
Definition
05 Mar 2024
EAI (enterprise application integration)
Enterprise application integration (EAI) is the process of connecting an organization's business applications, services, databases and other systems into an integrating framework that facilitates communications and interoperability. Continue Reading
-
Blog Post
04 Mar 2024
Best crash course to learn Jenkins from scratch
Need to learn Jenkins CI fast? This Jenkins tutorial will quickly get you up to speed on how to use the popular CI/CD tool. Continue Reading
-
Blog Post
27 Feb 2024
Brackets vs braces vs parentheses: What's the difference?
Stop using the terms square brackets, round brackets and squiggly brackets. Use the terms braces, brackets and parenthesis instead. Here's the difference between them. Continue Reading
-
Video
22 Feb 2024
Why we use static final in Java for constants
Java doesn't have global constants per se, but it does have static final variables. Here we explore how these two keywords make a variable constant in Java. Continue Reading
-
Definition
15 Feb 2024
event handler
In programming, an event handler is a callback routine that operates asynchronously once an event takes place. Continue Reading
-
Blog Post
14 Feb 2024
String to long in Java
The correct way to convert a String to long in Java is with the parseLong method of the wrapper class. The constructor conversion approach is deprecated! Use parseLong instead. Continue Reading
-
Blog Post
02 Feb 2024
How to unstage a file in Git
Want to unstage a file in Git? Use the restore command. Other options to have Git remove a file from the staging index have unintended consequences you'd really rather avoid. Continue Reading
-
Blog Post
01 Feb 2024
Why the Java const keyword is unimplemented
Why is the const keyword in Java not implemented? It's part of the language, but it can't be used to make a variable constant. Here's why const is included in Java, and why Java's const keyword is ... Continue Reading
-
Tip
30 Jan 2024
2024 technology predictions around AI, Mojo and blockchain
Blockchain, AI, anti-competitive activity and the new programming language Mojo are sure to fill the headlines in 2024. Continue Reading
-
Tip
23 Jan 2024
Debunking 5 blockchain myths and misconceptions
There's more to blockchain development than what you hear from the crypto community. Here, we debunk five common blockchain myths. Continue Reading
-
Blog Post
18 Jan 2024
Finding duplicate entries in a list in Python
A common problem in computing is to find out if a list contains duplicate entries. It's also a good subject to explore various ways to solve a problem. In this case, we will see the performance ... Continue Reading
-
Blog Post
17 Jan 2024
Solve the prefix sum problem with SIMDs and Vector APIs
The incubating Java Vector API gives software developers access to fast and efficient SIMD operations. Here's an example of how to solve the prefix sum problem with SIMDs and Vectors. Continue Reading
-
Blog Post
11 Jan 2024
How to download and install Java 21
2024 is a great time to start working with Java, because 2023's Java 21 release has some amazing new features. Here's how to quickly download and install the Java 21 JDK. Continue Reading
-
Blog Post
09 Jan 2024
Install the Eclipse IDE on Windows video tutorial
Need to install the Eclipse IDE on Windows? This quick video tutorial shows you how to install Eclipse and build your very first Java application in the popular, open-source IDE. Continue Reading
-
Blog Post
09 Jan 2024
Find duplicates in a List in Java
Need to dedupe a Java list? Here are 5 simple ways to remove duplicates from a List in Java. Continue Reading
-
Blog Post
08 Jan 2024
The prefix sum array problem
The prefix sum problem is often used to test a developer's mettle. Here's a simple solution to the prefix sum problem in Java that uses loops, arrays and basic Java syntax. Continue Reading
-
Tip
04 Jan 2024
How the event sourcing design pattern works, with example
Learn how to control state changes as immutable events through the event sourcing model. Continue Reading
-
Tip
28 Dec 2023
The benefits of using compiled regex in Python and Java
Whether you're programming in Java or Python, compiled regex can significantly speed up your text manipulation routines. Continue Reading
-
Tip
27 Dec 2023
Shorter code, fewer bugs: Python's syntax is its saving grace
Is shorter code too dense and hard to parse, or is it inherently more efficient and secure? Here's why Python's compact syntax tends toward less buggy code. Continue Reading
-
Blog Post
27 Dec 2023
Remove duplicates from a Java List
Deduping is a common part of data cleansing. Here are four simple ways to remove duplicates from lists in Java. Continue Reading
-
Feature
19 Dec 2023
The 5 SOLID principles of object-oriented design explained
In this primer on SOLID, we'll examine the five principles this development ideology embodies, the practices they encourage and the reasons these concepts matter. Continue Reading
-
Blog Post
06 Dec 2023
How the Actor Model works by example
For enterprise systems that need a flexible, asynchronous and message driven architecture, the Actor Model is often the right fit. Continue Reading
-
Tip
05 Dec 2023
A primer on Java 21 virtual threads with examples
Virtual threads let developers build applications that handle potentially millions of users and ensure consistent service delivery. Here's how Java 21 virtual threads work. Continue Reading
-
Answer
01 Dec 2023
11 real benefits of microservices
There's a reason why so many vendors have moved from monoliths to microservices. Here are 11 real benefits microservices bring to companies. Continue Reading
-
Answer
16 Nov 2023
10 disadvantages of microservices you'll need to overcome
Not everyone is keen to adopt a cloud-native architecture, for good reasons. These common drawbacks to microservices might convince you to stick with your traditional architecture. Continue Reading
-
Tip
19 Oct 2023
Understanding protocol buffers vs. JSON
Protocol buffers have some compelling advantages over JSON when it comes to sending data between internal services. But is it really a replacement for JSON? Continue Reading
-
Tip
04 Oct 2023
9 tips to improve Python performance
Python performance gets a bad rap compared with languages such as Java. Use these tips to identify and fix problems in your Python code to tweak its performance. Continue Reading
-
Blog Post
18 Sep 2023
Java vs. Python: Application code comparison
When you compare Java vs. Python application development in terms of simplicity, conciseness, security and performance, Java comes out on top in every category. Continue Reading
-
Definition
12 Sep 2023
model-view-controller (MVC)
In programming, model-view-controller (MVC) is an architectural design pattern that organizes an application's logic into distinct layers, each of which carries out a specific set of tasks. Continue Reading
-
Blog Post
01 Sep 2023
How to discard local changes in Git
Don't overlook a file or two when you attempt to remove and discard local, uncommitted changes in Git. Learn how to locally revert and remove uncommitted changes to files in Git properly. Continue Reading
-
Blog Post
30 Aug 2023
10 reasons to use Kotlin
Curious about the Kotlin language? It's an excellent choice as either a companion or alternative to Java, and offers many capabilities Java programmers wish they had all along. Continue Reading
-
Definition
30 Aug 2023
thread
A thread is, fundamentally, a clear, well-defined theme, subject, topic or focus. Continue Reading
-
Blog Post
24 Aug 2023
How to install Jenkins on Windows
With the Jenkins installer it's incredibly easy to download and run the popular CI/CD tool. Follow these simple steps and you'll have the continuous integration server running on Windows in no time. Continue Reading
-
Blog Post
21 Aug 2023
HTTP request methods explained
While there are almost 40 registered HTTP request methods, most RESTful web developers only use five of them. Here are the most important HTTP methods and examples of how to use them. Continue Reading
-
Blog Post
21 Aug 2023
PUT vs POST: What's the difference?
What's the difference between PUT and POST methods? Here we compare POST versus PUT in terms of idempotence, URL usage, payloads and their use in RESTful APIs. Continue Reading
-
Tutorial
11 Aug 2023
Understanding TypeScript generics
Programming languages such as Java, C# and Swift use generics to create code that's reusable and enforce type safety. In this tutorial, learn how generics in TypeScript work. Continue Reading
-
Blog Post
07 Aug 2023
How to login to Docker with a Docker Hub access token
Have you been snared by Docker's "unauthorized: incorrect username or password" error when you login at the command line? Here's how to generate an access token in Docker Hub and fix it. Continue Reading
-
Blog Post
06 Aug 2023
Get started with Spring Boot 3 tutorial
Need to learn Spring Boot 3? Want to quickly build a Spring Boot app with RESTful web services? This tutorial will help you create your first Spring Boot application in just minutes. Continue Reading
-
Tip
21 Jul 2023
The dangers of Python import and how enterprises can be safe
The Python import statement carries a security risk that developers and enterprises need to watch out for. Here's how it works and why there's no easy fix. Continue Reading
-
Blog Post
19 Jul 2023
Sprint vs Scrum: What's the difference?
The comparison of Scrum versus a sprint is less about differences and more about how Agile frameworks such as Scrum, SAFe and XP use short development cycles to limit risk and keep stakeholders ... Continue Reading
-
Blog Post
13 Jul 2023
How to enable Java 21 preview features
Java 21 includes numerous highly anticipated preview features including String templates, scoped variables and unnamed classes. Here's how to enable Java 21 preview features on your JDK. Continue Reading
-
Definition
13 Jul 2023
Remote Method Invocation (RMI)
Remote Method Invocation (RMI) is an application programming interface (API) in the Java programming language and development environment. Continue Reading
-
Tutorial
12 Jul 2023
Understanding the TypeScript method decorator
This tutorial explores TypeScript method decorators, reusable code similar to Java annotations that lets developers apply logic in a declarative manner at design time. Continue Reading
-
Definition
10 Jul 2023
Java Mission Control
Java Mission Control is a performance-analysis tool that renders sampled JVM metrics in easy-to-understand graphs, tables, histograms, lists and charts. Continue Reading
-
Blog Post
10 Jul 2023
Scrum's chicken and pigs parable
In a ham and eggs breakfast, the chicken is involved, but the pig's 100% committed. That's the problematic basis of Scrum's chicken and pigs parable. Continue Reading
-
Definition
10 Jul 2023
snake case
Snake case is a naming convention where a developer replaces spaces between words with an underscore. Continue Reading
-
Blog Post
03 Jul 2023
Create your first Java AWS Lambda function in minutes
If you haven't created a Java-based AWS Lambda function before, you'll be amazed at how easy it is. This quick AWS, Lambda and Java tutorial will quickly get you started in the world of serverless ... Continue Reading
-
Blog Post
01 Jul 2023
The var keyword in Java
While the use of var in Java brings inferred typing to the platform, it does not negate Java's dedication to strong typing. Here's how the Java var keyword works, along with simple examples of how ... Continue Reading
-
Tip
30 Jun 2023
How to apply the open-closed principle in Java
How does the open-closed SOLID principle work in a Java program? Here we show you what this important principle means, and how to implement the open-closed principle in Java. Continue Reading
-
Definition
27 Jun 2023
pseudocode
Pseudocode is a detailed yet readable description of what a computer program or algorithm should do. Continue Reading
-
Quiz
20 Jun 2023
10 WebAssembly questions to test your Wasm knowledge
Test your knowledge of WebAssembly with this tough, ten-question quiz on the benefits and applications of the new Wasm standard. Continue Reading
-
Definition
19 Jun 2023
requirements analysis (requirements engineering)
Requirements analysis (requirements engineering) is the process of determining user expectations for a new or modified product. Continue Reading
-
Definition
12 Jun 2023
lambda
Lambda, the 11th letter of the Greek alphabet, is used as both a symbol and a concept in various fields of science, mathematics and computing. Continue Reading
-
Blog Post
06 Jun 2023
How Java instance main methods and unnamed classes work
Say goodbye to the public static void main method in Java 21 with the unnamed classes and instance main methods preview features. Continue Reading
-
Blog Post
04 Jun 2023
Hibernate and JPA column mapping with annotations
Effective Hibernate and JPA column mapping requires the use of the @Column annotation to set important properties such as nullability, uniqueness, precision and scale. Continue Reading
-
Blog Post
01 Jun 2023
How System.out in Java works
New developers are often confused by the line of System.out.println() code they write when first introduced to Java. Here's a quick explanation of what System.out.println() means. Continue Reading
-
Blog Post
01 Jun 2023
How to use native SQL in Hibernate and JPA
Need to use raw SQL with JPA and JPA? The Jakarta Persistence API's NativeQuery interface makes it possible to use Hibernate, SQL and JPA together in the same app. Continue Reading
-
Blog Post
31 May 2023
Java's print vs println method: What's the difference?
What's the difference between print and println methods in Java? Our examples show that it comes down to the fact that println adds a newline character to output, while Java's print method does not. Continue Reading
-
Definition
31 May 2023
tuple
A tuple, pronounced TUH-pul, is an ordered and finite list of elements in various fields of interest, including computing. Continue Reading
-
Definition
22 May 2023
API security
Application program interface (API) security refers to policies and procedures that protect APIs against malicious attacks and vulnerabilities. Continue Reading
-
Definition
19 May 2023
no op (no operation)
No op means 'no operation,' which is a computer instruction that specifies no operation but takes up a small amount of storage space. Continue Reading
-
Definition
16 May 2023
Unicode
Unicode is a universal character encoding standard that is maintained by the Unicode Consortium, a standards organization founded in 1991 for the internationalization of software and services. Continue Reading
-
Blog Post
15 May 2023
Hibernate and JPA 3 CRUD example
Struggling to get your first JPA 3 application off the ground? Here's a quick Hibernate and JPA 3 CRUD example to help you get going with the latest version of the Java Persistence API. Continue Reading
-
Tip
09 May 2023
How to address Python performance problems
Python is a great language for nonprogrammers to do mathematical and scientific tasks, even if such optimization impacts performance. Here's why that's not a fair criticism. Continue Reading
-
Blog Post
01 May 2023
The right MySQL persistence.xml example file for JPA 3 and Hibernate 6
A quick migration from JPA 2.x to 3.x can become bottlenecked if the persistence.xml file is misconfigured. Here's what a proper persistence.xml file for JPA 3, Hibernate 6 and a MySQL database ... Continue Reading
-
Blog Post
30 Apr 2023
How to write your first Java program
Want to learn to code and write your first Java program? Here's a quick and fun Java programming tutorial that will have your running your first Java program in less than 10 minutes. Continue Reading
-
Blog Post
25 Apr 2023
Hello World in Python vs Java
'Hello World' is a silly criterion to use when comparing programming languages. Yet here we are, comparing 'Hello World' in Java vs Python. We'll let you judge the winner. Continue Reading
-
Tip
31 Mar 2023
JavaScript vs. TypeScript: What's the difference?
TypeScript and JavaScript are two complementary technologies that are driving both front-end and back-end development. Here are the similarities and differences between the two. Continue Reading
-
Tip
30 Mar 2023
How to apply the single responsibility principle in Java
How does the single responsibility model work in a Java program? Here we show you what this SOLID principle means, and how to implement the single responsibility model in Java. Continue Reading
-
Blog Post
29 Mar 2023
Why is the Bootstrap grid system 12 columns wide?
Ever wonder why they created a 12-column Bootstrap grid system, and not 10 or 15? It's the same reason there's 60 seconds in a minute, or 360 degrees in a circle. Continue Reading
-
Blog Post
28 Mar 2023
There's a new Java build system named Bld
Want to write your software build logic entirely in Java? A new build tool called Bld does exactly that, and Geert Bevin and Erik Thauvin are behind it. Continue Reading
-
Definition
28 Mar 2023
object-relational mapping (ORM)
Object-relational mapping (ORM) is a way to align programming code with database structures. Continue Reading
-
Blog Post
19 Mar 2023
Critical Java JVM options and parameters
The easiest way to optimize your Java runtime is to supply correct JVM options and parameters. In honor of the Java 21 release, we examine the 21 most important Java JVM options you can configure. Continue Reading
-
Blog Post
04 Mar 2023
Real world Java applications
Java runs on billions of devices, and Java applications of importance run on systems all over the world. Here are the top 10 applications of Java technology today, plus a look at what the future ... Continue Reading
-
Blog Post
28 Feb 2023
Top 10 software myths debunked
Software myths abound in the IT industry. Here are the top 10 software devlepment myths and misconceptions, along with a full debunking of these mythical ideas. Continue Reading
-
Blog Post
26 Feb 2023
How to use JShell in Java
If you haven't used Java's JShell yet, you're missing out. Here's a quick Java and JShell tutorial to get you started. Continue Reading
-
Definition
22 Feb 2023
abstract class
An abstract class is a template definition of methods and variables in a specific class, or category of objects. Continue Reading
-
Tip
15 Feb 2023
Why Java in 2023?
Has there ever been a better time to be a Java programmer? From new Spring releases to active JUGs, the Java platform is experiencing a renaissance. Continue Reading
-
Tip
27 Jan 2023
How developers can avoid remote work scams
Software developers can find good remote programming jobs, but some job offers are too good to be true. Follow these tips to spot remote job scams. Continue Reading
-
Tip
12 Jan 2023
Tips and tricks for TypeScript programming
For those new to TypeScript or for Java developers transitioning into JavaScript, these three TypeScript tips and tricks modern day software developers will come in handy. Continue Reading
-
Tutorial
06 Jan 2023
11 lessons learned from writing my first Java program
You'll be amazed how easy it is to learn Java and write powerful cross-platform applications when writing your first Java program. Some misconceptions about Java just aren't true. Continue Reading
-
Blog Post
04 Dec 2022
How do you say Udemy? The 11 most mispronounced tech terms
How do you say Udemy? How do you pronounce JSON or GIF? There's a right way and there's a wrong way. Learn the right way to say these commonly mispronounced tech terms. Continue Reading
-
Tip
25 Oct 2022
The differences between Java and TypeScript devs must know
Do you know Java? Are you trying to learn TypeScript? Here are five differences between TypeScript and Java that will make the learning transition easier. Continue Reading
-
Tutorial
29 Sep 2022
Your top 4 Java user input strategies
From System.in to the Scanner class, there are many ways to read user input into your Java programs. Find out which Java user input strategy is best for your software needs. Continue Reading
-
Tutorial
29 Sep 2022
How Java's System.in reads input from the user
The Java System.in component provides universal access to console-based user input. Learn how to make your applications interactive with this Java System.in tutorial. Continue Reading
-
Blog Post
09 Sep 2022
Java Exception handling best practices
Don't let the complexities of Java Exception handling get you down. Follow these top 10 Java Exception handling examples and you'll be an expert in handling errors in your Java code. Continue Reading
-
Definition
26 Aug 2022
Java string
A Java string is a sequence of characters that exists as an object of the class java.lang. Continue Reading
-
Blog Post
24 Jul 2022
How to format a Java String with printf example
The Java String printf method makes adding and formatting text incredibly easy. In this quick tutorial, you'll learn by example how to format, justify, pad and case output printed with Java's ... Continue Reading