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
// Send | |
StreamSender sender = conn.openStreamSender(address); | |
StreamSenderMessage message = sender.beginMessage(); | |
OutputStream out = message.dataOutputStream(); | |
// Receive | |
StreamReceiver receiver = conn.openStreamReceiver(address); |
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
def get_apples(): | |
for apple in database: | |
yield apple | |
for apple in get_apples(): | |
process(apple) |
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
diff --git a/python/generate.py b/python/generate.py | |
index 9e25cf1e4..9de10f06e 100644 | |
--- a/python/generate.py | |
+++ b/python/generate.py | |
@@ -58,8 +58,8 @@ def setup_release_script(): | |
call_and_print_on_error("cmake --version") | |
call_and_print_on_error("dot -V") | |
call_and_print_on_error("doxygen --version") | |
- call_and_print_on_error("epydoc --version") | |
- call_and_print_on_error("fop -version") |
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
diff --git a/scripts/test-minikube b/scripts/test-minikube | |
index cbda5c0..0127ee8 100755 | |
--- a/scripts/test-minikube | |
+++ b/scripts/test-minikube | |
@@ -3,6 +3,11 @@ | |
from tests import * | |
def main(): | |
+ # XXX | |
+ ENV["SKUPPER_PROXY_IMAGE"] = "quay.io/skupper/proxy:latest" |
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
FROM centos:8 | |
RUN dnf -qy install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm | |
RUN dnf -y install cmake gcc make openssl-devel python3-devel python3-requests qpid-proton-c-devel python3-qpid-proton | |
RUN curl -sfo qpid-dispatch-1.12.0.tar.gz https://downloads.apache.org/qpid/dispatch/1.12.0/qpid-dispatch-1.12.0.tar.gz | |
RUN tar -xf qpid-dispatch-1.12.0.tar.gz | |
RUN mkdir bld | |
WORKDIR bld |
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
// What we have: | |
void on_container_start(proton::container& cont) override { | |
proton::connection_options opts{}; | |
proton::reconnect_options ropts{}; | |
ropts.failover_urls(failover_urls_); | |
opts.reconnect(ropts); | |
cont.connect(primary_url_, opts); |
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
main.py: | |
from starlette.applications import Starlette | |
app = Starlette(debug=True) | |
-- | |
$ pip3 install --user hypercorn starlette | |
$ hypercorn main:app |
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
gdb -ex run -ex bt -ex "set confirm off" -ex quit --args build/multithreading/receive-acknowledge amqp://localhost:5672 q0 100 |
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
General idea: | |
- Base class Message, returned from delivery.message() | |
- Possibly, subclasses with interfaces that differ according to use cases | |
Common case: | |
- There's one body (maps, string, bytes) | |
- Bytes -> data section | |
- Otherwise -> AMQP value section |
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
def run_test(west_kubeconfig, east_kubeconfig): | |
# XXX | |
ENV["SKUPPER_PROXY_IMAGE"] = "quay.io/skupper/proxy:latest" | |
ENV["SKUPPER_CONTROLLER_IMAGE"] = "quay.io/ernieallen/controller:latest" | |
# End XXX | |
connection_token = make_temp_file() | |
with working_env(KUBECONFIG=west_kubeconfig): | |
call("kubectl create namespace west") |
NewerOlder