You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by tz...@apache.org on 2020/08/31 06:00:18 UTC

[flink-statefun] branch master updated (194b3f9 -> c483184)

This is an automated email from the ASF dual-hosted git repository.

tzulitai pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/flink-statefun.git.


    from 194b3f9  [FLINK-18518] Move statefun releated files into statefun/ dir
     new d2cdcd3  [FLINK-18979][docs] Move modules to overview and put remote modules on top
     new fa43ab8  [FLINK-18979][docs] Move Python SDK above Java SDK
     new 4a86dbe  [FLINK-18979][docs] Default to remote modules in connectors
     new 10df361  [FLINK-18979][docs] Update homepage introduction
     new c483184  [FLINK-18979][docs] Update READMEs

The 5 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 README.md                          |  12 ++-
 docs/index.md                      |  16 +--
 docs/io-module/apache-kafka.md     | 186 +++++++++++++++++-----------------
 docs/io-module/aws-kinesis.md      | 198 ++++++++++++++++++-------------------
 docs/io-module/flink-connectors.md |   2 +-
 docs/io-module/index.md            |  82 +++++++--------
 docs/sdk/index.md                  | 111 ++++++++++++++++++++-
 docs/sdk/java.md                   |   2 +-
 docs/sdk/modules.md                | 131 ------------------------
 statefun-python-sdk/README.md      |  12 ++-
 10 files changed, 374 insertions(+), 378 deletions(-)
 delete mode 100644 docs/sdk/modules.md


[flink-statefun] 02/05: [FLINK-18979][docs] Move Python SDK above Java SDK

Posted by tz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

tzulitai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink-statefun.git

commit fa43ab8969575ccf77badc5eadd1a5ee00a00ecc
Author: Seth Wiesman <sj...@gmail.com>
AuthorDate: Mon Aug 17 13:53:46 2020 -0500

    [FLINK-18979][docs] Move Python SDK above Java SDK
---
 docs/sdk/java.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docs/sdk/java.md b/docs/sdk/java.md
index b5903f5..5436fad 100644
--- a/docs/sdk/java.md
+++ b/docs/sdk/java.md
@@ -1,7 +1,7 @@
 ---
 title: Java SDK 
 nav-id: java-sdk
-nav-pos: 1
+nav-pos: 2
 nav-title: Java
 nav-parent_id: sdk
 ---


[flink-statefun] 01/05: [FLINK-18979][docs] Move modules to overview and put remote modules on top

Posted by tz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

tzulitai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink-statefun.git

commit d2cdcd3c93e2cd1a250c3ff3e98e7ce64a998324
Author: Seth Wiesman <sj...@gmail.com>
AuthorDate: Mon Aug 17 13:52:49 2020 -0500

    [FLINK-18979][docs] Move modules to overview and put remote modules on top
---
 docs/sdk/index.md   | 111 +++++++++++++++++++++++++++++++++++++++++++-
 docs/sdk/modules.md | 131 ----------------------------------------------------
 2 files changed, 110 insertions(+), 132 deletions(-)

diff --git a/docs/sdk/index.md b/docs/sdk/index.md
index c398744..42beaa3 100644
--- a/docs/sdk/index.md
+++ b/docs/sdk/index.md
@@ -4,7 +4,7 @@ nav-id: sdk
 nav-pos: 3
 nav-title: 'SDK'
 nav-parent_id: root
-nav-show_overview: false 
+nav-show_overview: true 
 permalink: /sdk/index.html
 ---
 <!--
@@ -25,3 +25,112 @@ KIND, either express or implied.  See the License for the
 specific language governing permissions and limitations
 under the License.
 -->
+
+Stateful Functions applications are composed of one or more modules.
+A module is a bundle of functions loaded by the runtime and made available to be messaged.
+Functions from all loaded modules are multiplexed and free to message each other arbitrarily.
+
+Stateful Functions supports two types of modules: Remote and Embedded.
+
+* This will be replaced by the TOC
+{:toc}
+
+## Remote Module
+
+Remote modules run as external processes from the Apache Flink® runtime; in the same container, as a sidecar, using a serverless platform or other external location.
+This module type can support any number of language SDKs.
+Remote modules are registered with the system via ``YAML`` configuration files.
+
+### Specification
+
+A remote module configuration consists of a ``meta`` section and a ``spec`` section.
+The ``meta`` contains auxiliary information about the module; 
+while ``spec`` describes the functions contained within the module and defines their persisted values.
+
+### Defining Functions
+
+``module.spec.functions`` declares a list of ``function`` objects that are implemented by the remote module.
+A ``function`` is described via a number of properties:
+
+* ``function.meta.kind``
+    * The protocol used to communicate with the remote function.
+    * Supported values - ``http``
+* ``function.meta.type``
+    * The function type, defined as ``<namespace>/<name>``.
+* ``function.spec.endpoint``
+    * The endpoint at which the function is reachable.
+    * Supported schemes: ``http``, ``https``.
+    * Transport via UNIX domain sockets is supported by using the schemes ``http+unix`` or ``https+unix``.
+    * When using UNIX domain sockets, the endpoint format is: ``http+unix://<socket-file-path>/<serve-url-path>``. For example, ``http+unix:///uds.sock/path/of/url``.
+* ``function.spec.states``
+    * A list of the persisted values declared within the remote function.
+    * Each entry consists of a `name` property and an optional `expireAfter` property.
+    * Default for `expireAfter` - 0, meaning that state expiration is disabled.
+* ``function.spec.maxNumBatchRequests``
+    * The maximum number of records that can be processed by a function for a particular ``address`` before invoking backpressure on the system.
+    * Default: 1000
+* ``function.spec.timeout``
+    * The maximum amount of time for the runtime to wait for the remote function to return before failing.
+    * Default: 1 min
+
+### Full Example
+
+{% highlight yaml %}
+version: "2.0"
+
+module:
+  meta:
+    type: remote
+  spec:
+    functions:
+      - function:
+        meta:
+          kind: http
+          type: example/greeter
+        spec:
+          endpoint: http://<host-name>/statefun
+          states:
+            - name: seen_count
+              expireAfter: 5min
+          maxNumBatchRequests: 500
+          timeout: 2min
+{% endhighlight %}
+
+## Embedded Module
+
+Embedded modules are co-located with, and embedded within, the Apache Flink® runtime.
+
+This module type only supports JVM-based languages and is defined by implementing the ``StatefulFunctionModule`` interface.
+Embedded modules offer a single configuration method where stateful functions bind to the system based on their
+[function type]({{ site.baseurl }}/concepts/logical.html#function-address).
+Runtime configurations are available through the ``globalConfiguration``, which is the union of all configurations
+in the applications ``flink-conf.yaml`` under the prefix ``statefun.module.global-config``, and any command line
+arguments passed in the form ``--key value``.
+
+{% highlight java %}
+package org.apache.flink.statefun.docs;
+
+import java.util.Map;
+import org.apache.flink.statefun.sdk.spi.StatefulFunctionModule;
+
+public class BasicFunctionModule implements StatefulFunctionModule {
+
+	public void configure(Map<String, String> globalConfiguration, Binder binder) {
+
+		// Declare the user function and bind it to its type
+		binder.bindFunctionProvider(FnWithDependency.TYPE, new CustomProvider());
+
+		// Stateful functions that do not require any configuration
+		// can declare their provider using java 8 lambda syntax
+		binder.bindFunctionProvider(Identifiers.HELLO_TYPE, unused -> new FnHelloWorld());
+	}
+}
+{% endhighlight %}
+
+Embedded modules leverage [Java’s Service Provider Interfaces (SPI)](https://docs.oracle.com/javase/8/docs/api/java/util/ServiceLoader.html) for discovery.
+This means that every JAR should contain a file ``org.apache.flink.statefun.sdk.spi.StatefulFunctionModule`` in the ``META_INF/services`` resource directory that lists all available modules that it provides.
+
+{% highlight none %}
+org.apache.flink.statefun.docs.BasicFunctionModule
+{% endhighlight %}
+
diff --git a/docs/sdk/modules.md b/docs/sdk/modules.md
deleted file mode 100644
index bea3aa6..0000000
--- a/docs/sdk/modules.md
+++ /dev/null
@@ -1,131 +0,0 @@
----
-title: Modules 
-nav-id: modules
-nav-pos: 3
-nav-title: Modules
-nav-parent_id: sdk
----
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements.  See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership.  The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License.  You may obtain a copy of the License at
-
-  http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied.  See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-
-Stateful Functions applications are composed of one or more modules.
-A module is a bundle of functions that are loaded by the runtime and available to be messaged.
-Functions from all loaded modules are multiplexed and free to message each other arbitrarily.
-
-Stateful Functions supports two types of modules: Embedded and Remote.
-
-* This will be replaced by the TOC
-{:toc}
-
-## Embedded Module
-
-Embedded modules are co-located with, and embedded within, the Apache Flink® runtime.
-
-This module type only supports JVM based languages and are defined by implementing the ``StatefulFunctionModule`` interface.
-Embedded modules offer a single configuration method where stateful functions are bound to the system based on their [function type]({{ site.baseurl }}/concepts/logical.html#function-address).
-Runtime configurations are available through the ``globalConfiguration``, which is the union of all configurations in the applications ``flink-conf.yaml`` under the prefix ``statefun.module.global-config`` and any command line arguments passed in the form ``--key value``.
-
-{% highlight java %}
-package org.apache.flink.statefun.docs;
-
-import java.util.Map;
-import org.apache.flink.statefun.sdk.spi.StatefulFunctionModule;
-
-public class BasicFunctionModule implements StatefulFunctionModule {
-
-	public void configure(Map<String, String> globalConfiguration, Binder binder) {
-
-		// Declare the user function and bind it to its type
-		binder.bindFunctionProvider(FnWithDependency.TYPE, new CustomProvider());
-
-		// Stateful functions that do not require any configuration
-		// can declare their provider using java 8 lambda syntax
-		binder.bindFunctionProvider(Identifiers.HELLO_TYPE, unused -> new FnHelloWorld());
-	}
-}
-{% endhighlight %}
-
-Embedded modules leverage [Java’s Service Provider Interfaces (SPI)](https://docs.oracle.com/javase/8/docs/api/java/util/ServiceLoader.html) for discovery.
-This means that every JAR should contain a file ``org.apache.flink.statefun.sdk.spi.StatefulFunctionModule`` in the ``META_INF/services`` resource directory that lists all available modules that it provides.
-
-{% highlight none %}
-org.apache.flink.statefun.docs.BasicFunctionModule
-{% endhighlight %}
-
-## Remote Module
-
-Remote modules are run as external processes from the Apache Flink® runtime; in the same container, as a sidecar, or other external location.
-
-This module type can support any number of language SDKs.
-Remote modules are registered with the system via ``YAML`` configuration files.
-
-### Specification
-
-A remote module configuration consists of a ``meta`` section and a ``spec`` section.
-``meta`` contains auxillary information about the module.
-The ``spec`` describes the functions contained within the module and defines their persisted values.
-
-### Defining Functions
-
-``module.spec.functions`` declares a list of ``function`` objects that are implemented by the remote module.
-A ``function`` is described via a number of properties.
-
-* ``function.meta.kind``
-    * The protocol used to communicate with the remote function.
-    * Supported Values - ``http``
-* ``function.meta.type``
-    * The function type, defined as ``<namespace>/<name>``.
-* ``function.spec.endpoint``
-    * The endpoint at which the function is reachable.
-    * Supported schemes are: ``http``, ``https``.
-    * Transport via UNIX domain sockets is supported by using the schemes ``http+unix`` or ``https+unix``.
-    * When using UNIX domain sockets, the endpoint format is: ``http+unix://<socket-file-path>/<serve-url-path>``. For example, ``http+unix:///uds.sock/path/of/url``.
-* ``function.spec.states``
-    * A list of the persisted values declared within the remote function.
-    * Each entry consists of a `name` property and an optional `expireAfter` property.
-    * Default for `expireAfter` - 0, meaning that state expiration is disabled.
-* ``function.spec.maxNumBatchRequests``
-    * The maximum number of records that can be processed by a function for a particular ``address`` before invoking backpressure on the system.
-    * Default - 1000
-* ``function.spec.timeout``
-    * The maximum amount of time for the runtime to wait for the remote function to return before failing.
-    * Default - 1 min
-
-### Full Example
-
-{% highlight yaml %}
-version: "2.0"
-
-module:
-  meta:
-    type: remote
-  spec:
-    functions:
-      - function:
-        meta:
-          kind: http
-          type: example/greeter
-        spec:
-          endpoint: http://<host-name>/statefun
-          states:
-            - name: seen_count
-              expireAfter: 5min
-          maxNumBatchRequests: 500
-          timeout: 2min
-{% endhighlight %}


[flink-statefun] 03/05: [FLINK-18979][docs] Default to remote modules in connectors

Posted by tz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

tzulitai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink-statefun.git

commit 4a86dbe35d68e19c2666d4db7ec61d99a3a9a39e
Author: Seth Wiesman <sj...@gmail.com>
AuthorDate: Mon Aug 17 14:22:12 2020 -0500

    [FLINK-18979][docs] Default to remote modules in connectors
---
 docs/io-module/apache-kafka.md     | 186 +++++++++++++++++-----------------
 docs/io-module/aws-kinesis.md      | 198 ++++++++++++++++++-------------------
 docs/io-module/flink-connectors.md |   2 +-
 docs/io-module/index.md            |  82 +++++++--------
 4 files changed, 234 insertions(+), 234 deletions(-)

diff --git a/docs/io-module/apache-kafka.md b/docs/io-module/apache-kafka.md
index 91146cc..9b47169 100644
--- a/docs/io-module/apache-kafka.md
+++ b/docs/io-module/apache-kafka.md
@@ -59,32 +59,6 @@ It accepts the following arguments:
 6. The position to start consuming from
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-package org.apache.flink.statefun.docs.io.kafka;
-
-import org.apache.flink.statefun.docs.models.User;
-import org.apache.flink.statefun.sdk.io.IngressIdentifier;
-import org.apache.flink.statefun.sdk.io.IngressSpec;
-import org.apache.flink.statefun.sdk.kafka.KafkaIngressBuilder;
-import org.apache.flink.statefun.sdk.kafka.KafkaIngressStartupPosition;
-
-public class IngressSpecs {
-
-  public static final IngressIdentifier<User> ID =
-      new IngressIdentifier<>(User.class, "example", "input-ingress");
-
-  public static final IngressSpec<User> kafkaIngress =
-      KafkaIngressBuilder.forIdentifier(ID)
-          .withKafkaAddress("localhost:9092")
-          .withConsumerGroupId("greetings")
-          .withTopic("my-topic")
-          .withDeserializer(UserDeserializer.class)
-          .withStartupPosition(KafkaIngressStartupPosition.fromLatest())
-          .build();
-}
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 version: "1.0"
@@ -111,6 +85,32 @@ spec:
                   - example-namespace/my-function-2
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+package org.apache.flink.statefun.docs.io.kafka;
+
+import org.apache.flink.statefun.docs.models.User;
+import org.apache.flink.statefun.sdk.io.IngressIdentifier;
+import org.apache.flink.statefun.sdk.io.IngressSpec;
+import org.apache.flink.statefun.sdk.kafka.KafkaIngressBuilder;
+import org.apache.flink.statefun.sdk.kafka.KafkaIngressStartupPosition;
+
+public class IngressSpecs {
+
+  public static final IngressIdentifier<User> ID =
+      new IngressIdentifier<>(User.class, "example", "input-ingress");
+
+  public static final IngressSpec<User> kafkaIngress =
+      KafkaIngressBuilder.forIdentifier(ID)
+          .withKafkaAddress("localhost:9092")
+          .withConsumerGroupId("greetings")
+          .withTopic("my-topic")
+          .withDeserializer(UserDeserializer.class)
+          .withStartupPosition(KafkaIngressStartupPosition.fromLatest())
+          .build();
+}
+{% endhighlight %}
+</div>
 </div>
 
 The ingress also accepts properties to directly configure the Kafka client, using ``KafkaIngressBuilder#withProperties(Properties)``.
@@ -126,17 +126,17 @@ The ingress allows configuring the startup position to be one of the following:
 Starts from offsets that were committed to Kafka for the specified consumer group.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KafkaIngressStartupPosition#fromGroupOffsets();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 startupPosition:
     type: group-offsets
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KafkaIngressStartupPosition#fromGroupOffsets();
+{% endhighlight %}
+</div>
 </div>
 
 #### Earlist
@@ -144,17 +144,17 @@ startupPosition:
 Starts from the earliest offset.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KafkaIngressStartupPosition#fromEarliest();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 startupPosition:
     type: earliest
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KafkaIngressStartupPosition#fromEarliest();
+{% endhighlight %}
+</div>
 </div>
 
 #### Latest
@@ -162,17 +162,17 @@ startupPosition:
 Starts from the latest offset.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KafkaIngressStartupPosition#fromLatest();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 startupPosition:
     type: latest
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KafkaIngressStartupPosition#fromLatest();
+{% endhighlight %}
+</div>
 </div>
 
 #### Specific Offsets
@@ -180,16 +180,6 @@ startupPosition:
 Starts from specific offsets, defined as a map of partitions to their target starting offset.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-Map<TopicPartition, Long> offsets = new HashMap<>();
-offsets.add(new TopicPartition("user-topic", 0), 91);
-offsets.add(new TopicPartition("user-topic", 11), 11);
-offsets.add(new TopicPartition("user-topic", 8), 8);
-
-KafkaIngressStartupPosition#fromSpecificOffsets(offsets);
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 startupPosition:
@@ -200,6 +190,16 @@ startupPosition:
         - user-topic/2: 8
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+Map<TopicPartition, Long> offsets = new HashMap<>();
+offsets.add(new TopicPartition("user-topic", 0), 91);
+offsets.add(new TopicPartition("user-topic", 11), 11);
+offsets.add(new TopicPartition("user-topic", 8), 8);
+
+KafkaIngressStartupPosition#fromSpecificOffsets(offsets);
+{% endhighlight %}
+</div>
 </div>
 
 #### Date
@@ -207,11 +207,6 @@ startupPosition:
 Starts from offsets that have an ingestion time larger than or equal to a specified date.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KafkaIngressStartupPosition#fromDate(ZonedDateTime.now());
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 startupPosition:
@@ -219,6 +214,11 @@ startupPosition:
     date: 2020-02-01 04:15:00.00 Z
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KafkaIngressStartupPosition#fromDate(ZonedDateTime.now());
+{% endhighlight %}
+</div>
 </div>
 
 On startup, if the specified startup offset for a partition is out-of-range or does not exist (which may be the case if the ingress is configured to start from group offsets, specific offsets, or from a date), then the ingress will fallback to using the position configured using ``KafkaIngressBuilder#withAutoOffsetResetPosition(KafkaIngressAutoResetPosition)``.
@@ -272,28 +272,6 @@ It accepts the following arguments:
 5. Properties for the Kafka producer
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-package org.apache.flink.statefun.docs.io.kafka;
-
-import org.apache.flink.statefun.docs.models.User;
-import org.apache.flink.statefun.sdk.io.EgressIdentifier;
-import org.apache.flink.statefun.sdk.io.EgressSpec;
-import org.apache.flink.statefun.sdk.kafka.KafkaEgressBuilder;
-
-public class EgressSpecs {
-
-  public static final EgressIdentifier<User> ID =
-      new EgressIdentifier<>("example", "output-egress", User.class);
-
-  public static final EgressSpec<User> kafkaEgress =
-      KafkaEgressBuilder.forIdentifier(ID)
-          .withKafkaAddress("localhost:9092")
-          .withSerializer(UserSerializer.class)
-          .build();
-}
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 version: "1.0"
@@ -316,6 +294,28 @@ spec:
               - foo.config: bar
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+package org.apache.flink.statefun.docs.io.kafka;
+
+import org.apache.flink.statefun.docs.models.User;
+import org.apache.flink.statefun.sdk.io.EgressIdentifier;
+import org.apache.flink.statefun.sdk.io.EgressSpec;
+import org.apache.flink.statefun.sdk.kafka.KafkaEgressBuilder;
+
+public class EgressSpecs {
+
+  public static final EgressIdentifier<User> ID =
+      new EgressIdentifier<>("example", "output-egress", User.class);
+
+  public static final EgressSpec<User> kafkaEgress =
+      KafkaEgressBuilder.forIdentifier(ID)
+          .withKafkaAddress("localhost:9092")
+          .withSerializer(UserSerializer.class)
+          .build();
+}
+{% endhighlight %}
+</div>
 </div>
 
 Please refer to the Kafka [producer configuration](https://docs.confluent.io/current/installation/configuration/producer-configs.html) documentation for the full list of available properties.
@@ -330,17 +330,17 @@ You can choose three different modes of operation.
 Nothing is guaranteed, produced records can be lost or duplicated.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KafkaEgressBuilder#withNoProducerSemantics();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 deliverySemantic:
     type: none
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KafkaEgressBuilder#withNoProducerSemantics();
+{% endhighlight %}
+</div>
 </div>
 
 #### At Least Once
@@ -348,17 +348,17 @@ deliverySemantic:
 Stateful Functions will guarantee that no records will be lost but they can be duplicated.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KafkaEgressBuilder#withAtLeastOnceProducerSemantics();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 deliverySemantic:
     type: at-least-once
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KafkaEgressBuilder#withAtLeastOnceProducerSemantics();
+{% endhighlight %}
+</div>
 </div>
 
 #### Exactly Once
@@ -366,11 +366,6 @@ deliverySemantic:
 Stateful Functions uses Kafka transactions to provide exactly-once semantics.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KafkaEgressBuilder#withExactlyOnceProducerSemantics(Duration.minutes(15));
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 deliverySemantic:
@@ -378,6 +373,11 @@ deliverySemantic:
     transactionTimeoutMillis: 900000 # 15 min
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KafkaEgressBuilder#withExactlyOnceProducerSemantics(Duration.minutes(15));
+{% endhighlight %}
+</div>
 </div>
 
 ### Kafka Serializer
diff --git a/docs/io-module/aws-kinesis.md b/docs/io-module/aws-kinesis.md
index 1975004..b9fc52a 100644
--- a/docs/io-module/aws-kinesis.md
+++ b/docs/io-module/aws-kinesis.md
@@ -59,34 +59,6 @@ It accepts the following arguments:
 6. The name of the stream to consume from
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-package org.apache.flink.statefun.docs.io.kinesis;
-
-import org.apache.flink.statefun.docs.models.User;
-import org.apache.flink.statefun.sdk.io.IngressIdentifier;
-import org.apache.flink.statefun.sdk.io.IngressSpec;
-import org.apache.flink.statefun.sdk.kinesis.auth.AwsCredentials;
-import org.apache.flink.statefun.sdk.kinesis.ingress.KinesisIngressBuilder;
-import org.apache.flink.statefun.sdk.kinesis.ingress.KinesisIngressStartupPosition;
-
-public class IngressSpecs {
-
-  public static final IngressIdentifier<User> ID =
-      new IngressIdentifier<>(User.class, "example", "input-ingress");
-
-  public static final IngressSpec<User> kinesisIngress =
-      KinesisIngressBuilder.forIdentifier(ID)
-          .withAwsRegion("us-west-1")
-          .withAwsCredentials(AwsCredentials.fromDefaultProviderChain())
-          .withDeserializer(UserDeserializer.class)
-          .withStream("stream-name")
-          .withStartupPosition(KinesisIngressStartupPosition.fromEarliest())
-          .withClientConfigurationProperty("key", "value")
-          .build();
-}
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 version: "1.0"
@@ -125,6 +97,34 @@ module:
                   - MaxConnections: 15
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+package org.apache.flink.statefun.docs.io.kinesis;
+
+import org.apache.flink.statefun.docs.models.User;
+import org.apache.flink.statefun.sdk.io.IngressIdentifier;
+import org.apache.flink.statefun.sdk.io.IngressSpec;
+import org.apache.flink.statefun.sdk.kinesis.auth.AwsCredentials;
+import org.apache.flink.statefun.sdk.kinesis.ingress.KinesisIngressBuilder;
+import org.apache.flink.statefun.sdk.kinesis.ingress.KinesisIngressStartupPosition;
+
+public class IngressSpecs {
+
+  public static final IngressIdentifier<User> ID =
+      new IngressIdentifier<>(User.class, "example", "input-ingress");
+
+  public static final IngressSpec<User> kinesisIngress =
+      KinesisIngressBuilder.forIdentifier(ID)
+          .withAwsRegion("us-west-1")
+          .withAwsCredentials(AwsCredentials.fromDefaultProviderChain())
+          .withDeserializer(UserDeserializer.class)
+          .withStream("stream-name")
+          .withStartupPosition(KinesisIngressStartupPosition.fromEarliest())
+          .withClientConfigurationProperty("key", "value")
+          .build();
+}
+{% endhighlight %}
+</div>
 </div>
 
 The ingress also accepts properties to directly configure the Kinesis client, using ``KinesisIngressBuilder#withClientConfigurationProperty()``.
@@ -140,17 +140,17 @@ The ingress allows configuring the startup position to be one of the following:
 Start consuming from the latest position, i.e. head of the stream shards.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KinesisIngressStartupPosition#fromLatest();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 startupPosition:
     type: latest
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KinesisIngressStartupPosition#fromLatest();
+{% endhighlight %}
+</div>
 </div>
 
 #### Earlist
@@ -158,17 +158,17 @@ startupPosition:
 Start consuming from the earliest position possible.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KinesisIngressStartupPosition#fromEarliest();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 startupPosition:
     type: earliest
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KinesisIngressStartupPosition#fromEarliest();
+{% endhighlight %}
+</div>
 </div>
 
 #### Date
@@ -176,11 +176,6 @@ startupPosition:
 Starts from offsets that have an ingestion time larger than or equal to a specified date.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-KinesisIngressStartupPosition#fromDate(ZonedDateTime.now());
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 startupPosition:
@@ -188,6 +183,11 @@ startupPosition:
     date: 2020-02-01 04:15:00.00 Z
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+KinesisIngressStartupPosition#fromDate(ZonedDateTime.now());
+{% endhighlight %}
+</div>
 </div>
 
 ### Kinesis Deserializer
@@ -239,32 +239,6 @@ It accepts the following arguments:
 6. The number of max outstanding records before backpressure is applied
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-package org.apache.flink.statefun.docs.io.kinesis;
-
-import org.apache.flink.statefun.docs.models.User;
-import org.apache.flink.statefun.sdk.io.EgressIdentifier;
-import org.apache.flink.statefun.sdk.io.EgressSpec;
-import org.apache.flink.statefun.sdk.kinesis.auth.AwsCredentials;
-import org.apache.flink.statefun.sdk.kinesis.egress.KinesisEgressBuilder;
-
-public class EgressSpecs {
-
-  public static final EgressIdentifier<User> ID =
-      new EgressIdentifier<>("example", "output-egress", User.class);
-
-  public static final EgressSpec<User> kinesisEgress =
-      KinesisEgressBuilder.forIdentifier(ID)
-          .withAwsCredentials(AwsCredentials.fromDefaultProviderChain())
-          .withAwsRegion("us-west-1")
-          .withMaxOutstandingRecords(100)
-          .withClientConfigurationProperty("key", "value")
-          .withSerializer(UserSerializer.class)
-          .build();
-}
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 version: "1.0"
@@ -293,6 +267,32 @@ module:
                   - ThreadPoolSize: 10
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+package org.apache.flink.statefun.docs.io.kinesis;
+
+import org.apache.flink.statefun.docs.models.User;
+import org.apache.flink.statefun.sdk.io.EgressIdentifier;
+import org.apache.flink.statefun.sdk.io.EgressSpec;
+import org.apache.flink.statefun.sdk.kinesis.auth.AwsCredentials;
+import org.apache.flink.statefun.sdk.kinesis.egress.KinesisEgressBuilder;
+
+public class EgressSpecs {
+
+  public static final EgressIdentifier<User> ID =
+      new EgressIdentifier<>("example", "output-egress", User.class);
+
+  public static final EgressSpec<User> kinesisEgress =
+      KinesisEgressBuilder.forIdentifier(ID)
+          .withAwsCredentials(AwsCredentials.fromDefaultProviderChain())
+          .withAwsRegion("us-west-1")
+          .withMaxOutstandingRecords(100)
+          .withClientConfigurationProperty("key", "value")
+          .withSerializer(UserSerializer.class)
+          .build();
+}
+{% endhighlight %}
+</div>
 </div>
 
 Please refer to the Kinesis [producer default configuration properties](https://github.com/awslabs/amazon-kinesis-producer/blob/master/java/amazon-kinesis-producer-sample/default_config.properties) documentation for the full list of available properties.
@@ -347,17 +347,17 @@ Both the Kinesis ingress and egress can be configured to a specific AWS region.
 Consults AWS's default provider chain to determine the AWS region.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-AwsRegion.fromDefaultProviderChain();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 awsCredentials:
     type: default
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+AwsRegion.fromDefaultProviderChain();
+{% endhighlight %}
+</div>
 </div>
 
 #### Specific
@@ -365,11 +365,6 @@ awsCredentials:
 Specifies an AWS region using the region's unique id.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-AwsRegion.of("us-west-1");
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 awsCredentials:
@@ -377,6 +372,11 @@ awsCredentials:
     id: us-west-1
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+AwsRegion.of("us-west-1");
+{% endhighlight %}
+</div>
 </div>
 
 
@@ -386,11 +386,6 @@ Connects to an AWS region through a non-standard AWS service endpoint.
 This is typically used only for development and testing purposes.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-AwsRegion.ofCustomEndpoint("https://localhost:4567", "us-west-1");
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 awsCredentials:
@@ -399,6 +394,11 @@ awsCredentials:
     id: us-west-1
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+AwsRegion.ofCustomEndpoint("https://localhost:4567", "us-west-1");
+{% endhighlight %}
+</div>
 </div>
 
 ## AWS Credentials
@@ -410,17 +410,17 @@ Both the Kinesis ingress and egress can be configured using standard AWS credent
 Consults AWS’s default provider chain to determine the AWS credentials.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-AwsCredentials.fromDefaultProviderChain();
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 awsCredentials:
     type: default
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+AwsCredentials.fromDefaultProviderChain();
+{% endhighlight %}
+</div>
 </div>
 
 #### Basic
@@ -428,11 +428,6 @@ awsCredentials:
 Specifies the AWS credentials directly with provided access key ID and secret access key strings.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-AwsCredentials.basic("accessKeyId", "secretAccessKey");
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 awsCredentials:
@@ -441,6 +436,11 @@ awsCredentials:
     secretAccessKey: secret-access-key
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+AwsCredentials.basic("accessKeyId", "secretAccessKey");
+{% endhighlight %}
+</div>
 </div>
 
 #### Profile
@@ -448,11 +448,6 @@ awsCredentials:
 Specifies the AWS credentials using an AWS configuration profile, along with the profile's configuration path.
 
 <div class="codetabs" markdown="1">
-<div data-lang="Embedded Module" markdown="1">
-{% highlight java %}
-AwsCredentials.profile("profile-name", "/path/to/profile/config");
-{% endhighlight %}
-</div>
 <div data-lang="Remote Module" markdown="1">
 {% highlight yaml %}
 awsCredentials:
@@ -461,5 +456,10 @@ awsCredentials:
     profilePath: /path/to/profile/config
 {% endhighlight %}
 </div>
+<div data-lang="Embedded Module" markdown="1">
+{% highlight java %}
+AwsCredentials.profile("profile-name", "/path/to/profile/config");
+{% endhighlight %}
+</div>
 </div>
 
diff --git a/docs/io-module/flink-connectors.md b/docs/io-module/flink-connectors.md
index dac8c2a..5856845 100644
--- a/docs/io-module/flink-connectors.md
+++ b/docs/io-module/flink-connectors.md
@@ -26,7 +26,7 @@ under the License.
 
 
 The source-sink I/O module allows you to plug in existing, or custom, Flink connectors that are not already integrated into a dedicated I/O module.
-For details details of how to build a custom connector see the official [Apache Flink documentation](https://ci.apache.org/projects/flink/flink-docs-stable).
+For details of how to build a custom connector see the official [Apache Flink documentation](https://ci.apache.org/projects/flink/flink-docs-stable).
 
 * This will be replaced by the TOC
 {:toc}
diff --git a/docs/io-module/index.md b/docs/io-module/index.md
index 9da09c1..b60c530 100644
--- a/docs/io-module/index.md
+++ b/docs/io-module/index.md
@@ -42,6 +42,22 @@ An ingress identifier, similar to a function type, uniquely identifies an ingres
 The spec defines the details of how to connect to the external system, which is specific to each individual I/O module. Each identifier-spec pair is bound to the system inside an stateful function module.
 
 <div class="codetabs" markdown="1">
+<div data-lang="Remote Module" markdown="1">
+{% highlight yaml %}
+version: "1.0"
+
+module:
+     meta:
+         type: remote
+     spec:
+         ingresses:
+           - ingress:
+               meta:
+                 id: example/user-ingress
+                 type: # ingress type
+               spec: # ingress specific configurations
+{% endhighlight %}
+</div>
 <div data-lang="Embedded Module" markdown="1">
 {% highlight java %}
 package org.apache.flink.statefun.docs.io.ingress;
@@ -79,22 +95,6 @@ public class ModuleWithIngress implements StatefulFunctionModule {
 }
 {% endhighlight %}
 </div>
-<div data-lang="Remote Module" markdown="1">
-{% highlight yaml %}
-version: "1.0"
-
-module:
-     meta:
-         type: remote
-     spec:
-         ingresses:
-           - ingress:
-               meta:
-                 id: example/user-ingress
-                 type: # ingress type
-               spec: # ingress specific configurations
-{% endhighlight %}
-</div>
 </div>
 
 ## Router
@@ -103,6 +103,15 @@ A router is a stateless operator that takes each record from an ingress and rout
 Routers are bound to the system via a stateful function module, and unlike other components, an ingress may have any number of routers.
 
 <div class="codetabs" markdown="1">
+<div data-lang="Remote Module" markdown="1">
+When defined in ``yaml``, routers are defined by a list of function types.
+The ``id`` component of the address is pulled from the key associated with each record in its underlying source implementation.
+{% highlight yaml %}
+targets:
+    - example-namespace/my-function-1
+    - example-namespace/my-function-2
+{% endhighlight %}
+</div>
 <div data-lang="Embedded Module" markdown="1">
 {% highlight java %}
 package org.apache.flink.statefun.docs.io.ingress;
@@ -146,15 +155,6 @@ public class ModuleWithRouter implements StatefulFunctionModule {
 }
 {% endhighlight %}
 </div>
-<div data-lang="Remote Module" markdown="1">
-When defined in ``yaml``, routers are defined by a list of function types.
-The ``id`` component of the address is pulled from the key associated with each record in its underlying source implementation.
-{% highlight yaml %}
-targets:
-    - example-namespace/my-function-1
-    - example-namespace/my-function-2
-{% endhighlight %}
-</div>
 </div>
 
 ## Egress
@@ -167,6 +167,22 @@ An egress spec defines the details of how to connect to the external system, the
 Each identifier-spec pair are bound to the system inside a stateful function module.
 
 <div class="codetabs" markdown="1">
+<div data-lang="Remote Module" markdown="1">
+{% highlight yaml %}
+version: "1.0"
+
+module:
+    meta:
+        type: remote
+    spec:
+        egresses:
+          - egress:
+              meta:
+                id: example/user-egress
+                type: # egress type
+              spec: # egress specific configurations
+{% endhighlight %}
+</div>
 <div data-lang="Embedded Module" markdown="1">
 {% highlight java %}
 package org.apache.flink.statefun.docs.io.egress;
@@ -205,22 +221,6 @@ public class ModuleWithEgress implements StatefulFunctionModule {
 }
 {% endhighlight %}
 </div>
-<div data-lang="Remote Module" markdown="1">
-{% highlight yaml %}
-version: "1.0"
-
-module:
-    meta:
-        type: remote
-    spec:
-        egresses:
-          - egress:
-              meta:
-                id: example/user-egress
-                type: # egress type
-              spec: # egress specific configurations
-{% endhighlight %}
-</div>
 </div>
 
 Stateful functions may then message an egress the same way they message another function, passing the egress identifier as function type.


[flink-statefun] 04/05: [FLINK-18979][docs] Update homepage introduction

Posted by tz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

tzulitai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink-statefun.git

commit 10df361a41ef343efb0cd1b9508ea0df64f2dfb1
Author: Seth Wiesman <sj...@gmail.com>
AuthorDate: Mon Aug 17 14:22:31 2020 -0500

    [FLINK-18979][docs] Update homepage introduction
---
 docs/index.md | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/docs/index.md b/docs/index.md
index 4a29a7b..41ec8c3 100644
--- a/docs/index.md
+++ b/docs/index.md
@@ -23,16 +23,19 @@ specific language governing permissions and limitations
 under the License.
 -->
 
-**Stateful Functions** is an open source framework that reduces the complexity of building and orchestrating distributed stateful applications at scale.
-It brings together the benefits of stream processing with Apache Flink® and Function-as-a-Service (FaaS) to provide a powerful abstraction for the next generation of event-driven architectures.
+Stateful Functions is an API that simplifies the building of **distributed stateful applications** with a **runtime built for serverless architectures**.
+It brings together the benefits of stateful stream processing - the processing of large datasets with low latency and bounded resource constraints -
+along with a runtime for modeling stateful entities that supports location transparency, concurrency, scaling, and resiliency. 
 
 <p class="text-center">
-  <img width="80%" src="{{ site.baseurl }}/fig/stateful_functions.png"/>
+    <img width="80%" src="{{ site.baseurl }}/fig/concepts/arch_overview.svg"/>
 </p>
 
-There are many ways to get started with Stateful Functions.
-Which one is the best for you depends on your goals and prior experience.
-Whether you prefer a more theoretical or a practical approach, we hope you’ll find this section helpful.
+It is designed to work with modern architectures, like cloud-native deployments and popular event-driven FaaS platforms 
+like AWS Lambda and KNative, and to provide out-of-the-box consistent state and messaging while preserving the serverless
+experience and elasticity of these platforms.
+
+Stateful Functions is developed under the umbrella of [Apache Flink](flink.apache.org).
 
 ## Learn By Doing
 
@@ -44,7 +47,6 @@ It provides a step by step introduction to the API and guides you through real a
 If you prefer to learn concepts step by step, start with our guide to [main concepts]({{ site.baseurl }}/concepts/application-building-blocks.html).
 It will walk you through all the API's and concepts to build advanced stateful systems.
 
-
 ## Start A New Project
 
 The [project setup]({{ site.baseurl }}/getting-started/project-setup.html) instructions show you how to create a project for a new Stateful Functions application in just a few steps.


[flink-statefun] 05/05: [FLINK-18979][docs] Update READMEs

Posted by tz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

tzulitai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink-statefun.git

commit c4831843ded974234854abd20b7875e31e8fb81e
Author: Seth Wiesman <sj...@gmail.com>
AuthorDate: Fri Aug 21 13:34:20 2020 -0500

    [FLINK-18979][docs] Update READMEs
    
    This closes #132.
---
 README.md                     | 12 ++++++++++--
 statefun-python-sdk/README.md | 12 ++++++++++--
 2 files changed, 20 insertions(+), 4 deletions(-)

diff --git a/README.md b/README.md
index 0a7cbd6..23619fd 100755
--- a/README.md
+++ b/README.md
@@ -1,8 +1,16 @@
 <img alt="Stateful Functions" src="docs/fig/stateful_functions_logo.png" width=350px/>
 
-Stateful Functions is an [Apache Flink](https://flink.apache.org/) library that **simplifies building distributed stateful applications**. It's based on functions with persistent state that can interact dynamically with strong consistency guarantees.
+Stateful Functions is an API that simplifies the building of **distributed stateful applications** with a **runtime built for serverless architectures**.
+It brings together the benefits of stateful stream processing - the processing of large datasets with low latency and bounded resource constraints -
+along with a runtime for modeling stateful entities that supports location transparency, concurrency, scaling, and resiliency. 
 
-Stateful Functions makes it possible to combine a powerful approach to state and composition with the elasticity, rapid scaling/scale-to-zero and rolling upgrade capabilities of FaaS implementations like AWS Lambda and modern resource orchestration frameworks like Kubernetes. With these features, it addresses [two of the most cited shortcomings](https://www2.eecs.berkeley.edu/Pubs/TechRpts/2019/EECS-2019-3.pdf) of many FaaS setups today: consistent state and efficient messaging between f [...]
+<img alt="Stateful Functions Architecture" width="80%" src="docs/fig/concepts/arch_overview.svg">
+
+It is designed to work with modern architectures, like cloud-native deployments and popular event-driven FaaS platforms 
+like AWS Lambda and KNative, and to provide out-of-the-box consistent state and messaging while preserving the serverless
+experience and elasticity of these platforms.
+
+Stateful Functions is developed under the umbrella of [Apache Flink](https://flink.apache.org/).
 
 This README is meant as a brief walkthrough on the core concepts and how to set things up
 to get yourself started with Stateful Functions.
diff --git a/statefun-python-sdk/README.md b/statefun-python-sdk/README.md
index f6ad972..a39294b 100755
--- a/statefun-python-sdk/README.md
+++ b/statefun-python-sdk/README.md
@@ -1,8 +1,16 @@
 # Apache Flink Stateful Functions
 
-Stateful Functions is an [Apache Flink](https://flink.apache.org/) library that **simplifies building distributed stateful applications**. It's based on functions with persistent state that can interact dynamically with strong consistency guarantees.
+Stateful Functions is an API that simplifies the building of **distributed stateful applications** with a **runtime built for serverless architectures**.
+It brings together the benefits of stateful stream processing - the processing of large datasets with low latency and bounded resource constraints -
+along with a runtime for modeling stateful entities that supports location transparency, concurrency, scaling, and resiliency. 
 
-Stateful Functions makes it possible to combine a powerful approach to state and composition with the elasticity, rapid scaling/scale-to-zero and rolling upgrade capabilities of FaaS implementations like AWS Lambda and modern resource orchestration frameworks like Kubernetes. With these features, it addresses [two of the most cited shortcomings](https://www2.eecs.berkeley.edu/Pubs/TechRpts/2019/EECS-2019-3.pdf) of many FaaS setups today: consistent state and efficient messaging between f [...]
+<img alt="Stateful Functions Architecture" width="80%" src="../docs/fig/concepts/arch_overview.svg">
+
+It is designed to work with modern architectures, like cloud-native deployments and popular event-driven FaaS platforms 
+like AWS Lambda and KNative, and to provide out-of-the-box consistent state and messaging while preserving the serverless
+experience and elasticity of these platforms.
+
+Stateful Functions is developed under the umbrella of [Apache Flink](https://flink.apache.org/).
 
 This README is meant as a brief walkthrough on the StateFun Python SDK and how to set things up
 to get yourself started with Stateful Functions in Python.