Skip to content

Instantly share code, notes, and snippets.

@igorkosta
igorkosta / composing-software.md
Created March 23, 2021 15:56 — forked from Geoff-Ford/composing-software.md
Eric Elliott's Composing Software Series

Eric Elliott's "Composing Software" Series

A collection of links to the excellent "Composing Software" series of medium stories by Eric Elliott.

Edit: I see that each post in the series now has index, previous and next links. However, they don't follow a linear flow through all the articles with some pointing back to previous posts effectively locking you in a loop.

'use strict'
const EventEmitter = require('events')
// default expiry 3 mins
const DEFAULT_EXPIRY = 3 * 60 * 1000
const create = ({ keys, ssm, keyPrefix = '', expiryMs = DEFAULT_EXPIRY }) => {
let isRefreshing = false
if (!keys || !Array.isArray(keys) || keys.length === 0) {
throw new Error('Provide a non-empty array of config keys')
@igorkosta
igorkosta / Common-Currency.json
Created January 22, 2018 09:43 — forked from ksafranski/Common-Currency.json
Common Currency Codes in JSON
{
"USD": {
"symbol": "$",
"name": "US Dollar",
"symbol_native": "$",
"decimal_digits": 2,
"rounding": 0,
"code": "USD",
"name_plural": "US dollars"
},
@igorkosta
igorkosta / timezones
Created January 17, 2018 16:03 — forked from ykessler/timezones
JSON list of time zones (Based on Olson tz database)
[
{"group":"US (Common)",
"zones":[
{"value":"America/Puerto_Rico","name":"Puerto Rico (Atlantic)"},
{"value":"America/New_York","name":"New York (Eastern)"},
{"value":"America/Chicago","name":"Chicago (Central)"},
{"value":"America/Denver","name":"Denver (Mountain)"},
{"value":"America/Phoenix","name":"Phoenix (MST)"},
{"value":"America/Los_Angeles","name":"Los Angeles (Pacific)"},
{"value":"America/Anchorage","name":"Anchorage (Alaska)"},
@igorkosta
igorkosta / request.js
Created December 22, 2017 10:36 — forked from sheharyarn/request.js
Axios Request Wrapper for React
/**
* Axios Request Wrapper
* ---------------------
*
* @author Sheharyar Naseer (@sheharyarn)
* @license MIT
*
*/
import axios from 'axios'
@igorkosta
igorkosta / cognito.yaml
Created December 11, 2017 15:08 — forked from singledigit/cognito.yaml
Create a Cognito Authentication Backend via CloudFormation
AWSTemplateFormatVersion: '2010-09-09'
Description: Cognito Stack
Parameters:
AuthName:
Type: String
Description: Unique Auth Name for Cognito Resources
Resources:
# Creates a role that allows Cognito to send SNS messages
@igorkosta
igorkosta / Auth^2_Microservices.md
Last active October 10, 2016 10:32 — forked from andineck/README.md
Authentication and Authorization Concepts for MicroServices

auth with microservices

Authorization and Authentication are hard. when you only have to implement them once (as you do within a monolith) instead of over and over again, it makes the developer happy :-), and maybe leads to less implementation failures.

When you have a bunch of microservices, this is something that has to be considered.

Implement it once or in every microservice, or something in between?

@igorkosta
igorkosta / post_representer.rb
Created May 6, 2016 12:44 — forked from teamon/post_representer.rb
Ruby representers without a library
module PostRepresenter
include Representer
using Representer
def basic(post)
select(post, :id, :name)
end
def details(post)
basic(post) & comments(post)
@igorkosta
igorkosta / introrx.md
Created April 14, 2016 19:59 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing