locked
LabDefaultTemplate.11.xaml workflow finished successfully however error in deployment script RRS feed

  • Question

  • Hi,

    I created new build definition based on LabDefaultTemplate.11.xaml.  Build works fine and deploys package. I use standard environment.

    Problem is that in case on any issue during  deployment , error is visible in  build summary but  status of build is still successful.

    What do I need to change in  build definition to  catch results from  deployment and based on that result  update  build status to Error?

    Thanks,
    marek



    Tuesday, August 27, 2013 12:52 PM

Answers

  • Hi Marek, 

    Thanks for your post.

    You can share your detailed build log here.

    As far as I know there’s no this default setting in build definition(use LabDefaultTemplate.11.xaml) to fail build if deploy not run successfully. I think you need to custom default LabDefaultTemplate.11.xaml template: in Deploy Build on Environment activity, add the Assign activity to set BuildStatus = Microsoft.TeamFoundation.Build.Client.BuildStatus.Failed under Catches section. If there’s exception during run Deploying Build activity, it will catch this exception and run that Assign activity to set BuildStatus = Microsoft.TeamFoundation.Build.Client.BuildStatus.Failed. Like fail build on test failure. 


    John Qiao [MSFT]
    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, August 28, 2013 12:03 PM
    Moderator

All replies

  • Hi Marek, 

    Thanks for your post.

    You can share your detailed build log here.

    As far as I know there’s no this default setting in build definition(use LabDefaultTemplate.11.xaml) to fail build if deploy not run successfully. I think you need to custom default LabDefaultTemplate.11.xaml template: in Deploy Build on Environment activity, add the Assign activity to set BuildStatus = Microsoft.TeamFoundation.Build.Client.BuildStatus.Failed under Catches section. If there’s exception during run Deploying Build activity, it will catch this exception and run that Assign activity to set BuildStatus = Microsoft.TeamFoundation.Build.Client.BuildStatus.Failed. Like fail build on test failure. 


    John Qiao [MSFT]
    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, August 28, 2013 12:03 PM
    Moderator
  • Hi Marek, 

    If misunderstood anything, please describe your question in more detail and we will try to provide the better responses.


    John Qiao [MSFT]
    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Monday, September 2, 2013 9:31 AM
    Moderator