REGIONAlert

REGIONAlert

(former AlertCity)

An alert city system

Running REGIONAlert:

Step 1: InterSCity

Make sure you have access to the InterSCity platform. You can check if the platform is online using the following command. In this example, we suppose InterSCity is at IP address `172.16.110.131` using TCP port 8000. Please, replace with the correct IP address or FQDN, and TCP port.

curl -X GET "http://172.16.110.131:8000/catalog/capabilities"

Instructions on installing InterSCity can be found here.

Note: Capabilities are created by br.com.meslin.alert.servlet.listener.CheckInterSCity (only) when the web server starts (only).

Step 2: ContextNet

You have two options for running ContextNet:

(1) you can install ContextNet using the instructions available here and run an instance of ContextNet using the following command. Please, replace the path according to your ContextNet installation.

$ java -jar /opt/ContextNet/contextnet-2.7.jar 127.0.0.1 5500 OpenSplice

(2) using Docker, you can run the container described below with ContextNet installed. Pay attention to the container's IP address when configuring REGINALert and HumanMobility.

$ sudo docker run meslin/contextnet

Step 3: REGIONAlert

You have two options for running ContextNet:

Option 1: Clone this project.

Please, configure:

  • Border database physical directory at:

    • br.com.meslin.alert.servlet.GetRegion.java

    • parameters:

      • (deprecated since 2022-01-11)--f Bairros/RioDeJaneiro.lista

      • (optional since 2022-01-11) -w /media/meslin/4E7E313D7E311EE1/Users/meslin/Google Drive/workspace-desktop-ubuntu/RegionAlert/

  • InterSCity IP address and TCP port at:

    • WebContent/WEB-INF/web.xml

    • (deprecated since 2022-01-15) br.com.meslin.alert.connection.Constants.java (???)

    • (deprecated since 2022-01-15) parameter -i VM005

  • Database at (address, user, and password):

    • br.com.meslin.alert.dao.UserDAO

      • CLASSNAME

      • DBURL

      • The current version uses SQLite, so, there is no need for username and password. If you change to another database that requires authentication, you can append a username and password to the URL.

Execute the class br.com.meslin.alert.main.MyContextNetCore as Java Application and the project (or WebContent\index.html) on server.

Option 2: Using Docker:

Run meslin/regionalert as a Docker image. The following exemplifies how to run:

$ sudo docker run -e REGIONALERT_GATEWAYIP=10.0.0.101 -e REGIONALERT_GATEWAYPORTNUMBER=5500 -e REGIONALERT_GROUPDESCRIPTIONFILENAME=Bairros/RioDeJaneiro.lista -e REGIONALERT_INTERSCITYIPADDRESS="172.16.110.131:8000" -e REGIONALERT_WORKDIR=/opt/REGIONAlert/ -it meslin/regionalert

Configure the following environment variables as Docker parameters according to your needs:

  • REGIONALERT_GATEWAYIP=10.0.0.101 → ContextNet-Gateway IP address

  • REGIONALERT_GATEWAYPORTNUMBER=5500 ContextNet-Gateway TCP port-number

  • REGIONALERT_GROUPDESCRIPTIONFILENAME=Bairros/RioDeJaneiro.lista Group description filename related to WORKDIR (se bellow)

  • REGIONALERT_INTERSCITYIPADDRESS="172.16.110.131:8000" InterSCity IP address or FQDN, and TCP port-number

  • REGIONALERT_WORKDIR=/opt/REGIONAlert/ Word directory, including the last slash

Note: You still need ContextNet Gateway and InterSCity platform as described above. Also, don't forget to run HumanMobility.

Step 4: HumanMobility

To run REGIONAlert, you will need the HumanMobility project to simulate users walking around the city.

This project simulates human mobility based on an actual trace. The humans take with them a simulated version of the Mobile Hub for Android.

Considering users at dataset directory, the following command line parameters are a suggestion for running HumanMobility:

-a 127.0.0.1 -p 5500 -d "/media/meslin/4E7E313D7E311EE1/Users/meslin/Google Drive/workspace-desktop-ubuntu/HumanMobility/dataset" -o -43.6 -v 10 -s 0.3 -l -23

That means:

  • latitude -23

  • longitude -43.6

  • simulation speed 10x

  • simulation scale 0.3x

Execute the class br.com.meslin.humanMobility.main.HumanMobility as Java application with the command line parameters described previously.

Environment