Skip to content

getAsync* methods are actually synchronous #31

Open
@mircea-cm

Description

@mircea-cm

All getAsync methods are actually synchronous.

For example, getAsyncChatCompletion (in AsyncDAOImpl) returns a POJO object: ChatCompletionResponse, and it should return a Future.

You create a CompletableFuture (all well for now), but the method ends in

return (ChatCompletionResponse)future.get();

Basically, it blocks the current thread until the future completes.

For the methods to be actually async they need to return Call<> or Future

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions