Announcement Announcement Module
Collapse
No announcement yet.
Gmail IDLE broken: imap-idle-channel-adapter Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Gmail IDLE broken: imap-idle-channel-adapter

    the imap-idle-channel-adapter only seems to receive push messages for the first 10 minutes, after which the connection remains open but no further mail messages are received.

    the idle connection handler seems to be doing its job, sending 'NOOP' commands to the open session every 10 seconds and receiving an 'OK' reply, but the IDLE command is never re-issued and i suspect this may be the cause of the issue.

    can anyone else verify this issue before i log a bug?

    addendum: my internet just dropped out momentarily causing my imap-idle-channel-adapter to reconnect, upon reconnection i received all the email messages that should have been pushed through earlier. so it seems the imap-idle-channel-adapter will need to be modified to actually _reconnect_ to google periodically - just keeping the existing IDLE connection alive with NOOP commands doesnt seem to cut it.

    Spring Integration 2.2.3
    JavaMail 1.4.3 and also 1.4.7

    Code:
    <int-mail:imap-idle-channel-adapter
    		id="customAdapter" 
    		store-uri="imaps://${imap.Account}:${imap.AccountPassword}@imap.gmail.com:993/inbox"
    		channel="incomingEmail" 
    		auto-startup="true" 
    		should-delete-messages="false"
    		should-mark-messages-as-read="true" 
    		java-mail-properties="javaMailProperties" />
    
    	<util:properties id="javaMailProperties">
    		<prop key="mail.debug">true</prop>
    		<prop key="mail.store.protocol">imaps</prop>
    		<prop key="mail.imaps.socketFactory.class">javax.net.ssl.SSLSocketFactory</prop>
    		<prop key="mail.imaps.socketFactory.fallback">false</prop>
    		<prop key="mail.imaps.connectiontimeout">5000</prop>
    		<prop key="mail.imaps.timeout">300000</prop>
    	</util:properties>
    Last edited by abonstu; Jun 3rd, 2013, 12:51 AM.

  • #2
    Hi!

    I can't reproduce it.
    I've copied your config, set my credentials and it worked after 10 min and even after 30 min.
    Maybe it's problem of your network...

    Sorry,
    Artem

    Comment


    • #3
      wow... okay - thats great.

      just to confirm: you actually were still receiving push _email_ after 30mins? it wasnt just an open IDLE connection??

      it seems strange though... my debug output doesnt really seem to imply a connection issue, i.e. it reliably sends the NOOP command and receives the OK reply every 10 seconds.

      thanks for confirming - i'll give it a go from a different server.

      Comment

      Working...
      X