Posts

Showing posts from March, 2021

Jupyter Notebooks

Image
Jupyter Notebooks are very popular in the Big Data / Data Science field. Notebooks are a great tool for discovery it allows us to have interactive code and abstract the runtime environment. Notebooks are sharable and are cool not only on the Big Data / Data Science landscape but also for anyone who wants to write better documentation, have better code examples for your consumers, or even just to learn pretty much anything. Jupyter notebooks are written in Python however is possible to install other Kernels for other languages like Java, Kotlin, Scala, Groovy, Go, Rust, and many more. Github knows how to read Jupiter notebook files and provides great visualization for you.  So today I made a short video showing some Jupyter capabilities across multiples kernels. 

Why Micro frontends might fail as microservices

Image
Micro frontends were highly inspired by Microservices. So why not extend the same benefits from microservices to micro frontends, right? Things are a bit easier at the backend because we can actually have proper and real isolation . Meaning process/machine isolation, since we can distribute workloads in different machines. When we are looking into micro frontends is not the same deal. We also need to remember that microservices were highly inspired by SOA and Microservices are a flavor of SOA. Microservices are DEAD and in decline for the Backend, so it's interesting to see it's a major trend for the frontend. At the end of the day the Browser architecture did not change much and in the backend is much easier to have isolations and we have different flavors of isolations like Docker , UniKernels , MicroWorkers , etc... 

Architecture & Engineering: Doing the non-obvious!

Image
This is the first slide-cast for Architecture and Engineering: Doing the non-obvious. This slide-cast was inspired by the Management: Doing the non-obvious series ( I and II ). For this slidecast, I will cover some non-traditional and non-obvious vision and philosophy about Engineering and Software Architecture. I also will recommend +20 books so you can improve and also get more insights. Buckle up, I will challenge several traditional and established ideas. So I hope you guys like it - Let's get started! The Video The Slides Architecture & Engineering: Doing the non-obvious! de Diego Pacheco Cheers, Diego Pacheco

Advanced Reflection in Java

Image
Reflection is a killer feature in Java Language. It's a technique that combined with annotations and interfaces allows us to do Dynamic and Generic programming which could be complete abstractions or even customizable callbacks. Reflection allows us to do Dynamic discovery in sense of Types, Methods, Fields, Methods, and Annotations. People often couple Annotations with Aspects or AOP. You do not need Aspect you dont need AOP in order to do Generic and dynamic programming using Annotations. Today I want to share a simple POC I made to show the power of annotations combined with Reflection. We will do a 2 layer abstraction pattern. The first level is more generic and the second level allows customization. So Let's get started.

Scala 3.0

Image
Scala 3.0 is not out yet but has some interesting new features. I'm still digesting some features some I have some mixed feelings about it. One of the main big changes is the support for Python-like syntax. Scala 3.0 has lots of shortcuts, types of convenience, and different ways to do generics. Scala always had the philosophy to be flexible on the language level and let the tools and companies restrict functionality, so this still pretty much very true. I made a series of 3 videos going over some of the changes in Scala 3. This material is highly inspired by the scala 3 boo/docs. Some code and features on the videos will not be limited by scala 3 but also cool things about scala 2 or even scala in general but mostly I will be talking about scala 3.0. Keep in mind scala 3 is not final so things could change but I believe you gonna be able to have a good sense of what to expect and what's going on. So Let's get started. 

Functional Programming in Kotlin

Image
Kotlin is an interesting JVM language. Today I want to show some capabilities Kotlin has around Functional Programing. FP is a very interesting way to think and create safe programs. Today we will cover High Orde Functions, Lambdas, and also Class extensions. So today I made a simple video and code POC. Let's get started! The Video The Code https://github.com/diegopacheco/kotlin-playground/tree/master/kotlin-fp-fun Cheers, Diego Pacheco

Generics in Kotlin

Image
Kotlin is an interesting JVM language. Today I want to show some capabilities Kotlin has around Generics. Generics are super important for any language. However, some languages abuse generics and have gaps. Generics are important for code reuse and also to enforce type constraints for safety. Kotlin has some interesting ways to express type constraints. So today I made a simple video and code POC. Let's get started!

Reflection in Kotlin

Image
Kotlin is an interesting JVM language. Today I want to show some capabilities Kotlin has around Reflection. Reflection is needed to perform some generic computations often to reuse code around some metadata processing. Kotlin separates Java and Kotlin classes(KClass) and has utility methods around them. So I made a simple POC and Video. Let's get started!

Strings in Kotlin

Image
Kotlin is an interesting JVM language. Today I want to show some capabilities Kotlin has around Strings. Strings are bread and butter or everyday work of any programing language. Strings are a basic type that can either be simple and pleasure or a nightmare i.e go look at Strings in Erlang.  Strings are pretty easy and cool in Kotlin. So I made a short video and some simple POC going over some String features in Kotlin. Let's get started!

ksqlDB

Image
ksqlDB is an Event Streaming Database. Basically, you turn Kafka Streams(topics) into Databases. Allowing you to have some level of consistency and fast lookups on real-time data. ksqlDB allows you to perform SQL queries on your Kafka topics. It's possible todo pull-based or even push-based queries. Kafka is getting closer and closer to be a Database and that's exciting. To be 100% clear Kafka is not a full-fledge database and I would cherry-pick use cases that fit into the model. There is no one-size-fits-all. So today I want to share a simple POC in a video I made for you guys where we will see push queries in action. So Let's get started!

Object Binding with remap in Java

Image
Object binding or mapping is something as old as Java. Sometimes you need to use this technique in order to isolate your core domain from your contract or with your persistence layer. It's always a good idea to have a clean and separated core.  DDD calls it an Anti-Corruption Layer . SOC(Separation of concerns) is always a good idea. As time passes Services and Services teams kind of lose that great Architectural and SOA Principles no wonder things are harder them before.  So today I want to talk a bit and show some code about a library called remap . Which provides declarative mapping. It's super easy to use and really will boost you productivity. So Let's get started!

XML Serialization in Java with XStream

Image
Xstream is an old but still a good framework for serialization. Definitely, there are faster libraries however Xstream still lightweight and relevant if you need to deal with XML. There are other formats like YAML, JSON, and so many others. For configurations, I definitely favor java properties file format which is just a key/value format. Generally, I would favor JSON for configs over YAML. So why XML in 2021? I'm not arguing XML is the way. Just saying sometimes you need to deal with old services or old systems and for that case, you might be constrained with whatever format is there. You might consider creating a wrapper service to abstract an old API and old format but eventually, complexity needs to live somewhere. So I made some POC showing some of the capabilities that Xstream has. Let's get started!

git rebase with squash

Image
Git is a very powerful tool for source code version control. Often we do POCs and no one whats to waste time while you are doing a POC so often people dont pay much attention to their commit messages(including myself). However the POC grows and you reach the point to productionize the solution, all great but what you do with your poor commit messages? Good messages are critical for good configuration management, release management, and code hygiene. So what can we do? Well git rebase can rescue us. Git rebase is also useful in other use cases where you need to have a specific format of messages because your CI/CD tool does some validations or you are hunting a bug down and you want to drop a bad commit or you are cherry-picking commits to doing a chirurgical release. So I made a short video showing rebase commands in action. We also will use squash which is an interesting way to combine your commits in one for better trackability. So Let's get started.