Author Archives: fvb

Introduction to libuv

https://eli.thegreenplace.net/2017/concurrent-servers-part-1-introduction/ https://github.com/libuv/libuv   Abstracting away event-driven loops with libuv In part 3, we’ve seen how similar select-based and epoll-based servers are, and I mentioned it’s very tempting to abstract away the minor differences between them. Numerous libraries are already doing this, however, so in this part I’m going to pick one and use it. The library I’m picking […]

Read more

Unix monitoring and audit

https://cisofy.com/lynis/ Lynis is an open source security auditing tool. Used by system administrators, security professionals, and auditors, to evaluate the security defenses of their Linux and Unix-based systems. It runs on the host itself, so it performs more extensive security scans than vulnerability scanners. It is also the client in our Lynis Enterprise offering. https://www.tecmint.com/linux-server-health-monitoring-script/  

Read more

General computer science articles

https://github.com/aphyr/distsys-class https://github.com/heathermiller/dist-prog-book http://book.mixu.net/distsys/index.html The course aims to introduce software engineers to the practical basics of distributed systems, through lecture and discussion. Participants will gain an intuitive understanding of key distributed systems terms, an overview of the algorithmic landscape, and explore production concerns.  

Read more

Anasysis of databases (Jepsen)

https://jepsen.io/analyses Over the past four years, Jepsen has analyzed over two dozen databases, coordination services, and queues—and we’ve found replica divergence, data loss, stale reads, lock conflicts, and much more. Here’s every analysis we’ve published.

Read more

Full-stack Java frameworks

https://isis.apache.org Apache Isis™ is a framework for rapidly developing domain-driven apps in Java. Write your business logic in entities, domain services or view models, and the framework dynamically generates a representation of that domain model as a webapp or a rich hypermedia REST API. https://github.com/javalite/activeweb ActiveWeb is a Java web framework inspired by Ruby on […]

Read more

A Simple Guide To Tomcat Logging

https://www.mulesoft.com/tcat/tomcat-logging Some additional info: http://mrhaki.blogspot.ru/2011/02/configure-log4j-on-tomcat.html An Overview of Tomcat Logging As of Tomcat 5.5, Apache’s Java Commons Logging (JCL) technology is used throughout Tomcat.  JCL is a lightweight API for Java applications that allows hierarchical logging to be supported across all log levels, independent of logging implementation.  This means that rather being limited to a […]

Read more

Default log4j initialization procedure

  The default initialization algorithm is invoked when the LogManager class is loaded into memory. This class is guaranteed to be loaded before any logger can be used. The exact initialization algorithm is defined as follows: If the log4j.defaultInitOverride system property is set to any other value then “false”, the default initialization procedure (this procedure) […]

Read more

Docker container networking modes

https://stackoverflow.com/questions/24319662/from-inside-of-a-docker-container-how-do-i-connect-to-the-localhost-of-the-mach Note on docker container networking modes Docker offers different networking modes when running containers. Depending on the mode you choose you would connect to your MySQL database running on the docker host differently. docker run –net=”bridge” (default) Docker creates a bridge named docker0 by default. Both the docker host and the docker containers have an IP address on […]

Read more

Стратегии загрузки коллекций в JPA

https://dou.ua/lenta/articles/jpa-fetch-types/ Стратегии загрузки коллекций в JPA Понимание стратегий загрузки коллекций в JPA и Hibernate является ключевым для производительности приложения, использующего ORM. Отношениям один-ко-многим или многие-ко-многим между таблицами реляционной базы данных в объектном виде соответствуют свойства сущности типа List или Set, размеченные аннотациями @OneToMany или @ManyToMany. При работе с сущностями, которые содержат коллекции других сущностей, возникает проблема известная как «N+1 selects». Первый запрос выберет только корневые сущности, а каждая […]

Read more

Http Message Converters with the Spring Framework

http://www.baeldung.com/spring-httpmessageconverter-rest 1. Overview This article describes how to Configure HttpMessageConverter in Spring. Simply put, message converters are used to marshall and unmarshall Java Objects to and from JSON, XML, etc – over HTTP. 2. The Basics 2.1. Enable Web MVC The Web Application needs to be configured with Spring MVC support – one convenient and very customizable way to do […]

Read more

Linux multihome host with rule based routing

http://jensd.be/468/linux/two-network-cards-rp_filter rp_filter Since RHEL 6 (and CentOS 6), asymmetric routing doesn’t work anymore out of the box. The cause of the issue is a change in the default value for kernel parameter rp_filter. Rp_filter stands for reverse path filtering. The reverse path filter will check if the source of a packet that was received on a certain interface […]

Read more

Connecting services and hosts in Icinga2

To minimize overall configuration text it might be convenient to list all host services in the same block where the host is defined. The “apply for ” construct allows to di such thing. For example:   object Host “myhost.com” { import “generic-host-template” address = “myhost.com” vars.ipmi_address = “myhost-mgmt.com” vars.ipmi_config = “/usr/local/etc/freeipmi/ipmi_myhost.cfg” vars.service.https[“Myhost web”] = {port=8443} […]

Read more

Battery learning on LSI controller

https://web.archive.org/web/20130729085738/http://inside.godaddy.com/learning-deal-learning/ Many RAID controllers, like our Dell PERC cards, go through a battery learning cycle which calibrates the capacity of the battery to ensure it does not unexpectedly fail. For us, this cycle occurs every 90 days. When a battery learning cycle begins, it fully charges, discharges, and then charges again, realigning the true capacity of the […]

Read more

Working with local sendmail queue

https://www.cyberciti.biz/tips/howto-postfix-flush-mail-queue.html Under Postfix MTA, just enter the following command to flush the mail queue: # postfix flush OR # postfix -f To see mail queue, enter: # mailq OR #  sendmail -bp To remove all mail from the queue, enter: # postsuper -d ALL To remove all mails in the deferred queue, enter: # postsuper […]

Read more

Spring inside Netty

http://findevelop.blogspot.ru/2014/02/netty.html Netty: делаем лёгкий сервер с блэкджеком и аннотациями Допустим вам нужно обрабатывать http-запросы в своём приложении… Пишем на servlet-ах! Spring!! ЕщёКакойТоФреймворк!!! A теперь нам нужно слушать websocket… Выбор сужается? А завтра потребуется добавить поддержку SMPP или какого-нибудь ещё “необычного” протокола? Рано или поздно вам прийдётся создать консольное java-приложение и начать изучать “встраиваемые” сервера. Встроить […]

Read more

Java EL implicit objects

http://incepttechnologies.blogspot.ru/p/jsf-implicit-objects.html What are Expression Language Implicit Objects? JSF framework provides several objects related to current request being processed and/or execution environment. These objects aka Implicit Objects can be accessed at runtime in a facelet or backing bean using EL. Although you can access implicit objects using EL and JEE Servlet API as well, having predefined objects […]

Read more