Skip to content

Instantly share code, notes, and snippets.

@timothycosta
timothycosta / CADisplayLinkBinding.swift
Last active April 3, 2020 00:43
A CADisplayLink in a BindableObject
//
// CADisplayLinkBinding.swift
// lingq-5
//
// Created by Timothy Costa on 2019/07/11.
// Copyright © 2019 timothycosta.com. All rights reserved.
//
import Combine
import SwiftUI
@helephant
helephant / concurrency-limits-and-step-functions.md
Last active November 23, 2022 10:30
Do step functions wait for an available lambda if they hit a concurrency limit or do they fail?

We have a process that spawns lots of lambdas that we were worried might hit a concurrency limit. We wanted to know what a step function would do in that situation because the AWS documentation says that poll-based services have a built-in retry mechanism if lambdas are throttled and we were hoping that the subsequent steps would simply wait until there was enough capacity.

So I built a step function with three steps that had a sleep in them, and then set the reserve concurrency to 1 for the middle step. Then I kicked off three step functions at the same time.

The result was the second intance of the step function failed on the throttled lamda with the error message: "Lambda.TooManyRequestsException"

There are retry options in step functions, but it is interesting to know that they don't wait for a lambda slot to be available.

PDF Make Definitions

A list of all the properties for the Document Definition objects in PDF Make. Gathered from the examples source code. Up to date for version 0.1.38.

Basic definition

  • The Document Definition is a javascript object: {}. It can contain the following.
  • content: array. This defines the layout of your document. All your tags will be defined in there. You define tags using object (e.g. content: [{text: 'Hello World'}])
  • styles: object. A dictionary of all the named styles in your document. You can then apply a style to any object using style: 'name' or style: ['name1', 'name2']
  • defaultStyle: object. Defines a style to be applied to every element in the document.
  • images: object. Another dictionary that you can use to specify all the images in your document.
<?xml version="1.0" encoding="UTF-8"?>
<ruleset xmlns="http://mojo.codehaus.org/versions-maven-plugin/rule/2.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" comparisonMethod="maven" xsi:schemaLocation="http://mojo.codehaus.org/versions-maven-plugin/rule/2.0.0 http://mojo.codehaus.org/versions-maven-plugin/xsd/rule-2.0.0.xsd">
<ignoreVersions>
<!-- Ignore Alpha's, Beta's, release candidates and milestones -->
<ignoreVersion type="regex">(?i).*Alpha(?:-?\d+)?</ignoreVersion>
<ignoreVersion type="regex">(?i).*Beta(?:-?\d+)?</ignoreVersion>
<ignoreVersion type="regex">(?i).*-B(?:-?\d+)?</ignoreVersion>
<ignoreVersion type="regex">(?i).*RC(?:-?\d+)?</ignoreVersion>
<ignoreVersion type="regex">(?i).*CR(?:-?\d+)?</ignoreVersion>
<ignoreVersion type="regex">(?i).*M(?:-?\d+)?</ignoreVersion>
@kbradl16
kbradl16 / AngularJS-ES6-Test-Skeleton
Created June 30, 2017 19:37 — forked from madhums/AngularJS-ES6-Test-Skeleton
AngularJS - Karma, Jasmine, Browserify, Stringify - ES6 Test Setup
We couldn’t find that file to show.
@remojansen
remojansen / class_decorator.ts
Last active September 14, 2023 14:54
TypeScript Decorators Examples
function logClass(target: any) {
// save a reference to the original constructor
var original = target;
// a utility function to generate instances of a class
function construct(constructor, args) {
var c : any = function () {
return constructor.apply(this, args);
}
@trabuccocampos
trabuccocampos / movewaves.css
Last active May 8, 2017 22:25
Wave .svg animation
/* WAVES as seen on http://www.villafeltrinelli.com
* -------------------------- */
.wave_wrapp {
width: 400px;
position: absolute;
background: red;
top: 120px;
position: absolute;
left: 50%;
margin-left: -200px;
@busypeoples
busypeoples / AngularJS-ES6-Test-Skeleton
Last active June 6, 2020 01:29
AngularJS - Karma, Jasmine, Browserify, Stringify - ES6 Test Setup
We couldn’t find that file to show.
@hofmannsven
hofmannsven / README.md
Last active July 16, 2024 01:30
Git CLI Cheatsheet