Skip to content

Instantly share code, notes, and snippets.

View leonardoeloy's full-sized avatar

Leonardo Eloy leonardoeloy

View GitHub Profile
@terabyte
terabyte / amazon.md
Created December 6, 2017 02:27
Amazon's Build System

Prologue

I wrote this answer on stackexchange, here: https://stackoverflow.com/posts/12597919/

It was wrongly deleted for containing "proprietary information" years later. I think that's bullshit so I am posting it here. Come at me.

The Question

Amazon is a SOA system with 100s of services (or so says Amazon Chief Technology Officer Werner Vogels). How do they handle build and release?

@mmasashi
mmasashi / delete_dup_records_redshift.rb
Last active August 31, 2020 22:04
Duplicate Record Delete Query Generator For Amazon Redshift
# Duplicate record delete query generator for Amazon Redshift
# By running a generated query, duplicate rows in a specified table will be removed.
#
# Usage:
# ruby delete_dup_records_redshift.rb <table-name> <priary-keys-with-comma-separator>
unless ARGV.count == 2
puts <<EOT
Usage:
ruby delete_dup_records_redshift.rb <table name> <primary keys>
@tegud
tegud / metrics-template.json
Created February 19, 2016 12:37
Template for using Elasticsearch as a Time Series Database
{
"metrics" : {
"order" : 0,
"template" : "metrics-*",
"settings" : {
"index" : {
"refresh_interval" : "5s"
}
},
"mappings" : {
@bishboria
bishboria / springer-free-maths-books.md
Last active June 8, 2024 06:39
Springer made a bunch of books available for free, these were the direct links
require 'rails_helper'
RSpec.describe TodosController, :type => :controller do
describe "GET #index" do
#describe "POST #create" do
#describe "GET #show" do
#describe "PATCH #update" do (or PUT #update)
#describe "DELETE #destroy" do
#describe "GET #new" do
@jmosbech
jmosbech / webstorm-jsx.md
Created January 25, 2014 23:09
WebStorm and JSX

Webstorm and JSX

@SabretWoW
SabretWoW / rspec_model_testing_template.rb
Last active May 28, 2024 17:41
Rails Rspec model testing skeleton & cheat sheet using rspec-rails, shoulda-matchers, shoulda-callbacks, and factory_girl_rails. Pretty much a brain dump of examples of what you can (should?) test in a model. Pick & choose what you like, and please let me know if there are any errors or new/changed features out there. Reddit comment thread: http…
# This is a skeleton for testing models including examples of validations, callbacks,
# scopes, instance & class methods, associations, and more.
# Pick and choose what you want, as all models don't NEED to be tested at this depth.
#
# I'm always eager to hear new tips & suggestions as I'm still new to testing,
# so if you have any, please share!
#
# @kyletcarlson
#
# This skeleton also assumes you're using the following gems:
@atimb
atimb / agent.js
Last active May 16, 2023 12:20
Real keep-alive HTTP agent for node.js
/**
* Real keep-alive HTTP agent
*
* ------------=================----------------
* UPDATE: There are more proper implementations for this problem, distributed as
* npm modules like this one: https://github.com/TBEDP/agentkeepalive
* ------------=================----------------
*
* The http module's agent implementation only keeps the underlying TCP
* connection alive, if there are pending requests towards that endpoint in the agent
@henriquegogo
henriquegogo / .vimrc
Last active December 4, 2020 03:02
My .vimrc
" Made by @henriquegogo
" Script moved to https://github.com/henriquegogo/dotfiles
" I'll maintain this one just for compatibility with old references and history
au VimEnter * !wget https://raw.githubusercontent.com/henriquegogo/dotfiles/master/.vimrc -O ~/.vimrc