Declarative Thinking, Async ≠ Reactive I’m strongly aligned with the declarative mindset of C# and Java. Not because they’re “enterprise defaults”, but because they let us describe what a system should do — clearly, predictably, and in a way the runtime can optimize. This naturally connects to Data-Oriented Programming: data over hierarchies, flows over objects, structure over cleverness. One important clarification I keep seeing blurred: `async/await` in C# is not Reactive Programming. `async/await` is an excellent abstraction for async concurrency. Reactive systems are about streams, backpressure, composition, and event propagation over time. Different problems. Different tools. Modern Java’s reactive stack proves this isn’t theory — it’s production-grade infrastructure. This isn’t nostalgia. It’s engineering clarity. #SoftwareEngineering #DeclarativeProgramming #ReactiveProgramming #AsyncAwait #Concurrency #EventDrivenArchitecture #Java #CSharp #BackendDevelopment #EngineeringMindset
Ofek Malka’s Post
More Relevant Posts
-
Async in Java Isn’t Just “Run It in Another Thread” Many developers say: “We made it async.” But what does that actually mean? Real async systems are built on 3 pillars: • Proper thread management • Non-blocking task orchestration • Controlled resource utilization When you use `ExecutorService`, you're not just creating threads. You're defining how your system behaves under pressure. Pool size too small? → Bottleneck. Too large? → Context switching overhead. When you use `CompletableFuture`, you're not just chaining methods. You're designing asynchronous workflows: * Transformations * Compositions * Parallel aggregations * Graceful error recovery Async isn’t about speed. It’s about scalability and resilience. In high-load systems: * Blocking kills throughput * Poor thread management causes exhaustion * Ignored exceptions break pipelines silently Mature backend engineering means: Designing async flows intentionally — not decorating methods randomly. Concurrency is architecture. Not syntax. #Java #BackendEngineering #Concurrency #AsyncProgramming #SoftwareArchitecture
To view or add a comment, sign in
-
Java Inheritance allows one class to acquire the properties and behaviours of another using the "extends" keyword. In simple terms, it helps create a hierarchy where common functionality is defined once in a parent class and reused by child classes. In real world Java applications, inheritance supports code reusability, cleaner architecture, and logical domain modelling. It is commonly used in service layers, framework design, and base entity structures in enterprise systems. From an interview perspective, it often connects to concepts like method overriding, runtime polymorphism, and the “is-a” relationship. Strengthening this fundamental improves how I think about designing reusable and maintainable backend components. When designing systems, how do you decide between using inheritance and favouring composition to avoid rigid or overly deep class hierarchies? #Java #ObjectOrientedProgramming #BackendDevelopment #SoftwareEngineering #JavaDeveloper #InterviewPreparation
To view or add a comment, sign in
-
-
Understanding static in Java — More Powerful Than It Looks While revisiting Core Java fundamentals, I explored how static works as a: • Static Variable • Static Method • Static Block At first, static feels simple. But in real-world backend systems, it plays a critical role. 1. Static Variable Shared across all objects of a class. Example: Company name shared by all employees. Only one copy exists in memory. 2. Static Method Belongs to the class, not the object. Called using the class name. Commonly used for utility logic and shared operations. 3. Static Block Executes only once when the class is loaded. Used for initializing configurations or shared resources. Why this matters in production systems: • Configuration management • Logging setup • Utility classes • Connection pools • Shared counters • Caching mechanisms Understanding static properly improves memory management and application design. Strong backend engineering starts with mastering how memory and class loading actually work. Curious to hear from experienced developers: Where have you seen static used effectively in production systems? #Java #CoreJava #BackendDevelopment #SoftwareEngineering #JVM #CleanCode #JavaDeveloper #TechCareers
To view or add a comment, sign in
-
-
Java Polymorphism allows a single interface or parent reference to represent different underlying object behaviours. Through method overriding and dynamic dispatch, the same method call can produce different outcomes depending on the object type at runtime. In real world Java and enterprise systems, polymorphism helps build flexible architectures where services depend on abstractions rather than concrete implementations. It is widely used in framework design, service layers, and API contracts, and is a common interview topic when discussing runtime behaviour, design patterns, and the Open/Closed principle. Strengthening this concept helps me approach backend design with more focus on extensibility rather than rigid class structures. When designing systems, how do you determine when polymorphism genuinely improves flexibility versus when it introduces unnecessary abstraction layers? #Java #ObjectOrientedProgramming #BackendDevelopment #SoftwareEngineering #JavaDeveloper #InterviewPreparation
To view or add a comment, sign in
-
-
In production grade Java applications, final and static are more than keywords, they shape stability and structure. From defining immutable constants (like configuration values) to managing shared utilities and class level resources in Spring Boot services, their correct use directly impacts performance, thread safety, and clean architecture. In interviews and enterprise projects, understanding when to use final for immutability and static for shared behavior often reflects clarity in design thinking. Sharpening these fundamentals daily helps me write more predictable, maintainable code. What’s a common mistake you’ve seen with static or final in large codebases: overuse, misuse, or hidden side effects? #Java #ObjectOrientedProgramming #BackendDevelopment #SoftwareDesign #JavaDeveloper #InterviewPreparation
To view or add a comment, sign in
-
-
Day 3 / 100 — A mistake I still see in many Java codebases 👀 After working with Java for nearly 10 years, one pattern shows up again and again in production systems: Developers catch exceptions… and do nothing with them. Something like this: try { processOrder(); } catch (Exception e) { } No log. No alert. No visibility. The system fails silently… and hours later someone is asking: "Why did the order fail?" Here’s the reality from real-world systems: ⚠️ Silent failures are far more dangerous than crashes. A crash is obvious. A silent failure can corrupt data, break workflows, and go unnoticed for days. A simple rule I’ve followed in every system: ✔️ Never swallow exceptions ✔️ Always log with context ✔️ Handle exceptions at the right layer Sometimes the smallest habits are what separate stable production systems from chaotic ones. Curious — what's the most painful bug you've debugged in production? 😅 More insights from 10 years of building Java systems tomorrow. #Java #JavaDeveloper #SpringBoot #BackendDevelopment #SoftwareEngineering #Programming #Microservices #SystemDesign #Coding #100DaysChallenge
To view or add a comment, sign in
-
-
Ever get confused between a Process and a Thread? 🤔 Understanding concurrency is a rite of passage for Java developers. Mastering it helps you build faster, more efficient applications. Here is the breakdown you need: 1. Process vs. Thread: The Analogy 🏢 Think of an application as a Company. · A Process is a standalone Department (e.g., HR, IT). It has its own private office space (memory) and doesn't interfere with others. · A Thread is an Individual Employee within that department. They share the same office space (memory) but can work on different tasks simultaneously. 2. How to Create Threads in Java You have two classic options: · Extend the Thread class: Override the run() method. · Implement the Runnable interface: Implement run(), then pass it to a Thread object. (Pro tip: Prefer Runnable because Java supports single inheritance for classes). 3. The Thread Lifecycle 🔄 A thread isn't always "running". It moves through states: New → Runnable → Blocked/Waiting → Timed Waiting → Terminated 4. Daemon Threads 👻 These are low-priority background workers (like Garbage Collectors). They run silently to support your main threads and automatically die when all user threads finish. Q1: If you have two cores on your CPU, how many threads can truly run in parallel at exactly the same moment? A1: Only 2. While you can have hundreds of software threads, only two can execute physically in parallel on a dual-core machine. The OS handles the scheduling for the rest. Q2: If you set a thread as setDaemon(true), can it prevent the JVM from exiting if it is still running? A2: No. The JVM exits as soon as all user (non-daemon) threads finish. Daemon threads are abruptly terminated and do not block the JVM from shutting down. #Java #Programming #Multithreading #TechInterview #Coding
To view or add a comment, sign in
-
Understanding Constructor Overloading in Java — A Small Concept with Big Impact While revisiting Core Java fundamentals, I explored Constructor Overloading and realized how powerful it is in real-world application design. Constructor overloading allows a class to have multiple constructors with different parameter lists, enabling flexible object creation. Example scenario: In a User Registration system, we may want to create: A user with just a name A user with name and email A user with name, email, and phone Instead of forcing one rigid constructor, we overload constructors to handle different initialization scenarios cleanly. Why this matters in real systems: • Improves flexibility in object creation • Supports multiple business flows • Keeps domain models clean • Makes code more scalable and maintainable This concept is widely used in: DTO classes Entity models API request handling Builder patterns Enterprise backend systems Strong backend engineering is not just about frameworks — it’s about mastering the fundamentals that power them. Curious to hear from experienced developers: Do you prefer constructor overloading or builder pattern for complex object creation in production systems? #Java #CoreJava #BackendDevelopment #SoftwareEngineering #OOP #CleanCode #JavaDeveloper #TechCareers
To view or add a comment, sign in
-
-
"Architecting Knowledge" - Java Wisdom Series Post #7: CompletableFuture - Don't Block Your Future 👇 You're using `CompletableFuture`, but still blocking. Here's the problem. Why This Matters: Calling `.get()` or `.join()` on a `CompletableFuture` defeats its entire purpose. You're forcing the calling thread to wait, turning async code back into synchronous blocking code. The power of CompletableFuture is in chaining operations with `thenApply`, `thenCompose`, `thenCombine` - letting the framework handle threading. Key Takeaway: Return `CompletableFuture` from your methods. Let the caller decide when to block. Your job is to build the async pipeline, not collapse it. #Java #JavaWisdom #CompletableFuture #AsyncProgramming #Concurrency #Performance Ever caught yourself calling .get() and wondered why async was slow? Share your async journey! All code examples on GitHub - bookmark for quick reference: https://lnkd.in/dJUx3Rd3
To view or add a comment, sign in
-
-
Level Up Your Backend Skills with Multithreading in Java Ever wondered how applications handle multiple users and tasks at the same time without slowing down? The answer lies in Multithreading. Multithreading enables a program to run multiple tasks concurrently, making systems faster, smoother, and more efficient. 🔹 Core Idea A thread is a lightweight unit of execution that runs independently while sharing the same memory space. This makes it faster and more resource-efficient compared to processes. 🔹 Why Developers Should Care ✔️ Handles multiple requests simultaneously ✔️ Improves performance and CPU utilization ✔️ Reduces execution time ✔️ Enhances user experience (no lag or freezing) 🔹 Behind the Scenes Multithreading works through thread scheduling, where the CPU switches between threads quickly, giving the illusion of parallel execution. 🔹 Two Ways to Create Threads 👉 Extending Thread class 👉 Implementing Runnable interface (preferred for flexibility) 🔹 Thread Life Cycle Simplified New → Runnable → Running → Blocked → Terminated 🔹 Real-World Example Think of a food delivery app 🍔 One thread handles order placement Another processes payment Another tracks delivery All running simultaneously without interrupting each other. 💡 Pro Tip: Writing multithreaded code requires proper handling (like synchronization) to avoid issues like race conditions. 🔥Follow me for more insights on Java & backend development. #Java #Multithreading #Backend #SoftwareDevelopment #Coding #Developers #TechLearning #ProgrammingLife
To view or add a comment, sign in
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development