sms_queue: It is a bad idea to detach a subscriber on failed delivery

It is a bad idea to detach a subscriber. The subscriber will not
be reachable until the next periodic updating cycle. In case we have
too many failed deliveries we will need to reduce the period for the
LU and implement a subscriber purging task.

This is a preparation for the 29C3 and a problem Jolly experience with
his type writer system.
neels/jolly/new_handover
Holger Hans Peter Freyther 10 years ago
parent 7456891439
commit 6b55f603e3
  1. 13
      openbsc/src/libmsc/sms_queue.c

@ -51,8 +51,6 @@ struct gsm_sms_pending {
unsigned long long sms_id;
int failed_attempts;
int resend;
int no_detach;
};
struct gsm_sms_queue {
@ -155,16 +153,6 @@ static void sms_pending_failed(struct gsm_sms_pending *pending, int paging_error
if (++pending->failed_attempts < smsq->max_fail)
return sms_pending_resend(pending);
if (paging_error && !pending->no_detach) {
LOGP(DSMS, LOGL_NOTICE,
"Subscriber %llu is not reachable. Setting LAC=0.\n", pending->subscr->id);
pending->subscr->lac = GSM_LAC_RESERVED_DETACHED;
db_sync_subscriber(pending->subscr);
/* Workaround a failing sync */
db_subscriber_update(pending->subscr);
}
sms_pending_free(pending);
smsq->pending -= 1;
sms_queue_trigger(smsq);
@ -356,7 +344,6 @@ static int sub_ready_for_sm(struct gsm_network *net, struct gsm_subscriber *subs
LOGP(DMSC, LOGL_NOTICE,
"Pending paging while subscriber %llu attached.\n",
subscr->id);
pending->no_detach = 1;
return 0;
}

Loading…
Cancel
Save