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
{ | |
"name": "{{$randomFullName}}", | |
"userName": "{{$randomUserName}}", | |
"location": "{{$randomCity}}", | |
"company": "{{$randomCompanyName}}", | |
"jobTitle": "{{$randomJobTitle}}", | |
"updatedAt": "{{$timestamp}}" | |
} |
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
// Build | |
$git clone git@github.com:microsoft/garnet.git | |
$cd garnet | |
$dotnet restore | |
$dotnet build -c Release | |
$dotnet test -c Release -f net8.0 -l "console;verbosity=detailed" | |
// Start server | |
$cd main/GarnetServer | |
$dotnet run -c Release -f net8.0 |
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
$node sample.js | |
{ | |
"id": 32844286, | |
"username": "labore", | |
"email": "ad in enim consequat nisi", | |
"firstName": "Ut nisi", | |
"lastName": "cillum aute est mollit minim", | |
"gender": "female", | |
"image": "velit proident commodo do", | |
"token": "elit dolore" |
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
$docker-compose up -d | |
$docker compose ps | |
NAME IMAGE COMMAND SERVICE CREATED STATUS PORTS | |
lgtm-lgtm-1 grafana/otel-lgtm "/bin/sh -c ./run-al…" lgtm 45 seconds ago Up 45 seconds 0.0.0.0:3000->3000/tcp, 0.0.0.0:4317-4318->4317-4318/tcp | |
$docker images | grep "grafana/otel-lgtm" | |
grafana/otel-lgtm latest f11d1d6cc69b 2 weeks ago 1.34GB |
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
# Builder | |
FROM node:18-alpine as builder | |
# Reference :: https://pnpm.io/docker | |
ENV PNPM_HOME="/pnpm" | |
ENV PATH="$PNPM_HOME:$PATH" | |
RUN corepack enable | |
WORKDIR /src | |
# Cache dependencies first | |
COPY package.json pnpm-lock.yaml ./ |
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
meta { | |
name: Get user detail | |
type: http | |
seq: 1 | |
} | |
get { | |
url: https://jsonplaceholder.typicode.com/users/1 | |
body: none | |
auth: none |
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
// Get data | |
var response = restClient | |
.get() | |
.uri("/users/1") | |
.retrieve() | |
.toEntity(UserResponse.class); | |
// Error handling | |
var request = restClient | |
.get() |
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
func main() { | |
ctx, cancel := signal.NotifyContext(context.Background(), os.Interrupt) | |
defer cancel() | |
shutdown := initProvider(ctx) | |
defer shutdown() | |
commonLabels := []attribute.KeyValue{ | |
attribute.String("result", "[skiped|success|failure]"), |
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
test('test customer login', { tag: ['@fast', '@login'] }, async ({ page }) => { | |
// ... | |
}); | |
// ทำการ run test ด้วย tag | |
$npx playwright test --grep @fast |
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
<Appenders> | |
<!-- Async Loggers will auto-flush in batches, so switch off immediateFlush. --> | |
<RandomAccessFile name="demo" fileName="mylog.log" | |
immediateFlush="false" append="false"> | |
... | |
</RandomAccessFile> | |
</Appenders> |