Posts

  • Biểu thức chính quy và automata

    Một vài ghi chú về biểu thức chính quy(regular expression) và automata

  • Linux ODBC and Microsoft Access

    How to load data from Microsoft Access in your Linux box

  • AWS Cognito: client and server authentication

    Notes on how to setup AWS Cognito as authentication service for your web application

  • Basic usage of libuv

    This post server as my note while fiddling with libuv, I will write some basic program using libuv.

  • Writing a C Compiler

    This year I will try learning about compiler by writing a C compiler.

  • Ruby 3: Non-blocking Fiber

    In this post, we will explore Ruby 3's new non-blocking Fiber and write a simple Fiber scheduler

  • Build your own React, part 2: Class and Functional Component

    In this next post of the series, let's implement the usual class and functional component.

  • Build your own React, part 1: DOM generator

    In order to understand a little bit more about React, I've set a goal to build myself a library with the same functionality as React. In this post, I will begin with DOM generation and JSX.

  • Books 2020

    Summary of books that I have been reading this year

  • Event driven non blocking IO with Ruby's fiber

    In this post, I will introduce about Ruby's fiber and some of its application in concurrency processing.

  • 2020's resolution

    My 2020's resolution

  • How does debugger locate source code of an executable

    My attempt to explain how a debugger can locate source information of an executable.

  • Compiler, linker and loader in Linux

    My explanation of gcc(or clang) compiler, linker and loader, their relationship

  • Advent of Code 2019

    Advent of Code is a coding puzzle event that hold from December 1st to 24th. It contains well-crafted coding problems with increasing difficulty when the event go on. It is a very good chances to learn or review a programming language.

  • Using CentOS's cloud image to bootstrap a CentOS virtual machine

    CentOS provides preconfigured cloud images which let's conveniently import and using without having to install from scratch. We will do some customise with this image in this post.

  • Centos 7 install with virt-install

    How to install CentOS 7 guest using virt-install in text mode

  • Sending log to GCP's Stackdriver from any server

    How to configure fluentd to send log to GCP stackdriver from any server, not necessarily from GCP or AWS.

  • Books 2019

    Summary of books that I have been reading this year

  • Azure DevOps

    Some of my experiences with Azure DevOps

  • 2019's resolution

    My New Year's resolution

  • Books 2018

    Books that I have read this year

  • End to end encrypt using ssh key pairs

    When you're too lazy to install gpg, this oneliner can be used to encrypt/decrypt a message with ssh keypair

  • Ruby hacking week 1

    From this week, I will try to hack into Ruby core, I will write blog posts along

  • Giới thiệu về EventMachine, phần 2

    Trong bài trước mình đã giới thiệu qua các khái niệm cơ bản của EventMachine, phần tiếp theo của loạt bài này, ta sẽ đi sâu vào một số hàm xử lý các event IO(đặc biệt là xử lý socket IO) để thấy được sức mạnh của EventMachine.

  • Giới thiệu về EventMachine, phần 1

    Nếu đã từng làm qua Javascript, chắc hẳn sẽ rất quen thuộc với reactor pattern(callback, promise...). Với Ruby ta cũng có thể áp dụng reactor với hỗ trợ của gem EventMachine. Trong bài này, ta sẽ tìm hiểu cơ bản về reactor pattern và cách sử dụng với EventMachine.

  • How is symbol passing as block implemented in Ruby

    How, in Ruby, a symbol can be passed as a block to a method.

  • Functor, Applicative, Monad

    Bài viết giải thích một cách đơn giản về các khái niệm trong lập trình hàm như functor, applicative, monad

  • Thu thập dữ liệu từ website cùng với Ruby, phần 2

    Tiếp theo loạt series về các cấu trúc xử lý concurrent, trong bài viết này sẽ giới thiệu pattern Actor cùng việc kết hợp giữa Ruby và Erlang thông qua Thrift.

  • Tìm hiểu về Apache Thrift

    Mỗi một ngôn ngữ đều có điểm mạnh và điểm yếu khác nhau. Trong các hệ thống lớn như Facebook, Twitter nhiều ngôn ngữ khác nhau được sử dụng để đạt được performance cao nhất. Tuy nhiên việc kết hợp nhiều ngôn ngữ, framework trong một ứng dụng không hề đơn giản. Thrift cung cấp một giải pháp giúp các process được implement bằng các ngôn ngữ khác nhau giao tiếp với nhau một cách dễ dàng. Bài viết này giới thiệu về Thrift thông qua ví dụ client/server bằng Ruby và Erlang

  • Mã hóa trong Ruby với thư viện openssl

    Gần đây mình có nhu cầu push một số data hơi nhạy cảm lên các public repo. Nhưng để ở plain text thì thấy không an tâm lắm, nên trong bài viết này, ta sẽ tìm hiểu về cách mã hóa trong Ruby sử dụng thư viện openssl.

  • Newcomb's paradox

    Tưởng tượng một trò chơi bao gồm 2 nhân vật như sau Predictor có khả năng tiên đoán tương lai rất chính xác, Player một người chơi bình thường

  • Thu thập dữ liệu từ website cùng với Ruby

    Trong bài này, ta tìm hiểu cấu trúc của một chương trình crawler đơn giản đồng thời áp dụng multi-threading để cải thiện tốc độ thực thi.

  • Full-text search: giới thiệu về token analysis

    Tiếp theo series giới thiệu về full-text search, bài viết này giới thiệu về tokenzer và filter, hai thành phần quan trọng của Solr/Lucene

  • Giới thiệu module Rails Concern

    Giới thiệu về module Concern của Rails. Một module rất đơn giản nhưng đôi khi rất hữu dụng khi refactor các phần code dùng chung của model.

  • Full-text search: các thuật toán cơ bản

    Giới thiệu những kiến thức cơ bản về full-text search, inverted index, mô hình vector space và thuật toán scoring.

  • Rails on Rack

    Tiếp theo bài giới thiệu về Ruby Rack trước, bài viết này sẽ đi sâu vào phân tích ứng dụng của Rack trong Rails.

  • Implement logistic regression using Fisher's scoring method

    Use logistic regression to solve binary classification problem. For simplicity, I have use Newton method(also called Fisher's scoring) to get the optimize parameters.

  • Giới thiệu Ruby Rack

    Nếu đã từng lập trình web với Ruby, bạn đã làm việc với Rack. Có thể nói Rack chính là nền tảng cho các web framework của Ruby. Từ Sinatra, Rails, đến các framework gần đây như Lotus đều dựa trên nền tảng của Rack. Tìm hiểu về Rack giúp ta có hiểu được cách thức hoạt động của các web framework, từ đó tùy biến chúng dễ dàng hơn.

  • Tách nội dung chính của một trang tin tức

    Trong bài viết này mình xin trình bày một thuật toán để tách nội dung chính của một trang web(tin tức).

  • Giới thiệu về caching trong Rails

    Loạt bài nhiều phần này nhằm giới thiệu từ tổng quan đến chi tiết, cũng như cách cài đặt sử dụng các loại hình caching trong Rails. Trong phần đầu, mình xin giới thiệu sơ lược về caching trong Rails.

subscribe via RSS