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
void main() { | |
} |
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 redis | |
import redis.sentinel | |
import logging | |
# TODO: would be useful to also | |
def discover_redis_master(sentinel_addrs, redis_name): | |
"""Use listed sentinels to find the redis master | |
""" | |
sentinel = redis.sentinel.Sentinel(sentinel_addrs, socket_timeout=0.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
############################################################################### | |
# | |
# The MIT License (MIT) | |
# | |
# Copyright (c) Crossbar.io Technologies GmbH | |
# | |
# Permission is hereby granted, free of charge, to any person obtaining a copy | |
# of this software and associated documentation files (the "Software"), to deal | |
# in the Software without restriction, including without limitation the rights | |
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
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
/* | |
This file had now been added to the git repo | |
https://github.com/darrenjs/openssl_examples | |
... which also includes a non blocking client example. | |
------------------------------------------------------------------------------- | |
ssl_server_nonblock.c -- Copyright 2017 Darren Smith -- MIT license |