microsoft / microsoft/Windows-classic-samples

[CloudMirror] CF_CALLBACK_TYPE_VALIDATE_DATA Does Not Trigger In CloudMirror Provider

Open
#280 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
No language data
Stars
5.7k
Forks
3.3k
PR merge metrics
No merged PRs in 30d

Description

The cfapi.h header documentation provided by Microsoft Learn does not explain how CF_CALLBACK_TYPE_VALIDATE_DATA is called by the provider, and when testing this callback is not called in the latest Windows 11 Insider Beta of 22623.1037 when running the CloudMirror sample.
The methods implemented by the provider are:

CF_CALLBACK_REGISTRATION FakeCloudProvider::s_MirrorCallbackTable[] =
{
{ CF_CALLBACK_TYPE_FETCH_DATA, FakeCloudProvider::OnFetchData },
{ CF_CALLBACK_TYPE_CANCEL_FETCH_DATA, FakeCloudProvider::OnCancelFetchData },
{ CF_CALLBACK_TYPE_NOTIFY_RENAME_COMPLETION, FakeCloudProvider::OnRenameCompletion },
{ CF_CALLBACK_TYPE_NOTIFY_DELETE_COMPLETION, FakeCloudProvider::OnDeleteCompletion },
{ CF_CALLBACK_TYPE_VALIDATE_DATA, FakeCloudProvider::OnValidateData },
CF_CALLBACK_REGISTRATION_END
};
The method FakeCloudProvider::OnValidateData:

void CALLBACK FakeCloudProvider::OnValidateData(
_In_ CONST CF_CALLBACK_INFO* callbackInfo,
_In_ CONST CF_CALLBACK_PARAMETERS* callbackParameters)
{
printf("Callback Validate Data Issued\n");
}
I have tried hydrating a placeholder, dehydrating a placeholder, opening the file on the system, and opening a Pinned file on the system, all without this method being called, along with Restarting the Cloud Provider. I am using the Microsoft Cloud Mirror Sample.
Is there any way I can find information regarding this feature, or any information on how to fix this in the sample? Thanks In Advance!

Relevant Microsoft Q&A Issue

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Microsoft Cloud Mirror sample's CF_CALLBACK_REGISTRATION callback table and FakeCloudProvider::OnValidateData implementation. Reproduce the reported hydration, dehydration, file-opening, and restart steps, then compare the observed behavior with the linked Microsoft Learn and Q&A discussions. Done means determining whether the callback is expected to fire and documenting or correcting the sample accordingly.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.