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

FISH-10120 collect logs from a remote ssh instance #60

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

NotedSalmon
Copy link
Contributor

I have revamped the LogCollector class so it utilises the command collect-log-files.

What the command does is it collects the log files from local or remote instances and stores it in a zip file in payara5/glassfish/domains/domain1/collected-logs. The LogCollector then uses the command output to determine the location of the file and unzips the file and copies into the respective folder.

It creates the log folders accordingly depending if there is an instance or not.

If a target is used (./asadmin collect-diagnostics --target instance) then it will use the target and attach it to the programOptions which is then used for the command.

I have also added some error handling on the CollectorService as if there are no instances it should still collect the logs for the server. A few bits of code has been commented out as I will need it for the next task which is to allow heap dump collection of SSH instances.

@luiseufrasio luiseufrasio self-requested a review December 18, 2024 12:38
}
// if (accessLog) {

Choose a reason for hiding this comment

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

Should we keep these lines or they could be deleted?

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

Successfully merging this pull request may close these issues.

2 participants