Open Sensor Search Software Development
General information, goals and roadmap can be found on the page OpenSensorSearch
Architecture and Features (under development!)
Libraries to use
Things to consider
- FEST and mockito
- Spring MVC
- use Json-schema: http://json-schema.org/
- core (GetCapabilities, DescribeSensor, SearchSensor, the RESTful equivalents)
- transactional (InsertSensorInfo, DeleteSensorInfo, UpdateSensorDescription, HarvestService, their RESTful equivalents)
- status (GetSensorStatus, InsertSensorStatus)
- catalog (ConnectoToCatalog, DisconnetFromCatalog)
- transform (SensorML to ebRIM, ...)
- /stations (by using to Sensor Web Client's server component?)
- Agile development with Scrum
- TDD with all tests following the F.I.R.S.T. principles: fast, isolates, repeatable, self-validating, timely.
- Unit tests for day-to-day developments
- Before accepting pull requests into the main repository, integration tests have to run successfully
Backlog is managed on easybacklog.com > contact DanielNuest
to get access.
Get a local development version in Eclipse
- We use the fork & pull development model.
- "No bugfix without a test."
- Bugs are managed with GitHub issues.
- We use the 52°North Eclipse code formatter, see Documentation
- Fork the repo on GitHub.
- Clone the fork into you local repository.
- Add the local repository to Eclipse, e.g. using e-Git.
- Go to the working directory, right click and import as "general project", click Finish.
- After the import, right click on the project and Configure > Convert to Maven Project
- (Alternatively:) New > Project > Select Wizard "Checkout Maven Projects from SCM"
Building with Maven
Build the project
mvn clean install
A notice file is mandatory for all projects licenced under Apache 2.0, so we use this handy plugin to create one for us. Important
: This only works automatically for Maven dependencies!
- Check if the notice file is up-to-date, which will also check if there are missing licenses for Java libraries:
- Generate the notice file:
When you add a new library or dependency, run the command below and see if it is added to the file LICENSE in the project root. If not you have to manually add the information to the file
The licence header plugin can be annoying at times, but it keeps the code alsways in a good state, therefore it always runs on every build.
- Check which files miss the header:
- Add the headers to these files:
If you include external libs as files don't forget to add their path/names to the exclusion patterns!
The gitlog plugin
is used to create a CHANGES file containing all the information that was changed between versions. This should motivate you to write reasonable commit messages!
- Show the output of gitlog in command line:
The gitlog is not yet included the default build process but will be once we add the proper assembly configurations
Run Integration Tests
- Configure and Start Solr
- See http://wiki.apache.org/solr/SolrInstall for full documentation.
- You can either install solr to your existing servlet container, or just download it and run it from the command line.
- Deploy to servlet container
- Follow the instructions here
- Run from the command line
- Download and extract Solr: http://lucene.apache.org/solr/downloads.html
- Got to directory
- Replace the contents of the file
schema.xml with this file from the OpenSensorSearch project:
- Go to the folder
<unpack-destination>/solr-4.x.x/example/, run the jar file with :
java -jar start.jar, for more instructions see <unpack-destination>/solr-4.x.x/example/README.txt
- Configure and Start PostgreSQL
- Open a console in the project root directory and make sure Maven is on the command line
Dummy Data Generators
TBDocumented: the old one with SensorML
, the new one by Mohammad