Skip to content

Instantly share code, notes, and snippets.

View murodin's full-sized avatar
🎯
Focusing

Murat Dindar murodin

🎯
Focusing
View GitHub Profile
@murodin
murodin / curl.md
Created November 10, 2023 11:51 — forked from subfuzion/curl.md
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@murodin
murodin / consist_hash.java
Created August 20, 2022 23:31 — forked from bcambel/consist_hash.java
Consistent Hash Java implementation
import java.util.Collection;
import java.util.SortedMap;
import java.util.TreeMap;
public class ConsistentHash<T> {
private final HashFunction hashFunction;
private final int numberOfReplicas;
private final SortedMap<Integer, T> circle = new TreeMap<Integer, T>();