none
Error on contract creation in my Application RRS feed

  • Question

  • Hello, I have a Blockchain Workbench application running and since Friday (September, 20th of 2019) we are facing an issue to create any contract. The steps are following:

    •  fill all information needed in form.
    • Click on create button.
    • Then you see a message "Contract X is being created"
    • Then other message "Working on contract  id X. It may take a few minutes"
    • And finally, another message: "This may take some time. Your administrator can use RequestId ec9c0ae4-66a9-4420-8f04-bc4737973563 to look up details in Application Insights."

    It's important to say that any changes were made and we have contracts created from Sep. 13th to Sep, 19th.

    Also, in the same workbench, we have another sample application that you created from Microsoft calles "Hello Blockchain" This application stopped to work either.

    Let me know if you need further information.

    Thank you in advance

    Wednesday, September 25, 2019 10:41 AM

All replies

  • Hi I'm sorry to hear that you are facing this issue. Have you followed these troubleshooting steps? 

    https://docs.microsoft.com/en-us/azure/blockchain/workbench/troubleshooting

    Wednesday, September 25, 2019 11:30 PM
    Moderator
  • Hello, thank you for your reply. Yes, I tried so far but I couldn't get any useful information to know what's happenning. If you see messages, it's different from when there was an error on contract creation. It seems a kind of timeout or something. Is that any contract numbers limit?

    I tried once again now, following SSH logs and it looks fine for me

    2019-09-26T08:15:05.904859820Z [08:15:05 INF] {Protocol="HTTP/1.1", Method="GET", ContentType="application/json;charset=utf-8", ContentLength=null, Scheme="http", Host="planetpmr-7hhjn6-api.azurew
    ebsites.net", PathBase="", Path="/api/v2/contracts", QueryString="?workflowId=1&sortBy=Timestamp&top=50&skip=0", EventId={Id=1}, SourceContext="Microsoft.AspNetCore.Hosting.Internal.WebHost", Requ
    estId="0HLQ067I4A20O:00000001", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Request starting HTTP/1.1 GET http://planetpmr-7hhjn6-api.azurewebsites.net/api/v2/contracts?workflow
    Id=1&sortBy=Timestamp&top=50&skip=0 application/json;charset=utf-8
    2019-09-26T08:15:05.906261535Z [08:15:05 INF] {EventId={Id=2}, SourceContext="Microsoft.AspNetCore.Authentication.JwtBearer.JwtBearerHandler", RequestId="0HLQ067I4A20O:00000001", RequestPath="/api
    /v2/contracts", ServiceName="appbuilder.api"} Successfully validated the token.
    2019-09-26T08:15:05.906767141Z [08:15:05 INF] {EventId={Id=8}, SourceContext="Microsoft.AspNetCore.Authentication.JwtBearer.JwtBearerHandler", RequestId="0HLQ067I4A20O:00000001", RequestPath="/api
    /v2/contracts", ServiceName="appbuilder.api"} AuthenticationScheme: Bearer was successfully authenticated.
    2019-09-26T08:15:05.907353048Z [08:15:05 INF] {SourceContext="data-access", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Execute
     [dbo].[GetUserByExternalId] with externalId = 29cdb28e-11e3-4e46-b71a-b789d4dd06d0
    2019-09-26T08:15:05.907776452Z [08:15:05 INF] {SourceContext="data-access", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executi
    ng sproc [dbo].[GetUserByExternalId]
    2019-09-26T08:15:05.913000510Z [08:15:05 INF] {SourceContext="data-access", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Execute
     [dbo].[GetUserChainMappings] with id = 1
    2019-09-26T08:15:05.913636717Z [08:15:05 INF] {SourceContext="data-access", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executi
    ng sproc [dbo].[GetUserChainMappings]
    2019-09-26T08:15:05.918884775Z [08:15:05 INF] {EventId={Id=4}, SourceContext="Microsoft.AspNetCore.Cors.Infrastructure.CorsService", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="
    /api/v2/contracts", ServiceName="appbuilder.api"} Policy execution successful.
    2019-09-26T08:15:05.919730784Z [08:15:05 INF] {EventId={Id=1}, SourceContext="Microsoft.AspNetCore.Authorization.DefaultAuthorizationService", ActionId="636bfd15-4e35-4b0c-81aa-a9ec68224e3a", Acti
    onName="Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.ContractsGet (Microsoft.AppBuilder.API)", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", Serv
    iceName="appbuilder.api"} Authorization was successful for user: g.francisco@medisoft.io.
    2019-09-26T08:15:05.920459592Z [08:15:05 INF] {EventId={Id=1}, SourceContext="Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker", ActionId="636bfd15-4e35-4b0c-81aa-a9ec68224e3a", RequestId
    ="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executing action method Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.Contracts
    Get (Microsoft.AppBuilder.API) with arguments (["50", "0", "1", "Timestamp"]) - ModelState is Valid
    2019-09-26T08:15:05.921060299Z [08:15:05 INF] {SourceContext="data-access", ActionId="636bfd15-4e35-4b0c-81aa-a9ec68224e3a", ActionName="Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.
    ContractsGet (Microsoft.AppBuilder.API)", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Execute [dbo].[GetContracts] with top = 5
    0, skip = 0, workflowId = 1, userId = 1, isAdmin = False, sortBy = Timestamp
    2019-09-26T08:15:05.921693306Z [08:15:05 INF] {SourceContext="data-access", ActionId="636bfd15-4e35-4b0c-81aa-a9ec68224e3a", ActionName="Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.
    ContractsGet (Microsoft.AppBuilder.API)", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executing sproc [dbo].[GetContracts]
    2019-09-26T08:15:05.946642981Z [08:15:05 INF] {EventId={Id=1}, SourceContext="Microsoft.AspNetCore.Mvc.Internal.ObjectResultExecutor", ActionId="636bfd15-4e35-4b0c-81aa-a9ec68224e3a", ActionName="
    Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.ContractsGet (Microsoft.AppBuilder.API)", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName=
    "appbuilder.api"} Executing ObjectResult, writing value Microsoft.AspNetCore.Mvc.ControllerContext.
    2019-09-26T08:15:05.948854906Z [08:15:05 INF] {EventId={Id=2}, SourceContext="Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker", ActionId="636bfd15-4e35-4b0c-81aa-a9ec68224e3a", RequestId
    ="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executed action Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.ContractsGet (Mic
    rosoft.AppBuilder.API) in 29.1442ms
    2019-09-26T08:15:05.949964918Z [08:15:05 INF] {ElapsedMilliseconds=45.3117, StatusCode=200, ContentType="application/json; charset=utf-8", EventId={Id=2}, SourceContext="Microsoft.AspNetCore.Hosti
    ng.Internal.WebHost", RequestId="5560f8c5-730a-43d1-b97f-35c78a9a428b", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Request finished in 45.3117ms 200 application/json; charset=u
    tf-8

    Thursday, September 26, 2019 8:23 AM
  • See other part of log.

    2019-09-26T08:15:05.070871110Z [08:15:05 INF] {EventId={Id=4}, SourceContext="Microsoft.AspNetCore.Cors.Infrastructure.CorsService", RequestId="5205f1ae-a399-431a-ba69-defa9eceb874", RequestPath="
    /api/v2/contracts", ServiceName="appbuilder.api"} Policy execution successful.
    2019-09-26T08:15:05.072698930Z [08:15:05 INF] {ElapsedMilliseconds=2.5743, StatusCode=204, ContentType=null, EventId={Id=2}, SourceContext="Microsoft.AspNetCore.Hosting.Internal.WebHost", RequestI
    d="5205f1ae-a399-431a-ba69-defa9eceb874", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Request finished in 2.5743ms 204
    2019-09-26T08:15:05.095440582Z [08:15:05 INF] {Protocol="HTTP/1.1", Method="POST", ContentType="application/json;charset=UTF-8", ContentLength=96, Scheme="http", Host="planetpmr-7hhjn6-api.azurewe
    bsites.net", PathBase="", Path="/api/v2/contracts", QueryString="?workflowId=1&contractCodeId=1&connectionId=1", EventId={Id=1}, SourceContext="Microsoft.AspNetCore.Hosting.Internal.WebHost", Requ
    estId="0HLQ067I4A20M:00000001", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Request starting HTTP/1.1 POST http://planetpmr-7hhjn6-api.azurewebsites.net/api/v2/contracts?workflo
    wId=1&contractCodeId=1&connectionId=1 application/json;charset=UTF-8 96
    2019-09-26T08:15:05.096541494Z [08:15:05 INF] {EventId={Id=2}, SourceContext="Microsoft.AspNetCore.Authentication.JwtBearer.JwtBearerHandler", RequestId="0HLQ067I4A20M:00000001", RequestPath="/api
    /v2/contracts", ServiceName="appbuilder.api"} Successfully validated the token.
    2019-09-26T08:15:05.097063799Z [08:15:05 INF] {EventId={Id=8}, SourceContext="Microsoft.AspNetCore.Authentication.JwtBearer.JwtBearerHandler", RequestId="0HLQ067I4A20M:00000001", RequestPath="/api
    /v2/contracts", ServiceName="appbuilder.api"} AuthenticationScheme: Bearer was successfully authenticated.
    2019-09-26T08:15:05.097605805Z [08:15:05 INF] {SourceContext="data-access", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Execute
     [dbo].[GetUserByExternalId] with externalId = 29cdb28e-11e3-4e46-b71a-b789d4dd06d0
    2019-09-26T08:15:05.098081811Z [08:15:05 INF] {SourceContext="data-access", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executi
    ng sproc [dbo].[GetUserByExternalId]
    2019-09-26T08:15:05.103629572Z [08:15:05 INF] {SourceContext="data-access", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Execute
     [dbo].[GetUserChainMappings] with id = 1
    2019-09-26T08:15:05.104217178Z [08:15:05 INF] {SourceContext="data-access", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executi
    ng sproc [dbo].[GetUserChainMappings]
    2019-09-26T08:15:05.109058232Z [08:15:05 INF] {EventId={Id=4}, SourceContext="Microsoft.AspNetCore.Cors.Infrastructure.CorsService", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="
    /api/v2/contracts", ServiceName="appbuilder.api"} Policy execution successful.
    2019-09-26T08:15:05.110085943Z [08:15:05 INF] {EventId={Id=1}, SourceContext="Microsoft.AspNetCore.Authorization.DefaultAuthorizationService", ActionId="a9dddc3a-8f6a-46f1-8c4b-cce3b24e0c90", Acti
    onName="Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.ContractPost (Microsoft.AppBuilder.API)", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", Serv
    iceName="appbuilder.api"} Authorization was successful for user: g.francisco@medisoft.io.
    2019-09-26T08:15:05.111661761Z [08:15:05 INF] {EventId={Id=1}, SourceContext="Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker", ActionId="a9dddc3a-8f6a-46f1-8c4b-cce3b24e0c90", RequestId
    ="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executing action method Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.ContractP
    ost (Microsoft.AppBuilder.API) with arguments (["class WorkflowActionInput {\n  WorkflowStateTransitionID: 1\n  WorkflowActionParameters: System.Collections.Generic.List`1[Microsoft.AppBuilder.Ser
    viceContracts.ContractActionParameter]\n}\n", "1", "1", "1"]) - ModelState is Valid
    2019-09-26T08:15:05.112338068Z [08:15:05 INF] {SourceContext="data-access", ActionId="a9dddc3a-8f6a-46f1-8c4b-cce3b24e0c90", ActionName="Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.
    ContractPost (Microsoft.AppBuilder.API)", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executing [dbo].[CreateContract]
    2019-09-26T08:15:05.112877574Z [08:15:05 INF] {SourceContext="data-access", ActionId="a9dddc3a-8f6a-46f1-8c4b-cce3b24e0c90", ActionName="Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.
    ContractPost (Microsoft.AppBuilder.API)", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executing sproc [dbo].[CreateContract]
    2019-09-26T08:15:05.254115834Z [08:15:05 INF] {EventId={Id=1}, SourceContext="Microsoft.AspNetCore.Mvc.Internal.ObjectResultExecutor", ActionId="a9dddc3a-8f6a-46f1-8c4b-cce3b24e0c90", ActionName="
    Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.ContractPost (Microsoft.AppBuilder.API)", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName=
    "appbuilder.api"} Executing ObjectResult, writing value Microsoft.AspNetCore.Mvc.ControllerContext.
    2019-09-26T08:15:05.255281347Z [08:15:05 INF] {EventId={Id=2}, SourceContext="Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker", ActionId="a9dddc3a-8f6a-46f1-8c4b-cce3b24e0c90", RequestId
    ="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Executed action Microsoft.AppBuilder.API.Controllers.ContractsV2Controller.ContractPost (Mic
    rosoft.AppBuilder.API) in 144.8923ms
    2019-09-26T08:15:05.256438959Z [08:15:05 INF] {ElapsedMilliseconds=160.7728, StatusCode=200, ContentType="application/json; charset=utf-8", EventId={Id=2}, SourceContext="Microsoft.AspNetCore.Host
    ing.Internal.WebHost", RequestId="03d14290-e19c-418e-862f-08b909a6da8d", RequestPath="/api/v2/contracts", ServiceName="appbuilder.api"} Request finished in 160.7728ms 200 application/json; charset
    =utf-8

    Thursday, September 26, 2019 8:27 AM
  • I have two api responses for two different contracts. First was created successfully a month ago. Its ID is 11

    {
        "id": 11,
        "provisioningStatus": 2,
        "timestamp": "2019-08-14T09:39:23.26",
        "connectionID": 1,
        "ledgerIdentifier": "0x57f94108be53f9966c61fff055d546a1baa9721d",
        "deployedByUserId": 1,
        "workflowId": 1,
        "requestId": "3c0e7503-ed8a-460c-98f8-5e896e1d9bd8",
        "contractCodeId": 1,
        "contractProperties": [
            {
                "workflowPropertyId": 1,
                "value": "0"
            },
            {
                "workflowPropertyId": 2,
                "value": "0x74ca86a504fc11097d58c2c231e80c54510e8269"
            },
            {
                "workflowPropertyId": 3,
                "value": "0x0000000000000000000000000000000000000000"
            },
            {
                "workflowPropertyId": 4,
                "value": "Initial Message"
            },
            {
                "workflowPropertyId": 5,
                "value": ""
            }
        ],
        "transactions": [
            {
                "id": 24,
                "connectionId": 1,
                "transactionHash": "0xe4e86bf7d84e6270a745b961dadb681a2b8efc2ed3f3d838a71a9685b332202d",
                "blockID": 1434365,
                "blockNumber": 1434454,
                "blockHash": "0xb2a59bddeda34a7b8f22ee3c1b060e7df329a7ded49585a428358bbd112fda16",
                "from": "0x74ca86a504fc11097d58c2c231e80c54510e8269",
                "to": null,
                "value": 0.00,
                "isAppBuilderTx": true
            }
        ],
        "contractActions": [
            {
                "id": 24,
                "userId": 1,
                "provisioningStatus": 2,
                "timestamp": "2019-08-14T09:39:30.82",
                "parameters": [
                    {
                        "name": "Request Message",
                        "value": "Initial Message",
                        "workflowFunctionParameterId": 3
                    }
                ],
                "workflowFunctionId": 1,
                "transactionId": 24,
                "workflowStateId": 1,
                "requestId": "3c0e7503-ed8a-460c-98f8-5e896e1d9bd8",
                "eventId": 27
            }
        ]
    }

    Second one was created today, ID 206. I hope this helps

    {
        "id": 206,
        "provisioningStatus": 1,
        "timestamp": "2019-09-26T08:24:15.7266667",
        "connectionID": 1,
        "ledgerIdentifier": "0x3bc9aaa248e07592a6322d9f4c869e29309f5a3b",
        "deployedByUserId": 1,
        "workflowId": 1,
        "requestId": "6c017ab0-3e7e-4581-9b40-74a9f7a30a66",
        "contractCodeId": 1,
        "contractProperties": [],
        "transactions": [],
        "contractActions": [
            {
                "id": 306,
                "userId": 1,
                "provisioningStatus": 1,
                "timestamp": "2019-09-26T08:24:16.4933333",
                "parameters": [
                    {
                        "name": "Request Message",
                        "value": "hey",
                        "workflowFunctionParameterId": 3
                    }
                ],
                "workflowFunctionId": 1,
                "transactionId": 306,
                "workflowStateId": null,
                "requestId": "6c017ab0-3e7e-4581-9b40-74a9f7a30a66",
                "eventId": null
            }
        ]
    }

     
    Thursday, September 26, 2019 8:32 AM
  • Hello, I updated this ticket with additional information. Did you see it?
    Monday, September 30, 2019 10:29 AM