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

Handle PSQLException in the FASTEN server and MetadataDBExtension #466

Merged
merged 7 commits into from
Jun 8, 2022

Conversation

mir-am
Copy link
Contributor

@mir-am mir-am commented May 31, 2022

Description

This PR makes the following changes:

  • The FASTEN server stops a plugin with a failed DB connection, that is, in the case where a PSQLException has occurred in the plugin.
  • If PSQLException has happened in MetadataDBExtension, the plugin will be stopped and restarted by K8s or DC.

Motivation and context

As discussed in #461, if a PSQLException happens in a plugin, it cannot proceed further due to a failed DB connection. Therefore, the plugin should be stopped and restarted by K8s/DC to make a new DB connection.

Testing

Tested with the DC.

@mir-am mir-am added the enhancement New feature or request label May 31, 2022
@mir-am mir-am self-assigned this May 31, 2022
Copy link
Contributor

@proksch proksch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added several comments.

@mir-am
Copy link
Contributor Author

mir-am commented Jun 1, 2022

I added several comments.

@proksch
Thanks for reviewing the code and comments.
I have addressed your comments and responded to your questions.

@MagielBruntink
Copy link
Member

Hi Amir, I tried restarting the REST API component for Java/MVN and it won't even come up anymore. I think it's really time to start trying things. What do you think?

@mir-am
Copy link
Contributor Author

mir-am commented Jun 7, 2022

Hi Amir, I tried restarting the REST API component for Java/MVN and it won't even come up anymore. I think it's really time to start trying things. What do you think?

Hi Magiel (@MagielBruntink )
Would you please elaborate a bit more on this issue? Did you try this on monster?
Also, note that #465 is not running in production as a new release should be created.

@MagielBruntink
Copy link
Member

If I kubectl rollout restart deployment/fasten-restapi-java -n fasten on monster the Java/Mvn REST API container is restarted, but upon starting it immediately crashes.

@mir-am
Copy link
Contributor Author

mir-am commented Jun 7, 2022

If I kubectl rollout restart deployment/fasten-restapi-java -n fasten on monster the Java/Mvn REST API container is restarted, but upon starting it immediately crashes.

I have created issue #471 as it's not related to this PR.

@mir-am
Copy link
Contributor Author

mir-am commented Jun 8, 2022

@proksch
Thanks for the discussion and further comments.
I have addressed them in my recent commits.

@mir-am mir-am merged commit fbb6bac into develop Jun 8, 2022
@mir-am mir-am deleted the handle-psql-exception-fs branch June 8, 2022 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants