Forum Discussion
Best Option
I have an application that needs me to select a pool based on the TCP port that it connects to the F5 on. (Server Port or Local Port) The number of ports that need to be tracked for each server can run into the thousands. My first idea was to use a data group and the switch command. The reason I wanted to go this way was because the switch command is suppose to be more efficient than the if statement. However, I have discovered that the switch command can not use data groups. So now I am considering going back to the if statements and use the data groups. The reason is because I believe using data groups will be a much more manageable option based on the number of TCP ports I have to account for. My basic question is do I lose much efficiency doing it this way or is there a better option out that I have not thought of yet. Thanks for any feedback.
Joe
4 Replies
- What_Lies_Bene1
Cirrostratus
How many pools are there? Perhaps some well chosen naming convention would help or a regex rather than a DG?
- Joe_Curl_105786
Nimbostratus
I am expecting the number of pools to be between 50 to 75 when then entire project is completed.
- Kevin_Stewart
Employee
You don't have to use a switch command with a data group:
when HTTP_REQUEST { if { [class match [TCP::local_port] equals my_dg] } { pool [class match -value [TCP::local_port] equals my_dg] } } - Joe_Curl_105786
Nimbostratus
Ok, the only reason I started down the switch path was because trying to keep the F5 performance optimal. Even though it is a small number of servers total it is a high volume of TCP small size packet traffic. Based on this I may go back and rework with the if statement and then use the data group. Thanks for you feed back on this.
Joe
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com