This object is in archive! 

Major delay when creating new waypoints

joeloc shared this problem 11 years ago
Solved

Sometimes, Locus takes a major delay (up to a minute "working..." window is shown) when I simply add a new waypoint. I havent really figured out when this happens. Is it possible that Locus tries some network thingies when adding a point and delays when I have a very bad&slow connection? The UI task must obviously never be delayed by network access, that would be a major blunder.

Replies (27)

photo
0

hmm there is for sure not any network connection that blocks this task.


"minute", really? this is crazy. Only task that happen during a "working" dialog is saving to SD card. So slowness may be just because of some problem in writing to database. In this case I suggest to defragment you card, because I never saw such problem during a developing.

photo
0

Creation of waypoints are very snappy for me (tired, old S2) no matter the quality of the connection, so it cannot be Locus unless there is something wrong with the install. (Corrupted files over time etc)


-Defrag, as Menion says sounds like good idea.

photo
0

S2 isn`t really tired


Adding a waypoint works fast and proper here on my good old S2 :)


Most of time, i use "quick add poi" function.


btw


How big are your waypoints.db?


(Locus/data/database ?)

photo
0

yes I also agree that SGS2 is very fast. I also test it before release on SGS2 with some custom 4.2 rom and thanks to "small" screen, it`s maybe faster then Note 2 I primary use.


Here really have to be some problem with access to database. Size (number of points) should also have an influence, mainly for a first point that is added to newly opened database.

photo
0

Hm. Ok. No network issue. It only happens very occasionally for me, normally its superfast (galaxy note 2). Point database is still small, tracks i have a lot though. Will try to figure our more. Database is on internal sd btw.

photo
0

I just had this major delay again two times today and I am quite sure it is in fact a network issue. Both times I had a rubbishly slow GSM connection and both times creating a POI put me on hold for a long time. And both times, the delay STOPPED and the point appeared immediately as soon as I disabled mobile data.


One other time, I waited a bit longer and Locus finally added the point, but it also put up a little red message saying "there is a problem with the internet connection".


So... I dont really know whats going on... but some network stuff is blocking waypoints. Maybe a secret setting that would query altitude or address automatically? I would really love automatic altitude querying btw when the srtm data is not present, but obviously it must be non-blocking.

photo
0

hey I`m betrayed by message "there is a problem with the internet connection" :)


just kidding ... what function you use to add new point? so I may trace all possible places.

photo
0

live tracking or(and) a networklink element (*.kml) used the same db in the background?

photo
0

it`s question on me? :) They don`t use any DB. Live tracking do not need to store any data and network links are stored in operational memory, not in any database

photo
0

just an idea :)

photo
0

Live tracking might have been enabled when the waypoint delays happened.

photo
0

Now it wasnt. And it still delayed.

photo
0

again: "what function you use to add new point? so I may trace all possible places. "


simple "Add new point" from right panel or by button in action bar in "data" screen?


EDIT: I`m checking whole code for screen that edit point and there is no http connection except two cases - address and online altitude. Both are anyway only after you press button. So there have to be some other problem and I really need exact way what you do. Also popup with "Problem with internet connection" may be as gynta wrote, just notification from different service, like live tracking ...

photo
0

@joeloc


You use two *.kml files with network links inside - right?


These are also active when the error occurs?

photo
0

I normally add waypoints by long-clicking on the map and then clicking on the bubble. Address search is on. But in case of bad connection, i simply click the loading... bubble. Then the waypoint window comes up and then i type in the name and click on save. Then the "working..." window appears and doesnt go away for ages.

photo
0

To be clear: the delay happens AFTER i hit the save button in the waypoint dialog. Not before.


Maybe something with terminating the (still running?) Address search task from long clicking a screen position?

photo
0

ok, this is quite important information "the delay happens AFTER i hit the save button in the waypoint dialog", you should say this before.


I searched code once more and checked all possibilities that may happen after you tap on save. Only place that may take a while, is created new connection to database. May you check if this happen just for the first point after you enable (start from fresh) locus or also for some second, third etc. points in one locus session?


If just first, then it really should be a problem of slow database access. One minute is really weird, but it may happen. Anyway, there is really not connection to internet that may slow this action. If you`ll want, I may add some debug information to next test version, so you may record them.

photo
0

Well... long clicking on the map certainly has a "connection" to the internet when Locus starts the address search. Are you sure this is not related somehow?

photo
0

I`m rarely 100% sure, because everything is possible. But in this case, you may try to disable this address search in settings http://docs.locusmap.eu/doku.php/manu... > Enable address search and check what happen.


For me it`s mainly mystery, because I never ever saw this problem, and seems you`re also only one. Are you using any custom or original ROM? I`m asking because it can be connected, but not in normal android. Both actions (loading address and storing to database) should run in different thread and not block one another ...

photo
0

This problem still exists menion and is 100% reproducable. It is caused by the address search task failing to find the address because of miserable internet connection. If you add a waypoint anyway by clicking the address bubble "searching for address" and then click on Save, Locus will STILL wait for the address search network access to timeout (one minute?), even though thats completely pointless. Can you not simply abort the address search task as soon as I click the bubble?


There is NO delay when adding waypoints with the toolbar button. The bug is definitely with terminating the address search thread.

photo
0

You can probably "emulate" a miserable inet connection by using wlan at home and misconfiguring your dsl router.

photo
0

To reprodouce this problem, your Locus must be in a state where the address search bubble stays on screen for a long time and only goes away after the (one minute?) Timeout.

photo
0

ah maybe I found a problem ... you`ll see in next version

photo
0

hard to see now because i am back home and my internet is blazingly fast again. maybe i have to misconfigure my own dsl router to test :)

photo
0

I have the same problem also when adding a normal point. Is this related?


It`s only the first time when I add a point that it takes up to 10 seconds to display the menu. The next points are very fast.

photo
0

I just added a few waypoints with address search on and a miserably slow connection. No more delays with latest Locus. Apparently, this problem is fixed. Thanks :).

photo
0

finally? perfect :)

Replies have been locked on this page!