You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Christian Schneider (JIRA)" <ji...@apache.org> on 2012/06/26 17:31:42 UTC

[jira] [Created] (CAMEL-5399) New component camel-dynamicep

Christian Schneider created CAMEL-5399:
------------------------------------------

             Summary: New component camel-dynamicep
                 Key: CAMEL-5399
                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
             Project: Camel
          Issue Type: Bug
            Reporter: Christian Schneider
            Assignee: Christian Schneider
             Fix For: 3.0.0


I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this

from("dynamicep:file:test,jms:myqueue")...

So you simply supply a list of normal endpoints separated by commas. 

Some things we need to decide are:
- Name of the component. I am not sure if dynamicep i ideal. Any better names?
- Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI

I currently set the Fix version to 3.0.0 but we can easily backport this.


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402125#comment-13402125 ] 

Christian Schneider commented on CAMEL-5399:
--------------------------------------------

Hmmm .. how about simply allowing "," in from(String) like: from("jms:myqueue, jms:myqueue2"). That would allow tools
like the Talend Route Builder to work with a list of endpoints already.

The from(Expression) has the disadvantage that tooling needs to be adapted to it. Still it makes sense to have it of course.
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402092#comment-13402092 ] 

Christian Schneider edited comment on CAMEL-5399 at 6/27/12 9:51 AM:
---------------------------------------------------------------------

Not exactly. There are some substantial differences that made me code this.

In the dynamicep component the exact same route is used while in your example there are two instances.
Using direct endpoints this could be achieved like:
rom("file:test").to("direct:test")
from("jms:myqueue").to("direct:test")
from("direct:test").to("...")

As you can use property placeholders in the uri you can have a dynamical list of endpoints to listen on:
from("dynamicep:{{listenEndpoints}}").to("...")
So this allows to listen on a list of endpoints where the number of endpoints to listen on is not known at compile time. We use this for a customer that wants to listen on a larger list of jms queues.
This behaviour is quite difficult to mimic without the new component.
... Seeems the curly braces in my route are swallowd by jira.. so imagine you see a placeholder there :-)
                
      was (Author: chris@die-schneider.net):
    Not exactly. There are some substantial differences that made me code this.

In the dynamicep component the exact same route is used while in your example there are two instances.
Using direct endpoints this could be achieved like:
rom("file:test").to("direct:test")
from("jms:myqueue").to("direct:test")
from("direct:test").to("...")

As you can use property placeholders in the uri you can have a dynamical list of endpoints to listen on:
{pre}from("dynamicep:{{listenEndpoints}}").to("..."){pre}
So this allows to listen on a list of endpoints where the number of endpoints to listen on is not known at compile time. We use this for a customer that wants to listen on a larger list of jms queues.
This behaviour is quite difficult to mimic without the new component.

                  
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402123#comment-13402123 ] 

Christian Schneider commented on CAMEL-5399:
--------------------------------------------

Sounds basically good. My component had the advantage to work even with older camel versions but I agree that your proposal is nicer. I can work on that.
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402111#comment-13402111 ] 

Christian Schneider commented on CAMEL-5399:
--------------------------------------------

@Guillaume I donĀ“t think it is possible to achieve what I need (dynamic list of endpoints) with what we have now. If you find a good way then we do not need the component of course.
Btw. the component is really small (only has 3 files). I will commit it soon on trunk so you can have a look at it. If we find a nice way without the component we can remove the code again. 
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

[jira] [Updated] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Schneider updated CAMEL-5399:
---------------------------------------

    Attachment: RouteDefinitionHelper.java.patch
                camel-dynamicep.zip
    
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>         Attachments: RouteDefinitionHelper.java.patch, camel-dynamicep.zip
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Guillaume Nodet (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402109#comment-13402109 ] 

Guillaume Nodet commented on CAMEL-5399:
----------------------------------------

Yeah, I much prefer building the endpoints list using an expression instead of adding a new component.  Kinda like the same discussion we had with the proposed osgi component.
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Guillaume Nodet (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402082#comment-13402082 ] 

Guillaume Nodet commented on CAMEL-5399:
----------------------------------------

Is the following:
  from("dynamicep:file:test,jms:myqueue").to("xxx")
just a shortcut for:
  from("file:test").to("xxx")
  from("jms:myqueue").to("xxx")
?
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Schneider updated CAMEL-5399:
---------------------------------------

    Attachment: RouteDefinitionHelper.java.patch

I have found a solution to implement the split by comma for any endpoint URI. See my patch. 

I first wanted to do it in the RouteDefinition.from(String) but then the spring dsl would not work. So I did the split in the helper which is called from Java and Spring DSL.

What do you guys think? In case we have a problem with the comma being used in come components we can refine the split regex to check if after the comma there is a component id and a colon. 
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>         Attachments: RouteDefinitionHelper.java.patch
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402131#comment-13402131 ] 

Christian Schneider commented on CAMEL-5399:
--------------------------------------------

Absolutely .. but not in tooling if the tooling wants to put a string there. I think the change to achieve this split in the impl of from should be fairly small. I will try to implement that and report what I found.
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402108#comment-13402108 ] 

Claus Ibsen commented on CAMEL-5399:
------------------------------------

You example above can only be done in Java, not in XML
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402113#comment-13402113 ] 

Claus Ibsen commented on CAMEL-5399:
------------------------------------

Please dont commit to trunk, as we are in the process of releasing Camel 2.10, so the trunk code must be stable!
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402118#comment-13402118 ] 

Christian Schneider commented on CAMEL-5399:
--------------------------------------------

Ok .. thought we were through with that already .. I will add a patch and wait till 2.10 is through
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Schneider updated CAMEL-5399:
---------------------------------------

    Issue Type: New Feature  (was: Bug)
    
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Schneider updated CAMEL-5399:
---------------------------------------

    Attachment:     (was: RouteDefinitionHelper.java.patch)
    
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (CAMEL-5399) New component camel-dynamicep

Posted by "Guillaume Nodet (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402120#comment-13402120 ] 

Guillaume Nodet edited comment on CAMEL-5399 at 6/27/12 10:24 AM:
------------------------------------------------------------------

I didn't say we could do it now, but I think the same thing would be better achieved using an expression passed to from(xx)
such as from(myExpression) for a dynamic list or using multiple arguments from(xx, yy) for a fixed list.
So what I was suggesting is enhance the RouteBuilder to support using an expression as the from parameter instead of writing a new component.  Given the RouteBuilder already supports a few variations, one more would be more consistent and flexible than a new component, so in addition to
{code}
from(Endpoint)
from(Endpoint...)
from(String)
from(String...)
{code}
we'd have
{code}
from(Expression)
{code}
and afaik, that would fix your use case and be even more flexible than a component I think.

                
      was (Author: gnt):
    I didn't say we could do itnow, but I think the same thing would be better achieved using an expression passed to from(xx)
such as from(myExpression) for a dynamic list or using multiple arguments from(xx, yy) for a fixed list.
So what I was suggesting is enhance the RouteBuilder to support using an expression as the from parameter instead of writing a new component.  Given the RouteBuilder already supports a few variations, one more would be more consistent and flexible than a new component, so in addition to
{code}
 from(Endpoint)
 from(Endpoint...)
 from(String)
 from(String...)
{code}
we'd have
{code}
 from(Expression)
{code}
and afaik, that would fix your use case and be even more flexible than a component I think.

                  
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Schneider updated CAMEL-5399:
---------------------------------------

    Attachment: camel-dynamicep.zip

I have also added the dynamicep component code if wedecide to do it this way.
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Schneider updated CAMEL-5399:
---------------------------------------

    Attachment:     (was: camel-dynamicep.zip)
    
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402092#comment-13402092 ] 

Christian Schneider edited comment on CAMEL-5399 at 6/27/12 9:50 AM:
---------------------------------------------------------------------

Not exactly. There are some substantial differences that made me code this.

In the dynamicep component the exact same route is used while in your example there are two instances.
Using direct endpoints this could be achieved like:
rom("file:test").to("direct:test")
from("jms:myqueue").to("direct:test")
from("direct:test").to("...")

As you can use property placeholders in the uri you can have a dynamical list of endpoints to listen on:
{pre}from("dynamicep:{{listenEndpoints}}").to("..."){pre}
So this allows to listen on a list of endpoints where the number of endpoints to listen on is not known at compile time. We use this for a customer that wants to listen on a larger list of jms queues.
This behaviour is quite difficult to mimic without the new component.

                
      was (Author: chris@die-schneider.net):
    Not exactly. There are some substantial differences that made me code this.

In the dynamicep component the exact same route is used while in your example there are two instances.
Using direct endpoints this could be achieved like:
rom("file:test").to("direct:test")
from("jms:myqueue").to("direct:test")
from("direct:test").to("...")

As you can use property placeholders in the uri you can have a dynamical list of endpoints to listen on:
from("dynamicep:\{\{listenEndpoints\}\}").to("...")
So this allows to listen on a list of endpoints where the number of endpoints to listen on is not known at compile time. We use this for a customer that wants to listen on a larger list of jms queues.
This behaviour is quite difficult to mimic without the new component.

                  
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Guillaume Nodet (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402120#comment-13402120 ] 

Guillaume Nodet commented on CAMEL-5399:
----------------------------------------

I didn't say we could do itnow, but I think the same thing would be better achieved using an expression passed to from(xx)
such as from(myExpression) for a dynamic list or using multiple arguments from(xx, yy) for a fixed list.
So what I was suggesting is enhance the RouteBuilder to support using an expression as the from parameter instead of writing a new component.  Given the RouteBuilder already supports a few variations, one more would be more consistent and flexible than a new component, so in addition to
{code}
 from(Endpoint)
 from(Endpoint...)
 from(String)
 from(String...)
{code}
we'd have
{code}
 from(Expression)
{code}
and afaik, that would fix your use case and be even more flexible than a component I think.

                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402119#comment-13402119 ] 

Christian Schneider commented on CAMEL-5399:
--------------------------------------------

Damn .. must have hit the wrong button while adding the resources locally .. Seems I just committed .. will roll back

                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402092#comment-13402092 ] 

Christian Schneider edited comment on CAMEL-5399 at 6/27/12 9:49 AM:
---------------------------------------------------------------------

Not exactly. There are some substantial differences that made me code this.

In the dynamicep component the exact same route is used while in your example there are two instances.
Using direct endpoints this could be achieved like:
rom("file:test").to("direct:test")
from("jms:myqueue").to("direct:test")
from("direct:test").to("...")

As you can use property placeholders in the uri you can have a dynamical list of endpoints to listen on:
from("dynamicep:\{\{listenEndpoints\}\}").to("...")
So this allows to listen on a list of endpoints where the number of endpoints to listen on is not known at compile time. We use this for a customer that wants to listen on a larger list of jms queues.
This behaviour is quite difficult to mimic without the new component.

                
      was (Author: chris@die-schneider.net):
    Not exactly. There are some substantial differences that made me code this.

In the dynamicep component the exact same route is used while in your example there are two instances.
Using direct endpoints this could be achieved like:
rom("file:test").to("direct:test")
from("jms:myqueue").to("direct:test")
from("direct:test").to("...")

As you can use property placeholders in the uri you can have a dynamical list of endpoints to listen on:
from("dynamicep:{{listenEndpoints}}").to("...")
So this allows to listen on a list of endpoints where the number of endpoints to listen on is not known at compile time. We use this for a customer that wants to listen on a larger list of jms queues.
This behaviour is quite difficult to mimic without the new component.

                  
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402131#comment-13402131 ] 

Christian Schneider edited comment on CAMEL-5399 at 6/27/12 10:55 AM:
----------------------------------------------------------------------

Absolutely .. but not in tooling if the tooling wants to put a string there. I think the change to achieve this split in the impl of from should be fairly small. I will try to implement that and report what I found. The only risk I see is if a Endpoint URI already contains a comma which is not meant to be a separator. 
                
      was (Author: chris@die-schneider.net):
    Absolutely .. but not in tooling if the tooling wants to put a string there. I think the change to achieve this split in the impl of from should be fairly small. I will try to implement that and report what I found.
                  
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402105#comment-13402105 ] 

Christian Schneider edited comment on CAMEL-5399 at 6/27/12 10:10 AM:
----------------------------------------------------------------------

The from("..").from("..") does not work if you do not know the number of endpoints in advance. 
Building the endpoint list using an expression or bean could be a nice addition. It would allow to abstract the config from the endpoint syntax. 
So for example you could have only a list of queues in the config and a bean would create the the exact dynamicep uri. 

I think this is already possible though:
MyBean epBean = new MyBean();
from(epBean.getUri()).to("..")

So I think we do not need to implement this in the component.

Btw. by using blueprint and conig admin service I was able to restart the context on property changes. So the endpoint list could be really changed at runtime without even redeploying the bundle.
                
      was (Author: chris@die-schneider.net):
    The from("..").from("..") does not work if you do not know the number of endpoints in advance. 
Building the endpoint list using an expression or bean could be a nice addition. It would allow to abstract the config from the endpoint syntax. 
So for example you could have only a list of queues in the config and a bean would create the the exact dynamicep uri. 

I think this is already possible though:
MyBean epBean = new MyBean();
from(epBean.getUri()).to("..")

So I think we do not need to implement this in the component.
                  
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402097#comment-13402097 ] 

Claus Ibsen commented on CAMEL-5399:
------------------------------------

You can do today
{code}
from("file:test", "jms:myqueue").to("xxx")
{code}

Or stack multiple froms (maybe not so nice readable)
{code}
from("file:test").from("jms:myqueue").to("xxx")
{code}

The dynamiceip would IMHO only be interesting if it computes at route startup time (eg runtime) the incoming endpoints to the route.
{code}
from("dynamiceip:bean:myInputs").to("xxx")
{code}

And then myInputs could be a expression that returns a 1..n uris of endpoints, or Endpoint instances. And with the simple expression we could read the uris from a .properties file etc.
{code}
from("dynamiceip:simple:${properties.myInputs}").to("xxx")
{code}

I guess the syntax needs to be worked a bit, but then you could dynamic decide the inputs to the route from various sources, easily pluggable using the Camel expression.

                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Comment Edited] (CAMEL-5399) New component camel-dynamicep

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402097#comment-13402097 ] 

Claus Ibsen edited comment on CAMEL-5399 at 6/27/12 9:58 AM:
-------------------------------------------------------------

You can do today
{code}
from("file:test", "jms:myqueue").to("xxx")
{code}

Or stack multiple froms (maybe not so nice readable)
{code}
from("file:test").from("jms:myqueue").to("xxx")
{code}

The dynamiceip would IMHO only be interesting if it computes at route startup time (eg runtime) the incoming endpoints to the route.
{code}
from("dynamiceip:bean:myInputs").to("xxx")
{code}

And then myInputs could be a bean that returns a 1..n uris of endpoints, or Endpoint instances. 

And with the simple expression we could read the uris from a .properties file etc.
{code}
from("dynamiceip:simple:${properties.myInputs}").to("xxx")
{code}

I guess the syntax needs to be worked a bit, but then you could dynamic decide the inputs to the route from various sources, easily pluggable using the Camel expression.
                
      was (Author: davsclaus):
    You can do today
{code}
from("file:test", "jms:myqueue").to("xxx")
{code}

Or stack multiple froms (maybe not so nice readable)
{code}
from("file:test").from("jms:myqueue").to("xxx")
{code}

The dynamiceip would IMHO only be interesting if it computes at route startup time (eg runtime) the incoming endpoints to the route.
{code}
from("dynamiceip:bean:myInputs").to("xxx")
{code}

And then myInputs could be a expression that returns a 1..n uris of endpoints, or Endpoint instances. And with the simple expression we could read the uris from a .properties file etc.
{code}
from("dynamiceip:simple:${properties.myInputs}").to("xxx")
{code}

I guess the syntax needs to be worked a bit, but then you could dynamic decide the inputs to the route from various sources, easily pluggable using the Camel expression.

                  
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402114#comment-13402114 ] 

Claus Ibsen commented on CAMEL-5399:
------------------------------------

You can attach a patch or host the source on github etc if ppl wanna try it out now.
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402105#comment-13402105 ] 

Christian Schneider commented on CAMEL-5399:
--------------------------------------------

The from("..").from("..") does not work if you do not know the number of endpoints in advance. 
Building the endpoint list using an expression or bean could be a nice addition. It would allow to abstract the config from the endpoint syntax. 
So for example you could have only a list of queues in the config and a bean would create the the exact dynamicep uri. 

I think this is already possible though:
MyBean epBean = new MyBean();
from(epBean.getUri()).to("..")

So I think we do not need to implement this in the component.
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402092#comment-13402092 ] 

Christian Schneider commented on CAMEL-5399:
--------------------------------------------

Not exactly. There are some substantial differences that made me code this.

In the dynamicep component the exact same route is used while in your example there are two instances.
Using direct endpoints this could be achieved like:
rom("file:test").to("direct:test")
from("jms:myqueue").to("direct:test")
from("direct:test").to("...")

As you can use property placeholders in the uri you can have a dynamical list of endpoints to listen on:
from("dynamicep:{{listenEndpoints}}").to("...")
So this allows to listen on a list of endpoints where the number of endpoints to listen on is not known at compile time. We use this for a customer that wants to listen on a larger list of jms queues.
This behaviour is quite difficult to mimic without the new component.

                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-5399) New component camel-dynamicep

Posted by "Guillaume Nodet (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-5399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13402129#comment-13402129 ] 

Guillaume Nodet commented on CAMEL-5399:
----------------------------------------

Well, you can already pass an array of string, but you can already do that by using
{code}
  from("jms:myqueue,mms:myqueue2".split(","))
{code}
afaiu.
                
> New component camel-dynamicep
> -----------------------------
>
>                 Key: CAMEL-5399
>                 URL: https://issues.apache.org/jira/browse/CAMEL-5399
>             Project: Camel
>          Issue Type: New Feature
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>             Fix For: 3.0.0
>
>
> I have written a new camel-component that allows to listen on a dynamic list of endpoints. It works like this
> from("dynamicep:file:test,jms:myqueue")...
> So you simply supply a list of normal endpoints separated by commas. 
> Some things we need to decide are:
> - Name of the component. I am not sure if dynamicep i ideal. Any better names?
> - Syntax of the endpoint URI. I am not sure if the combinded URI is a valid URI
> I currently set the Fix version to 3.0.0 but we can easily backport this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira