activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Filip Hanik (JIRA)" <j...@apache.org>
Subject [jira] Commented: (AMQ-1860) soTimeout transport property- Incorrect documentation (or code, you pick)
Date Tue, 05 Aug 2008 04:03:52 GMT

    [ https://issues.apache.org/activemq/browse/AMQ-1860?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=44723#action_44723
] 

Filip Hanik commented on AMQ-1860:
----------------------------------

Looks like the problems go further than just the documentation being incorrect. On the server,
it the soTimeout setting wont take into effect unless you use transport.soTimeout property.
However, trying to apply this setting to a client URL, the system bombs out
Caused by: java.lang.IllegalArgumentException: Invalid connect parameters: {transport.soTimeout=180000}
    at org.apache.activemq.transport.TransportFactory.doConnect(TransportFactory.java:133)
    at org.apache.activemq.transport.TransportFactory.doConnect(TransportFactory.java:47)
    at org.apache.activemq.transport.TransportFactory.connect(TransportFactory.java:76)
    at org.apache.activemq.ActiveMQConnectionFactory.createTransport(ActiveMQConnectionFactory.java:235)

then it would probably be better to just allow the property soTimeout, but it looks like the
entire socket property settings need to have a look over, since there is no consistent way
of setting these properties. And because the soTimeout property is not set, the whoe server
locks up if there is a client that is deciding to stop receiving data.



> soTimeout transport property- Incorrect documentation (or code, you pick)
> -------------------------------------------------------------------------
>
>                 Key: AMQ-1860
>                 URL: https://issues.apache.org/activemq/browse/AMQ-1860
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker, Documentation
>    Affects Versions: 5.0.0, 5.1.0
>         Environment: All
>            Reporter: Filip Hanik
>            Assignee: Rob Davies
>         Attachments: transport-options.patch
>
>
> The documentation for TCP transport, shows soTimeout, connectionTimeout and socketBufferSize
as properties without a prefix.
> The code in TcpTransportServer.java doesn't have the support for these properties.
> hence setting a URL to tcp://192.168.3.3:61616?soTimeout=180000 does nothing, and defaults
to soTimeout=0 (which is a bad value due to how sockets get closed, and can cause the system
to hang on  a socketWrite call, causing the rest of the server to hang, but I can explain
that on the dev lists for those interested)
> Bug description: Transport properties are incorrectly document or implemented
> There are two solutions to this bug:
> 1. The preferred, would be to fix the documentation
> http://activemq.apache.org/tcp-transport-reference.html
> the mentioned options will work if they are prefixed with "transport."
> so the URL would be 
> tcp://192.168.3.3:61616?transport.soTimeout=180000
> 2. Add the properties with their getters/setters into TcpTransportServer.java and then
during the handleSocket method add them to the options map
> Please note, this bug refers to the soTimeout setting on the socket that gets created
on the server when a producer/consumer connects in using TCP
> best
> Filip

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


Mime
View raw message