Phase (a) part 1 of docs/DESIGN.md: the email_ tables (provider, message, attempt, template, version, brand, suppression) with Postgres DDL; provider rows with env-var-name credentials; EmailService with idempotency keys, suppression and same-transaction enqueue; the dispatcher with unique-attempt claims, leases, backoff, dead letters, rate limits and provider health; SMTP (jakarta.mail with auth, TLS and timeouts) and SES (AWS SDK v2 sesv2 raw) transports; the QBIT_EMAIL core messaging provider; Resend, Cancel, Send Now and Send Test Email record actions; scheduled dispatch, maintenance and retention. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
48 lines
1.7 KiB
Java
48 lines
1.7 KiB
Java
/*
|
|
* QQQ - Low-code Application Framework for Engineers.
|
|
* Copyright (C) 2021-2025. Kingsrook, LLC
|
|
* 651 N Broad St Ste 205 # 6917 | Middletown DE 19709 | United States
|
|
* contact@kingsrook.com
|
|
* https://github.com/Kingsrook/
|
|
*
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
* you may not use this file except in compliance with the License.
|
|
* You may obtain a copy of the License at
|
|
*
|
|
* https://www.apache.org/licenses/LICENSE-2.0
|
|
*
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
* See the License for the specific language governing permissions and
|
|
* limitations under the License.
|
|
*/
|
|
|
|
package com.kingsrook.qbits.email.bridge;
|
|
|
|
|
|
import com.kingsrook.qqq.backend.core.model.metadata.messaging.QMessagingProviderMetaData;
|
|
import com.kingsrook.qqq.backend.core.modules.messaging.QMessagingProviderDispatcher;
|
|
|
|
|
|
/*******************************************************************************
|
|
** Core messaging provider type registered independently of EMAIL and SES.
|
|
*******************************************************************************/
|
|
public class EmailOutboxMessagingProviderMetaData extends QMessagingProviderMetaData
|
|
{
|
|
public static final String TYPE = "QBIT_EMAIL";
|
|
|
|
static
|
|
{
|
|
QMessagingProviderDispatcher.registerMessagingProvider(new EmailOutboxMessagingProvider());
|
|
}
|
|
|
|
/*******************************************************************************
|
|
** The bridge type.
|
|
*******************************************************************************/
|
|
public EmailOutboxMessagingProviderMetaData()
|
|
{
|
|
setType(TYPE);
|
|
}
|
|
}
|