Skip to content

testfind: reuse filedaemon logic#1234

Merged
arogge merged 34 commits intobareos:masterfrom
HediBenFraj:dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind
Mar 2, 2023
Merged

testfind: reuse filedaemon logic#1234
arogge merged 34 commits intobareos:masterfrom
HediBenFraj:dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind

Conversation

@HediBenFraj
Copy link
Contributor

@HediBenFraj HediBenFraj commented Aug 23, 2022

Description

In this PR, testfind tries first to mimic sending filesets from DIR to FD, and then tries to mimic sending over files from the FD to the SD, without the SD receiving any actual data.

Please check

  • Short description and the purpose of this PR is present above this paragraph
  • Your name is present in the AUTHORS file (optional)

If you have any questions or problems, please give a comment in the PR.

Helpful documentation and best practices

Checklist for the reviewer of the PR (will be processed by the Bareos team)

Make sure you check/merge the PR using devtools/pr-tool to have some simple automated checks run and a proper changelog record added.

General
  • Is the PR title usable as CHANGELOG entry?
  • Purpose of the PR is understood
  • Commit descriptions are understandable and well formatted
  • Check backport line
Source code quality
  • Source code changes are understandable
  • Variable and function names are meaningful
  • Code comments are correct (logically and spelling)
  • Required documentation changes are present and part of the PR
Tests
  • Decision taken that a test is required (if not, then remove this paragraph)
  • The choice of the type of test (unit test or systemtest) is reasonable
  • Testname matches exactly what is being tested
  • On a fail, output of the test leads quickly to the origin of the fault

@HediBenFraj HediBenFraj force-pushed the dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind branch 2 times, most recently from 6d96b52 to 154669e Compare August 23, 2022 10:04
pstorz
pstorz previously requested changes Aug 24, 2022
Copy link
Member

@pstorz pstorz left a comment

Choose a reason for hiding this comment

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

This PR does not implement what it says that it does.

What are the steps to read data from a file?

@HediBenFraj HediBenFraj changed the title Dev/hedi ben fraj/build testfind/add read file feature to testfind testfind: added read file functionality Aug 25, 2022
@HediBenFraj
Copy link
Contributor Author

HediBenFraj commented Aug 25, 2022

This PR does not implement what it says that it does.

What are the steps to read data from a file?

the actual reading of the file is missing I am working on it

@HediBenFraj HediBenFraj reopened this Aug 25, 2022
@pstorz pstorz force-pushed the dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind branch from 154669e to ec40a6d Compare August 26, 2022 10:26
@HediBenFraj HediBenFraj force-pushed the dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind branch from ec40a6d to 3e35d03 Compare August 26, 2022 11:22
@pstorz pstorz changed the title testfind: added read file functionality testfind: add read file functionality Aug 29, 2022
@HediBenFraj HediBenFraj force-pushed the dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind branch from 131e427 to 2642e09 Compare September 16, 2022 11:19
@HediBenFraj HediBenFraj changed the title testfind: add read file functionality Testfind: Reuse-filedaemon-logic-in-testfind Sep 16, 2022
@HediBenFraj HediBenFraj changed the title Testfind: Reuse-filedaemon-logic-in-testfind testfind: reuse-filedaemon-logic-in-testfind Sep 16, 2022
@HediBenFraj HediBenFraj requested a review from pstorz September 16, 2022 11:34
@HediBenFraj HediBenFraj marked this pull request as draft September 16, 2022 11:37
@HediBenFraj HediBenFraj changed the title testfind: reuse-filedaemon-logic-in-testfind testfind: reuse-filedaemon-logic Sep 22, 2022
@HediBenFraj HediBenFraj changed the title testfind: reuse-filedaemon-logic testfind: reusen filedaemon logic Sep 22, 2022
@HediBenFraj HediBenFraj changed the title testfind: reusen filedaemon logic testfind: reuse filedaemon logic Sep 22, 2022
@HediBenFraj HediBenFraj requested a review from pstorz September 22, 2022 14:36
@arogge arogge added the onhold label Oct 6, 2022
@HediBenFraj HediBenFraj removed the onhold label Nov 2, 2022
@HediBenFraj HediBenFraj force-pushed the dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind branch 5 times, most recently from 2f6f121 to 9a2930c Compare November 9, 2022 14:51
@HediBenFraj HediBenFraj force-pushed the dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind branch from 9a2930c to c31efef Compare November 24, 2022 12:24
@pstorz pstorz added the nobuild label Dec 1, 2022
alaaeddineelamri and others added 28 commits March 2, 2023 18:16
It turns out that `TermFindFiles` and  `TermFindOne` were made
to return hard links just for testfind. Nowhere else in the code is 
hard links count used.
Testfind will later directly get the count from its own fileset without 
the need for calling `TermFindFiles`
`SendExcludeList` doesn't do anything, and is now just a placeholder. 
`SendIncludeList` does the job for both Include and Exclude lists, 
so it is now renamed accordingly
- Faking how sockets work to mimick the real interaction between 
dird and fd
- Renamed `testfind_jcr` to `testfind_fd`
- Moved testfind from dird to tools
- Enabled joblog messages
asd
@arogge arogge force-pushed the dev/HediBenFraj/build-testfind/add-readFile-feature-to-testfind branch from e3e7ebb to e7425c5 Compare March 2, 2023 17:16
@arogge arogge merged commit d03eace into bareos:master Mar 2, 2023
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.

6 participants

Comments