Add Suave server integration package - #567
xperiandri with Copilot wants to merge 26 commits into
Conversation
|
@copilot Does this support websocket aspects of GraphQL spec? |
Checked this in the current implementation at 46c8871: no, the Suave package does not support the WebSocket/GraphQL-over-WebSocket part right now. What exists today in The WebSocket implementation lives in So the short answer is: HTTP GraphQL is supported in Suave, WebSocket GraphQL is not. Reusing the ASP.NET Core implementation as-is would not work directly; it would need either a Suave-specific WebSocket adapter or a refactor that extracts the transport-agnostic parts into shared code. |
…ory` and remove external server orchestration from build (#564) Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com>
…compile time (#569) Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com>
Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com>
Signed-off-by: dependabot[bot] <support@github.com>
46c8871 to
7be94f3
Compare
…, and add PR preview publishing (#570) Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com> Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Added MSBuild target to ensure DesignTime DLL is included in NuGet package, working around F# SDK limitations with ProjectReference-based providers. Removed obsolete target for cleaning NuGet pack input and updated conditions for consistency.
… to `3.53.3` (#588) Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com>
* Refactored `ObjectListFilter`: modularized, added type coercion - Moved filter operators and LINQ logic to ObjectListFilterModule.fs - Added `TypeCoercion.fs` for automatic filter value coercion (`Guid`, `DateTime`, F# DUs, etc.) - Introduced `FilterValueCoercer` and extended `ObjectListFilterLinqOptions` for custom coercion - Centralized filter suffix constants in `FilterSuffixConstants.fs` - Updated `SchemaDefinitions.fs` to use new suffix constants - Added `vtryFind` and `vtryPick` utilities for arrays/lists in `Extensions.fs` - Improved code style, documentation, and function signatures * Refactor 'ObjectListFilter' to use 'System.Text.Json' coercion Replaces custom value coercers with 'System.Text.Json'-based coercion in 'ObjectListFilter', supporting advanced scenarios like F# DUs and CLR enums via 'JsonSerializerOptions'. Updates 'ObjectListFilterLinqOptions' to accept 'JsonSerializerOptions'. Refactors 'TypeCoercion' module to use JSON serialization/deserialization for all type conversions. Updates filter application logic and expands the test suite with new files to cover a wide range of coercion scenarios. Updates documentation and usage examples accordingly. * Updateв schema, add type coercion guide, bug report, tools * Added bug report for InputObject array type mismatch with analysis and test cases * Added type coercion guide for ObjectListFilter with usage and API docs * Introduced format-changed-files.ps1 to batch-format changed F# files via Fantomas * Updated schema snapshots for relay-style connections and new scalars * Refactored field_aliases.fsx for relay-style friends connection * Optimized TypeCoercion.fs to use Utf8JsonWriter for value coercion * Added prompt template for automated PR/issue description generation * Rebase fix * Update filters to use `CurrentCulture` string comparison Updated all string comparison operations in `ObjectListFilter` and filter parsing logic to use `StringComparer.CurrentCulture` or `StringComparer.CurrentCultureIgnoreCase` instead of `Ordinal`/`OrdinalIgnoreCase`. Adjusted related test expectations to match. This ensures string-based filters now respect the current culture's case rules. * Rebase fixes * Removed unnecessary `ObjectListFilterValidationException` * Added test traits * AI review fixes * Fix ObjectListFilter IN coercion behavior and add converter/no-converter tests
* Enhanced `InputValue.OfObject` to handle `Guid` (as `StringValue "D"`), `IReadOnlyDictionary`/`IDictionary` (as `ObjectValue`), and improved F# union handling. * Added `GuidId` DU, wrapped scalar, and new `Guid`/`ValueObject` fields to test types, extended tests for filtering with `Guid` and custom value object scalars.
* Added `ObjectListFilterEmptyArrayTests.fs` with cases for Contains, Equals, Not Equals, and logical operators on empty/non-empty lists. Updated `.fsproj` to include the new file. * Extended `ObjectListFilterLinqGenerateTests.fs` to verify correct Cosmos SQL generation for list equality and length checks.
- Implemented comprehensive validation for interface field covariance, covering output type subtyping, argument compatibility, and field implementation checks. - Enhanced error messages with clearer formatting and context. - Updated validation logic for object, input object, union, and enum types to use interpolated strings. - Added `InterfaceCovarianceTests.fs` with extensive valid/invalid covariance scenarios. - Modernized `TypeValidationTests.fs` and expanded `UnionInterfaceTests.fs` for execution coverage.
|
Can @copilot implement web sockets? |
7be94f3 to
f2196b0
Compare
|
WebSockets are already implemented and packaged in ASP.NET Core project (as far as I remember) |
IIUIR Suave is outside of ASP.NET so this would need an implementation built on top of Suave |
…server (#586) Signed-off-by: dependabot[bot] <support@github.com>
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/1f4b9b83-930c-43b3-a8a5-8cf795269b9d Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/1f4b9b83-930c-43b3-a8a5-8cf795269b9d Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/1f4b9b83-930c-43b3-a8a5-8cf795269b9d Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
f2196b0 to
c4cfcc3
Compare
This adds an official Suave integration package for
FSharp.Data.GraphQL, following the existing Giraffe/Oxpecker shape. The new package exposes GraphQL as a SuaveWebPartso it can be embedded directly into larger Suave applications.New Suave integration package
FSharp.Data.GraphQL.Server.SuaveHttpHandlers.graphQLHttpHandlers.setRequestTypeGETintrospection requestsPOSTJSON GraphQL requestsRequest handling model
IInputExecutionContextimplementation for file uploadsRequest-Typeresponse header convention used by the current integrationsPackaging and build wiring
Focused coverage
Example usage: