This file contains 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
[package] | |
name = "lambda_runtime" | |
version = "0.4.1" | |
edition = "2021" | |
[dependencies] | |
tokio = { version = "1.0", features = ["macros", "io-util", "sync", "rt-multi-thread"] } | |
hyper = { version = "0.14", features = ["http1", "client", "server", "stream", "runtime"] } | |
serde = { version = "1", features = ["derive"] } | |
serde_json = "^1" |
This file contains 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
[package] | |
name = "hnrs" | |
version = "0.1.0" | |
edition = "2018" | |
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | |
[profile.release] | |
"codegen-units" = 1 | |
lto = "fat" |
This file contains 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
// g++ -o bench.exe --std=c++17 -lpqxx bench.cc | |
// POSTGRES_CONNECTION_STRING=<connection string> ./bench.exe <threads count> <iterations count> <max rows> <mode 0-5> | |
#include <iostream> | |
#include <functional> | |
#include <pqxx/pqxx> | |
#include <thread> | |
#include <future> | |
#include <cstring> | |
#include <vector> |
This file contains 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
/* eslint-disable @typescript-eslint/explicit-function-return-type */ | |
const SHA256 = require('crypto-js/sha256') | |
const encHex = require('crypto-js/enc-hex') | |
const HmacSHA256 = require('crypto-js/hmac-sha256') | |
const AWS_SHA_256 = 'AWS4-HMAC-SHA256' | |
const AWS4_REQUEST = 'aws4_request' | |
const AWS4 = 'AWS4' | |
const X_AMZ_DATE = 'x-amz-date' |
This file contains 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 { declareRuntimeEnv } from 'resolve-scripts' | |
export default { | |
target: 'cloud', | |
mode: 'production', | |
staticPath: declareRuntimeEnv('RESOLVE_CLOUD_STATIC_URL'), | |
eventstoreAdapter: { | |
module: 'resolve-eventstore-postgresql-serverless', | |
options: { | |
awsSecretStoreArn: declareRuntimeEnv('RESOLVE_ES_SECRET_ARN'), |
This file contains 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
-- Copyright from https://www.red-gate.com/simple-talk/sql/t-sql-programming/consuming-json-strings-in-sql-server/ | |
CREATE TYPE dbo.Hierarchy AS TABLE | |
( | |
element_id INT NOT NULL, /* internal surrogate primary key gives the order of parsing and the list order */ | |
sequenceNo [int] NULL, /* the place in the sequence for the element */ | |
parent_ID INT,/* if the element has a parent then it is in this column. The document is the ultimate parent, so you can get the structure from recursing from the document */ | |
[Object_ID] INT,/* each list or object has an object id. This ties all elements to a parent. Lists are treated as objects here */ | |
NAME NVARCHAR(2000),/* the name of the object, null if it hasn't got one */ | |
StringValue NVARCHAR(MAX) NOT NULL,/*the string representation of the value of the element. */ |
This file contains 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 { Selector } from 'testcafe' | |
const ROOT_URL = `https://jd05ienjxfkjegg8mim64t8z1e.resolve.sh` | |
const roundSeed = `${Date.now()}-${Math.floor(Math.random()*100000000000)}` | |
fixture`Testcafe stress` | |
test('Testcafe stress test', async (t) => { | |
await t.setNativeDialogHandler(() => true) | |
{ |
This file contains 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
fixture`HackerNews`.page`https://jd05ienjxfkjegg8mim64t8z1e.resolve.sh/` | |
test('HackerNews 1', async t => { | |
await t.setNativeDialogHandler(() => true) | |
const pageContent = (await t.eval(() => window.document.body.innerHTML)) | |
console.log(pageContent) | |
}) | |
test('HackerNews 2', async t => { | |
await t.setNativeDialogHandler(() => true) |
This file contains 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
fixture`ResolveJS`.page`https://github.com/reimagined/resolve` | |
test('ResolveJS', async t => { | |
await t.setNativeDialogHandler(() => true) | |
const locationPath = (await t.eval(() => window.location)).pathname | |
await t.expect(locationPath).eql('/reimagined/resolve') | |
// await t.expect(locationPath).eql('/reimagined/resolve2') | |
}) |
This file contains 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
curl "https://api.github.com/repos/ORG/REPO/statuses/COMMIT_SHA?access_token=ACCESS_TOKEN" -H "Content-Type: application/json" -X POST -d "{\"state\": \"success\", \"context\": \"continuous-integration/drone/push\", \"target_url\": \"\"}" |
NewerOlder