Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3457124
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T09:49:20+00:00 2026-05-18T09:49:20+00:00

I am writing some code to update an application by fetching new dlls from

  • 0

I am writing some code to update an application by fetching new dlls from an ftp site, according to a manifest file, also at the ftp site, which specifies the versions of each dll. The basic idea is, that an updater program runs at startup, which checks the manifest at the ftp site, downloads any dll’s which are newer than those currently used by the application, and then starts the application and shuts itself down.

This leads to the following problem, that I am not sure of the best way to handle: Say that I want to put a new dll on the ftp site, but at the same time an updater application instance tries to read that dll. If I delete the dll, and then copy over the new one, the updater might not see the file, even though the manifest says that it should be there.

I have the idea of a sort of marker file, that will act as a synchronization object, and whose existence I and the updater instance can use as a lock, but is that not just moving the problem? There is still the time between checking if the lock is there, and making the lock, in which someone else could make the lock, and start modifying the ftp files. Plus, if some updater crashes before deleting the marker, there is no way of telling, whether the leftover marker should be deleted.

Edit: I also saw a suggestion to upload the files to another folder, and then rename the folder, since renames are supposed to be an atomic operation in ftp, but is it possible to just rename the folder to the name of an existing folder? Shouldn’t the existing folder be deleted first, thus causing the same problem?

Is there a standard approach to solve this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T09:49:21+00:00Added an answer on May 18, 2026 at 9:49 am

    How about this: On the FTP server, include version info in the filename. On the client, rename the file after downloading.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am writing some code to determine whether a network domain is registered. For
So I was writing some code today that basically looks like this: string returnString
I am writing some code and trying to speed it up using SIMD intrinsics
I'm writing some code for a class constructor which loops through all the properties
I'm writing some code in python and I'm having trouble when trying to retrieve
I'm writing some code that id like to be able to work with any
I was writing some code, and I notice a pattern in the exception handling
I'm writing some code that handles logging xml data and I would like to
I'm writing some code where the UI thread need to communicate with the background
I'm writing some code that uses dynamic shared libraries as plugins. My command line

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.