EndPointCorp / lg_ros_nodes

A ROS software stack for running Liquid Galaxy applications
https://liquidgalaxy.endpoint.com/
Apache License 2.0
19 stars 5 forks source link

lg_sv: Preserve single Map() instance #384

Open axisofentropy opened 6 years ago

axisofentropy commented 6 years ago

Overview: Today's lg_sv implementation creates and destroys Chrome browser windows every time Street View is opened and closed on Roscoe Liquid Galaxies. Now that Maps API usage is metered, it would be very valuable to maintain Map() instances for as long as feasible. We can modify lg_sv to send Street View browser windows to the background instead of destroying them.

Requirements:

Development notes In most places where we set the state to STOPPED we should instead set to state HIDDEN. Example: https://github.com/EndPointCorp/lg_ros_nodes/blob/master/lg_sv/scripts/server.py#L106

Every time we set a state other than VISIBLE, that's the time to suspend SpaceNav input to the PanoViewerServer class.

Contact @mvollrath for help with this codebase.

Testing scenario On a system with heavy Street View usage, see if its Maps API key has greatly reduced utilization. We expect at most one API request per display per relaunch (plus 1-3 from the touchscreen.) There should be zero API requests generated entering and exiting Street View after the first time after a relaunch.

Watch the ROS topic /streetview/state for state changes.

axisofentropy commented 6 years ago

@kiselev-dv is working on this here https://github.com/EndPointCorp/lg_ros_nodes/tree/sv_persist_browsers

axisofentropy commented 6 years ago

This is now deployed to the client system that was using the most Maps API calls. It seems to work fine, and the number of API calls has drastically diminished.

This is included within our disk image version 2.11.0-rc9002.

axisofentropy commented 2 years ago

I think this ticket can be closed.