To create a cluster, we need to spin up a few empty Redis instances and configure them to run in cluster mode.
Here’s a minimal configuration file for Redis Cluster:
# redis.conf file
port 7000| package main | |
| import ( | |
| "fmt" | |
| "log" | |
| "github.com/go-ldap/ldap/v3" | |
| ) | |
| const ( |
| package main | |
| import ( | |
| "bytes" | |
| "encoding/hex" | |
| "flag" | |
| "fmt" | |
| "io" | |
| "log" | |
| "net" |
| machine github.com | |
| login technoweenie | |
| password SECRET | |
| machine api.github.com | |
| login technoweenie | |
| password SECRET |
| AWSTemplateFormatVersion: 2010-09-09 | |
| Transform: AWS::Serverless-2016-10-31 | |
| Resources: | |
| VPC: | |
| Type: AWS::EC2::VPC | |
| Properties: | |
| CidrBlock: 10.0.0.0/16 | |
| InternetGateway: |
This TRIGGER function calls PosgreSQL's NOTIFY command with a JSON payload. You can listen for these calls and then send the JSON payload to a message queue (like AMQP/RabbitMQ) or trigger other actions.
Create the trigger with notify_trigger.sql.
When declaring the trigger, supply the column names you want the JSON payload to contain as arguments to the function (see create_triggers.sql)
The payload returns a JSON object:
| package query_builder | |
| import ( | |
| "strings" | |
| "strconv" | |
| "html/template" | |
| "fmt" | |
| ) | |
| type DynamicQueryBuilder string |
| license: gpl-3.0 | |
| height: 300 |
| // paket add nuget NEST | |
| #I "../../packages" | |
| #r "Elasticsearch.Net/lib/net46/Elasticsearch.Net.dll" | |
| #r "NEST/lib/net46/Nest.dll" | |
| open System | |
| //open Elasticsearch.Net | |
| open Nest |