Home » Open Source » Page 2

Tag Archives: Open Source

KivaKit resources

java-interview-questions-answers

A resource is a stream of data that can be opened, read from or written to, and then closed. KivaKit provides a resource mini-framework that allows easy and consistent access to many types of resources, and it makes it easy to create new resources. Examples of KivaKit resources include: FilesSocketsZip or JAR file entriesS3 objectsPackage resourcesHDFS filesHTTP responsesInput streamsOutput streams ...

Read More »

KivaKit command line parsing

java-interview-questions-answers

The kivakit-commandline module provides the switch and argument parsing used by kivakit-application. Let’s take a look at how this works. When an Application starts up (see KivaKit applications), the Application.run(String[] arguments) method uses the kivakit-commandline module to parse the argument array passed to main(). Conceptually, this code looks like this: public final void run(String[] arguments) { onRunning(); [...] commandLine = ...

Read More »

KivaKit applications

java-interview-questions-answers

The kivakit-application module contains building blocks for creating applications and servers. In the diagram below, we can see that the Application class extends BaseComponent. Server, in turn, extends Application. BaseComponent inherits Repeater functionality from BaseRepeater, and handy default methods from the Component interface. ComponentMixin (shown in the next diagram) also inherits these methods from Component. Application provides command-line parsing (see ...

Read More »

Overhead added by Garbage Collection Logging

Enabling Garbage collection logs on your application has certain advantages. In nutshell, Garbage collection logs will facilitate you to optimize Garbage Collection pause time, improve overall application’s response time, forecast production outages, reduce computing cost. Even though Garbage collection logs have these advantages, we weren’t sure what overhead does garbage collection logging add to the application. Thus we set out ...

Read More »

Add Grpc to your Java Application

Grpc is a high performance, open source universal RPC framework.There are various benefits for using gRPC. It simplifies development by providing client/server codeIt supports multiple languages It all starts with defining a .proto file, .proto files reside on src/main/proto file. Be aware it is a good practise to keep proto files on a repo and have some schema versioning. This ...

Read More »

Generating Meaningful Mock Data with Faker

 Faker is an Open Source Python package that generates synthetic data that could be used for many things such as populating a database, do load testing or anonymize production data for development or ML purposes. Generating fully random data isn’t a good choice: with Faker you can drive the generation process and tailor the generated data to your specific needs: ...

Read More »

Python Calculations in Jupyter with Handcalcs

 Jupyter notebooks allows LaTeX rendering inside markdown. This way you can write complex math equations within a notebook. While LaTeX is the de facto standard for scientific documents, it hasn’t a very friendly and intuitive syntax. handcalcs is an Open Source library for converting Python calculations into rendered LaTeX: just write the symbolic formula, followed by numeric substitutions and that’s ...

Read More »

Set it up

In Java, we often have framework support for importing settings from the file system of our application. If we’re lucky, and we often are, these settings can be customised and overridden by system properties or environment variables. However, there are a couple of situations where this doesn’t quite apply: Very lightweight applications that use no frameworksLoading custom settings based on ...

Read More »