This page describes external applications in Lenses.
External applications are your custom applications that are deployed outside of Lenses, for example a Java Kafka Streams or Python Application.
You can register these into ways:
Via the an SDK
Http Endpoint
This page describes using the Lenses Java SDK to register your own applications with Lenses.
A Java SDK is available, for example, to add Kafka Streams, Akka Streams, and Spark Structured Streaming. You can find full working examples on GitHub.
This page describes using the Lenses Rest endpoints to register your own applications with Lenses.
Each app can be registered with a set of endpoints that return the status of each app’s running instances. These endpoints are called runners
and allow Lenses to get the running instances’ status by pinging these endpoints. The app state is consolidated based on the individual runner’s state, which is periodically checked.
Each runner can be only:
RUNNING - When the health-check endpoints return 200 HTTP Status Code
UNKNOWN - When the health-check endpoints return anything other than 200 HTTP Status Code
Lenses consolidates the individual runners’ statuses into a single app state:
RUNNING - All Runners are RUNNING
WARNING - At least 1 Runner is UNKWOWN
UNKNOWN - No information about Runners, either they are unreachable
To add your external apps to Lenses, you can currently use the API by doing a POST
to api/v1/apps/external
endpoint.
Apps are another type of built-in application. Go to Workspace->Apps
to view your application.
In the application details page, you can see additional information about each application, and also information about each runner, along with metadata information, such as Description
, and auditing information such as Created At
, Created By
and Modified At
, Modified By
.
You can add runners with a POST
request to api/v1/apps/external
. The body of the new request should be the same as the first one except for the runners
key. What needs to be changed is only the array of the runners
key.
You can also remove runners with a DELETE request.
You can remove the app by making a DELETE
request to /api/v1/apps/external/{name}
. By Removing an App from Lenses, you just drop Lenses’ visibility for that specific App.
Alternatively, you can use the Lenses UI to remove the App: