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

Fix placement assumptions in TestNodeManagement tests #599

Closed
roman-khimov opened this issue Aug 15, 2023 · 3 comments
Closed

Fix placement assumptions in TestNodeManagement tests #599

roman-khimov opened this issue Aug 15, 2023 · 3 comments
Assignees

Comments

@roman-khimov
Copy link
Member

Three tests from the network test suite that fail in this report are actually fine, we still have two copies, but they're placed a bit differently with SDK RC10 code.

But notice that we're likely to have the same problem after nspcc-dev/neofs-node#2495 and while you can have some static assumptions about "correct" placement now you're not likely to have it after this change (what's the disk size on our runners? can it change?). So we either need to remove them from tests or set "capacity" attributes manually.

@evgeniiz321
Copy link
Contributor

evgeniiz321 commented Aug 23, 2023

These failures seems to be real bugs for me. Or I do not completely understand how storage policies work.
E.g. test failure with the following policy:

REP 1 CBF 1 SELECT 1 FROM LOC_SPB FILTER 'UN-LOCODE' NE 'RU MOW' AND 'UN-LOCODE' NE 'SE STO' AND 'UN-LOCODE' NE 'FI HEL' AS LOC_SPB

Due to nodes attributes, only one node should be used in this case (the s02, which has an attribute UN-LOCODE equal to RU LED)
But looks like the policy works incorrectly and a random node is chosen each time. So, it is either a problem with the expression itself(but i would expect a syntax error in this case)or with a parsing code.

Another test scenario that fails uses this policy:

'REP 2 CBF 1 SELECT 2 FROM LOC_EU FILTER Country NE 'Russia' AS LOC_EU'

Although there is no 'Country' attribute in the node config, I see only two attrs in the storage node compose file in dev-env:

      - NEOFS_NODE_ATTRIBUTE_1=UN-LOCODE:SE STO
      - NEOFS_NODE_ATTRIBUTE_2=Price:11

It is not quite clear to me what is the origin of this attribute.
But nevertheless, there is other test that always passes, with the following policy:

REP 2 CBF 1 SELECT 2 FROM LOC_RU FILTER Country EQ 'Russia' AS LOC_RU

It actually the same test, but the opposite filter, we filter here with EQ. And this test always passes. That makes me think there is probably some problem with NE statements.

Same thing with the third failed test:

REP 2 CBF 1 SELECT 2 FROM LOC_RU FILTER SubDivCode NE 'AB' AND SubDivCode NE '18' AS LOC_RU

It uses NE inside FILTER expression - and nodes are chosen randomly.
So, to sum up - it looks like valid failures for me, that relate to using NE operator inside FILTER expression.

@vvarg229
Copy link
Collaborator

@evgeniiz321 It seems to be a nspcc-dev/neofs-node#2441 issue.

@evgeniiz321
Copy link
Contributor

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

3 participants