---
title: "Petra's Tech Notes (@pmb) | Hashnode"
description: "Petra's Tech Notes (@pmb) writes on Hashnode. Read their latest articles and follow their work."
url: "https://hashnode.com/@pmb"
---

@pmb

# Petra's Tech Notes

@pmb · Joined July 2022

### [Crafting Thread-Safe Functions in Java - Part 3](https://petratechnotes.hashnode.dev/crafting-thread-safe-functions-in-java-part-3?utm_source=hashnode&utm_medium=feed)

Learn to synchronize Java functions using semaphores for thread safety. Understand printing 0s, odd, and even numbers

2 min read · [petratechnotes.hashnode.dev](https://petratechnotes.hashnode.dev/crafting-thread-safe-functions-in-java-part-3?utm_source=hashnode&utm_medium=feed)

[Oct 9, 2024](https://hashnode.com/posts/crafting-thread-safe-functions-in-java-part-3/670686aa74eb5857cff60b3d)

### [Crafting Thread-Safe Functions in Java - Part 2](https://petratechnotes.hashnode.dev/crafting-thread-safe-functions-in-java-part-2?utm_source=hashnode&utm_medium=feed)

Learn to make Java functions thread-safe, ensuring consistent execution and understanding the difference between Mesa and Hoare monitors

3 min read · [petratechnotes.hashnode.dev](https://petratechnotes.hashnode.dev/crafting-thread-safe-functions-in-java-part-2?utm_source=hashnode&utm_medium=feed)

[Oct 9, 2024](https://hashnode.com/posts/crafting-thread-safe-functions-in-java-part-2/670685fffe5d1241160c3c6d)

### [Crafting Thread-Safe Functions in Java - Part 1](https://petratechnotes.hashnode.dev/crafting-thread-safe-functions-in-java-part-1?utm_source=hashnode&utm_medium=feed)

Prevent race conditions and ensure thread safety in Java using synchronized functions. Essential for reliable multithreaded applications

4 min read · [petratechnotes.hashnode.dev](https://petratechnotes.hashnode.dev/crafting-thread-safe-functions-in-java-part-1?utm_source=hashnode&utm_medium=feed)

[Oct 9, 2024](https://hashnode.com/posts/crafting-thread-safe-functions-in-java-part-1/6706856ef10a393d9226e2b6)

### [Understanding Multi-threading in Java: Essential Basics - Part 2](https://petratechnotes.hashnode.dev/understanding-multi-threading-in-java-essential-basics-part-2?utm_source=hashnode&utm_medium=feed)

Learn mutexes, semaphores, and monitors for Java multi-threading: their functions, differences, and uses in concurrency control

3 min read · [petratechnotes.hashnode.dev](https://petratechnotes.hashnode.dev/understanding-multi-threading-in-java-essential-basics-part-2?utm_source=hashnode&utm_medium=feed)

[Oct 9, 2024](https://hashnode.com/posts/understanding-multi-threading-in-java-essential-basics-part-2/670684611bd6207542af4b48)

### [Understanding Multi-threading in Java: Essential Basics - Part 1](https://petratechnotes.hashnode.dev/understanding-multi-threading-in-java-essential-basics-part-1?utm_source=hashnode&utm_medium=feed)

Learn Java multi-threading for concurrency, parallelism, and efficiency. Improve performance and write thread-safe applications

8 min read · [petratechnotes.hashnode.dev](https://petratechnotes.hashnode.dev/understanding-multi-threading-in-java-essential-basics-part-1?utm_source=hashnode&utm_medium=feed)

[Oct 9, 2024](https://hashnode.com/posts/understanding-multi-threading-in-java-essential-basics-part-1/670684059ad0c20b9b313ee6)
