greet: function*(name: string) {
return `Hello, ${name}!`;
},
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import * as restate from "@restatedev/restate-sdk"; | |
| import {RestatePromise, TerminalError} from "@restatedev/restate-sdk"; | |
| import {readFile} from "fs/promises"; | |
| import {join} from "path"; | |
| import type * as dosswf from "./workflow_dsl_types" | |
| import * as dosswfruntime from "./workflow_interpreter_runtime" | |
| type ActionStackElement = { id: number, stepIds: string[] }; | |
| type ExecuteRequest = { | |
| steps: dosswf.ActionStep[]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { | |
| service, | |
| Operation, sleep, | |
| internal as restateInternal, date | |
| } from "@restatedev/restate-sdk-gen"; | |
| import * as restate from "@restatedev/restate-sdk"; | |
| import {Attributes, Context, Counter, Histogram, metrics} from '@opentelemetry/api'; | |
| import { | |
| ConsoleMetricExporter, | |
| MeterProvider, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // --------------------------------------------------------------------------- | |
| // Journal data model | |
| // --------------------------------------------------------------------------- | |
| type Bytes = number[]; | |
| type CompletionId = number; | |
| type MillisSinceEpoch = number; | |
| interface Header { | |
| name: string; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import dev.restate.integration.Invocation; | |
| import dev.restate.integration.ProducerNotReadyException; | |
| import java.util.concurrent.CompletableFuture; | |
| /** | |
| * An at-least-once producer: the client assigns a monotonically increasing offset to each | |
| * invocation. Deduplication is disabled (empty producer id); add an idempotency key on the | |
| * invocations if you need handler-level dedup. | |
| * |
OlderNewer