Skip to content

Instantly share code, notes, and snippets.

View r3code's full-sized avatar

Dmitriy S. Sinyavskiy r3code

View GitHub Profile
{ Created it because I found that defining the columns at design time isn't much productive.
Usage:
Consider CustomersBindingScope is a TBindScope and CustomersGrid is a TStringGrid, and
CustomerBindingScope.DataObject points to a TList<TCustomer> and TCustomer is declared as
follow:
type
TCustomer = class
public
property Name: String read FName write FName;
property Age: Integer read FAge write FAge;
@r3code
r3code / vue.md
Created July 18, 2018 15:33 — forked from DawidMyslak/vue.md
Vue.js and Vuex - best practices for managing your state

Vue.js and Vuex - best practices for managing your state

Modyfing state object

Example

If you have to extend an existing object with additional property, always prefer Vue.set() over Object.assing() (or spread operator).

Example below explains implications for different implementations.

@r3code
r3code / golang-tls.md
Created September 27, 2019 11:44 — forked from denji/golang-tls.md
Simple Golang HTTPS/TLS Examples
Generate private key (.key)
# Key considerations for algorithm "RSA" ≥ 2048-bit
openssl genrsa -out server.key 2048

# Key considerations for algorithm "ECDSA" ≥ secp384r1
# List ECDSA the supported curves (openssl ecparam -list_curves)
@r3code
r3code / conventional-commits-guide-russian.md
Last active April 15, 2025 07:09 — forked from bibendi/gist:7941823
Оформление коммитов

Общепринятые коммиты

Как писать сообщения коммитов (сообщение при фиксации кода в систему хранения версий кода), которые удобны для чтения людьми и машинами. В итоге это может дать нам возможность автоматически генерировать Changelog, и автоматически выпускать новые версии при добавлении возможностей.

За основу взято соглашение https://www.conventionalcommits.org/ru/v1.0.0-beta.4/

Для оформления сообщения коммита следует использовать следующий шаблон:

<тип>(<область>): <описание изменения>

@r3code
r3code / app.yaml
Created October 29, 2019 12:56 — forked from akhenakh/app.yaml
Example of graceful shutdown with grpc healthserver * httpserver
readinessProbe:
exec:
command: ["/root/grpc_health_probe", "-addr=:6666"]
initialDelaySeconds: 1
livenessProbe:
exec:
command: ["/root/grpc_health_probe", "-addr=:6666"]
initialDelaySeconds: 2
imagePullPolicy: IfNotPresent
@r3code
r3code / webstoemp-gulpfile.js
Created April 1, 2020 20:31 — forked from jeromecoupe/webstoemp-gulpfile.js
Gulp 4 sample gulpfile.js. For a full explanation, have a look at https://www.webstoemp.com/blog/switching-to-gulp4/
"use strict";
// Load plugins
const autoprefixer = require("autoprefixer");
const browsersync = require("browser-sync").create();
const cp = require("child_process");
const cssnano = require("cssnano");
const del = require("del");
const eslint = require("gulp-eslint");
const gulp = require("gulp");
@r3code
r3code / goroutinesLimit.go
Created April 19, 2020 09:21 — forked from unanoc/goroutinesLimit.go
Ограничение горутин по ресурсам. А именно, чтобы в одно время работало не больше определенного количества горутин.
package main
import (
"fmt"
"runtime"
"strings"
"sync"
"time"
)
@r3code
r3code / db.go
Created November 4, 2020 17:40 — forked from adamfdl/db.go
package sql
import (
"database/sql"
)
var (
ErrNoRows = sql.ErrNoRows
)
@r3code
r3code / README.md
Last active April 20, 2021 14:07 — forked from vporoshok/README.md
Snippet of README file for RDD (Readme driven development)

Russian version here

So, are you building microservices? Take a look at a few of these symptoms, and decide for yourself:

  • A change to one microservice often requires changes to other microservices
  • Deploying one microservice requires other microservices to be deployed at the same time
  • Your microservices are overly chatty
  • The same developers work across a large number of microservices