{"id":56893,"library":"org-osgi-util-tracker","title":"OSGi Util Tracker","description":"Provides utility classes for tracking OSGi services and service references.","status":"active","version":"1.5.4","language":"java","source_language":null,"source_url":"https://github.com/osgi/osgi","tags":["osgi","service-tracker","utility"],"install":[{"cmd":"<dependency>\n  <groupId>org.osgi</groupId>\n  <artifactId>org.osgi.util.tracker</artifactId>\n  <version>1.5.4</version>\n</dependency>","lang":"xml","label":"Maven"},{"cmd":"implementation 'org.osgi:org.osgi.util.tracker:1.5.4'","lang":"groovy","label":"Gradle"}],"dependencies":[],"imports":[{"symbol":"ServiceTracker","correct":"org.osgi.util.tracker.ServiceTracker"}],"quickstart":{"code":"import org.osgi.util.tracker.ServiceTracker;\nimport org.osgi.framework.BundleContext;\n\npublic class Example {\n    public void trackService(BundleContext context) {\n        ServiceTracker<?, ?> tracker = new ServiceTracker<>(context, \"com.example.MyService\", null);\n        tracker.open();\n        Object service = tracker.getService();\n        System.out.println(\"Tracked service: \" + service);\n    }\n}","lang":"java","description":"Creates and opens a ServiceTracker to track an OSGi service."},"warnings":[{"fix":"Call tracker.close() when the tracker is no longer needed.","message":"ServiceTracker must be properly closed to avoid resource leaks.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"search_vec":"'class':6 'osgi':1,9,14 'provid':4 'refer':13 'servic':10,12,16 'service-track':15 'track':8 'tracker':3,17 'util':2,5,18","created_at":"2026-06-15T10:54:44.474725+00:00","updated_at":"2026-06-15T10:54:44.474725+00:00","problems":[],"ecosystem":"maven","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://docs.osgi.org/","github":"https://github.com/osgi/osgi","docs":"https://appdoc.app/artifact/org.osgi/org.osgi.util.tracker/","changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["utility"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-15","next_check":"2026-12-12","install_tag":null}}