Author Topic: Setting up an instance of TM's DB and web front end  (Read 16221 times)

0 Members and 1 Guest are viewing this topic.

Offline yakra

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2849
  • Last Login:Today at 12:55:55 pm
Re: Setting up an instance of TM's DB and web front end
« Reply #15 on: June 30, 2019, 08:29:12 pm »
Sure, TravelMappingTest works. Thanks!

Offline michih

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2820
  • Last Login:Today at 05:18:18 pm
Re: DOWNTIME COMING: 7/13/2019
« Reply #16 on: July 09, 2019, 01:10:18 pm »
I've got a mirror running at http://205.209.84.174, so we won't have to go without our fix for a day. :)

Cool 8) I don't wanna complain - I'm very happy that it's working :D - but does your PC have a clock so that you can show the timestamp of "the most recent site update completed"? ;)

Offline yakra

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2849
  • Last Login:Today at 12:55:55 pm
Re: Re: DOWNTIME COMING: 7/13/2019
« Reply #17 on: July 09, 2019, 01:12:52 pm »
 I haven't paid any attention to that feature. I'll have to give it a look.

Offline yakra

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2849
  • Last Login:Today at 12:55:55 pm
Re: Setting up an instance of TM's DB and web front end
« Reply #18 on: July 09, 2019, 01:29:56 pm »
Code: [Select]
// get the timestamp of most recent DB update
function tm_update_time() {
    global $tmdb;
    global $tmdbname;
    $sql_command = "SELECT create_time FROM information_schema.tables WHERE TABLE_SCHEMA = '".$tmdbname."' ORDER BY create_time DESC;";
    global $tmsqldebug;
    if ($tmsqldebug) {
        echo "<!-- SQL: ".$sql_command." -->\n";
    }
    $res = tmdb_query($sql_command);
    $row = $res->fetch_assoc();
    $ans = $row['create_time'];
    $res->free();
    return $ans;
}

Code: [Select]
mysql> SELECT create_time FROM information_schema.tables WHERE TABLE_SCHEMA = 'TravelMapping' ORDER BY create_time DESC;
+---------------------+
| CREATE_TIME         |
+---------------------+
| 2019-07-09 10:52:07 |
| 2019-07-09 10:52:07 |
| 2019-07-09 10:52:06 |
| 2019-07-09 10:52:06 |
| 2019-07-09 10:52:05 |
| 2019-07-09 10:51:57 |
| 2019-07-09 10:51:51 |
| 2019-07-09 10:51:49 |
| 2019-07-09 10:51:48 |
| 2019-07-09 10:51:48 |
| 2019-07-09 10:51:48 |
| 2019-07-09 10:50:42 |
| 2019-07-09 10:50:16 |
| 2019-07-09 10:50:14 |
| 2019-07-09 10:49:51 |
| 2019-07-09 10:49:49 |
| 2019-07-09 10:49:46 |
| 2019-07-09 10:49:46 |
| 2019-07-09 10:49:46 |
| 2019-07-09 10:49:46 |
| 2019-07-09 10:49:46 |
+---------------------+
21 rows in set (0.00 sec)
I'm not sure what's happening.
« Last Edit: July 09, 2019, 01:47:59 pm by yakra »

Offline yakra

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2849
  • Last Login:Today at 12:55:55 pm
Re: Setting up an instance of TM's DB and web front end
« Reply #19 on: July 09, 2019, 01:39:41 pm »
Fixed. Apparently my CentOS setup was treating 'create_time' as case-sensitive, while Jim's FreeBSD setup was not.
https://github.com/TravelMapping/Web/pull/317
« Last Edit: July 09, 2019, 02:07:24 pm by yakra »

Offline yakra

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2849
  • Last Login:Today at 12:55:55 pm
Re: Setting up an instance of TM's DB and web front end
« Reply #20 on: June 29, 2020, 05:18:55 pm »
Attempting to update lab2 with (almost) the latest Web commits...
https://github.com/yakra/Web/tree/lab2redo
https://github.com/yakra/Web/tree/517ebc0898d11985bfaac5fdec2d5f0c8749dbf2

HB is broken:
• No waypoints listed in table
• Map stays centered at Siena,  and Processing Route Waypoint Data... message doesn't go away.

Mapview broken too; same basic symptoms as the 2nd bullet point.

For now, reverting to the previous head I'd been using...
https://github.com/yakra/Web/tree/lab2
https://github.com/yakra/Web/tree/4c7f5d9c607a0bc32c6478830214f9f83ce50000
It will take some detective work to find just where things broke.