Enabling Sticky Sessions with an AWS Application Load Balancer (ALB) | AWS Tutorial

Поділитися
Вставка
  • Опубліковано 7 січ 2025

КОМЕНТАРІ • 61

  • @vibales
    @vibales 2 роки тому +2

    Wow this information is pure gold, hope more people can watch this.

  • @msizinkosi3481
    @msizinkosi3481 4 місяці тому

    I love you 😊, after trolling through google trying to find a simple explanation without success the angels directed me to you and we are married from now on, subscribed.

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  2 місяці тому

      LOL!! Awwww, thanks so much! 🥰🌟 Welcome to the channel, and sorry for the super slow response!

  • @saipriya8114
    @saipriya8114 6 місяців тому

    After watching so many videos in you tube. you were the best in explanation.

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  6 місяців тому

      Yay! I'm so glad it helped. Thanks for watching and for such a nice comment!! 🙏🤓🌟

  • @tanujagpsty7578
    @tanujagpsty7578 2 роки тому +1

    You deserve more subscribers and viewers - loved your content

  • @Pranith35
    @Pranith35 Рік тому +1

    Thanks for sharing the video. I was able to achieve the sticky session with AWS using a load balancer generated cookie. I am using ALB for navigating TCP requests to target groups. But I am facing issue with browser based application as I am unable to pass the cookie in headers section in websocket requests. Can you please suggest an alternative for achieving the stickyness with browser based applications

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  Рік тому

      Hi Pranith! 😊 Sorry for the delayed response. Were you able to sort this out? I haven't tried this with web sockets, but according to AWS, they're inherently sticky so you shouldn't need to implement anything? docs.aws.amazon.com/prescriptive-guidance/latest/load-balancer-stickiness/options.html

  • @bulliraj-j9r
    @bulliraj-j9r Рік тому

    Simple and precise up to point with great example. Love your videos

  • @4-r-k
    @4-r-k Рік тому +1

    Hi Tina, my "target groups" don't even have "Attributes" tab shown. When I go by the "Actions" > "Edit attributes" from the dropdown menu, the popup box has "Stickiness" section but only "on/off" checkbox is inside. The stickiness "types" are entirely missing. (And the ELB itself has "Cross-zone load balancing" option enabled, even if that was the case)

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  Рік тому

      Hey Ark - So sorry for the delay on this. It looks like there have been some small UI changes, but the main "stickiness" options should still be there. I grabbed some screenshots here if this helps? drive.google.com/file/d/1G6JGhI6UVxlcdg-kqh9FyPNaoxU2e49Z/view?usp=share_link

  • @ShivamAggarwal-n8t
    @ShivamAggarwal-n8t Рік тому

    this so helpful...get straight in my head....thnks a ton

  • @nehalverma1444
    @nehalverma1444 2 роки тому

    I love your videos. Thankyou so much Tiny!

  • @kinal37
    @kinal37 10 місяців тому +1

    Can we make that default stickyness cookies to non-persistent by update expire date to zero?

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  10 місяців тому

      Hi Kinal! 👋 If you make the default cookies non-persistent, I'm wondering if you really need sticky sessions? Do you want requests to go to the same instance or the default round-robin approach?

  • @mrcharm767
    @mrcharm767 2 роки тому +1

    please dont stop with aws .. love ur videos

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  2 роки тому +1

      Awww, thanks so much, Syed! I plan to keep going! :)

    • @mrcharm767
      @mrcharm767 2 роки тому

      @@TinyTechnicalTutorials more power to u 🔥

    • @mrcharm767
      @mrcharm767 2 роки тому +1

      Wil u b able to upload realtime projects with AWS?

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  2 роки тому +1

      Hey Syed! Can you clarify? Are you talking about doing live UA-cam sessions for AWS projects? Want to make sure I understand the question! :)

    • @mrcharm767
      @mrcharm767 2 роки тому +1

      @@TinyTechnicalTutorials yes basically AWS projects .. going from a small level to a good level where a person can say he is experienced in AWS after following ur tutorials .. if possible u can include docker and kubernetes.. if ur doing that I'll be fully committed to follow all those playlists u explain excellent I'm sure others wil also follow

  • @ankitagarwal6014
    @ankitagarwal6014 7 місяців тому +1

    What if my instances scale in and out? will it still maintain the stickiness?

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  7 місяців тому

      Hi Ankit! 👋 Sorry for the delayed response. If you're still looking for an answer, maybe this will help?
      SCALING OUT (Adding Instances)
      -New Instances: When new instances are added to the pool due to scaling out, they start receiving new traffic. However, existing sessions (those already stickied to other instances) are not affected. Only new sessions can be directed to the new instances.
      -Sticky Sessions: Existing sticky sessions will continue to route to the same instances they were initially directed to, unless those instances are terminated or fail.
      SCALING IN (REMOVING INSTANCES)
      -Removing Instances: When instances are removed from the pool due to scaling in, this can affect sticky sessions. If an instance that is handling sticky sessions is terminated:
      --The sessions that were stickied to that instance will be interrupted.
      --The next time the client sends a request, the load balancer will select a new instance based on the current load balancing algorithm, and a new sticky session will start with the new instance.
      -Session Persistence: The key point is that sticky sessions do not migrate. If the instance to which they are stickied is removed, those sessions do not maintain their state but are rather reset and will need to re-establish on a new instance.

  • @kanappilly
    @kanappilly Рік тому

    simple and powerful tutorial

  • @chandraprakashdwivedi1
    @chandraprakashdwivedi1 2 роки тому

    it is realy quick and to the point appreciate it :)

  • @subhashkr8143
    @subhashkr8143 Рік тому +1

    If there are multiple application server and sticky session off the sso stops working . How can we enable SSO with sticky session off

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  Рік тому +1

      Hi subhash! 😊 By default, sticky sessions are off, so in theory, shouldn't be affecting anything unless you enabled them. Also, sticky sessions are meant to save state within a session/application, not to be used for authentication across applications. But maybe I'm misunderstanding the question? 😊

  • @NityaGuptanitya
    @NityaGuptanitya 2 роки тому

    Very helpful, it saved my time, thank you

  • @ykuldeep
    @ykuldeep Рік тому +1

    I can't see option to "Edit Attributes" but "Edit Load Balancer Attributes" and clicking that doesn't show the options you are using. Is it dependent on region?

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  Рік тому

      Hi Kuldeep! Make sure you're editing the attributes for the target group, not the load balancer itself. I think that's probably the issue. 😊

    • @ykuldeep
      @ykuldeep Рік тому +1

      @@TinyTechnicalTutorials Thank you for the pin point help. I found it.

  • @amitpadgaonkar8830
    @amitpadgaonkar8830 Рік тому

    What a simple, clean and awesome looking presentation...What do you use to create it? Powerpoint (with some addons) or something else?

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  Рік тому

      Thanks for the nice comment, Amit! 😊 Yeah, it's just PowerPoint, with some animations. Nothing too fancy.

    • @amitpadgaonkar8830
      @amitpadgaonkar8830 Рік тому

      @@TinyTechnicalTutorials Thats amazing eh!! Thanks from Canada.

  • @ejyanezpvideo
    @ejyanezpvideo Рік тому

    easy and to the point.😊

  • @YourExcellency-gv3hl
    @YourExcellency-gv3hl 2 роки тому

    Loved the video. Could you please share the Dockerfile script? I trying to create Docker image with "Hello World This is IP". So far no luck. Thank you in advance.

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  2 роки тому

      Thank you, Your Excellency! :D I think you're talking about the User Data script that installs a web server and an index.html page? I put it into a Google Doc for you here: docs.google.com/document/d/1s8iNjZkDwq42fnpM-AeE27F1FEtbRYP24RicUi0VIbk/edit?usp=sharing. Hope that helps!

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  2 роки тому

      And to get the IP address, in that script, update "$(hostname -f)" to "$(hostname -i)"

    • @YourExcellency-gv3hl
      @YourExcellency-gv3hl 2 роки тому +1

      Thank you for your quick response. I appreciate it. In the video, you take the DNS record from load balancer and paste it into the browser. And you have the output that says "Hello World This is ip-172.31.22.245. internal, How I can have the same output?

    • @YourExcellency-gv3hl
      @YourExcellency-gv3hl 2 роки тому +1

      I was creating load balancer for ECS Fargate

    • @TinyTechnicalTutorials
      @TinyTechnicalTutorials  2 роки тому +1

      Oh, gotcha. In that video, I was load balancing between EC2 instances, and used the User Data script to do the "hello world." I haven't done that with containers in ECS before, but I think this might get you started with the Dockerfile script? docs.aws.amazon.com/AmazonECS/latest/userguide/create-container-image.html. Or at least that should get you the static "Hello world" index.html page.
      Loading in a variable for IP address seems to be a bit more complicated. I found this example that displays hostname, using a Python script to get it (towards the end of the page): stackify.com/docker-tutorial/. Hope that sort of helps?

  • @edgardejesusmendozaortegon7655

    😍