This is a test application created to test how the Pax Web Whiteboard Extender handles overapping paths from two servlets exposed by two different DS components.

steinarb d3d1a624b3 Merge pull request #25 from steinarb/dependabot/maven/org.junit-junit-bom-5.13.0 2 дней назад
.github fa0b28a2ec Replace java 11 with java 21 in github actions CI build 1 неделя назад
jacoco-coverage-report 0589925ed2 Bump org.jacoco:jacoco-maven-plugin from 0.8.10 to 0.8.13 6 дней назад
src bfe18d049d Initial commit. 7 лет назад
webapi d6b65e0364 Require the Service Component Runtime (SCR) feature, aka Declarative Services (DS) 1 год назад
webgui d11ffe1ad7 Use OSGi 7 web whiteboard annotations for the web GUI 1 год назад
.editorconfig bfe18d049d Initial commit. 7 лет назад
.gitignore bfe18d049d Initial commit. 7 лет назад
LICENSE bfe18d049d Initial commit. 7 лет назад
README.org 8de1fcb3e1 Replace travis-ci CI build with github actions CI build 2 лет назад
pom.xml 9a97a67fec Bump org.junit:junit-bom from 5.12.2 to 5.13.0 2 дней назад

README.org

A test for overlapping whiteboard servlets

This is a test application created to test how the Pax Web Whiteboard Extender handles overapping paths from two servlets exposed by two different DS components.

The webapp servlet will install on overlap and the REST service servlet will install on /overlap/api/testservice

Status

file:https://github.com/steinarb/whiteboard-web-and-api-karaf-demo/actions/workflows/whiteboard-web-and-api-karaf-demo-maven-ci-build.yml/badge.svg https://coveralls.io/repos/github/steinarb/whiteboard-web-and-api-karaf-demo/badge.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=alert_status#.svg file:https://maven-badges.herokuapp.com/maven-central/no.priv.bang.demos.whiteboardwebapi/whiteboard-web-and-api-karaf-demo/badge.svg

file:https://sonarcloud.io/images/project_badges/sonarcloud-white.svg

How to install

file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=sqale_index#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=coverage#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=ncloc#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=code_smells#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=sqale_rating#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=security_rating#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=bugs#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=vulnerabilities#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=duplicated_lines_density#.svg file:https://sonarcloud.io/api/project_badges/measure?project=steinarb_whiteboard-web-and-api-karaf-demo&metric=reliability_rating#.svg

    This is how to build and install the servlet:
  1. First download and install apache karaf
  2. In the apache karaf command line, install the features that pulls in the servlets with their dependencies
  3. #+BEGIN_EXAMPLE feature:repo-add mvn:no.priv.bang.demos.whiteboardwebapi/whiteboard-web-and-api-karaf-demo/LATEST/xml/features feature:install webapi feature:install webgui #+END_EXAMPLE
  4. After this, the servlet will be listening for POST requests, at the local path "/overlap/api/testservice" on the karaf web server, e.g. http://localhost:8181/overlap for a karaf server started locally, with default settings

To uninstall the counter servlet from karaf

    This is how to uninstall the servlet from karaf:
  1. At the karaf console prompt, give the following command:
  2. #+BEGIN_EXAMPLE feature:uninstall webapi #+END_EXAMPLE

This will cause repeated clicks on the "Increment" button to result in 405 responses, because the webgui servlet now intercepts the requests, but that servlet doesn't support the POST requests used to increment the counter.

Reinstalling the webapi feature will cause the count to start again from 0.

License

This software project is licensed under Apache License v. 2.

See the LICENSE file for details.