Skip to content
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

JabRef does not shutdown at all after interacting with OpenAI #77

Closed
koppor opened this issue Jul 10, 2024 · 10 comments
Closed

JabRef does not shutdown at all after interacting with OpenAI #77

koppor opened this issue Jul 10, 2024 · 10 comments
Milestone

Comments

@koppor
Copy link
Collaborator

koppor commented Jul 10, 2024

(see title)


@koppor koppor added this to the Week 1 milestone Jul 10, 2024
@koppor
Copy link
Collaborator Author

koppor commented Jul 10, 2024

VisualVM shows

grafik

One cannot shutdown OkHttp using a parameter. See square/okhttp#6173.

@koppor
Copy link
Collaborator Author

koppor commented Jul 11, 2024

I think, I found the root cause: langchain4j/langchain4j#1449

@koppor
Copy link
Collaborator Author

koppor commented Jul 11, 2024

Waiting for 60 seconds, the tasks are like this:

image

@koppor
Copy link
Collaborator Author

koppor commented Jul 11, 2024

JabRef running (on main branch)

image

@koppor
Copy link
Collaborator Author

koppor commented Jul 11, 2024

New threads after inputting a message:

image

pool-4-thread-1, pool-8-thread-1, and pool8-thread-2 are new.

And pool-4-htread-1 is not terminated.

@koppor
Copy link
Collaborator Author

koppor commented Jul 11, 2024

Opening Tab only:

image

@koppor
Copy link
Collaborator Author

koppor commented Jul 11, 2024

Next step: Find out what is this pool-4-thread-1: (It has "always" the same name. And there is a sister thread generated: pool-4-thread-2. That one is properly shut down)

image

@koppor
Copy link
Collaborator Author

koppor commented Jul 12, 2024

Current state: This thread is created at dev.langchain4j.chain.ConversationalRetrievalChain#execute. Need to dive more into it.

@InAnYan
Copy link
Owner

InAnYan commented Jul 12, 2024

@koppor thank you very much for the findings!!!

Will also try to investigate it!

@koppor
Copy link
Collaborator Author

koppor commented Jul 12, 2024

To searcha for the thead starter, Byteman could be used. Source: https://stackoverflow.com/a/78051083/873282

However, I do not know at all how to start with Gradle. -- Maybe it is very simple: pass the JAVA_TOOL_OPTIONS using IntelliJ somehow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants