From 6355144b8c3514cccc5c2ab4f7c4fd8e76a1a9fc Mon Sep 17 00:00:00 2001 From: hozan23 Date: Sun, 23 Jun 2024 15:57:43 +0200 Subject: Fix the issue with message dispatcher and channels Resolved a previous error where each subscription would create a new channel with the fixed buffer size. This caused blocking when the channel buffer was full, preventing the client from handling additional messages. Now, there is a `subscriptions` struct that holds a queue for receiving notifications, ensuring the notify function does not block. --- Makefile | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..12f1a55 --- /dev/null +++ b/Makefile @@ -0,0 +1,17 @@ +GO := go +LINTER := golangci-lint +PKGS := ./... + +.PHONY: all test lint clean + +all: lint test + +test: + $(GO) test $(PKGS) + +lint: + $(LINTER) run $(PKGS) + +clean: + $(GO) clean + -- cgit v1.2.3