-
Notifications
You must be signed in to change notification settings - Fork 72
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 42070be
Showing
798 changed files
with
73,842 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
*.iml | ||
*.ipr | ||
*.iws | ||
catalina.*/ | ||
target/ | ||
indexes/ | ||
.idea/ | ||
|
||
# The Hibernate JPAModelGen plugin currently puts the sources in generates | ||
# in the wrong place; they should be under target/generated-sources/, but | ||
# instead it puts them in /com/ . Ignore it until that's fixed... | ||
/com/ | ||
/aspectj-generated-sources/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
#### This software uses assets from the following sources: | ||
|
||
Silk Icons | ||
- License: Creative Commons Attribution 2.5 | ||
- http://www.famfamfam.com/lab/icons/silk/ | ||
|
||
#### This software uses the following open source libraries: | ||
|
||
AspectJ 1.8.9 | ||
- License: EPL 1.0 | ||
- https://eclipse.org/aspectj/ | ||
|
||
Spring Framework 4.2.5 | ||
- License: Apache 2.0 | ||
- http://projects.spring.io/spring-framework/ | ||
|
||
Spring Data JPA 1.9.4 | ||
- License: Apache 2.0 | ||
- http://projects.spring.io/spring-data-jpa/ | ||
|
||
Spring Security 4.0.3 | ||
- License: Apache 2.0 | ||
- http://projects.spring.io/spring-security/ | ||
|
||
Thymeleaf 2.1.4 | ||
- License: Apache 2.0 | ||
- http://www.thymeleaf.org/ | ||
|
||
HikariCP 2.4.5 | ||
- License: Apache 2.0 | ||
- https://brettwooldridge.github.io/HikariCP/ | ||
|
||
Hibernate ORM 5.1.0 | ||
- License: LGPL 2.1 | ||
- http://hibernate.org/orm/ | ||
|
||
Hibernate Search 5.5.3 | ||
- License: LGPL 2.1 | ||
- http://hibernate.org/search/ | ||
|
||
Logback 1.1.5 | ||
- License: LGPL 2.1 | ||
- http://logback.qos.ch/ | ||
|
||
HyperSQL 2.3.3 | ||
- License: BSD | ||
- http://hsqldb.org/ | ||
|
||
SLF4J 1.7.16 | ||
- License: MIT | ||
- http://www.slf4j.org/ | ||
|
||
Jackson Databind 2.6.5 | ||
- License: Apache 2.0 | ||
- https://github.com/FasterXML/jackson-databind | ||
|
||
Google Guava 18.0 | ||
- License: Apache 2.0 | ||
- https://github.com/google/guava | ||
|
||
JUnit 4.12 | ||
- License: EPL 1.0 | ||
- http://junit.org/junit4/ | ||
|
||
Mockito 1.10.19 | ||
- License: MIT | ||
- http://mockito.org/ | ||
|
||
AssertJ 2.3.0 | ||
- License: Apache 2.0 | ||
- http://joel-costigliola.github.io/assertj/ | ||
|
||
Hamcrest 1.3 | ||
- License: BSD | ||
- http://hamcrest.org/ | ||
|
||
Objenesis 2.1 | ||
- License: MIT | ||
- http://objenesis.org/ | ||
|
||
MySQL Connector 6.0.2 | ||
- License: GPLv2 | ||
- https://dev.mysql.com/downloads/connector/j/ | ||
|
||
Apache Commons Codec 1.10 | ||
- License: Apache 2.0 | ||
- https://commons.apache.org/proper/commons-codec/ | ||
|
||
Apache Commons Compress 1.10 | ||
- License: Apache 2.0 | ||
- https://commons.apache.org/proper/commons-compress/ | ||
|
||
Apache Commons Lang 3.3.2 | ||
- License: Apache 2.0 | ||
- https://commons.apache.org/proper/commons-lang/ | ||
|
||
Google Maps Services 0.1.12 | ||
- License: Apache 2.0 | ||
- https://github.com/googlemaps/google-maps-services-java | ||
|
||
YamlBeans 1.09 | ||
- License: BSD | ||
- https://github.com/EsotericSoftware/yamlbeans | ||
|
||
Sencha ExtJS 6.0.1 | ||
- License: GPLv3 | ||
- https://www.sencha.com/products/extjs/ | ||
|
||
OpenLayers 3.15.1 | ||
- License: BSD | ||
- http://openlayers.org/ | ||
|
||
SockJS 1.0.3 | ||
- License: MIT | ||
- https://github.com/sockjs/sockjs-client | ||
|
||
StompJS | ||
- License: Apache 2.0 | ||
- http://jmesnil.net/stomp-websocket/doc/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
# Bag Database changelog | ||
|
||
2.0 | ||
|
||
- Adding Tomcat manually installation instructions | ||
- Removed the "Name" database column; it was useless | ||
- Bumping the version number to 2.0 for the open source release | ||
- Consistently using the name "bag-database" between the Docker image and the Maven artifact name | ||
- Adding the 3-clause BSD license | ||
- Adding attributions for all of the dependencies | ||
- Updated some dependencies | ||
- Extracted bag reading a deserializing functionality into a separate library | ||
- Changed the Maven groupId to com.github.swri-robotics | ||
- Changed the package name to com.github.swrirobotics | ||
- Preventing the user from dragging windows outside of the viewable area | ||
- Fixing an issue that would make map tile credentials invisible | ||
|
||
1.7 | ||
|
||
- Displaying visible warnings when searching by both message types and topic names | ||
- Optimizing some CSS | ||
- Adding the ability to download multiple bags at once | ||
- Adding the ability to plot multiple bags on a single map | ||
- Couldn't save bag files | ||
- Couldn't search on the description field | ||
- Using the Java 1.8 stream operators where possible for parallelizability | ||
|
||
1.6 | ||
|
||
- Adding checkboxes for controlling the full text search fields | ||
- Enabling filtering for all grid columns | ||
- Switching the Bag grid to a BufferedStore for faster loading | ||
- Disabling inline editing on the main grid due to an ExtJS bug | ||
- Handling sorting and pagination on the remote side | ||
- Adding /vehicle/gps/fix to the list of known GPS topics | ||
|
||
1.5 | ||
|
||
- Handle relative URLs properly | ||
- Enable gzip compression in Tomcat for Docker | ||
- ExtJS updated to 6.0.1 | ||
- OpenLayers updated to 3.51.1 | ||
- Added an "About" window | ||
- A navigation button has been added with links to the admin and config pages | ||
- Administrative privileges are required to access the admin and config pages | ||
- The admin password can be set through the config file on startup | ||
- CSRF protection has been implemented | ||
- Handling changing the bag path at runtime | ||
- Added a Dockerfile and a maven plugin for building a Docker image | ||
- Rewrote bag hashing to be more reliable | ||
- Cleaned up and documented lots of code | ||
- Improved bag reading performance | ||
- Removed the "DuplicateBag" table and related functionality; it was just a workaround due to hashing bags being very slow | ||
|
||
1.4 | ||
|
||
- Implemented generic message deserialization | ||
- Removed hand-written deserialization classes | ||
|
||
1.3 | ||
|
||
- Sped up bag hashing |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
Copyright (c) 2016, Southwest Research Institute® (SwRI®) | ||
All rights reserved. | ||
|
||
Redistribution and use in source and binary forms, with or without | ||
modification, are permitted provided that the following conditions are met: | ||
* Redistributions of source code must retain the above copyright | ||
notice, this list of conditions and the following disclaimer. | ||
* Redistributions in binary form must reproduce the above copyright | ||
notice, this list of conditions and the following disclaimer in the | ||
documentation and/or other materials provided with the distribution. | ||
* Neither the name of Southwest Research Institute® (SwRI®) nor the | ||
names of its contributors may be used to endorse or promote products | ||
derived from this software without specific prior written permission. | ||
|
||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND | ||
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | ||
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
DISCLAIMED. IN NO EVENT SHALL Southwest Research Institute® BE LIABLE FOR ANY | ||
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES | ||
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; | ||
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND | ||
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS | ||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,155 @@ | ||
# Bag Database | ||
|
||
The Bag Database is a web-based application that monitors a directory for ROS bag | ||
files, parses their metadata, and provides a friendly web interface for searching | ||
for bags and downloading them. Its goal is to make it easy to catalog thousands | ||
of bag files, search through them for relevant data such as topic names and message | ||
types, view information about them, and download them. | ||
|
||
Currently it is intended primarily for internal use. Any user can edit metadata | ||
for bag files, and it is expected that users have access to the location where bags | ||
are stored and will be manually uploading files there. | ||
|
||
 | ||
|
||
## Features | ||
|
||
- **Directory Monitoring**: It will watch a directory for any changes and | ||
automatically scan any bag files placed in that directory. | ||
- **Full-text Searching**: The Search field will search the text fields selected by the user in every | ||
bag file for any strings containing the provided text; it can search: | ||
- The bag's file name | ||
- The path leading to the bag on the filesystem | ||
- A user-provided description of the bag | ||
- The name of the physical location where the bag was recorded | ||
- (Either this must be manually entered or support for Google's reverse | ||
geocoding API must be enabled) | ||
- The name of the vehicle | ||
- The types of any messages used | ||
- The topics published | ||
- **Filtering**: Every column in the grid can by filtered by arbitrary values; | ||
click the down arrow on a column header to set a filter. | ||
- **Displaying Metadata**: All of the same information you could obtain with | ||
`rosbag info` is extracted and stored so that it can be easily viewed for any | ||
bag file. | ||
- **Message Types and Topics**: You can also easily view all of the different | ||
message types and topics used in the bag file. | ||
- **Displaying GPS Coordinates**: GPS coordinates recorded in a bag file are | ||
extracted and stored, and if support for Bing Maps or MapQuest is enabled you | ||
can view the vehicle's path on a map. | ||
- **Downloading**: Every bag file can be downloaded from the interface without | ||
needing to find it on the host filesystem. | ||
|
||
## Compiling | ||
|
||
The bag database is a Spring-based web application that requires Java 8.0 or later. | ||
To compile it, you need JDK 8.0 or later and Maven 3.0.5 or later. To build a | ||
WAR package, run: | ||
|
||
`mvn package` | ||
|
||
The preferred mechanism for running the bag database is as a | ||
[Docker](https://www.docker.com/) container. To build the docker image, run: | ||
|
||
`mvn package && sudo mvn docker:build` | ||
|
||
## Running | ||
|
||
### Docker (Preferred method) | ||
|
||
The bag database can run standalone in order to demonstrate its functionality, but | ||
if you do so it will have to rebuild the database every time it restarts. Instead | ||
you should link it to an external database. MySQL and PostgreSQL are supported; | ||
PostgreSQL is preferred. | ||
|
||
To start a PostgreSQL container with PostGIS support: | ||
``` | ||
docker run -d \ | ||
--name bagdb-postgres \ | ||
-e POSTGRES_PASSWORD=letmein \ | ||
-e POSTGRES_USER=bag_database \ | ||
-e POSTGRES_DB=bag_database \ | ||
mdillon/postgis:latest | ||
``` | ||
|
||
The bag database exposes port 8080 and expects to find bag files in a volume at /bags by default. You can run it like so: | ||
``` | ||
docker run -d \ | ||
-p 8080:8080 \ | ||
-v /bag/location:/bags \ | ||
--name bagdb \ | ||
--link bagdb-postgres:bagdb-postgres \ | ||
-e DB_DRIVER=org.postgresql.Driver \ | ||
-e DB_PASS=letmein \ | ||
-e DB_URL="jdbc:postgresql://bagdb-postgres/bag_database" \ | ||
-e DB_USER=bag_database \ | ||
swrirobotics/bag-database:latest | ||
``` | ||
|
||
After the bag database has successfully started, the bag database should be available at `http://127.0.0.1:8080`. Modify your Docker parameters as desired to expose it on a different port or set up [HAProxy](https://hub.docker.com/_/haproxy/) if you want to enable SSL or have it accessible via a subdirectory. | ||
|
||
#### Volumes | ||
|
||
Several volumes within the Docker container may be useful to mount externally: | ||
|
||
##### `/bags` | ||
|
||
The location which will be monitored for bag files. | ||
|
||
##### `/root/.ros-bag-database/indexes` | ||
|
||
The location in which the bag database stores its Lucene database indexes. | ||
|
||
##### `/usr/local/tomcat/logs` | ||
|
||
The location where Tomcat places its log files. | ||
|
||
#### Environment Variables | ||
|
||
Several environment variables can be set to configure the Docker container: | ||
|
||
##### ADMIN_PASSWORD | ||
|
||
The default password for administrative access. If this is not set, one will be randomly generated and printed to the log file on initial startup. | ||
|
||
##### DB_DRIVER | ||
|
||
The class name of the JDBC driver to use. | ||
|
||
##### DB_PASS | ||
|
||
The password to use when connecting to the database. | ||
|
||
##### DB_URL | ||
|
||
The JDBC URL for connecting to the database. | ||
|
||
##### DB_USER | ||
|
||
The username to use when connecting to the database. | ||
|
||
##### GOOGLE_API_KEY | ||
|
||
A Google API key that has permission to use the Google Maps GeoCoding API; this is necessary in order to resolve place names for GPS coordinates. | ||
|
||
##### USE_MAPQUEST | ||
|
||
Set this to `true` to use MapQuest for displaying map imagery; set it to `false` to disable MapQuest. The default is `true`. | ||
|
||
##### USE_BING | ||
|
||
Set this to `true` to use Bing Maps for displaying map imagery; set it to `false` to disable Bing. The default is `false`. | ||
|
||
##### BING_KEY | ||
|
||
The API key to use when connecting to Bing Maps. | ||
|
||
### As An Application Server Servlet | ||
|
||
Only Tomcat 8.0 with Java 8.0 has been tested. | ||
|
||
1. Start up your application server and deploy the WAR file to it. | ||
2. The bag database will automatically create a directory at `${HOME}/.ros-bag-database` and place its configuration inside there. | ||
3. Edit `${HOME}/.ros-bag-database/settings.yml` and set your configuration, then restart the application. | ||
4. Look inside the log file at `${TOMCAT_HOME}/logs/bag_database.log` to find the automatically-generated administrator password. | ||
5. Log in through the GUI and use the Maintenance panel to change the password. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.