Skip to content

Instantly share code, notes, and snippets.

View palash25's full-sized avatar

Palash Nigam palash25

View GitHub Profile
@Horusiath
Horusiath / DESIGN.md
Last active June 21, 2023 18:21
Yggdrassil design document

Yggdrassil design document

This paper discusses some ideas of how to extend HyParView/Plumtree beyond the most straightforward implementation. It presents the goals that we wanted to have in mind when building actual implementation in Rust.

Motivation

While Partisan - the original and probably the most widely adopted implementation of HyParView+Plumtree - value proposition relies on building huge clusters (having >10 000 nodes) capable of broadcasting messages via self-healing broadcast trees, its network protocol seems to limit its possibilities to centralized solutions - like services living in data centres or at the edge, where peer discoverability and reachability is in control of their developers/operators. Other issue is that when exchanging neighbors/shuffle peers, plumtree blindly replaces them with current passive view without checking if they are reachable for the current peer in the first place.

We think, that adopting HyParView/Plumtree in Rust with extensible API could expand its capabil

@Horusiath
Horusiath / Prolog.fs
Last active May 17, 2024 15:12
Yata move algorithm
namespace Demos
open System
type ReplicaId = String
[<RequireQualifiedAccess>]
module Array =
@typesanitizer
typesanitizer / resources.md
Last active October 29, 2024 03:54
Software Engineering and Management resources

Here is a list of resources that I have read either fully, or at least to an extent with which I am comfortable with endorsing them.

I've used these resources in different ways:

  • Direct application: Some bits and pieces of advice can be applied very directly.
  • Reflection: For organizational things, sometimes I would try to write down how I felt my work environment mirrored, and how it differed from the situation described in some work. Writing things down is a useful forcing function to think clearly.
  • 1:1 discussions with my manager: We'd take the first 15-20 minutes of
@niklaskorz
niklaskorz / goroutines.go
Last active May 5, 2023 09:51
Threading Performance Comparison
package main
import (
"fmt"
"os"
"runtime"
"sync"
"time"
)
@Horusiath
Horusiath / Protocols.fs
Last active June 21, 2023 18:20
Plumtree + Hyparview implementation in F#
namespace Protocols
open System
open System.Runtime.ExceptionServices
type Endpoint = string
type TTL = int
type Binary = byte[]
type MessageId = Guid
type Round = uint64
@Horusiath
Horusiath / Program.fs
Last active June 21, 2023 18:23
Fun with concepts about composeable logging.
open System
open System.IO
open System.Threading.Tasks
(*
Some notes:
1. TextWriter is overbloated. Ideally this should be something like Go's io.Writer interface. Notice that Go doesn't
differentiate between async/non-async functions (it doesn't have to), which makes API even simpler.
2. While very rough, this snippet already provides a lot of what mature logging frameworks (like Serilog) can do:
@bushidocodes
bushidocodes / wasm-summit-2020-notes.md
Last active July 30, 2020 23:47
WebAssembly Summit 2020 Notes

WebAssembly Summit 2020

https://webassembly-summit.org/

Lin Clark's Talk - "WebAssembly Nanoprocess"

https://www.youtube.com/watch?v=IBZFJzGnBoU

  • the missing functionality alongside WASI and Interface Types is something that provides "capability-based security".
  • Delegation of permissions to propagate down transitive dependencies
  • plan to use fine-grain form of per-module virtualization
  • A "WebAssembly nanoprocess" is just wasm, but follows a particular pattern.
@Horusiath
Horusiath / Fiber.fs
Last active May 17, 2024 15:09
Custom fibers implementation in F#
/// MIT License
///
/// Copyright (c) 2024 Bartosz Sypytkowski
///
/// Permission is hereby granted, free of charge, to any person obtaining a copy
/// of this software and associated documentation files (the "Software"), to deal
/// in the Software without restriction, including without limitation the rights
/// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
/// copies of the Software, and to permit persons to whom the Software is
/// furnished to do so, subject to the following conditions:
@shakna-israel
shakna-israel / Prose.md
Last active November 15, 2023 22:06
Obfuscating Python

Obfuscating Python

Obfuscation isn't difficult in most programming languages. It's why we have "good practices" because it is so easy to hide what you mean in badly written code.

Obfuscation tends to be even easier in dynamic languages because of how forgiving they tend to be - and because they tend to give you direct access to the environment so that you can manipulate it.

Today, for fun, I'm going to obfuscate this code:

def _(n):

if n <= 0:

@Horusiath
Horusiath / Main.fs
Last active June 21, 2023 18:27
Affine thread pool
/// The MIT License (MIT)
///
/// Copyright (c) Bartosz Sypytkowski <[email protected]>
///
/// Permission is hereby granted, free of charge, to any person obtaining a copy
/// of this software and associated documentation files (the "Software"), to deal
/// in the Software without restriction, including without limitation the rights
/// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
/// copies of the Software, and to permit persons to whom the Software is
/// furnished to do so, subject to the following conditions: