Skip to content

Commit

Permalink
doc: Update front page (#3544)
Browse files Browse the repository at this point in the history
  • Loading branch information
xerial authored May 31, 2024
1 parent a30f942 commit 26e62c5
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 45 deletions.
8 changes: 1 addition & 7 deletions docs/airframe-di.md
Original file line number Diff line number Diff line change
Expand Up @@ -615,13 +615,7 @@ display the lifecycle of AirframeSession and the injected objects:

## Use Cases

This page illustrates typical use cases of Airframe.

- [Configuring Applications](#configuring-applications)
- [Managing Resources](#managing-resources)
- [Factory Binding](#factory-binding)
- [Service Mix-In](#service-mix-in)
- [Override Bindings](#override-bindings)
This page illustrates typical use cases of Airframe DI.

### Configuring Applications

Expand Down
2 changes: 1 addition & 1 deletion docs/airframe-rx.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ counter := 2
// <div>count: 2</div>
```

`Rx[A]` represents a reactive component which will be updated if there is any change in its upstream operators. In this example, we are chaining actions (map operator, etc.) based on the current state of `counter` variable. These actions are observing the state of the variable, and if the `counter` variable is updated, the registered actions will be triggered. [airframe-rx-html](airframe-rx-html.md) uses this pattern a lot to build flexible UI code in [Scala.js](https://www.scala-js.org), which will be compiled to JavaScripts so that we can use Scala for web browsers.
`Rx[A]` represents a reactive component which will be updated if there is any change in its upstream operators. In this example, we are chaining actions (map operator, etc.) based on the current state of `counter` variable. These actions are observing the state of the variable, and if the `counter` variable is updated, the registered actions will be triggered. airframe-rx-html uses this pattern a lot to build flexible UI code in [Scala.js](https://www.scala-js.org), which will be compiled to JavaScripts so that we can use Scala for web browsers.

### Backend Programming

Expand Down
4 changes: 2 additions & 2 deletions docs/comparison.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ The chart below shows major features supported in selected DI frameworks. For co
| Auto-wiring |||| (Manual wiring) |
| Compile-time dependency check | | |||
| Dynamic-type binding ||| | ✓ (using [implicit parameters](https://gist.github.com/gvolpe/1454db0ed9476ed0189dcc016fd758aa#the-fp-way-2)) |
| [Constructor injection](airframe-di.md#bind) || ✓ (Require `@Inject` annotation) || ✓ (manual argument passing) |
| [In-trait injection](airframe-di.md#bind) (mix-in support) || (Java has no trait) || ✓ (manual override) |
| [Constructor injection](airframe-di.md) || ✓ (Require `@Inject` annotation) || ✓ (manual argument passing) |
| [In-trait injection](airframe-di.md) (mix-in support) | (Deprecated in favor of Constructor Injection) | (Java has no trait) || ✓ (manual override) |
| [Life-cycle management](airframe-di.md#life-cycle) (On start/inject/shutdown hooks) || (Need an extension like [airlift](https://github.com/airlift/airlift/tree/main/bootstrap/src/main/java/io/airlift/bootstrap)) | limited (inject interceptor using reflection)| (Need to use IO Monad library like [Cats Effect](https://typelevel.org/cats-effect/)) |
| [Lazy/eager initialization switch](airframe-di.md#life-cycle) || ✓ (with [Stage](https://github.com/google/guice/wiki/Bootstrap)) | (lazy only) | (lazy only) |
| [Multi-bindings](airframe-di.md#multi-binding) |✓ (Just Scala) | ✓ |✓ (Just Scala) |✓ (Just Scala)
Expand Down
10 changes: 1 addition & 9 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ title: Overview

<img style = "float: right; padding: 10px;" width="150px" src="../img/logos/airframe_icon_small.png"/>

Airframe is a collection of essential building blocks for writing full-fledged applications in Scala, Scala.js, and Scala Ntive.
Airframe is a collection of essential building blocks for writing full-fledged applications in Scala, Scala.js, and Scala Native.

- [Release Notes](release-notes.md)
- [Source Code (GitHub)](https://github.com/wvlet/airframe)
Expand Down Expand Up @@ -292,14 +292,6 @@ usage: myapp [options]
-h, --help show help messages
```

### Application Config Flow

![config](../img/immutable_config.png)

[airframe-config](airframe-config.md) supports YAML-based application configurations and provides
immutable config objects that can be injected through DI. Partially overriding configurations is also asupported.



## List of Airframe Modules

Expand Down
34 changes: 8 additions & 26 deletions website/pages/en/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,28 +102,28 @@ class Index extends React.Component {
<Container
padding={['bottom', 'top']}
background="light"
className="threeColumn">
className="twoColumn">
<div>
<img width='200px' src={`${baseUrl}img/logos/airframe-logo-tr.png`} alt="Project Logo"/>
</div>
</Container>
);

const Features = ({background = 'light'}) => (
<Block layout="threeColumn">
<Block layout="twoColumn">
{[
{
content: '[Airframe RPC](docs/airframe-rpc) supports seamless integration of server and clients using Scala as RPC interfaces.',
content: '[Airframe RPC](docs/airframe-rpc) supports seamless integration of server and clients using Scala as RPC interfaces. You can also define plain [REST](docs/airframe-http) interfaces.',
image: `${baseUrl}img/airframe-rpc/rpc-overview.png`,
imageAlign: 'top',
title: 'RPC Framework',
title: 'RPC and REST Framework',
},
{
content: 'Have you ever used [slf4](http://slf4j.org/) (logging), [Jackson](https://github.com/FasterXML/jackson) (JSON-based serialization), [Guice](https://github.com/google/guice) (dependency injection)? ' +
'Airframe has redesigned these Java-based ecosystem as [airframe-log](docs/airframe-log), [airframe-codec](docs/airframe-codec), and [airframe-di](docs/airframe-di) in order to maximize the power of Scala and Scala.js',
content: 'Airframe extends capability of Scala to the next level. Have you ever used [slf4](http://slf4j.org/) (logging), [Jackson](https://github.com/FasterXML/jackson) (JSON-based serialization), [Guice](https://github.com/google/guice) (dependency injection)? ' +
'Airframe has redesigned these Java-based ecosystem as [airframe-log](docs/airframe-log), [airframe-codec](docs/airframe-codec), and [airframe-di](docs/airframe-di) in order to maximize the power of Scala',
image: `${baseUrl}img/features/scala-logo-red-spiral-dark.png`,
imageAlign: 'top',
title: 'Designed for Scala and Scala.js',
title: 'Designed for Scala, Scala.js, and Scala Native',
},
{
content:
Expand All @@ -133,29 +133,11 @@ class Index extends React.Component {
title: 'MessagePack-based Object Serialization',
},
{
content: '[AirSpec](docs/airspec) is a simple unit testing framework for Scala and Scala.js. You can use public methods in your classes as test cases. No need to remember complex DSLs for writing tests in Scala.',
content: '[AirSpec](docs/airspec) is a simple unit testing framework. No need to remember complex DSLs for writing tests in Scala.',
image: `${baseUrl}/img/features/airspec.png`,
imageAlign: 'top',
title: 'Simple Testing Framework'
},
{
content: "[airframe-http](docs/airframe-http) supports building REST web services by using Scala as an IDL (Interface Definition Language). Airframe provides a ready-to use web server implementation based on [Twitter Finagle](https://twitter.github.io/finagle/guide/) and built-in JSON/MessagePack-based REST API call mapping to crate microservice API servers and clients at ease",
image: `${baseUrl}/img/features/finagle.png`,
imageAlign: 'top',
title: 'REST Services'
},
{
content: 'Retrying HTTP requests for API calls is an essential technique for connecting microservices. [airframe-control](docs/airframe-control) will provide essential tools for making your requests reliable with exponential backoff retry, jitter, circuit-breaker, rate control, etc.',
image: `${baseUrl}/img/features/undraw_process_e90d.svg`,
imageAlign: 'top',
title: 'Retry, Rate Control'
},
{
content: "Web application development often requires mock web servers. With [airframe-http-recorder](docs/airframe-http-recorder), you can record and replay the real server responses for running unit tests even if the servers are offline or unreachable from CI environments.",
image: `${baseUrl}/img/features/undraw_server_down_s4lk.svg`,
imageAlign: 'top',
title: 'HTTP Client and Recorders',
},
{
content: "[airframe-metrics](docs/airframe-metrics) provides human-friendly time range selectors (e.g., -1d, -1w) and data units for measuring elapsed time (e.g., 0.1s, 1.5h) and data sizes (e.g., GB, PB.)",
image: `${baseUrl}/img/features//undraw_time_management_30iu.svg`,
Expand Down

0 comments on commit 26e62c5

Please sign in to comment.