-
Notifications
You must be signed in to change notification settings - Fork 3
first draft of Bulk API and retrieve tests #122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Good stuff, nice progress! How could we keep this aligned (to a sensible degree) with the TypeScript implementation? |
|
Nice! We should be able to run this client against the |
I played with the idea of making the code in https://github.com/Strumenta/starlasu-lionweb-repository-client implement the interfaces exposed by this PR. The first issue I ran into is that the code in my client is asynchronous (I used Kotlin's coroutines) while this code is synchronous. I can make the asynchronous code synchronous, like this:
But this raised the question: would it make sense to have the interfaces implement asynchronous methods and then have a wrapper that makes those calls synchronous for clients who prefer synchronous APIs? |
Maybe the other way around: define a synchronous API, and (re-)wrap that in an asynchronous one, and always use and implement the latter.
Uhm, synchronous can be made asynchronous but not the other way around. (“Asynchronicity is viral.”) I think it's an inherent property of distributed systems that calls are inherently asynchronous. |
I agree with Meinte, the code should stay synchronous. Java allows wrapping in both directions, but the API is cleaner in the sync variant, and it is a lot easier to debug. |
Ok then, thank you for the comments |
Eventually we took inspiration from this and introduced a synchronous interface ( |
I guess they should end up in the integration repo -- we should have something similar as the delta tests also for bulk. |
No description provided.