Skip to main content

Tech Conversant Weekly Apr 24 - May 06

Topic: General                                                                                                                Level: All

Welcome to the world of cutting-edge technology! Every bi-week, we bring you the latest and most incredible advancements in the tech industry that are sure to leave you feeling inspired and empowered.

Stay ahead of the game and be the first to know about the newest innovations shaping our world. Discover new ways to improve your daily life, become more efficient, and enjoy new experiences.

This time, we've got some exciting news to share with you!

ZGC optimizes the HotStop JVM GC for low latency and scalability, offering the benefits of,
1. Scalable Heap memory area 
2. Low latency <1ms GC pause times regardless of the heap size definitions
3. Autotuned GC for optimal performance 
4. Throughput reduction 
As the ZGC is designed,
1. Concurrency - threads continue to execute and collect objects for GC 
2. Constant GC pause times - delegation of work outside the pause times (concurrent mark, remap, reallocate) 
3. Parallel - multiple threads perform collection 
4. Compacting - object movement fragmentation 
5. Region based - heap split into parts of the isolated collection 
6. NUMA Aware - objects are placed locally to the CPU thread that is executing 
7. Autotuned - GC parameter tuning is dynamic (only tunable parameter -Xmx max. Heap size)
8. Load barriers and Colored pointers - for concurrency in GC 
Generational ZGC - for handling workloads where the object allocation rate exceeds the GC's pace.
Having Young Gen and Old Gen, initializing objects in Young Gen, GC visits the object and computes the graph which it holds for a certain duration, then eventually this object here promoted to the Old Gen heap such that 4x throughput, 25% memory, and maintains sub-millisecond pause times and tuning automatically for 
1. Generation Sizing 
2. Tenuring Threshold 
3. Heap Occupancy Initiation
4. # Thread allocation 

Predictions on real-time high-frequency telemetry time series data and forecasting using Apache Kafka pub-sub architecture design and building an ML prediction pipeline.
How cool!
More on the library 

Spring AOP is an implementation of a Proxy interceptor design pattern, that applies common functionality like security, logging, pre/post-processing checks on methods, annotations, and even on HTTP servlet calls as well as on Bean instantiations and tear down.
1. Aspect: the functionality that needs to be applied throughout the application.
2. Join Point: a specific point in the execution flow of the application, where an aspect can be applied.
3. Advice: The action taken by an aspect at a specific join point is called advice. There are different types of advice, such as before, after, around, and after-throwing.
4. Pointcut: A pointcut is a set of join points where an aspect should be applied.
However, caution should be exercised while decorating the code with proxies as it would take a performance hit, as the call stacks are intercepted and stacks are pushed and popped on AOP Advice.
By annotating the Spring Bean class with Aspect we could define Pointcut taking in the expression to where the Aspect needs to be applied and invoking the Pointcut applied method via the Advice annotated method that defines the Aspect to be executed.
The same constructs apply for 
1. Any application methods 
2. Any annotations (subject to proxied)
https://debugagent.com/spring-boot-debugging-with-aspect-oriented-programming-aop 

For observability characteristics of an application, it is required to see the intermediate data state transitions/changes that the data propagates through the code underlying each stage.
Logging in general can be a useful tool for debugging and tracking the data flow through the application.
With levels like INFO, DEBUG, and WARN we can apply fine-grained loggers to the data.
In Python,
StreamHandler - specifies where the log message should go ie stdout, stderr.
The logging module also has a setter attribute for the logging levels.
Formatter can provide in-place property substitution that can be decorated to the StreamHandler formatter.
There can be multiple loggers identified by name given at the time of creation.
By using Filter to get environment variables for displaying host details and registering the filter to the logger.
JsonFormatter can be leveraged to output the log messages in JSON format by setting the formatter in StreamHandler, further, we can add additional JSON logs messages to the existing logger.
Consolidation of all the configurations in a single dictionary and load it via logging. config.dictConfig such that it will be globally available.
From the MLModel we can create a dictionary and pass it to the logger.
Furthermore, we can deploy the model with a logger configuration with Docker Image to the Kubernetes cluster and direct the logging output centralized log service provider.
Well-articulated post demonstrating the steps from Dev to Deployment

Spring's Transactional annotation is a pointcut applying the aspect specified in TransactionInterceptor that in turn delegates to JpaTransactionManager to create Transactional Context (based on the transaction propagation type is., REQUIRED, REQUIRES_NEW, NESTED, MANDATORY, SUPPORTS, NEVER, NOT_SUPPORTED) and to the service invocation.
For lazy fetching of DB connection, we can define a property namely,
spring.jpa.properties.hibernate.connection.provider_disables_autocommit=true
And annotate at class level Transactional(readOnly = true) and specify Transactional annotation for default read-write to override at the method-specific level.
However, specifying the isolation levels and other parameters on Transactional annotation causes eager fetching of DB connection overriding the property defined.
spring.jpa.properties.hibernate.connection.handling_mode=DELAYED_ACQUISITION_AND_RELEASE_AFTER_TRANSACTION 
delays the connection acquisition until Hibernate needs to execute a SQL statement.

Connecting to the OpenAI engine to send and retrieve the search prediction outcomes via HTTP API in JSON format and scaling with Java

Analysis and comprehension on thread dump 

Benefits and efficiency in the new Python upgrade 3.12 on the interpreter, concurrency, thin objects, 

Deviations and distinctions between GraalVM, AOT and JIT

Virtual Threads from Project Loom

Creation of efficient and performant microservices with Micronaut and GraalVM

To obtain the metadata on the currently matched resource method, use the ResourceInfo interface from Jakarta REST API

Java Reflections and its performance implications

Disclaimer: 
This is a personal blog. Any views or opinions represented in this blog are personal and belong solely to the blog owner and do not represent those of people, institutions or organizations that the owner may or may not be associated with in a professional or personal capacity, unless explicitly stated. Any views or opinions are not intended to malign any religion, ethnic group, club, organization, company, or individual. All content provided on this blog is for informational purposes only. The owner of this blog makes no representations as to the accuracy or completeness of any information on this site or found by following any link on this site. The owner will not be liable for any errors or omissions in this information nor for the availability of this information. The owner will not be liable for any losses, injuries, or damages from the display or use of this information.
Downloadable Files and ImagesAny downloadable file, including but not limited to pdfs, docs, jpegs, pngs, is provided at the user’s own risk. The owner will not be liable for any losses, injuries, or damages resulting from a corrupted or damaged file.
  • Comments are welcome. However, the blog owner reserves the right to edit or delete any comments submitted to this blog without notice due to :
  • Comments deemed to be spam or questionable spam.
  • Comments including profanity.
  • Comments containing language or concepts that could be deemed offensive.
  • Comments containing hate speech, credible threats, or direct attacks on an individual or group.
The blog owner is not responsible for the content in the comments. This blog disclaimer is subject to change at any time.

Comments

Popular posts from this blog

Tech Conversant Weekly Jul 03 - Jul 15

Topic: General                                                                                                                                              Level: All Welcome to the world of cutting-edge technology! Every bi-week, we bring you the latest and most incredible advancements in the tech industry that are sure to leave you feeling inspired and empowered. Stay ahead of the game and be the first to know about the newest innovations shaping our world. Discover new ways to improve your daily life, become more efficient, and enjoy new experiences. This time, we've...

Tech Conversant Weekly Jun 19 - Jul 01

Topic: General                                                                                                                                              Level: All Welcome to the world of cutting-edge technology! Every bi-week, we bring you the latest and most incredible advancements in the tech industry that are sure to leave you feeling inspired and empowered. Stay ahead of the game and be the first to know about the newest innovations shaping our world. Discover new ways to improve your daily life, become more efficient, and enjoy new experiences. This time, we've...

Microservices - Design Patterns

Topic: Software Design                                                                                                        Level: Intermediate Microservices - What? Microservice is a software design methodology, delegated to perform an isolated decoupled single functionality (following the Single-Responsibility Principle from object-oriented SOLID design principles).  Moreover, microservices by design, are decoupled making it easy to develop, test, maintain, deploy, configure, monitor and scale modules independently. Microservices - Why? Having one microservice would not be helpful without it being able to interact with other microservices, to aid in bringing an end-to-end b...