microsoft / service-fabric

Service Fabric is a distributed systems platform for packaging, deploying, and managing stateless and stateful distributed applications and containers at large scale.
https://docs.microsoft.com/en-us/azure/service-fabric/
MIT License
3.03k stars 401 forks source link

Error: sample.exe was not found on your system. #1413

Open enagaraj89 opened 1 year ago

enagaraj89 commented 1 year ago

I have a stateless application running on Service fabric. It uses an executable sample.exe to process some files. The exe properties are set to Content & Copy Always. I am able to run the application and use the sample.exe from build location to process files. But, when I deploy the same application to Azure 5 node cluster I am getting "sample.exe is not found on your system" error. When I look at the build location ono 5 nodes, sample.exe exists.

I tried to access sample.exe using Path.Combine(Directory.GetCurrentDirectory(), "sample.exe") and Path.Combine(FabricRuntime.GetActivationContext().GetCodePackageObject("Code").Path, "sample.exe")

Both codes works fine in local dev environment & On-Prem single node servers but fails in Azure 5 node servers.

Can someone help me to resolve this issue?

**Service Fabric Version: 9.1.1390.9590

**Guest OS version: Windows 10

**Hosted on Azure or On-Prem: Azure

sunil-indoria commented 1 year ago

Could you please check if sample.exe is part of package which is being pushed to azure ?