boly38
boly38

Reputation: 1955

Service fabric deploy deprecated files from previous deployment

When redeploying an application on service fabric (using Publish-UpgradedServiceFabricApplication), why do I always see the files from previous deployment ? Some file of my application seems not deleted properly or cached somewhere.

For example

Result in target _VM "SF/_App" data directory:

Upvotes: 1

Views: 206

Answers (1)

boly38
boly38

Reputation: 1955

Inside ApplicationManifest.xml of my application I had "1.8-SNAPSHOT" as ApplicationTypeVersion attribute value.

So I encounter the issue when updating and redeploying this SNAPSHOT version multiples times.

Seems like in this usecase - as ApplicationTypeVersion is unchanged - SF overrides or append the deployment bundle content of the previous deployment instead of recreating a new one from scratch (for me it's an issue).

To fix it, I add build timestamp to ApplicationTypeVersion value (ex. 1.8-SNAPSHOT-20160128_1113) . This case, there is no more ServiceFabric cache effect. The version and deployment content is updated for each deployment.

Upvotes: 1

Related Questions