The first 2 characters of the UUID value comes from the MD5 hash of the backend pid modulo 3. The next 2 characters are the MD5 hash of the concatenation of the current year and week number. This value is, of course, static over a week. The remaining of the UUID value comes from the MD5 of a random value and the current time at a precision of 1us. The third field is prefixed with a “4” to indicate it is a version 4 UUID type.
const bitcoin = require('bitcoinjs-lib'); | |
var privatekey = process.argv[2] | |
// NOTE: only wif and pubKeyHash are correct, they were all that is needed for this function to work | |
const pair = bitcoin.ECPair.fromWIF(privatekey, { | |
messagePrefix: '\x19Denarius Signed Message:\n', | |
bip32: { | |
public: 0x019da462, // TODO DONT USE | |
private: 0x019d9cfe // TODO DONT USE |
#!/bin/bash | |
if [ -z "$2" ] | |
then | |
echo "Usage: $(basename $0) <namespace> <app>" | |
exit 1 | |
fi | |
POD=$(kubectl get pods -n $1 -l app=$2 -o jsonpath="{.items[*].metadata.name}") | |
kubectl logs -n $1 $POD -f |
function fit(num, oldmin, oldmax, newmin, newmax) { | |
const ratio = (num - oldmin) / (oldmax - oldmin); | |
return newmin + ratio * (newmax - newmin); | |
} |
//registry.npmjs.org/:_authToken=${NPM_TOKEN} |
//registry.npmjs.org/:_authToken=${NPM_TOKEN} |
var CSSOM = require('cssom'); | |
/** | |
* @param {Object} object | |
* @return {Object} | |
*/ | |
function uncircularOwnProperties(object) { | |
function _uncircular(object, depth, stack) { | |
var stackLength = stack.push(object); | |
depth++; |
The first four characters of the UUID value comes from the MD5 hash of the concatenation of the current year and week number. This value is, of course, static over a week. The remaining of the UUID value comes from the MD5 of a random value and the current time at a precision of 1us. The third field is prefixed with a “4” to indicate it is a version 4 UUID type. There are 65536 possible prefixes so, during a week, only 1/65536 of the table rows are required in the memory to avoid a read IOP upon insertion. That’s much easier to manage, a 1TB table will need to have only about 16MB in the buffer pool to support the inserts
The first 2 characters of the UUID value comes from the MD5 hash of a supplied UUID. The next 3 characters are the MD5 hash of the concatenation of the current year and week number -- this value is, of course, static over a week. The remaining of the UUID value comes from the MD5 of a random value and the current time at a precision of 1us. The third field is prefixed with a “4” to indicate it is a version 4 UUID type.
apiVersion: extensions/v1beta1 | |
kind: Deployment | |
metadata: | |
name: my-app | |
spec: | |
replicas: 1 | |
template: | |
metadata: | |
labels: | |
app: my-app |