Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-39721

AWSEBDeployment Plugin Null Pointer Exception

      Its possible to create an AWS EB Application with no version.
      I do this via terraform because I'm basically creating a skeleton.
      Once the environment is up (and red) i use Jenkins to deploy to it via the AWSEB plugin

      If there is no version deployed, it errors with a Null pointer exception.

      Turns out there's already a PR at https://github.com/ingenieux/awseb-deployment-plugin/pull/45

      Started by user stratabot
      [EnvInject] - Loading node environment variables.
      Building remotely on Jenkins Slave (OPS) (i-0085c914aef60b3a1) (jenkins_ops_slave) in workspace /home/ubuntu/workspace/Deploy Beanstalk
      Cloning the remote Git repository
      Cloning repository git@github.com:redact/redact.git
       > git init /home/ubuntu/workspace/Deploy Beanstalk # timeout=10
      Fetching upstream changes from git@github.com:redact/redact.git
       > git --version # timeout=10
       > git fetch --tags --progress git@github.com:redact/redact.git +refs/heads/*:refs/remotes/origin/*
       > git config remote.origin.url git@github.com:redact/redact.git # timeout=10
       > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
       > git config remote.origin.url git@github.com:redact/redact.git # timeout=10
      Fetching upstream changes from git@github.com:redact/redact.git
       > git fetch --tags --progress git@github.com:redact/redact.git +refs/heads/*:refs/remotes/origin/*
      Seen branch in repository origin/master
      Seen 1 remote branches
      Checking out Revision 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c (origin/master)
       > git config core.sparsecheckout # timeout=10
       > git checkout -f 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c
       > git rev-list 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c # timeout=10
       > git tag -a -f -m Jenkins Build #25 jenkins-Deploy_Beanstalk-25 # timeout=10
      [Deploy Beanstalk] $ /bin/bash -x /tmp/hudson3795559793539651526.sh
      ++ git rev-parse --short HEAD
      + echo GIT_SHORT_HASH=8eb5aa5
      ++ date -u +%Y-%m-%dT%H:%M:%SZ
      + echo DEPLOY_TIME=2016-11-14T16:15:08Z
      [EnvInject] - Injecting environment variables from a build step.
      [EnvInject] - Injecting as environment variables the properties file path 'env.props'
      [EnvInject] - Variables injected successfully.
      AWSEB Deployment Plugin Version 0.3.10
      Zipping contents of Root File Object (Deploy Beanstalk) into tmp file awseb-8318042900571940160.zip (includes=, excludes=)
      Uploading file awseb-8318042900571940160.zip as s3://elasticbeanstalk-us-east-1-redact/redact/redact-8eb5aa5-2016-11-14T16:15:08Z.zip
      Creating application version 8eb5aa5-2016-11-14T16:15:08Z for application redact for path s3://elasticbeanstalk-us-east-1-redact/redact/redact-8eb5aa5-2016-11-14T16:15:08Z.zip
      Created version: 8eb5aa5-2016-11-14T16:15:08Z
      Cleaning up temporary file /tmp/awseb-8318042900571940160.zip
      FATAL: Deployment Failure
      java.io.IOException: Deployment Failure
      	at br.com.ingenieux.jenkins.plugins.awsebdeployment.AWSEBDeploymentBuilder.perform(AWSEBDeploymentBuilder.java:171)
      	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)
      	at hudson.model.Build$BuildExecution.build(Build.java:205)
      	at hudson.model.Build$BuildExecution.doRun(Build.java:162)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534)
      	at hudson.model.Run.execute(Run.java:1741)
      	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      	at hudson.model.ResourceController.execute(ResourceController.java:98)
      	at hudson.model.Executor.run(Executor.java:410)
      Caused by: java.util.concurrent.ExecutionException: java.lang.NullPointerException
      	at hudson.remoting.Channel$2.adapt(Channel.java:813)
      	at hudson.remoting.Channel$2.adapt(Channel.java:808)
      	at hudson.remoting.FutureAdapter.get(FutureAdapter.java:55)
      	at br.com.ingenieux.jenkins.plugins.awsebdeployment.DeployerRunner.perform(DeployerRunner.java:66)
      	at br.com.ingenieux.jenkins.plugins.awsebdeployment.AWSEBDeploymentBuilder.perform(AWSEBDeploymentBuilder.java:167)
      	... 9 more
      Caused by: java.lang.NullPointerException
      	at br.com.ingenieux.jenkins.plugins.awsebdeployment.cmd.DeployerCommand$LookupEnvironmentId.perform(DeployerCommand.java:196)
      	at br.com.ingenieux.jenkins.plugins.awsebdeployment.cmd.DeployerChain.perform(DeployerChain.java:54)
      	at br.com.ingenieux.jenkins.plugins.awsebdeployment.SlaveDeployerCallable.call(SlaveDeployerCallable.java:42)
      	at br.com.ingenieux.jenkins.plugins.awsebdeployment.SlaveDeployerCallable.call(SlaveDeployerCallable.java:27)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:153)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:50)
      	at hudson.remoting.Request$2.run(Request.java:332)
      	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      	at java.lang.Thread.run(Thread.java:745)
      	at ......remote call to Jenkins Slave (OPS) (i-0085c914aef60b3a1)(Native Method)
      	at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1416)
      	at hudson.remoting.UserResponse.retrieve(UserRequest.java:253)
      	at hudson.remoting.Channel$2.adapt(Channel.java:811)
      	... 13 more
      Finished: FAILURE
      

          [JENKINS-39721] AWSEBDeployment Plugin Null Pointer Exception

          marc young created issue -
          marc young made changes -
          Description Original: Its possible to create an AWS EB Application with no version.
          I do this via terraform because I'm basically creating a skeleton.
          Once the environment is up (and red) i use Jenkins to deploy to it via the AWSEB plugin

          If there is no version deployed, it errors with a Null pointer exception.


          {code:java}
          Started by user stratabot
          [EnvInject] - Loading node environment variables.
          Building remotely on Jenkins Slave (OPS) (i-0085c914aef60b3a1) (jenkins_ops_slave) in workspace /home/ubuntu/workspace/Deploy Beanstalk
          Cloning the remote Git repository
          Cloning repository git@github.com:redact/redact.git
           > git init /home/ubuntu/workspace/Deploy Beanstalk # timeout=10
          Fetching upstream changes from git@github.com:redact/redact.git
           > git --version # timeout=10
           > git fetch --tags --progress git@github.com:redact/redact.git +refs/heads/*:refs/remotes/origin/*
           > git config remote.origin.url git@github.com:redact/redact.git # timeout=10
           > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
           > git config remote.origin.url git@github.com:redact/redact.git # timeout=10
          Fetching upstream changes from git@github.com:redact/redact.git
           > git fetch --tags --progress git@github.com:redact/redact.git +refs/heads/*:refs/remotes/origin/*
          Seen branch in repository origin/master
          Seen 1 remote branches
          Checking out Revision 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c (origin/master)
           > git config core.sparsecheckout # timeout=10
           > git checkout -f 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c
           > git rev-list 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c # timeout=10
           > git tag -a -f -m Jenkins Build #25 jenkins-Deploy_Beanstalk-25 # timeout=10
          [Deploy Beanstalk] $ /bin/bash -x /tmp/hudson3795559793539651526.sh
          ++ git rev-parse --short HEAD
          + echo GIT_SHORT_HASH=8eb5aa5
          ++ date -u +%Y-%m-%dT%H:%M:%SZ
          + echo DEPLOY_TIME=2016-11-14T16:15:08Z
          [EnvInject] - Injecting environment variables from a build step.
          [EnvInject] - Injecting as environment variables the properties file path 'env.props'
          [EnvInject] - Variables injected successfully.
          AWSEB Deployment Plugin Version 0.3.10
          Zipping contents of Root File Object (Deploy Beanstalk) into tmp file awseb-8318042900571940160.zip (includes=, excludes=)
          Uploading file awseb-8318042900571940160.zip as s3://elasticbeanstalk-us-east-1-redact/redact/redact-8eb5aa5-2016-11-14T16:15:08Z.zip
          Creating application version 8eb5aa5-2016-11-14T16:15:08Z for application redact for path s3://elasticbeanstalk-us-east-1-redact/redact/redact-8eb5aa5-2016-11-14T16:15:08Z.zip
          Created version: 8eb5aa5-2016-11-14T16:15:08Z
          Cleaning up temporary file /tmp/awseb-8318042900571940160.zip
          FATAL: Deployment Failure
          java.io.IOException: Deployment Failure
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.AWSEBDeploymentBuilder.perform(AWSEBDeploymentBuilder.java:171)
          at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
          at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)
          at hudson.model.Build$BuildExecution.build(Build.java:205)
          at hudson.model.Build$BuildExecution.doRun(Build.java:162)
          at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534)
          at hudson.model.Run.execute(Run.java:1741)
          at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
          at hudson.model.ResourceController.execute(ResourceController.java:98)
          at hudson.model.Executor.run(Executor.java:410)
          Caused by: java.util.concurrent.ExecutionException: java.lang.NullPointerException
          at hudson.remoting.Channel$2.adapt(Channel.java:813)
          at hudson.remoting.Channel$2.adapt(Channel.java:808)
          at hudson.remoting.FutureAdapter.get(FutureAdapter.java:55)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.DeployerRunner.perform(DeployerRunner.java:66)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.AWSEBDeploymentBuilder.perform(AWSEBDeploymentBuilder.java:167)
          ... 9 more
          Caused by: java.lang.NullPointerException
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.cmd.DeployerCommand$LookupEnvironmentId.perform(DeployerCommand.java:196)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.cmd.DeployerChain.perform(DeployerChain.java:54)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.SlaveDeployerCallable.call(SlaveDeployerCallable.java:42)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.SlaveDeployerCallable.call(SlaveDeployerCallable.java:27)
          at hudson.remoting.UserRequest.perform(UserRequest.java:153)
          at hudson.remoting.UserRequest.perform(UserRequest.java:50)
          at hudson.remoting.Request$2.run(Request.java:332)
          at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
          at java.util.concurrent.FutureTask.run(FutureTask.java:262)
          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
          at java.lang.Thread.run(Thread.java:745)
          at ......remote call to Jenkins Slave (OPS) (i-0085c914aef60b3a1)(Native Method)
          at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1416)
          at hudson.remoting.UserResponse.retrieve(UserRequest.java:253)
          at hudson.remoting.Channel$2.adapt(Channel.java:811)
          ... 13 more
          Finished: FAILURE
          {code}
          New: Its possible to create an AWS EB Application with no version.
          I do this via terraform because I'm basically creating a skeleton.
          Once the environment is up (and red) i use Jenkins to deploy to it via the AWSEB plugin

          If there is no version deployed, it errors with a Null pointer exception.

          Turns out there's already a PR at https://github.com/ingenieux/awseb-deployment-plugin/pull/45


          {code:java}
          Started by user stratabot
          [EnvInject] - Loading node environment variables.
          Building remotely on Jenkins Slave (OPS) (i-0085c914aef60b3a1) (jenkins_ops_slave) in workspace /home/ubuntu/workspace/Deploy Beanstalk
          Cloning the remote Git repository
          Cloning repository git@github.com:redact/redact.git
           > git init /home/ubuntu/workspace/Deploy Beanstalk # timeout=10
          Fetching upstream changes from git@github.com:redact/redact.git
           > git --version # timeout=10
           > git fetch --tags --progress git@github.com:redact/redact.git +refs/heads/*:refs/remotes/origin/*
           > git config remote.origin.url git@github.com:redact/redact.git # timeout=10
           > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
           > git config remote.origin.url git@github.com:redact/redact.git # timeout=10
          Fetching upstream changes from git@github.com:redact/redact.git
           > git fetch --tags --progress git@github.com:redact/redact.git +refs/heads/*:refs/remotes/origin/*
          Seen branch in repository origin/master
          Seen 1 remote branches
          Checking out Revision 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c (origin/master)
           > git config core.sparsecheckout # timeout=10
           > git checkout -f 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c
           > git rev-list 8eb5aa5a7620f0ec70cdacb646cf1e21d35ebc4c # timeout=10
           > git tag -a -f -m Jenkins Build #25 jenkins-Deploy_Beanstalk-25 # timeout=10
          [Deploy Beanstalk] $ /bin/bash -x /tmp/hudson3795559793539651526.sh
          ++ git rev-parse --short HEAD
          + echo GIT_SHORT_HASH=8eb5aa5
          ++ date -u +%Y-%m-%dT%H:%M:%SZ
          + echo DEPLOY_TIME=2016-11-14T16:15:08Z
          [EnvInject] - Injecting environment variables from a build step.
          [EnvInject] - Injecting as environment variables the properties file path 'env.props'
          [EnvInject] - Variables injected successfully.
          AWSEB Deployment Plugin Version 0.3.10
          Zipping contents of Root File Object (Deploy Beanstalk) into tmp file awseb-8318042900571940160.zip (includes=, excludes=)
          Uploading file awseb-8318042900571940160.zip as s3://elasticbeanstalk-us-east-1-redact/redact/redact-8eb5aa5-2016-11-14T16:15:08Z.zip
          Creating application version 8eb5aa5-2016-11-14T16:15:08Z for application redact for path s3://elasticbeanstalk-us-east-1-redact/redact/redact-8eb5aa5-2016-11-14T16:15:08Z.zip
          Created version: 8eb5aa5-2016-11-14T16:15:08Z
          Cleaning up temporary file /tmp/awseb-8318042900571940160.zip
          FATAL: Deployment Failure
          java.io.IOException: Deployment Failure
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.AWSEBDeploymentBuilder.perform(AWSEBDeploymentBuilder.java:171)
          at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
          at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)
          at hudson.model.Build$BuildExecution.build(Build.java:205)
          at hudson.model.Build$BuildExecution.doRun(Build.java:162)
          at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534)
          at hudson.model.Run.execute(Run.java:1741)
          at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
          at hudson.model.ResourceController.execute(ResourceController.java:98)
          at hudson.model.Executor.run(Executor.java:410)
          Caused by: java.util.concurrent.ExecutionException: java.lang.NullPointerException
          at hudson.remoting.Channel$2.adapt(Channel.java:813)
          at hudson.remoting.Channel$2.adapt(Channel.java:808)
          at hudson.remoting.FutureAdapter.get(FutureAdapter.java:55)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.DeployerRunner.perform(DeployerRunner.java:66)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.AWSEBDeploymentBuilder.perform(AWSEBDeploymentBuilder.java:167)
          ... 9 more
          Caused by: java.lang.NullPointerException
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.cmd.DeployerCommand$LookupEnvironmentId.perform(DeployerCommand.java:196)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.cmd.DeployerChain.perform(DeployerChain.java:54)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.SlaveDeployerCallable.call(SlaveDeployerCallable.java:42)
          at br.com.ingenieux.jenkins.plugins.awsebdeployment.SlaveDeployerCallable.call(SlaveDeployerCallable.java:27)
          at hudson.remoting.UserRequest.perform(UserRequest.java:153)
          at hudson.remoting.UserRequest.perform(UserRequest.java:50)
          at hudson.remoting.Request$2.run(Request.java:332)
          at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
          at java.util.concurrent.FutureTask.run(FutureTask.java:262)
          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
          at java.lang.Thread.run(Thread.java:745)
          at ......remote call to Jenkins Slave (OPS) (i-0085c914aef60b3a1)(Native Method)
          at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1416)
          at hudson.remoting.UserResponse.retrieve(UserRequest.java:253)
          at hudson.remoting.Channel$2.adapt(Channel.java:811)
          ... 13 more
          Finished: FAILURE
          {code}

            Unassigned Unassigned
            myoung34 marc young
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: