All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marcel Holtmann <marcel@holtmann.org>
To: ofono@ofono.org
Subject: Re: [PATCH 06/11] Made it possible to ask for status report via SendMessage method parameters. True=status report on, false=off.
Date: Wed, 09 Jun 2010 18:11:14 -0700	[thread overview]
Message-ID: <1276132274.2182.74.camel@localhost.localdomain> (raw)
In-Reply-To: <1276126192.2509.28.camel@localhost.localdomain>

[-- Attachment #1: Type: text/plain, Size: 2472 bytes --]

Hi Inaky,

> > > > > > I don't like this being an argument to SendMessage(). I think it
> > > > > > needs to be exposed, but as a property instead. Is there a use case
> > > > > > for setting this per message? I think majority of current phones
> > > > > > either provide a global setting for this, or set it on by default.
> > > > >
> > > > > our idea is actually that every new SMS has its own object path for its
> > > > > lifetime. So we can have then properties easily on them.
> > > >
> > > > Sure, but there should still be a property in SmsManager to control
> > > > whether srr is to be set on outgoing messages.
> > > >
> > > > Another property in the actual SmsMessage (residing on its own object
> > > > path) could then indicate whether srr *was* set for that particular
> > > > message when it was sent.
> > > 
> > > I tend to disagree with that; by making it an SmsManager property, you
> > > are creating an API that is not reentrant. If more than one application
> > > is sending SMS's at the same time and they have different requirements
> > > wrt to status-reports, they would be trumping each other:
> > 
> > While you're 100% correct about a possible race condition, the reality is that 
> > nobody actually uses it this way.  It is just a setting buried somewhere in 
> > the Settings UI that the user maybe changes once in his lifetime.
> 
> If you are confident this will never be a problem then *shrug*; I am
> just not comfortable with generic unconstrained APIs that operate like
> that.

please keep in mind that we are on purpose not going to expose anything
just for the sake of having an API for it. The API must make sense from
an UI use case point of view. oFono is suppose to do all the heavy
lifting and this also means that we are not exposing every single detail
or possibility of GSM/UMTS.

I would even go one step further in this case and always request status
reports and if the user doesn't want them, then it can throw this kind
of information away.

So there might be cases where we are wrong in the first place, but that
is fine as well. This is a learning experience that we have to go
through to create proper APIs. This API design by committee is not
working out anyway. It just creates clutter and extra shim layers since
everything gets way too complicated. The idea is to have a really simple
API first and then only if needed introduce complexity.

Regards

Marcel



  reply	other threads:[~2010-06-10  1:11 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-27 10:54 [PATCH 01/11] In drivers/atmodem/sms.c:at_cmgl_cpms_cb() there is a temporary fix for Siemens TC65. If AT+CMGL=4 is sent to TC65, the AT command queue jams pasi.miettinen
2010-05-27 10:54 ` [PATCH 02/11] Made needed changes to at_cds_notify() for status report and corrected at_cmgl_cpms_cb() to meet the ISO standard pasi.miettinen
2010-05-27 10:54   ` [PATCH 03/11] Enable status report pasi.miettinen
2010-05-27 10:54     ` [PATCH 04/11] Changes for SMS statur report pasi.miettinen
2010-05-27 10:54       ` [PATCH 05/11] Added message delivery time to dbus message pasi.miettinen
2010-05-27 10:54         ` [PATCH 06/11] Made it possible to ask for status report via SendMessage method parameters. True=status report on, false=off pasi.miettinen
2010-05-27 10:54           ` [PATCH 07/11] Removed Siemens TC65 specific code pasi.miettinen
2010-05-27 10:54             ` [PATCH 08/11] Some style corrections pasi.miettinen
2010-05-27 10:54               ` [PATCH 09/11] Support for concatenated SMS status report. And ofono_history_sms is now updated according to received status reports pasi.miettinen
2010-05-27 10:54                 ` [PATCH 10/11] Some naming changes to enum sms_status_report_result pasi.miettinen
2010-05-27 10:54                   ` [PATCH 11/11] Style corrections pasi.miettinen
2010-05-28 17:20                     ` Denis Kenzior
2010-05-28 17:26                 ` [PATCH 09/11] Support for concatenated SMS status report. And ofono_history_sms is now updated according to received status reports Denis Kenzior
2010-05-31 12:33                   ` VS: " Miettinen Pasi
2010-05-31 16:18                     ` Denis Kenzior
2010-05-28 17:15             ` [PATCH 07/11] Removed Siemens TC65 specific code Denis Kenzior
2010-05-27 11:32           ` [PATCH 06/11] Made it possible to ask for status report via SendMessage method parameters. True=status report on, false=off Aki Niemi
2010-05-27 11:39             ` Marcel Holtmann
2010-05-27 11:56               ` Aki Niemi
2010-06-09 22:21                 ` Inaky Perez-Gonzalez
2010-06-09 22:47                   ` Denis Kenzior
2010-06-09 23:29                     ` Inaky Perez-Gonzalez
2010-06-10  1:11                       ` Marcel Holtmann [this message]
2010-05-27 11:51             ` Denis Kenzior
2010-05-27 13:19               ` Marcel Holtmann
2010-05-28  9:08                 ` VS: " Miettinen Pasi
2010-05-28 17:34                   ` Denis Kenzior
2010-05-27 11:41       ` [PATCH 04/11] Changes for SMS statur report Aki Niemi
2010-05-28 12:02         ` VS: " Miettinen Pasi
2010-05-28 17:12       ` Denis Kenzior
2010-05-28 16:56     ` [PATCH 03/11] Enable status report Denis Kenzior
2010-05-28 16:55   ` [PATCH 02/11] Made needed changes to at_cds_notify() for status report and corrected at_cmgl_cpms_cb() to meet the ISO standard Denis Kenzior
2010-05-28 16:48 ` [PATCH 01/11] In drivers/atmodem/sms.c:at_cmgl_cpms_cb() there is a temporary fix for Siemens TC65. If AT+CMGL=4 is sent to TC65, the AT command queue jams Denis Kenzior

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1276132274.2182.74.camel@localhost.localdomain \
    --to=marcel@holtmann.org \
    --cc=ofono@ofono.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.