camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ben O'Day (JIRA)" <>
Subject [jira] Commented: (CAMEL-2989) provider an API to query available endpoints on a component
Date Wed, 19 Jan 2011 02:28:44 GMT


Ben O'Day commented on CAMEL-2989:

hey James, I started looking into adding to camel-web's endpoints page.  Any reason we couldn't
use the CamelContext getEndpointMap() API for this?  Something like this could return all
endpoints matching a given pattern (component prefix, etc.)...

        //find all file endpoints
        String filter = "file:";
        Map<String, Endpoint> map = this.context.getEndpointMap();
        Set<Map.Entry<String, Endpoint>> entries = map.entrySet();
        ArrayList<String> matches = new ArrayList<String>();
        for (Map.Entry<String, Endpoint> entry : entries) {
            if(entry.getKey().indexOf(filter) != -1) {
        System.out.println("matches->" + matches);

> provider an API to query available endpoints on a component
> -----------------------------------------------------------
>                 Key: CAMEL-2989
>                 URL:
>             Project: Camel
>          Issue Type: New Feature
>          Components: camel-core
>    Affects Versions: 2.4.0
>            Reporter: james strachan
>             Fix For: 3.0.0
> many components like file, activemq, nmr, jbi, database all are capable of browsing the
available endpoints that a user could use from, say, a command line tool or from camel-web.
> So we should add a browse API that lets you query a component for available endpoints.
> Maybe allow things to be browsed in a tree kind of way - maybe with a text search type
thing (for completion boxes etc)

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message