| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
and NNTPDirect is subsumed by the NewsRunner.
|
| |
|
|
|
|
|
|
| |
DeliverToUser(): Don't put DELIVERY_MODULE in the pipeline; that's now
handled by the OutgoingRunner.
LIST_PIPELINE: Put ToUsenet at the end of the pipeline, and add
ToOutgoing to make sure the message gets put in qfiles/out.
|
| | |
|
| |
|
|
|
|
|
|
| |
created messages, explicitly set the 'noack' flag to true so that by
default, Replybot will ignore the message. This will get overridden
by the flag set in qrunner (which is the only place that externally
generated messages are injected into the system using
DeliverToUser()). Closes SF bug #114603.
|
| |
|
|
|
| |
call. If the module does a fork, and the child process returns here,
we exit immediately.
|
| |
|
|
|
|
|
|
|
| |
DeliverToList(): Handle `_enqueue_immediate' by bypassing the call to
do_pipeline and enquing the message immediately to disk. Still
maintains the same interface to the outside world.
Also, copy the pipeline list regardless of whether it comes from
LIST_PIPELINE or from msgdata.
|
| |
|
|
| |
to provide a better rejection notice suggestion in the admindb page.
|
| | |
|
| |
|
|
|
|
| |
must make a copy of LIST_PIPELINE, otherwise subsequent calls to
DeliverToList() do nothing... e.g. qrunner on multiple message
deliveries.
|
| |
|
|
|
|
|
|
| |
hardcoded value.
Also, if delivery retries expire, don't just trash the message; delete
the first entry on the pipeline (which should always be the delivery
module) and continue with pipeline processing.
|
| |
|
|
|
|
| |
This means that clients of this interface normally don't need to check
the return value. Only cron/qrunner checks the return value (which is
now just a boolean) to know whether it can dequeue the message or not.
|
| |
|
|
|
| |
DeliverToUser(): Don't set `recips' key in the dictionary definition,
since it's set conditionally below that.
|
| |
|
|
| |
for update()'ing into the message metadata.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
failures, bugs, and lock acquisition timeouts. Instead of storing
information about the progress of the delivery on the Message object,
we pass around a parallel data structure called `msgdata' (current
just a dictionary). All calculated information is passed through this
object, but this changes the API to handler modules. They now take
three arguments: the mailing list, the message object, and the
msgdata. WARNING: This may change before 2.0 final.
Specific changes include:
HandlerAPI
DiscardMessage(), HandlerAPI.SomeRecipientsFailed(): New shared
exceptions.
pipeline_deliver(): removed
LIST_PIPELINE: global containing the primary list delivery
pipeline
DelivertoList: Revamped main entry point into message delivery to
list membership. Takes three arguments: the mailing list, the
message object, and the msgdata dictionary. This digs the
pipeline to use out of the msgdata (allowing resumption of
prematurely interrupted pipeline deliveries).
Then each module is called in turn, and the shared exceptions are
caught. As each module is completed successfully, it is removed
from the head of the pipeline. This function returns the number
of pipeline modules remaining to be executed (i.e. a return of 0
means DeliverToList() is done with this message and it can be
dequeued).
A catch-all is included in case some unexpected exception occurs
(say a bug or typo in one of the delivery modules). Such an error
will queue the message, so at least it doesn't just get lost. We
try to never just lose a message.
RedeliverMessage(), DeliverToUser(): reimplemented in terms of
DeliverToList().
Acknowledge, AfterDelivery, CalcRecips, Cleanse, CookHeaders,
Decorate, Replybot, ToArchive, ToUsenet
Fix the function signature to match the new API (three arguments),
and changed the implementations to extract delivery information
from msgdata instead of as attributes of the message object.
Approved
Same as above, but also removed NotApproved exception. LoopError
is now multiply derived from HandlerAPI.DiscardMessage and
Errors.MMLoopingPost.
Hold
Same as above, but also changed slightly the way an exception is
raised when a message is held. hold_for_approval() now takes four
arguments (the msgdata parameter has been added), and the exc
object can be a class or instance. If it's a class, it is simply
zero-arg'd instantiated. We also use the str() of the exception
to get us the reason for the hold. This allows us to override
HandlerAPI.MessageHeld.__str__() for MessageToBig so that we can
include the size of the message being held.
SMTPDirect
Same as above, but instead of explicitly enqueuing the messages
when some or all of the recipient deliveries failed, just raise a
HandlerAPI.SomeRecipientsFailed exception and let DeliverToList()
manage the enqueuing. Thus queue_message() is removed.
Sendmail
Same as above, but if any chunks fail delivery, those recipients
are queued by raising SomeRecipientsFailed.
SpamDetect
Same as above, except that if a regexp matches, a SpamDetect
exception is raised directly. The DeliverToList() framework
discards these spam messages instead of holding them for
approval.
ToDigest
Same as above, except that if a digest is prepared for delivery,
it is not sent directly via mlist.Post(). Instead, the message is
queued for delivery, thereby relinquishing the lock soon. This
means that digests will only be sent the next time qrunner runs.
|
| |
|
|
|
|
|
| |
DeliverToList(), DeliverToUser(): Use pipeline_delivery
RedeliverMessage(): New delivery top-level function which is used by
qrunner to attempt re-delivery.
|
| | |
|
| | |
|
| |
|
|
|
|
| |
module.
DeliverToUser(): Add the Replybot module as the first in the list.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
| |
DeliverToUser(): New function which implements a pipeline for direct
delivery to a specified user. This pipeline is used for all admin
notifications, and other things like user post acks. It sets
msg.fastrack attribute to 1 so other modules can know which delivery
track this message is on.
This lets us use the same module for all delivery, or separate ones
for delivery to list and delivery to user.
|
| |
|