freedomotic icon indicating copy to clipboard operation
freedomotic copied to clipboard

Notify the user when Freedomotic can't load

Open mcicolella opened this issue 8 years ago • 5 comments

If there is any problem at startup (due to a bad configured environment), FD stops without notifying the user, so he just think that FD doesn't work. We need to offer the info to the user in a nice way.

mcicolella avatar Feb 14 '16 14:02 mcicolella

@P3trur0 what do you think?

mcicolella avatar Jan 27 '17 17:01 mcicolella

@mcicolella this seems a little abstract scenario. What do you specifically mean with startup problem? The front end part or the engine itself?

One proposal could be to send either an e-mail or to display a basic GUI prompt.

However, we should evaluate how much each of those approaches could be feasible according to the failure scenario (e.g.: if the JVM goes down it'd be difficult to perform any notification from freedomotic itself).

ubaldop avatar Jan 27 '17 18:01 ubaldop

@P3trur0 I agree with you. If you start Freedomotic manually from command line you can see any log message about startup problems: environment file not found, network not available, other missing files etc But an unmanned/headless installation requires a notification system. The same if you start FD by .exe or .sh file: the spash screen disappears and you don't know what happened.

mcicolella avatar Jan 28 '17 10:01 mcicolella

Another notification: when the network is not available (e.g. PC not connected to a LAN/WLAN) FD stops with a lot of error messages

ERROR [main] - Failed to start Apache ActiveMQ ([ba0cb4d7-8aa8-4ad6-8241-7264de82a50f, ID:emmecilab-42086-1486394041702-0:2], java.net.SocketException: bad argument for IP_MULTICAST_IF2) INFO [main] - Apache ActiveMQ 5.14.1 (ba0cb4d7-8aa8-4ad6-8241-7264de82a50f, ID:emmecilab-42086-1486394041702-0:2) is shutting down INFO [main] - Network Connector DiscoveryNetworkConnector:NC:BrokerService[ba0cb4d7-8aa8-4ad6-8241-7264de82a50f] stopped ERROR [main] - Failed to advertise our service: freedomotic-commander.ActiveMQ-4.dead.%localhost%tcp://emmecilab:41678 java.io.IOException: Network is unreachable at java.net.PlainDatagramSocketImpl.send(Native Method) at java.net.DatagramSocket.send(DatagramSocket.java:693) at org.apache.activemq.transport.discovery.multicast.MulticastDiscoveryAgent.doAdvertizeSelf(MulticastDiscoveryAgent.java:446)

mcicolella avatar Feb 06 '17 15:02 mcicolella

Maybe the nicest way to notify the user about Freedomotic startup failure is an alert icon in the traybar. It is a quite universal GUI element whatever OS you are using. If you can add a baloon with critical last ActiveMQ warnings too, perhaps it would be perfect ;)

amenak77 avatar Oct 11 '17 23:10 amenak77