[ome-devel] Email Util Design

Aleksandra Tarkowska A.Tarkowska at dundee.ac.uk
Tue Nov 26 21:06:27 GMT 2013


Dear Douglas,

Admin panel is available in both clients: Insight and WebAdmin. Long time ago OME Team decided to make clients consistent as close as possible. Adding new functionality to one should be easily transferable to another. That's why everything reusable should be pushed as low as possible = server side Interface, giving access from the API in every languages.

onero.web.email... settings you mentioned are Django settings configurable from the CLI to avoid manual modification of omeroweb/settings.py. These are nothing else then https://docs.djangoproject.com/en/1.3/topics/email/. Intention was to let admin receive broken link notification. If that is confusing perhaps we should turn it off.

As we already have that in place I am happy to make small adjustment and add requested functionality to the appropriate bean to make it available in the interface. Please create a ticket with an example.

Kind regards
Ola

On 26 Nov 2013, at 00:03, "Douglas Russell" <douglas.russell at bioch.ox.ac.uk<mailto:douglas.russell at bioch.ox.ac.uk>> wrote:

As far as my web form for sending email as concerned, I've programmed it to use the existing capabilities in webadmin to send email. This has the advantage of at least being able to check if the mail sending capabilities have been configured in order to offer them.

I see there are settings as you say for configuring resetpassword. I don't really know how this LocalAdmin stuff works. I assume that this is made available in some way to the Python CLI. So I guess if desired I can put my code to resolve users/groups into a set of email addresses into the utilities as it sounds that this is the only missing link?

Douglas


On 25 November 2013 10:23, Aleksandra Tarkowska <A.Tarkowska at dundee.ac.uk<mailto:A.Tarkowska at dundee.ac.uk>> wrote:
Hi Douglas

I think that functionality shouldn't be only limited to OMERO.web. We already have in place working (I hope so) email sending bean on the server side to reset password.

Please look at omero.properties # reset password

############################################
# Reset password properties
############################################
omero.resetpassword.bean=defaultMailSender
omero.resetpassword.config=false
omero.resetpassword.from=ADDRESS at domain
omero.resetpassword.host=smtp.domain
omero.resetpassword.port=25
omero.resetpassword.username=
omero.resetpassword.password=
omero.resetpassword.mail.transport.protocol=smtp
omero.resetpassword.mail.smtp.auth=false
omero.resetpassword.mail.debug=false
omero.resetpassword.mail.smtp.starttls.enable=false
omero.resetpassword.mail.smtp.socketFactory.class=javax.net.SocketFactory
omero.resetpassword.mail.smtp.socketFactory.fallback=false
omero.resetpassword.mail.smtp.socketFactory.port=25
omero.resetpassword.mail.smtp.timeout=25000

If you look in IAdmin for

private boolean sendEmail(Experimenter e, String newPassword)

I think with the small adjustment we could move it to LocalAdmin interface and make it public.
If you need any help with this please let me know.

I hope that make sense

Kind regards
Ola

From: Douglas Russell <douglas.russell at bioch.ox.ac.uk<mailto:douglas.russell at bioch.ox.ac.uk>>
Date: Saturday, 23 November 2013 16:48
To: Devel <ome-devel at lists.openmicroscopy.org.uk<mailto:ome-devel at lists.openmicroscopy.org.uk>>
Subject: [ome-devel] Email Util Design

Hi,

Posted this on the wrong list initially, please follow up here.

I'm adding an email announcement page to the admin tabs in the web client. Chris mentioned there was a desire to add more email capability to the CLI so I've implemented the web app to use an email sending back-end in utils.

I've already written the actual email sending functions in utils, but now there are some design decisions to make.

OMERO Connection in Utils
Is it desired that utils are not dependant on an OMERO connection? The web client interface I've designed offers an admin the opportunity to select all-users, some groups, some users and there is a text field for arbitrary cc. I can do the resolution of omeName/id and groupId to sets of email addresses in the webclient code, but if it would be useful, I can put it in utils instead? Obviously this relies on having an OMERO connection in the utils, I would just pass it in from the calling function.

Configuration
The current configuration parameters are for the web:

omero.web.server_email "webmaster at example.com<mailto:webmaster at example.com>"
omero.web.email_host "email.example.com<http://email.example.com/>"
omero.web.email_host_user "username"
omero.web.email_host_password "password"
omero.web.email_host_port "2255"
omero.web.email_use_tls "True"
omero.web.email_subject_prefix "Subject prefix for outgoing e-mail"

Options:

  1.  Use these settings everywhere (wont make much sense)
  2.  Define additional settings (bit clumsy)
  3.  Change these setttings to more general ones and have the web use those (more work and requires config changes on existing servers).

Also, obviously the web currently has the capability to send email. Should this be modified to use this generic email system?

Thoughts?

Douglas

The University of Dundee is a registered Scottish Charity, No: SC015096

_______________________________________________
ome-devel mailing list
ome-devel at lists.openmicroscopy.org.uk<mailto:ome-devel at lists.openmicroscopy.org.uk>
http://lists.openmicroscopy.org.uk/mailman/listinfo/ome-devel

The University of Dundee is a registered Scottish Charity, No: SC015096
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openmicroscopy.org.uk/pipermail/ome-devel/attachments/20131126/532c0668/attachment.html>


More information about the ome-devel mailing list