You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2010/04/05 12:07:08 UTC

[jira] Created: (CAMEL-2613) CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging

CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging
-------------------------------------------------------------------------------------------

                 Key: CAMEL-2613
                 URL: https://issues.apache.org/activemq/browse/CAMEL-2613
             Project: Apache Camel
          Issue Type: Improvement
          Components: camel-core
            Reporter: Claus Ibsen
            Assignee: Claus Ibsen
            Priority: Minor
             Fix For: 2.3.0


By default Camel Proxy is always {{InOut}} unless you set some specific @Pattern annotation such as @InOnly.

We should add an option to <camelProxy> so you can let {{void}} methods be {{InOnly}} and the others {{InOut}}.

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


[jira] Resolved: (CAMEL-2613) CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging

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

Claus Ibsen resolved CAMEL-2613.
--------------------------------

    Resolution: Won't Fix

trunk: 931612.

> CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging
> -------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-2613
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-2613
>             Project: Apache Camel
>          Issue Type: Improvement
>          Components: camel-core
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.3.0
>
>
> By default Camel Proxy is always {{InOut}} unless you set some specific @Pattern annotation such as @InOnly.
> We should add an option to <camelProxy> so you can let {{void}} methods be {{InOnly}} and the others {{InOut}}.

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


[jira] Commented: (CAMEL-2613) CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging

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

Claus Ibsen commented on CAMEL-2613:
------------------------------------

{code}
davsclaus:(svn)camel[trunk:931578]/$ svn merge -c -930866 .
--- Reverse-merging r930866 into '.':
D    components/camel-spring/src/test/java/org/apache/camel/spring/config/CamelProxyVoidAsInOnlyTest.java
D    components/camel-spring/src/test/java/org/apache/camel/spring/config/CamelProxyVoidAsInOutTest.java
D    components/camel-spring/src/test/java/org/apache/camel/spring/config/MyOtherProxySender.java
D    components/camel-spring/src/test/resources/org/apache/camel/spring/config/CamelProxyVoidAsInOnlyTest.xml
D    components/camel-spring/src/test/resources/org/apache/camel/spring/config/CamelProxyVoidAsInOutTest.xml
U    components/camel-spring/src/main/java/org/apache/camel/spring/remoting/CamelProxyFactoryBean.java
U    components/camel-spring/src/main/java/org/apache/camel/spring/CamelProxyFactoryDefinition.java
U    camel-core/src/test/java/org/apache/camel/component/bean/BeanProxyTest.java
D    camel-core/src/main/java/org/apache/camel/builder/ProxyBuilder.java
U    camel-core/src/main/java/org/apache/camel/component/bean/MethodInfoCache.java
U    camel-core/src/main/java/org/apache/camel/component/bean/BeanInfo.java
U    camel-core/src/main/java/org/apache/camel/component/bean/ProxyHelper.java
U    camel-core/src/main/java/org/apache/camel/component/bean/MethodInfo.java
{code}

I will keep the {{ProxyBuilder}} as it makes creating proxy's from Java DSL a bit easier.

> CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging
> -------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-2613
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-2613
>             Project: Apache Camel
>          Issue Type: Improvement
>          Components: camel-core
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.3.0
>
>
> By default Camel Proxy is always {{InOut}} unless you set some specific @Pattern annotation such as @InOnly.
> We should add an option to <camelProxy> so you can let {{void}} methods be {{InOnly}} and the others {{InOut}}.

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


[jira] Commented: (CAMEL-2613) CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging

Posted by "James Strachan (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-2613?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=58676#action_58676 ] 

James Strachan commented on CAMEL-2613:
---------------------------------------

my worry is really folks losing exceptions without really knowing about it.

Certainly we should only support this for void methods with no checked exceptions. Though if the method is invoking lots of spring stuff, which tends to use runtime exceptions (or scala code which does the same) - its very easy to lose exceptions.

We need to make a massive error message if a runtime exception is thrown and the method is invoked async so folks are really aware.

So long as the default is to only do async when @InOnly is there, I'm happy. Having an option to override this (for example when using legacy code) is fine, so long as users understand the big risk they are taking 

> CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging
> -------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-2613
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-2613
>             Project: Apache Camel
>          Issue Type: Improvement
>          Components: camel-core
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.3.0
>
>
> By default Camel Proxy is always {{InOut}} unless you set some specific @Pattern annotation such as @InOnly.
> We should add an option to <camelProxy> so you can let {{void}} methods be {{InOnly}} and the others {{InOut}}.

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


[jira] Resolved: (CAMEL-2613) CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging

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

Claus Ibsen resolved CAMEL-2613.
--------------------------------

    Resolution: Fixed

trunk: 930866.

> CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging
> -------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-2613
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-2613
>             Project: Apache Camel
>          Issue Type: Improvement
>          Components: camel-core
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.3.0
>
>
> By default Camel Proxy is always {{InOut}} unless you set some specific @Pattern annotation such as @InOnly.
> We should add an option to <camelProxy> so you can let {{void}} methods be {{InOnly}} and the others {{InOut}}.

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


[jira] Reopened: (CAMEL-2613) CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging

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

Claus Ibsen reopened CAMEL-2613:
--------------------------------


Yeah the hidden of runtime exception might take people by surprise. Well its not hidden but the method invoked does not throw any exception.

So lets -1 and have people force to use @InOnly to force the fire and forget mode.

> CamelProxy - Add option to treat void methods as InOnly for fire and forget style messaging
> -------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-2613
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-2613
>             Project: Apache Camel
>          Issue Type: Improvement
>          Components: camel-core
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.3.0
>
>
> By default Camel Proxy is always {{InOut}} unless you set some specific @Pattern annotation such as @InOnly.
> We should add an option to <camelProxy> so you can let {{void}} methods be {{InOnly}} and the others {{InOut}}.

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