Hey,
I’ve been looking into the Outlook SMTP OAuth project for GSoC and have been poking around the email-ext-plugin code to get familiar with how things work. I put up a small PR ( Account for OAuth2 in credential validation by subwaycookiecrunch · Pull Request #1467 · jenkinsci/email-ext-plugin · GitHub ) that adds useOAuth2 handling to doCheckCredentialsId . Nothing huge, just noticed it wasn’t being accounted for.
Wanted to ask about the actual OAuth implementation direction. For token acquisition, should we use MSAL4J directly or hook into Jenkins’ credential system somehow? Not sure if there’s an existing pattern for this in plugins. And on the caching side, re-fetching tokens on every send seems wasteful , is there a standard approach or would a simple in-memory cache with TTL be fine?
Also curious whether this should be Microsoft/Outlook-only first or designed to be provider-agnostic from the start.
@slide_o_mix @krisstern would love your thoughts if you get a chance.
Thanks