- Weekly Agenda (created on a different day, and embedded with
/Block Reference
) - [[Morning Questions]] [[2/24 -- 3/1/2020]]
- {{[[slider]]}} How many hours of sleep did I get?
- [[What's one thing top of mind today?]]
- [[What's the one thing I need to get done today to make progress?]]
- Agenda
- {{[[TODO]]}} 2 hours focused time
- {{[[TODO]]}} Read 30 minutes #goal-learning #habit
- Health & self-care
- {{[[TODO]]}} 30 minutes outside #goal-health #habit
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
############################################################################### | |
### Reaction OSS v3.0.4 | |
### This is an example configuration and is not modified from the original | |
### reaction-v3.0.4.mk | |
############################################################################### | |
# List of tools that must be installed. | |
# A simple check to determine the tool is available. No version check, etc. | |
define REQUIRED_SOFTWARE | |
docker \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defmacro map-fields-comparator | |
"Comparator for sorting maps by field. `kw-orders` must be pairs of keywords | |
on which to sort and a sort direction, either :asc or :desc. | |
Example: | |
(map-fields-comparator :id :asc :time :desc) | |
The above is fine for key values that are inexpensive to compute from the values | |
being sorted. If the key values are expensive to compute, it is better to |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
title Inventory Data Flow | |
participant Kafka Topic | |
participant Shippable-Inventory-Plugin | |
participant Simple-Inventory-Plugin | |
participant Inventory | |
participant MongoDB SimpleInventory | |
participant MongoDB Products | |
participant MongoDB Orders |
bin/kafka-topics.sh --zookeeper localhost:2181 --list
bin/kafka-topics.sh --zookeeper localhost:2181 --describe --topic mytopic
bin/kafka-topics.sh --zookeeper localhost:2181 --alter --topic mytopic --config retention.ms=1000
... wait a minute ...
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def ^:dynamic repl-context) | |
(defn tinyrepl | |
"Simple REPL. :quit to exit." | |
[{:keys [prefix layer] :or {prefix "" layer 1} :as context}] | |
(let [pre (str prefix ">>>")] | |
(with-bindings {#'repl-context (assoc context | |
:prefix pre | |
:layer (inc layer))} | |
(print (str (ns-name *ns*) (str pre " "))) | |
(flush) |
I hereby claim:
- I am ticean on github.
- I am ticean (https://keybase.io/ticean) on keybase.
- I have a public key whose fingerprint is 4027 3B22 CA85 EDBE A3C3 A3FD 678F F894 896B C705
To claim this, I am signing this object:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- show running queries (pre 9.2) | |
SELECT procpid, age(query_start, clock_timestamp()), usename, current_query | |
FROM pg_stat_activity | |
WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%' | |
ORDER BY query_start desc; | |
-- show running queries (9.2) | |
SELECT pid, age(query_start, clock_timestamp()), usename, query | |
FROM pg_stat_activity | |
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%' |
Simply put, destructuring in Clojure is a way extract values from a datastructure and bind them to symbols, without having to explicitly traverse the datstructure. It allows for elegant and concise Clojure code.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Demo contextual log pattern with the logfmt-node library. | |
var logger = require('logfmt').namespace({app: "test"}); | |
function task(id, throwError) { | |
var taskLogger = logger.namespace({event: "task.run", "task.id": id}); | |
var taskTimer = taskLogger.time(); | |
taskLogger.log({msg: "Starting the task.", at: "start"}); | |
setTimeout(function() { |
NewerOlder