4

I am using javapns with Google App Engine. Everything was working fine until this morning. Now, it raises this exception:

java.lang.NoSuchMethodError: sun.security.ssl.SSLSocketImpl.receivedChangeCipherSpec()Z
    at sun.security.ssl.Handshaker.receivedChangeCipherSpec(Handshaker.java:356)
    at sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:347)
    at sun.security.ssl.Handshaker.processLoop(Handshaker.java:901)
    at sun.security.ssl.Handshaker.process_record(Handshaker.java:837)
    at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1026)
    at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1324)
    at sun.security.ssl.SSLSocketImpl.writeRecord(SSLSocketImpl.java:712)
    at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:122)
    at java.io.OutputStream.write(OutputStream.java:75)
    at javapns.notification.PushNotificationManager.sendNotification(PushNotificationManager.java:402)
    at javapns.notification.PushNotificationManager.sendNotification(PushNotificationManager.java:350)
    at javapns.notification.PushNotificationManager.sendNotification(PushNotificationManager.java:320)
    at javapns.Push.sendPayload(Push.java:177)
    at javapns.Push.payload(Push.java:149)

Any idea? I have seen the missing method in JDK7u but I think I am using JDK7. Not sure if this is related.

Montaner
  • 522
  • 5
  • 16

2 Answers2

1

I contacted Google Support regarding this issue and got the following response:

This is a known issue that is already resolved.

They did not disclosure the root cause.

Kirill Lebedev
  • 650
  • 4
  • 9
0

I was trying to use the BigTable client and ran into the same issue. It's due to the Google API using HTTP2 with TLS. The ALPN library used to support TLS modifies the bytecode on boot up and is tightly coupled with the version of the JRE/JDK you are running. Check the "Versions" table at http://www.eclipse.org/jetty/documentation/current/alpn-chapter.html to match the specific version of ALPN to your JRE and you should be good.

manolama
  • 1
  • 1