Skip to content

Instantly share code, notes, and snippets.

@sheac
sheac / dev-accepting-affected-fields.md
Last active May 8, 2018 21:26
Some demos for affected-fields ticket Dev Acceptance
@sheac
sheac / backfill-doc-checksum-script-safety.md
Last active May 15, 2018 16:42
Verify the safety and effectiveness of the script for backfilling document checksums

1. Purpose

This gist is to verify the safety and effectiveness of the script for backfilling document checksums. The script can be found on this mothership PR.

2. Script Requirements

This "script" is meant to fill in checksums for any documents table row that should have a checksum, but doesn't. Documents "should have" a checksum if pending == false. But not all do.

Beacon Error Spam Investigation

Summary

I can't find any reason for this in the code. But based on its movement from staging to production at roughly our deploy cycle cadence, I advise checking to see if there is any environment/config changes that are responsible.

Problem

At some point, staging and production each started encountering the same error:

Intro

First, I don't know the answer to this yet, so I can't tell you. What I can do is show you how I'd find the answer.

I'll be using line numbers, which will change when you merge master back into your branch. The commit I'm working off of is the current git HEAD of your PR.

Start with the error message

@sheac
sheac / martin-jung-backend-eng-interview-2018-july-19.md
Last active July 20, 2018 23:57
Martin Jung (Backend Eng) Interview - 2018-July-19

Martin Jung

Video Interview

Mogo

Questions Asked

  • General questions about his background and experience
  • Two-way chit-chat about microservices best practices and trade-offs
  • Coding problem:
    • Using any programming language (even pseudocode), write a function that takes in a string and outputs the first non-repeating character
@sheac
sheac / jaeger-zipkin-instrumentation-estimates.md
Last active August 10, 2018 00:55
Work Estimates for Instrumenting Beacon with Jaeger (and Almost with Zipkin)

Estimating Instrumentation Effort for Jaeger and Zipkin

Terminology

Tracing framworks have the following components:

  1. A client library that is used directly in the application code for instrumenation
  2. A sidecar application that buffers data from the client library and passes it along
  3. A dedicated aggregation and reporting server that accumulates and processes data from sidecar applications

Questions for Kepware People

How long is data retained for on the KepServerEx server?

  • What are conditions under which data loss may occur?

What are the trade-offs of using the ODBC interface, vs IoT Gateway?

Notes from August 20 2018 meeting with Kepware

Attendees

  • Shea
  • Sam
  • Brent (Kep)
  • Nick (Kep

Kepware's IoT Gateway REST Server does not store data in a historical or time-series fashion

Let's design a URL-shortener service

Requirements:

  • Accepts a long URL string
  • Quickly returns a URL that is:
    • Short
    • Unique
  • Redirects from resulting shortened URLs to corresponding long URL input
  • Has "sane" expiration policy (for negotiable definition of "sane")