Граф коммитов

21362 Коммитов

Автор SHA1 Сообщение Дата
Alex Villarreal c74e1ce03f
refactor(devtools-view): Move axe-core to devDependencies (#22797)
## Description

`axe-core` is used for accessibility tests only, it doesn't need to be a
prod dep.
2024-10-14 22:01:06 +00:00
Tyler Butler 91ace91767
fix(generate:changelog): Calculate correct changeset version (#22796)
We run `changeset version` during changelog generation, which causes
changesets to be consumed and the package.json versions to be bumped. We
need to calculate the same "target version" that the changesets tools
calculate so we can correctly replace the output of the changelogs to
the correct versions and do our other cleanup.

This change fixes the calculation to take into account the bump ranges
in the changesets.
2024-10-14 14:50:21 -07:00
Jatin Garg 3912f98df2
Add ability to skip coverage check in code coverage module (#22793)
## Description

This PR includes small improvements in the code coverage module.
1.) Add ability to skip coverage check in code coverage module in case
of regression.
2.) Fix glyph and use unicode characters for arrows.
3.) Improve code coverage readme.
4.) Add more details to the code coverage summary.

---------

Co-authored-by: Jatin Garg <jatingarg@Jatins-MacBook-Pro-2.local>
Co-authored-by: Alex Villarreal <716334+alexvy86@users.noreply.github.com>
2024-10-14 14:45:05 -07:00
Alex Villarreal aec02330fb
refactor(ai-collab): Cleanup (#22794)
## Description

Follow-up to https://github.com/microsoft/FluidFramework/pull/22732,
with a bit of cleanup from PR suggestions.

- Removes unnecessary config files and dependencies.
- Cleans up npm scripts.
- Adds the ESM output to code coverage configuration.
- Updates README in the sample app with basic instructions on how to
start it.
2024-10-14 13:59:44 -05:00
Matt Rakow ebddec41e8
Reenable api-report for migration-tools (#22788) 2024-10-14 18:53:45 +00:00
Tyler Butler a06e3c19b5
build(client): Generate release notes for 2.4.0 (#22785)
Generated release notes for the 2.4 release. The notes were generated using the following command:

```shell
flub generate releaseNotes -g client -t minor --outFile RELEASE_NOTES/2.4.0.md
```
2024-10-14 10:38:34 -07:00
Tyler Butler 0b3dda17bf
build(client): Tag asserts (#22784)
Tag asserts for the 2.4 release.

Command used:

```shell
flub release -g client
```
2024-10-14 16:51:18 +00:00
jzaffiro 673cd41c0d
merge-tree: Add regression tests for bugs with zero length obliterate (#22787)
Using the sided obliterate function in shared string fails currently
with two different errors:

- `0x2d8: Empty change event should not be emitted`
- `0x045: On insert, seq number already assigned!`

Tests in `sharedString.spec.ts` currently repro the `0x2d8` error only. 

[AB#19742](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/19742)
2024-10-14 15:10:09 +00:00
Joshua Smithrud 3cb85a3494
build(docs): Update `api-markdown-documenter` (#22790)
Updates to `0.17.1`
2024-10-14 09:50:47 -05:00
Jason Hartman a754dfe7cb
fix(client-presence): relax connection expectation (#22792)
Presence asserted connection when processing signals, but that doesn't
hold as signals may be queued and connection status might change along
the way.
Just skip an attempt to respond when not connected.
2024-10-12 00:50:01 +00:00
Mark Fields de6928b528
Stop parsing op contents in DeltaManager - runtime will do it (#22750)
A long time ago (5acfef448f) we added
support in ContaineRuntime to parse op contents if it's a string. The
intention was to stop parsing in DeltaManager once that saturated. This
is that long overdue follow-up.

Taking this opportunity to make a few things hopefully clearer in
ContainerRuntime too:

* Highlighting where/how the serialization/deserialization of `contents`
happens
* Highlighting the different treatment/expectations for runtime v.
non-runtime messages during `process` flow

## Deprecations:

Deprecating use of `contents` on the event arg `op` for
`batchBegin`/`batchEnd` events, they're in for a surprise. I added a
changeset for this case.
2024-10-11 23:01:59 +00:00
Matt Rakow 5ca6cd2257
Relax migration sequence number requirement (#22786) 2024-10-11 14:59:45 -07:00
Daniel Madrid 3dbda6c6d5
Fix 0x11f raise condition (#22780)
While stashing blobs, we need to first send the blob attach op before
resolving the blob handle to keep order of ops correctly (blob attach op
and op referencing the blob). This change of order causes the stashed
container to have a blob attach op whose blob won't be used in case of
aborting the closeAndGetPendingLocalState call.

Instead of cleaning up the pending state, for now we will just accept
the fact that the blob attach op will be stashed with no usage. We could
come up with an optimization of this later on when our partners catch up
with our latest offline features.
2024-10-11 20:25:51 +00:00
Mark Fields 887a75ff76
Add simple op submit and roundtrip benchmarks (#22783)
This PR adds some benchmark tests to get coverage of the Runtime's
handling of ops when submitting and processing them. This can be used to
test out the perf impact of various configurations or proposed changes.
2024-10-11 20:00:04 +00:00
Craig Macomber (Microsoft) 3b083cc333
Tidy up some oddities for package configuration in "client" (#22713)
## Description

While looking at our pnpm version, I found two packages inside of client
other than the root specifying the pnpm version. This seems unnecessary.
This removes them, as well as the apparently unneeded workspace and
pnpm-lock from tools/markdown-magic.
2024-10-11 12:46:20 -07:00
Navin Agarwal 0e3abe80be
(tree) Added a beta API to deep clone tree nodes (#22719)
## Description
Added a beta API to deep clone nodes in a tree. The properties of this
API are:
- It deep clones all persisted data associated with the node and its
subtree.
- It can clone primitive types as well.
- It can clone both hydrated and unhydrated nodes.

## Future considerations
One useful property of this API could be to replace identifiers in the
node's subtree. However, I am choosing to not do this in the first
iteration of this API. We can consider doing this as a follow up or when
there is a customer ask which will give us more details into what the
requirements are and how best to design it.


[AB#13000](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/13000)
2024-10-11 11:44:51 -07:00
Mark Fields 37c0f2d1c9
Flakey Test: Fix possible race condition (#22776)
The test `Parallel Forks: Closes (ForkedContainerError and
DuplicateBatchError) when hydrating twice and submitting in parallel
(via Counter DDS)` has had some recent failures when running against
t9s.

Reading through the test again, the only idea I have so far is that
maybe one of the containers manages to submit the stashed ops before it
can pause the outbound queue after creation.

This change aims to close that gap.
2024-10-10 18:55:39 -07:00
Alex Villarreal 880afad134
feat: Experimental AI collab package (#22732)
## Description

Adds a new package `@fluid-experimental/ai-collab` with the first draft
of a library that simplifies integration with AI / LLM agents in
Fluid-based applications.

Also adds a sample application that leverages said package. NOTE: we
know already that the app will probably be re-written so we're not
spending more time fixing its source code.

---------

Co-authored-by: seanimam <105244057+seanimam@users.noreply.github.com>
Co-authored-by: Tyler Butler <tyler@tylerbutler.com>
2024-10-10 17:53:37 -05:00
Tyler Butler 05695194d6
build(client): Upgrade are-the-types-wrong to latest version (0.16.4) (#22778) 2024-10-10 14:23:26 -07:00
Jatin Garg e3b4f23669
Fix cobertura configuration for showing code covearge stats (#22746)
## Description


[AB#19036](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/19036)

Fix cobertura configuration for showing code covearge stats in client
repo. Currently running npm run test:coverage does not display code
coverage stats because lib files are not included in the config.

Since when running test for an individual package we run:
"test:mocha:esm", that is why lib files needs to be included for
coverage to be reported correctly.

---------

Co-authored-by: Jatin Garg <jatingarg@Jatins-MacBook-Pro-2.local>
2024-10-10 14:00:43 -07:00
Mark Fields 37d6657ef2
Offline: Properly handle ID Allocation batches (#22739)
ID Allocation ops are not resubmitted one-by-one like other ops, but
rather the ID Compressor is told to generate new ops once and for all
right at the start of the Resubmit flow (before calling
`PendingStateManager.replayPendingStates`). The original Batch ID isn't
available at that point, so there's no way to correlate the new ID
Allocation Batch to the original one.

In a forked container scenario, we can ignore the Batch IDs of ID
Allocation batches, knowing that the main batch will also be duplicated
and we'll detect that.
2024-10-10 13:37:13 -07:00
Tong Chen 73bdeee619
fix(@fluid-tools/benchmark): Make telemetry generator handler to log error (#22689)
## Description

### Changes Made

Validation Improvement: Updated the validation logic to use
Number.isNaN(Number.parseFloat(value)) instead of isNaN. This ensures
that any non-number data is correctly identified and handled.

### Error Handling
For app insights handlers, retained the try-catch mechanism to continue
processing subsequent metrics even if an error occurs.

_For non-app-insight handlers, implemented a strategy to throw an error
and terminate the process when non-number data is encountered. This
provides a clear indication of unexpected data and prevents the
submission of potentially invalid values._

### Unit Tests

Added unit tests to cover scenarios involving non-number data in
customData. These tests ensure that the new validation logic works as
expected and helps prevent future regressions.

## Test result
~~~
@chentong7 ➜ /workspaces/FluidFramework/tools/telemetry-generator
(telemetry) $ npm run test

> @fluid-tools/telemetry-generator@1.0.0 test
> mocha --recursive "dist/test/**/*.test.*js" --exit

Writing test results relative to package to nyc/junit-report.xml and
nyc/junit-report.json


  appInsightsCustomBenchmarkHandler
    ✔ should emit metrics to Azure App Insights

  appInsightsExecutionTimeTestHandler
    ✔ should emit valid metrics to Azure App Insights
    ✔ should skip logging for invalid metrics

  appInsightsMemoryUsageTestHandler
✔ should emit heap used avg and std dev metrics to Azure App Insights
    ✔ should skip metrics if values are not numbers

  executionTimeTestHandler
    ✔ should emit execution time avg and std dev metrics to logger

  memoryUsageTestHandler
    ✔ should emit heap used avg and std dev metrics to logger
    ✔ should throw an error for invalid heap used avg metric
    ✔ should throw an error for invalid heap used std dev metric


  9 passing (12ms)
~~~

---------

Co-authored-by: Alex Villarreal <716334+alexvy86@users.noreply.github.com>
2024-10-10 11:24:06 -07:00
yunho-microsoft 03d6823692
Improve socket errors for AFR (#22745)
This PR includes:

1. Send back retryAfterMs for draining errors
2. Use Network for token revocation errors; deprecate
TokenRevocationErrors

---------

Co-authored-by: Yunho <yunho-macbookpro2024@Yunhos-MacBook-Pro.local>
Co-authored-by: Yunho <yunho-macbookpro2024@Yunhos-MBP.guest.corp.microsoft.com>
2024-10-10 11:06:02 -07:00
Brandon fffe980734
Session discovery metrics/monitoring (#22681)
## Description

- Add metrics to know where time is being spent during session discovery
- Broken down into two primary pieces: verifyStorageToken and getSession
- GetSession is further broken down into three parts:
checkDocumentExistence, updateExistingSession, and createNewSession
- checkDocumentExistence is the DB call that is made to retrieve the doc
and see if it exists
- updateExistingSession will only happen if the session is not yet
alive/discovered
- createNewSession will only happen if the session is undefined (docs
created before the concept of service sessions)

---------

Co-authored-by: Brandon Diaz <“BrandonLouisDiaz@gmail.com”>
2024-10-10 14:01:31 -04:00
Tyler Butler 1bc44ec9d4
ci: Auto-generate and publish release notes for minor releases (#22514)
The transform:releaseNotes command was added in #22466 to enable
automated release note creation for minor releases. This change updates
the CI pipeline to take advantage of the new capabilities.


[AB#19242](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/19242)

---------

Co-authored-by: Alex Villarreal <716334+alexvy86@users.noreply.github.com>
2024-10-10 16:51:38 +00:00
MarioJGMsoft 6d00fc740d
Remove READ support for compatDetails on ContainerRuntime ops (#22715)
#### Description 
Search for compatDetails in the code - all some usages can now be
removed. Maintaining this behavior has been a pain in tests, and it is
not a good feature.

It was only ever used for GC, and wasn't as useful (or safe) as
expected. See discussion in ADO:
https://dev.azure.com/fluidframework/internal/_workitems/edit/17024 -
RC1 clients don't know about TombstoneLoaded subtype

Fixes issue:
[AB#17024](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/17024)

The full removal of this feature is planned for next sprint (10/14 -
11/1)

---------

Co-authored-by: Mark Fields <markfields@users.noreply.github.com>
2024-10-10 08:59:56 -07:00
jzaffiro 487c2a499c
mergetree: Remove exposure of overwrite property (#22774)
Instead of passing the overwrite property through the merge tree tests
and various functions, only use it within the functions when necessary.
The previous default value of `false` is used to initialize the variable
in these cases.


[AB#15995](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/15995)
2024-10-10 00:17:50 +00:00
jzaffiro 809a1e7344
Merge tree: add sidedness to obliterate ops in conflict farm tests (#22747)
Functionally the same as #22615, but on a clean branch. 


[AB#15963](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/15963)
2024-10-09 23:30:21 +00:00
Joshua Smithrud 6c06bbd686
fix(api-markdown-documenter): Fix issue that caused packages skipped via `skipPackage` option to still be listed on root "model" page (#22772)
See updated test collateral for an example
2024-10-09 22:59:47 +00:00
Tyler Butler a1146fc590
build(client): Update build-tools deps to 0.48.0 (#22770) 2024-10-09 15:42:37 -07:00
Kian Thompson 3bb89e1caa
Re-enable message size test for t9s (#22759)
Ran this test over 10k times and didn't see a single failure. We have a
new flow that detects flaky tests, so I'll re-enable the test for t9s
and let that workflow catch any future flakiness.

Fixes
[AB#7669](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/7669)
2024-10-09 15:11:53 -07:00
clarenceli-msft aa24ad4f66
Fix the error due to previous bad pull/rebase (#22771)
Due to some bad pull/rebase, the PR
https://github.com/microsoft/FluidFramework/pull/21702 introduced
content that shouldn't exist in the main branch (based on the commit
c126bba051 (diff-5839274c7eb7f262c570edf94a75999ccf76913c6d7b9ec3d53152537a00b0cb)).
This PR is to address this issue.

## Reviewer Guidance

The review process is outlined on [this wiki
page](https://github.com/microsoft/FluidFramework/wiki/PR-Guidelines#guidelines).

> List any specific things you want to get reviewer opinions on, and
anything a reviewer would need to know to review this PR effectively.
> Things you might want to include:
>
> - Questions about how to properly make automated tests for your
changes.
> -   Questions about design choices you made.
> - Descriptions of how to manually test the changes (and how much of
that you have done).
> -   etc.
>
> If you have any questions in this section, consider making the PR a
draft until all questions have been resolved.
2024-10-09 18:07:21 -04:00
Alex Villarreal 4228a21d96
fix: Update transitive dependencies on `braces` to address CVE (#22768)
## Description

Updates transitive dependencies on `braces` from 3.0.2 to 3.0.3 to
address [CVE-2024-4068](https://nvd.nist.gov/vuln/detail/CVE-2024-4068).

A couple of applications of `flub modify lockfile --dependency braces
--version 3.0.3 --releaseGroup <release group>`, and some manual updates
in packages/release groups that we can't target with `flub`, basically
doing the same thing but manually (add an override in package.json,
install dependencies, remove override, install dependencies again to
clean up override from the lockfile).

In a few cases I got unrelated updates, mostly about node types, which I
reverted manually.

Server packages also got semver update from 7.6.0 to 7.6.3 which seems
fine.
2024-10-09 14:16:38 -05:00
jzaffiro 0637dcc29d
merge tree: Update docs to reflect endpoint expansion changes (#22764)
Adds information about the new behavior of obliterate with endpoint
expansion to the documentation. The majority of the changes fall under
the "Endpoint Behavior" section, since conceptually the obliterate stays
mostly the same.
2024-10-09 11:12:32 -07:00
Craig Macomber (Microsoft) 16906d0390
tree: reduce "rebasing commits" benchmarks when not in perf mode (#22765)
## Description

In October 2023, one of the "rebasing commits" tests timed out during
test stability testing.

For me locally these tests run as follows:

  SharedTree benchmarks
    rebasing commits
✔ @Benchmark @Measurement @ExecutionTime for 1 commits per peer for 2
peers (45ms)
✔ @Benchmark @Measurement @ExecutionTime for 5 commits per peer for 2
peers (56ms)
✔ @Benchmark @Measurement @ExecutionTime for 10 commits per peer for 2
peers (89ms)
✔ @Benchmark @Measurement @ExecutionTime for 1 commits per peer for 4
peers (72ms)
✔ @Benchmark @Measurement @ExecutionTime for 5 commits per peer for 4
peers (196ms)
✔ @Benchmark @Measurement @ExecutionTime for 10 commits per peer for 4
peers (398ms)

Since my system is much faster than CI, and CI has a default timeout of
2 seconds, its plausible that this could be an issue if CI has a really
slow run sometime.

This change reduces the size of test cases run when not in performance
testing mode so that the run now look like:

  SharedTree benchmarks
    rebasing commits
✔ @Benchmark @Measurement @ExecutionTime for 1 commits per peer for 2
peers (52ms)
✔ @Benchmark @Measurement @ExecutionTime for 2 commits per peer for 2
peers (40ms)
✔ @Benchmark @Measurement @ExecutionTime for 1 commits per peer for 4
peers (88ms)
✔ @Benchmark @Measurement @ExecutionTime for 2 commits per peer for 4
peers (132ms)

With this the worst case is now more than twice as fast.

This should have no impact on the tests when run as performance tests.

Tracked internally by
https://dev.azure.com/fluidframework/internal/_workitems/edit/6003
2024-10-09 17:17:02 +00:00
Tyler Butler 271b3c7dbb
[bump] build-tools: 0.48.0 => 0.49.0 (minor) (#22760)
Bumped build-tools from 0.48.0 to 0.49.0.
2024-10-08 22:43:52 +00:00
Jatin Garg 7a7263c69e
Modify comment syntax for code coverage (#22752)
## Description

Modify comment for code coverage.
Add the line coverage summary to the summary.

Co-authored-by: Jatin Garg <jatingarg@Jatins-MacBook-Pro-2.local>
2024-10-08 15:34:24 -07:00
yann-achard-MS 83f885149d
Docs(tree): updates and clarifications in detached trees doc (#22756) 2024-10-08 22:09:50 +00:00
Tony Murphy e02cc904aa
MergeTree: Initialize DoublyLinkedList from Values (#22753)
Small change from a bigger change that adds a constructor to the
DoublyLinkedList class so it can easily be initialized with values
2024-10-08 20:28:55 +00:00
Craig Macomber (Microsoft) 6a75bd0616
tree: Cleanup object property tests, and fix bug (#22748)
## Description

This cleans up a section of the object node tests which used schema
types in a complicated generic way that's fragile and hard to work with.

When rewriting these tests, I focused the new ones on testing aspects
that actually have special logic and are likely to break instead of just
different value types. Thus the tests now cover the odd normalization
cases of numbers.

These tests found a couple of issues:
- unhydrated node handling of null was incorrect (see changeset)
- Some type errors were thrown for invalid user input. TO help keep it
easy to tell which errors are our bugs and which are app bugs I've made
these fluid usage errors.
- A needless check for NaN was included where the check for isFinaite
would handle it correctly (Number.isFinite considers NaNs to not be
finite: comment already calls out NaN and it has test coverage so this
seems like a safe change.)
2024-10-08 17:58:09 +00:00
Craig Macomber (Microsoft) a8d7871f48
Delete markdown-magic pipeline (#22714)
## Description

Delete markdown-magic pipeline.
2024-10-08 10:56:10 -07:00
Tyler Butler 082c72d416
feat(fluid-build): Add support for declarative tasks (#22663)
Adds support for creating fluid-build tasks from config only, by
declaring the command corresponding to the task and providing globs for
input and output files.

- Adds two new settings to the fluid-build config.
- `declarativeTasks?: DeclarativeTasks;` - a mapping of
executable/command to input/output globs and a gitignore setting that
controls whether gitignore rules are applied to the input/output globs.
- `multiCommandExecutables?: string[]` - a list of executables that have
subcommands, like `flub` or `oclif`. This is needed to ensure that the
commands in the declarative tasks are parsed correctly.
- Added types to represent "task handlers" - functions that create
LeafTask objects to handle tasks.
- Added support for free functions that return instances of LeafTasks -
this is needed so that task handlers can be dynamically created. Task
subclasses with constructors still work as before.
- Added a new DeclarativeTaskHandler class that handles the declarative
tasks. It is a typical Task class, but the primary way it is used is via
a factory function. This allows us to pass in the configuration settings
for each task dynamically but re-use the DeclarativeTask class for all
the core functionality.
- Defined new declarative tasks for oclif, jssm-viz, and syncpack in the
root fluid-build config. These won't take effect until the new version
of build-tools is integrated into client.
- New dependency: globby - globby is helpful because it can auto-apply
gitignore rules which we need to do for some tasks' input/output globs.


[AB#13203](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/13203)
2024-10-08 09:24:37 -07:00
Craig Macomber (Microsoft) 00ed297786
Remove unused packagesToBump from checkNoPrereleaseDependencies (#22728)
## Description

Remove unused `packagesToBump` from `checkNoPrereleaseDependencies`.
2024-10-08 09:24:16 -07:00
jzaffiro 870d6c972e
Add regression test for sided obliterates (#22595)
A skipped test to illustrate a bug found from adding sided obliterate
ops to the conflict farm stress tests. Once sidedness is enabled and the
bug is fixed, the .skip will be removed from the test.
2024-10-07 16:34:57 -07:00
clarenceli-msft fe46e41055
Improve DDS stress testing: introduce enum stress mode (#21702)
[AB#2729](https://dev.azure.com/fluidframework/internal/_workitems/edit/2729),
[AB#2730](https://dev.azure.com/fluidframework/internal/_workitems/edit/2730)

This PR is a prototype for improving the Test - DDS Stress line by using
a numeric stressLevel instead of a boolean isStress. This change allows
for more granular control over whether to use stress runs and to what
degree.

The follow-up tasks include:

1. Integrating this functionality (potentially as a stage) into the CI
build pipeline with a light stress level mode, so it can be triggered in
the PR gateway.

2. Creating a long-running pipeline to execute the DDS stress tests with
a heavy stress level mode, scheduled to run periodically during off-peak
hours, similar to the test stability pipeline.


[Guidelines for Pull
Requests](https://github.com/microsoft/FluidFramework/wiki/PR-Guidelines#guidelines).


## Reviewer Guidance

The review process is outlined on [this wiki
page](https://github.com/microsoft/FluidFramework/wiki/PR-Guidelines#guidelines).

> List any specific things you want to get reviewer opinions on, and
anything a reviewer would need to know to review this PR effectively.
> Things you might want to include:
>
> - Questions about how to properly make automated tests for your
changes.
> -   Questions about design choices you made.
> - Descriptions of how to manually test the changes (and how much of
that you have done).
> -   etc.
>
> If you have any questions in this section, consider making the PR a
draft until all questions have been resolved.

---------

Co-authored-by: Abram Sanderson <Abram.sanderson@gmail.com>
2024-10-07 19:28:23 -04:00
WillieHabi e187fe8136
test(client): Disable ODSP targeted signal tests (#22743)
ODSP targeted signal tests are consistently failing due to reuse of
socket references in ODSP driver. These tests can be re-enabled once
targetClientId is included in the return signal from PushChannel.
2024-10-08 01:24:00 +02:00
Daniel Madrid 48b11bedf2
Fix offline blob tests (#22744)
in ODSP, we can't load a container offline and send a server request to
create a blob because our call would not be complete, specifically we
would lack the epoch value which is set until we connect to the delta
stream, ending up with a 'ODSP fetch error [400]' response.

Even though this problem is worth tackling separately I believe both
affected tests are not specifically testing this behavior so I changed
them slightly to send a createBlob request while being disconnected
instead of using our loadOffline function. Both tests are connecting
anyway after creating the blob and the relevant asserts happen after
that part of those tests.

I added another test which replicates the issue and skip it in ODSP for
now. If we want to solve the initial issue, we would need to stash the
epoch info in our serialized state.
[AB#19035](https://dev.azure.com/fluidframework/235294da-091d-4c29-84fc-cdfc3d90890b/_workitems/edit/19035)

---------

Co-authored-by: Abram Sanderson <Abram.sanderson@gmail.com>
2024-10-07 22:58:25 +00:00
Jason Hartman f57799c060
feat(client-presence): System Workspace (#22670)
1. Add infrastructure for custom System Workspace to handle internal
states including ClientConnectionId to ClientSessionId.
2. Move audience support to System Workspace
3. Add `attendeeJoined` implementation
4. Add test coverage for new attendee's joining and consistency of
lookup. New test cases:
```
    PresenceManager
      ✔ throws when unknown attendee is requested via `getAttendee`
      when connected
        attendee
          ✔ is announced via `attendeeJoined` when new
          already known
            ✔ is available from `getAttendee` by connection id
            ✔ is available from `getAttendee` by session id
            ✔ is available from `getAttendees`
            ✔ is NOT announced when rejoined with same connection (duplicate signal)
            ✔ is NOT announced when rejoined with different connection and current information is updated
```
5. Update general update protocol to always include client connection id
-> current session id entry to ensure all updates are always working
with known (already registered) session id even if a prior join or
broadcast were missed.
2024-10-07 12:40:38 -07:00
Jason Hartman efa8231107
refactor(client): refactor signal telemetry (#22738)
Move signal telemetry and tracking to helper methods
- add processSignalForTelemetry and add comments
- add submitEnvelopedSignal that handles tracking updates a little
closer to submission
2024-10-07 12:17:15 -07:00
Tony Murphy e180043832
Remove mocha-json-output-reporter (#22735)
The mocha-json-output-reporter is failing which I was able to determine
via trial and error by adjusting the reporters, it also appears to be
essentially unsupported. It seems we only use it for inline logs in our
ci build output, which shouldn't be necessary as we have the test
results separately in the test tab. I think the best solution is to just
remove this.
2024-10-07 18:46:47 +00:00