After performing a fairly obtrusive refactor (renaming projects, moving service etc) - I'm finding that the appropriate configuration in the ServiceManifest.xml and ApplicationManifest.xml are not being generated for both Stateless and Stateful services.
Steps to repro:
- Right click on an existing service fabric application project (.sfproj)
- Add > New Service Fabric Service...
- Select Stateless Service
Have a look in ServiceManifest.xml and you will see this:
<!-- Code package is your service executable. --> <CodePackage Name="Code" Version="1.0.0"> <EntryPoint> <ExeHost> <Program>Stateless1.exe</Program> </ExeHost> </EntryPoint> </CodePackage> <!-- Config package is the contents of the Config directoy under PackageRoot that contains an independently-updateable and versioned set of custom configuration settings for your service. --> <ConfigPackage Name="Config" Version="1.0.0" /> <Resources> <Endpoints> <!-- This endpoint is used by the communication listener to obtain the port on which to listen. Please note that if your service is partitioned, this port is shared with replicas of different partitions that are placed in your code. --> <Endpoint Name="ServiceEndpoint" /> </Endpoints> </Resources>
Now delete the ServiceManifest.xml
- Re-build
I'm expecting the ServiceManifest.xml to be recreated on build. If you perform the above steps for StatefulService you get the same result. However, if you do this for an ActorService - the ServiceManifest.xml will be regenerated perfectly fine.
If the StatelessService is not defined in the ServiceManifest and ApplicationManifest the service will not be deployed.
This seems like it maybe a bug, has anyone encountered this and have a solution?