All Projects → RxDave → Qactive

RxDave / Qactive

Licence: apache-2.0
Reactive queryable observable framework.

Projects that are alternatives of or similar to Qactive

Rxviz
Rx Visualizer - Animated playground for Rx Observables
Stars: ✭ 1,471 (+900.68%)
Mutual labels:  reactive, observable, rx
Audio player flutter
🎧 Apple Music / Tidal Audio Player for Flutter
Stars: ✭ 52 (-64.63%)
Mutual labels:  reactive, rx
Kefir
A Reactive Programming library for JavaScript
Stars: ✭ 1,769 (+1103.4%)
Mutual labels:  reactive, observable
Rx Connect
Glue your state and pure React components with RxJS
Stars: ✭ 86 (-41.5%)
Mutual labels:  reactive, rx
Reaktive
Kotlin multi-platform implementation of Reactive Extensions
Stars: ✭ 760 (+417.01%)
Mutual labels:  reactive, rx
Ngx Restangular
Restangular for Angular 2 and higher versions
Stars: ✭ 787 (+435.37%)
Mutual labels:  reactive, observable
Rocket.jl
Functional reactive programming extensions library for Julia
Stars: ✭ 69 (-53.06%)
Mutual labels:  reactive, observable
Formily
Alibaba Group Unified Form Solution -- Support React/ReactNative/Vue2/Vue3
Stars: ✭ 6,554 (+4358.5%)
Mutual labels:  reactive, observable
Rx React Container
Use RxJS in React components, via HOC or Hook
Stars: ✭ 105 (-28.57%)
Mutual labels:  observable, rx
Lightweightobservable
📬 A lightweight implementation of an observable sequence that you can subscribe to.
Stars: ✭ 114 (-22.45%)
Mutual labels:  observable, rx
Marble
Marble.js - functional reactive Node.js framework for building server-side applications, based on TypeScript and RxJS.
Stars: ✭ 1,947 (+1224.49%)
Mutual labels:  reactive, observable
Combinex
Open source implementation for Apple's Combine
Stars: ✭ 496 (+237.41%)
Mutual labels:  reactive, rx
Rxretrojsoup
A simple API-like from html website (scrapper) for Android, RxJava2 ready !
Stars: ✭ 492 (+234.69%)
Mutual labels:  observable, rx
Sheldon
Type-safe reactive preferences for Android
Stars: ✭ 34 (-76.87%)
Mutual labels:  reactive, rx
Outwatch
A purely functional and reactive UI framework
Stars: ✭ 376 (+155.78%)
Mutual labels:  reactive, rx
Android Okgraphql
Reactive GraphQl client for Android
Stars: ✭ 64 (-56.46%)
Mutual labels:  reactive, rx
Mikado
Mikado is the webs fastest template library for building user interfaces.
Stars: ✭ 323 (+119.73%)
Mutual labels:  reactive, observable
Observable
The easiest way to observe values in Swift.
Stars: ✭ 346 (+135.37%)
Mutual labels:  reactive, observable
Redux Most
Most.js based middleware for Redux. Handle async actions with monadic streams & reactive programming.
Stars: ✭ 137 (-6.8%)
Mutual labels:  reactive, observable
Rxios
A RxJS wrapper for axios
Stars: ✭ 119 (-19.05%)
Mutual labels:  observable, rx

Qactive

A reactive queryable observable framework.

Download from NuGet

Qactive.Providers.Tcp
Depends on Rx, Qactive.Providers.Streaming, Qactive.Expressions and Qactive
Runtimes: .NET Framework 4.6.1; 4.5.2; 4.0

Qactive.Providers.Streaming
Depends on Rx, Qactive.Expressions and Qactive
Runtimes: .NET Framework 4.6.1; 4.5.2; 4.0

Qactive
Depends on Rx
Runtimes: .NET Framework 4.6.1; 4.5.2; 4.0, ASP.NET Core 1.0, Windows 8, Windows Phone 8.1, Xamarin.Android, Xamarin.iOS

Qactive.Expressions
No dependencies
Runtimes: .NET Framework 4.6.1; 4.5.2; 4.0

Overview

Qactive builds on Reactive Extension's queryable observable providers, enabling you to write elegant reactive queries in LINQ that execute server-side, even though they are written on the client. Qactive makes the extremely powerful act of querying a reactive service as easy as writing a typical Rx query.

More specifically, Qactive enables you to easily expose IQbservable<T> services for clients to query. When a client defines a query and subscribes, a connection is made to the server and the serialized query is transmitted to the server as an expression tree. The server deserializes the expression tree and executes it as a standing query. Any output from the query is marshaled back to the client over a persistent, full-duplex connection. Members on closures and static members that are local to the client are invoked from within the service automatically via full-duplex messaging. Anonymous types are automatically serialized as well.

For more information, see this series of blog posts.

Warning: Qactive allows clients to execute arbitrary code on your server. There are security mechanisms in place by default to prevent malicious clients but only to a point, it hasn't been fully considered yet. Do not expose a Qbservable service on a public server without taking the necessary precautions to secure it first.

See Security Guidelines for more information.

Features

Please refer to the list of features in the wiki.

Getting Started

Qactive is a set of .NET class libraries that you can reference in your projects. NuGet is recommended.

Add a reference to the Qactive.Providers.Tcp package in your Visual Studio project. That package references the other packages as dependencies, so NuGet will automatically download all of them for you.

Note: Currently, the TCP provider is the only provider available.

The source code's Examples folder contains projects that show various usages of Qactive, from a simple query over a timer to a real-time chat application.

To run the examples:

  1. Run QbservableServer.exe.
  2. The server will start hosting example Qbservable services as soon as the console application begins.
  3. Pressing a key at any time will stop the server.
  4. Run QbservableClient.exe.
  5. You can run several client console applications at the same time.
  6. When the client console application starts, press any key to connect to the server. The client will begin running the first example.
  7. Press any key to stop the current example and start the following example.

To build the source code:

  1. Set the QbservableServer project as the startup project.
  2. Build and run. The server will start as soon as the console application begins.
  3. Set the QbservableClient project as the startup project.
  4. Build and run. You can run several client console applications at the same time.
  5. When the client console application starts, press any key to connect to the server.

Tip: To see the original and rewritten expression trees, run the client application with the debugger attached and look at the Output window.

Simple Example

The following example creates a cold observable sequence that generates a new notification every second and exposes it as an IQbservable<long> service over TCP port 3205 on the local computer.

Server

IObservable<long> source = Observable.Interval(TimeSpan.FromSeconds(1));

var service = source.ServeQbservableTcp(new IPEndPoint(IPAddress.Loopback, 3205));

using (service.Subscribe(
  client => Console.WriteLine("Client shutdown."),
  ex => Console.WriteLine("Fatal error: {0}", ex.Message),
  () => Console.WriteLine("This will never be printed because a service host never completes.")))
{
  Console.ReadKey();
}

The following example creates a LINQ query over the IQbservable<long> service that is created by the previous example. Subscribing to the query on the client causes the query to be serialized to the server and executed there. In other words, the where clause is actually executed on the server so that the client only receives the data that it requested without having to do any filtering itself. The client will receive the first six values, one per second. The server then filters out the next 2 values - it does not send them to the client. Finally, the remaining values are sent to the client until either the client or the server disposes of the subscription.

Client

var client = new TcpQbservableClient<long>(new IPEndPoint(IPAddress.Loopback, 3205));

IQbservable<long> query =
  from value in client.Query()
  where value <= 5 || value >= 8
  select value;

using (query.Subscribe(
  value => Console.WriteLine("Client observed: " + value),
  ex => Console.WriteLine("Error: {0}", ex.Message),
  () => Console.WriteLine("Completed")))
{
  Console.ReadKey();
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].