This repository was archived by the owner on Apr 1, 2023. It is now read-only.
Draft
Conversation
…socket, and able to parse packet until the ARP level
…d tx packets; however, more investigation is needed in order to use the db functions
…emented endpoint cache layer for better lookup performance; refactored functions in af_xdp_user to utils
…eighborInMemory from pointer to value, in order to make the packet correct after modification
…s; need to investigate how to add use round robin in kernel, how to make iperf work and how to user more threads
…en after trading from bpool. Made a hack to make iperf work.
… it still stops receiving traffic from time to time
…Completion Queue to have the same size
…bpf map fd for security group ebpf table; added sample code to insert data into security group ebpf maps
…need to be tested
…security_group_port_bindnig info from arion master, and program into the sg_cidr_map ebpf map
…elarted port bindings and programs the rules
lfu-ps
reviewed
Jan 28, 2023
|
|
||
| struct SecurityGroupPortBindingProgrammingState { | ||
| int version; | ||
| }; // local db table 2 - security rule ebpf programmed version |
lfu-ps
reviewed
Jan 28, 2023
| ./comm/grpc_client.cpp | ||
| ) | ||
| # db/db_client.cpp | ||
| comm/af_xdp_user_multi_thread.cpp ) |
lfu-ps
reviewed
Jan 28, 2023
| #include "marl/scheduler.h" | ||
| #include "marl/waitgroup.h" | ||
| #include "af_xdp_user_multi_thread.h" | ||
| #include "grpc_client.h" |
Collaborator
There was a problem hiding this comment.
there's a //#include "grpc_client.h" above, please keep only 1
lfu-ps
reviewed
Jan 28, 2023
| g_arion_master_port, | ||
| g_arion_group, | ||
| g_arion_neighbor_table); | ||
| g_arion_group,\ |
lfu-ps
reviewed
Jan 28, 2023
| // | ||
|
|
||
| // SPDX-License-Identifier: GPL-2.0 | ||
| /* Copyright(c) 2020 - 2022 Intel Corporation. */ |
Collaborator
There was a problem hiding this comment.
Can we add co-author of Futurewei, just like grpc server/client files?
lfu-ps
reviewed
Jan 28, 2023
| // lock transaction section | ||
| // segment lock allows some level of concurrent manipulations of concurrent version map | ||
| // as long as the multi-threading version updates' keys are not hashed to the same slot in segment array | ||
| segment_lock.lock(neighbor_key); |
Collaborator
There was a problem hiding this comment.
you didn't include util\segment_lock.h or .cpp
lfu-ps
reviewed
Jan 28, 2023
| sg_key.local_ip = local_ip_sock.sin_addr.s_addr; | ||
| sg_key.direction = direction == "egress" ? 0 : 1; // going out is 0 and coming in is 1 | ||
|
|
||
| if (protocol == "TCP") { |
lfu-ps
reviewed
Jan 28, 2023
|
|
||
| if (protocol == "TCP") { | ||
| sg_key.protocol = IPPROTO_TCP; | ||
| } else if (protocol == "UDP") { |
lfu-ps
reviewed
Jan 28, 2023
| } | ||
|
|
||
| printf("GPPC: Inserted this sg rule into map: vip: %s, vni: %d\n", vpc_ip.c_str(), vni); | ||
|
|
lfu-ps
reviewed
Jan 28, 2023
| add_programmed_security_group_port_binding_version_db_stmt); | ||
| }); | ||
| } | ||
|
|
lfu-ps
reviewed
Jan 28, 2023
| } | ||
|
|
||
| } | ||
| if (ebpf_rc < 0) { |
lfu-ps
suggested changes
Jan 28, 2023
Collaborator
lfu-ps
left a comment
There was a problem hiding this comment.
After we test with DP E2E, and clean up dead code. Let's review again. Before that, you don't need to address.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR does the following:
db_client.h, in order to use it among different files.std::unordered_mapfor endpoint querying.arion-dprepository.Performance:
As of 3a5d5b8, Arion Agent is able to achieve the following performance:
10 traffic flows (10
iperfs), all traffic handled by AF_XDP , running for 200 seconds, 10G NIC card:Same test, but all traffic handled by in-kernel XDP:
Comparison:
What's next:
std::unordered_mapshall be replaced by some DB.