The veteran paceman is Sri Lanka's third highest wicket-taker in ODI cricket after Muttiah Muralitharan (523) and Chaminda Vaas (399).
After the match, he insisted it was the right time for him to retire as Sri Lanka begin rebuilding for the next World Cup. The pacer bowler, who will turn 36 next month, urged the younger generation to step up.
"My captains expect me to take wickets," Malinga said at the post-match presentation. "I tried my best all through my career. I hope all the young bowlers do this as well. Because just surviving in cricket, I don't think anyone can go far. You have to be a match-winner.
"That's what I'm looking forward to in the future. These young bowlers have to get match-winning performances and people have to say, 'That's a match-winning bowler!' We have a couple of guys, they have the ability and we have to look after them."
Malinga chose to bow out in front of the home crowd, and they turned out in huge numbers to send him off.
"I've played the last 15 years for Sri Lanka. Really an honour to play, and really happy to play for these people and for all crowd that's been behind me," he said. "I feel this is the time I have to move on because we have to build for the 2023 World Cup and that's why I realised, 'OK, my time is up, I have to go'."