XT-i / aws-lambda-jenkins-plugin

Jenkins plugin for AWS Lambda deployment
MIT License
39 stars 41 forks source link

PublishConfig is not serializable #64

Closed rostskadat closed 7 years ago

rostskadat commented 7 years ago

Hi,

I have job a that has 2 build steps:

  1. "Copy artifacts from another project"
  2. "AWS Lambda publish new version and update alias"

When launching the job, the second step fails with the following error:

java.io.NotSerializableException: com.xti.jenkins.plugin.awslambda.publish.PublishConfig
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1184)
    at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1548)
    at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1509)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1432)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1178)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:348)
    at hudson.remoting.UserRequest._serialize(UserRequest.java:190)
    at hudson.remoting.UserRequest.serialize(UserRequest.java:199)
Caused: java.io.IOException: Unable to serialize com.xti.jenkins.plugin.awslambda.callable.PublishCallable@15383af4
    at hudson.remoting.UserRequest.serialize(UserRequest.java:201)
    at hudson.remoting.UserRequest.<init>(UserRequest.java:64)
    at hudson.remoting.Channel.call(Channel.java:828)
    at com.xti.jenkins.plugin.awslambda.publish.LambdaPublishBuildStep.perform(LambdaPublishBuildStep.java:57)
Caused: java.lang.RuntimeException
    at com.xti.jenkins.plugin.awslambda.publish.LambdaPublishBuildStep.perform(LambdaPublishBuildStep.java:65)
    at com.xti.jenkins.plugin.awslambda.publish.LambdaPublishBuildStep.perform(LambdaPublishBuildStep.java:45)

It seems that the POJO com.xti.jenkins.plugin.awslambda.publish.PublishConfig does not implements Serializable.

I'm using the version 0.5.8 of the plugin (with Jenkins 2.47)

/Julien

cast commented 7 years ago

Hi @rostskadat, thank you for the bug report and pull request.

Release 0.5.9 is on the way and should arrive in your update center tomorrow.

venketraman commented 7 years ago

We are using 0.5.10 and I am getting similar error from LambdaPublishServiceResponse. I have created new issue.

Thanks,