This file contains hidden or 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
create table test | |
as | |
select id, random() > 0.5 as to_be | |
from generate_series(1, 10000000) as id; | |
CREATE INDEX IF NOT EXISTS idx_1 | |
ON test (id) | |
WHERE to_be = true; | |
CREATE INDEX IF NOT EXISTS idx_2 |
This file contains hidden or 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
#!/bin/bash | |
users=("cantony" "hadmohammadi" "helseoudy" "mmorsy" "mtaufikakbar" "pebermann" "rogupta" "sdousti" "tschlage" "yzykau") | |
token=`ztoken` | |
for user in ${users[*]}; do | |
has_role=$(curl -sH "Authorization: Bearer $token" https://users.auth.zalando.com/api/employees/$user/groups | jq '.[] | select(.dn | contains("24x7 Emergency,ou=Retail Operations")) | length > 0') | |
echo "$user: $has_role" | |
done |
This file contains hidden or 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
#!/bin/bash | |
set -euxo pipefail | |
echo "Starting Colima..." | |
colima start >/dev/null 2>&1 | |
echo "Creating docker.sock anew..." | |
sudo bash -c ' | |
rm /var/run/docker.sock >/dev/null 2>&1 | |
ln -sf $HOME/.colima/default/docker.sock /var/run/docker.sock |
This file contains hidden or 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
import ch.qos.logback.classic.Level; | |
import ch.qos.logback.classic.Logger; | |
import ch.qos.logback.classic.spi.ILoggingEvent; | |
import ch.qos.logback.core.read.ListAppender; | |
import jakarta.annotation.Nonnull; | |
import org.slf4j.LoggerFactory; | |
import java.util.List; | |
import java.util.function.Supplier; |
This file contains hidden or 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
#!/bin/bash | |
# Assign the first argument to branch_name, | |
# or use "new-branch" if no argument is provided | |
branch_name=${1:-new-branch} | |
# Set the branch variable based on existence | |
if git show-ref --verify --quiet refs/heads/master; then | |
branch=master |
This file contains hidden or 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
[ | |
{ | |
"metadata": | |
{ | |
"occurred_at": "2023-08-02T10:52:57.454Z", | |
"eid": "85469179-ef95-41b8-9c04-1184685e5555" | |
}, | |
"data_op": "C", | |
"data_type": "wholesale.goods-receipt-event", | |
"data": |
This file contains hidden or 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
#!/bin/bash | |
secret_name=lumberjack-subscription-management-staging-credentials | |
token=$(zkubectl get secrets $secret_name -ojsonpath='{$.data.nakadi-token-secret}' | base64 -d) | |
# Nakadi URL | |
TEST_URL=https://nakadi-staging.aruha-test.zalan.do | |
PROD_URL=https://nakadi-live.nakadi.zalan.do | |
nakadi_url=$TEST_URL |
This file contains hidden or 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
# First enable "Developer Tools" & "USB Debugging" | |
adb shell | |
pm uninstall -k --user 0 com.mi.globalbrowser | |
pm uninstall -k --user 0 com.miui.analytics |
This file contains hidden or 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
import org.bouncycastle.crypto.agreement.srp.SRP6Client; | |
import org.bouncycastle.crypto.agreement.srp.SRP6Server; | |
import org.bouncycastle.crypto.agreement.srp.SRP6StandardGroups; | |
import org.bouncycastle.crypto.agreement.srp.SRP6VerifierGenerator; | |
import org.bouncycastle.crypto.digests.SHA256Digest; | |
import org.bouncycastle.util.BigIntegers; | |
import java.lang.reflect.Field; | |
import java.math.BigInteger; | |
import java.nio.charset.StandardCharsets; |
This file contains hidden or 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
/* | |
* ==================================================================== | |
* Licensed to the Apache Software Foundation (ASF) under one | |
* or more contributor license agreements. See the NOTICE file | |
* distributed with this work for additional information | |
* regarding copyright ownership. The ASF licenses this file | |
* to you under the Apache License, Version 2.0 (the | |
* "License"); you may not use this file except in compliance | |
* with the License. You may obtain a copy of the License at | |
* |