Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Reproducer:
Lets add test for space and tuple-space with asynchronous mode.
New config:
https://github.com/Sberbank-Technology/tarantool-clj-1.7/blob/master/config/test_async.clj
New test file:
https://github.com/Sberbank-Technology/tarantool-clj-1.7/blob/master/test/tarantool_clj/client_async_test.clj
Test results:
tuple-space test - {:test 1, :pass 9, :fail 0, :error 0, :type :summary}
space test - {:test 1, :pass 0, :fail 0, :error 15, :type :summary}
When i tried "(space/select-first space {:id 1})", i got "CompilerException java.lang.IllegalArgumentException: Don't know how to create ISeq from: clojure.core.async.impl.channels.ManyToManyChannel, compiling:(D:/work/connector/test/tarantool_clj/client_async_test.clj:26:1)". It happened cause record TarantoolConnection returned channel (in async mode), then record Space tried to exec function first with channel. Same with other funcs.
My offer: add parameter callback-function to send-request at Connection. This callback-fn contains function for processing data from tarantool, so data in channel is ready for use and there is no need to process data in Space record.
Lets discuss this solution.