Skip to content

Instantly share code, notes, and snippets.

Logs of pinniped-proxy using the `RUST_LOG=info,mio=trace` to see the polling registration and deregistration of tokio's mio.
The first two requests get proxied...
2022-10-18T00:47:13.870Z TRACE mio::poll > registering event source with poller: token=Token(16777220), interests=READABLE | WRITABLE
2022-10-18T00:47:13.870Z INFO pinniped_proxy::service > Beginning proxy request for https://kubernetes.default/api?timeout=32s
2022-10-18T00:47:13.870Z INFO pinniped_proxy::service > Exchanging id_token for X509 client identity using pinniped
2022-10-18T00:47:13.875Z TRACE mio::poll > registering event source with poller: token=Token(16777218), interests=READABLE | WRITABLE
2022-10-18T00:47:13.875Z INFO pinniped_proxy::service > Beginning proxy request for https://kubernetes.default/apis/authorization.k8s.io/v1/selfsubjectaccessreviews
2022-10-18T00:47:13.875Z INFO pinniped_proxy::service > Exchanging id_token for X509 client identity using pinniped
@absoludity
absoludity / comparison.md
Created August 23, 2022 21:00
Comparison of main vs upsert_handle for sharding/input

q4 single core

This query is greatly improved from main to upsert_handle, although, only slightly for the input usr CPU (which is similar), the bulk of the improvement is in the actual DBSP Usr CPU (where the step()s are called).

main q4 1 core

database-stream-processor git:(main) cargo bench --bench nexmark --features with-nexmark -- --first-event-rate=10000000 --max-events=10000000 --cpu-cores 1 --query q4
   Compiling dbsp v0.1.0 (/home/michael/dev/vmware/database-stream-processor)
    Finished bench [optimized + debuginfo] target(s) in 27.61s
     Running benches/nexmark/main.rs (target/release/deps/nexmark-c782d17920c2b5ef)
@absoludity
absoludity / kubeapps-carvel-pkg-8.0.10.yaml
Created April 12, 2022 06:54
Testing Kubeapps Carvel packaging for 8.0.10
---
apiVersion: data.packaging.carvel.dev/v1alpha1
kind: PackageMetadata
metadata:
name: "kubeapps.community.tanzu.vmware.com"
spec:
displayName: "Kubeapps"
shortDescription: "Kubeapps is a web-based UI for deploying and managing applications in Kubernetes clusters."
providerName: VMware
maintainers:
$ grpcurl -plaintext -d '{"context":{"namespace":"ldap"}}' localhost:8080 kubeappsapis.plugins.helm.packages.v1alpha1.HelmPackagesService.GetInstalledPackageSummaries
{
"installedPackageSummaries": [
{
"installedPackageRef": {
"context": {
"namespace": "ldap"
},
"identifier": "ldap"
},
$ grpcurl -plaintext -d '{"context": {"namespace": "default"},"filterOptions": {"query": "zookeeper"}}' localhost:8080 kubeappsapis.plugins.helm.packages.v1alpha1.HelmPackagesService.GetAvailablePackageSummaries
{
"availablePackageSummaries": [
{
"availablePackageRef": {
"context": {
"namespace": "kubeapps"
},
"identifier": "bitnami/dataplatform-bp1",
"plugin": {
# First, a non-root container with a volume, no fsGroup 0 security context:
$ cat <<EOF | kubectl apply -f -
apiVersion: v1
kind: Pod
metadata:
name: mariadb-test
spec:
securityContext:
runAsNonRoot: true
@absoludity
absoludity / storage_accounts.json
Created April 12, 2018 00:33
Test idempotency
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "0.0.0.1",
"variables": {
"accountPrefix": "[concat('test-sm2', uniqueString(resourceGroup().id))]",
"storageAccountOutputName": "[concat(variables('accountPrefix'), 'output')]",
"storageAccountInputName": "[concat(variables('accountPrefix'), 'input')]"
},
"resources": [
{

Keybase proof

I hereby claim:

  • I am absoludity on github.
  • I am michaelnelson (https://keybase.io/michaelnelson) on keybase.
  • I have a public key ASC4lH9yiBpERE2tYgTGSfNAIZzvuiVEEkHk5PszqE_5-wo

To claim this, I am signing this object:

#!/bin/bash
set -euo pipefail
# sagan is a runnable jar from spring, with built-in servlet.
sudo systemctl stop tomcat
# Our current build script copies the uploaded jar into a directory of the same
# name (as the extension doesn't match war|WAR|zip|ZIP).
java -jar /usr/share/tomcat/webapps/sagan-site-1.0.0.BUILD-SNAPSHOT.jar/sagan-site-1.0.0.BUILD-SNAPSHOT.jar
#!/bin/bash
# This script demos an issue I see with aws s3 presigned urls, where depending on
# the bucket host resolved by dns, I see different behaviour - for some IPs
# the timeout is checked at the beginning of the request, others apparently the end.
set -eu
# The url at which I'm creating a presigned url
# with a 10s timeout.
BASE_URL=${1:-"http://localhost:3010"}