Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
**/target/*
.DS_Store
*.pdf
16 changes: 0 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,6 @@ For the exercises, make sure to run `temporal server start-dev --ui-port 8080 --
| `exercises/farewell-workflow` | [Exercise 3](exercises/farewell-workflow/README.md) |
| `exercises/finale-workflow` | [Exercise 4](exercises/finale-workflow/README.md) |

## GitPod Environment Shortcuts

If you are executing the exercises in the provided GitPod environment, you
can take advantage of certain aliases to aid in navigation.

| Command | Action |
| :------ | :-------------------------------------- |
| `ex1` | Change to Exercise 1 Practice Directory |
| `ex1s` | Change to Exercise 1 Solution Directory |
| `ex2` | Change to Exercise 2 Practice Directory |
| `ex2s` | Change to Exercise 2 Solution Directory |
| `ex3` | Change to Exercise 3 Practice Directory |
| `ex3s` | Change to Exercise 3 Solution Directory |
| `ex4` | Change to Exercise 4 Practice Directory |
| `ex4s` | Change to Exercise 4 Solution Directory |

## Instructor-Led Demonstrations

| Directory Name | Description |
Expand Down
12 changes: 6 additions & 6 deletions demos/service-workflow/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,39 +21,39 @@
<dependency>
<groupId>io.temporal</groupId>
<artifactId>temporal-sdk</artifactId>
<version>1.19.1</version>
<version>1.31.0</version>
</dependency>

<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-nop</artifactId>
<version>2.0.6</version>
<version>2.0.17</version>
</dependency>

<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.11</version>
<version>3.18.0</version>
</dependency>

<dependency>
<groupId>io.temporal</groupId>
<artifactId>temporal-testing</artifactId>
<version>1.19.1</version>
<version>1.31.0</version>
<scope>test</scope>
</dependency>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<version>4.13.2</version>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<version>5.1.1</version>
<version>5.14.2</version>
<scope>test</scope>
</dependency>

Expand Down
4 changes: 2 additions & 2 deletions demos/writing-a-workflow-definition/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>

<dependencies>
Expand Down
17 changes: 0 additions & 17 deletions exercises/farewell-workflow/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,6 @@ you'll need to change. If you get stuck and need additional hints, or
if you want to check your work, look at the completed example in the
`solution` directory.

## GitPod Environment Shortcuts

If you are executing the exercises in the provided GitPod environment, you
can take advantage of certain aliases to aid in navigation and execution of
the code.

| Command | Action |
| :---------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------- |
| `ex3` | Change to Exercise 3 Practice Directory |
| `ex3s` | Change to Exercise 3 Solution Directory |
| `ex3m` | Execute the Exercise 3 Microservice. Must be within the appropriate directory for this to succeed. (either `practice` or `solution`) |
| `ex3w` | Execute the Exercise 3 Worker. Must be within the appropriate directory for this to succeed. (either `practice` or `solution`) |
| `ex3st YOUR_NAME` | Execute the Exercise 3 Starter, passing in your name. Must be within the appropriate directory for this to succeed. (either `practice` or `solution`) |

## Part A: Write an Activity Method

The `GreetingActivities.java` file defines an interface with the Activity method signatures.
Expand Down Expand Up @@ -65,12 +51,9 @@ before executing the following commands:

1. Compile the code using the command `mvn clean compile`
2. Start the microservice by running `mvn exec:java -Dexec.mainClass="farewellworkflow.Microservice"` in a terminal
1. **Note:** If you're using GitPod, you can run the shortcut `ex3m`
3. In another terminal, start your Worker by running `mvn exec:java -Dexec.mainClass="farewellworkflow.GreetingWorker"`
1. **Note:** If you're using GitPod, you can run the shortcut `ex3w`
4. In a third terminal, execute your Workflow by running `mvn exec:java -Dexec.mainClass="farewellworkflow.Starter" -Dexec.args="Mason"`
(replacing `Mason` with your own name)
1. **Note:** If you're using GitPod, you can run the shortcut `ex3st Mason` (replacing `Mason` with your own name)

If there is time remaining, experiment with Activity failures and retries
by stopping the microservice (press Ctrl-C in its terminal) and re-running
Expand Down
12 changes: 6 additions & 6 deletions exercises/farewell-workflow/practice/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,39 +22,39 @@
<dependency>
<groupId>io.temporal</groupId>
<artifactId>temporal-sdk</artifactId>
<version>1.19.1</version>
<version>1.31.0</version>
</dependency>

<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-nop</artifactId>
<version>2.0.6</version>
<version>2.0.17</version>
</dependency>

<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.11</version>
<version>3.18.0</version>
</dependency>

<dependency>
<groupId>io.temporal</groupId>
<artifactId>temporal-testing</artifactId>
<version>1.19.1</version>
<version>1.31.0</version>
<scope>test</scope>
</dependency>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<version>4.13.2</version>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<version>5.1.1</version>
<version>5.14.2</version>
<scope>test</scope>
</dependency>

Expand Down
12 changes: 6 additions & 6 deletions exercises/farewell-workflow/solution/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,39 +22,39 @@
<dependency>
<groupId>io.temporal</groupId>
<artifactId>temporal-sdk</artifactId>
<version>1.19.1</version>
<version>1.31.0</version>
</dependency>

<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-nop</artifactId>
<version>2.0.6</version>
<version>2.0.17</version>
</dependency>

<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.11</version>
<version>3.18.0</version>
</dependency>

<dependency>
<groupId>io.temporal</groupId>
<artifactId>temporal-testing</artifactId>
<version>1.19.1</version>
<version>1.31.0</version>
<scope>test</scope>
</dependency>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<version>4.13.2</version>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<version>5.1.1</version>
<version>5.14.2</version>
<scope>test</scope>
</dependency>

Expand Down
24 changes: 4 additions & 20 deletions exercises/finale-workflow/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,6 @@ different languages, you'll need to start two Worker programs, one
written in Java that will execute the Activity code and one written
in Go that will execute the Workflow code.

## GitPod Environment Shortcuts

If you are executing the exercises in the provided GitPod environment, you
can take advantage of certain aliases to aid in navigation and execution.

| Command | Action |
| :---------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `ex4` | Change to Exercise 4 Practice Directory |
| `ex4j` | Execute the Exercise 4 jar file Directory |
| `ex4w` | Execute the Exercise 4 Worker. |
| `ex4st YOUR_NAME` | Execute the Exercise 4 Starter, passing in your name. If you provide a name with spaces in it, be sure to enclose it in quotation marks. Ex: "Mason Egger" |

# Run the Activity Worker (implemented in Java):

In one terminal, run the following command:
Expand All @@ -37,30 +25,26 @@ $ java -classpath \
io.temporal.training.PdfCertWorker
```

**Note:** If you're using GitPod, you can run the shortcut `ex4j`

# Run the Workflow Worker (implemented in Go):

In another terminal, run this command:
In another terminal, run these commands:

```
$ cd go
$ go run worker/main.go
```

**Note:** If you're using GitPod, you can run the shortcut `ex4w`

# Start the Workflow (Go)

In another terminal, run the following command,
In another terminal, run the following commands,
but be sure to replace `Mason Egger` with your
full name.

```
$ cd go
$ go run start/main.go "Mason Egger"
```

**Note:** If you're using GitPod, you can run the shortcut `ex4st "Mason Egger"`

- Once the workflow is complete, use the explorer
view on the left side of the exercise environment
to locate the file created by this workflow. It
Expand Down
35 changes: 18 additions & 17 deletions exercises/finale-workflow/go/go.mod
Original file line number Diff line number Diff line change
@@ -1,32 +1,33 @@
module finale

go 1.19
go 1.23.0

require go.temporal.io/sdk v1.22.1
toolchain go1.24.6

require go.temporal.io/sdk v1.35.0

require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/facebookgo/clock v0.0.0-20150410010913-600d898af40a // indirect
github.com/gogo/googleapis v1.4.1 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/gogo/status v1.1.1 // indirect
github.com/golang/mock v1.6.0 // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 // indirect
github.com/pborman/uuid v1.2.1 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.22.0 // indirect
github.com/nexus-rpc/sdk-go v0.3.0 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/robfig/cron v1.2.0 // indirect
github.com/stretchr/objx v0.5.0 // indirect
github.com/stretchr/testify v1.8.2 // indirect
go.temporal.io/api v1.19.1-0.20230322213042-07fb271d475b // indirect
go.uber.org/atomic v1.9.0 // indirect
golang.org/x/net v0.8.0 // indirect
golang.org/x/sys v0.6.0 // indirect
golang.org/x/text v0.8.0 // indirect
golang.org/x/time v0.1.0 // indirect
github.com/stretchr/objx v0.5.2 // indirect
github.com/stretchr/testify v1.10.0 // indirect
go.temporal.io/api v1.49.1 // indirect
golang.org/x/net v0.39.0 // indirect
golang.org/x/sync v0.13.0 // indirect
golang.org/x/sys v0.32.0 // indirect
golang.org/x/text v0.24.0 // indirect
golang.org/x/time v0.3.0 // indirect
google.golang.org/genproto v0.0.0-20230322174352-cde4c949918d // indirect
google.golang.org/grpc v1.54.0 // indirect
google.golang.org/protobuf v1.30.0 // indirect
google.golang.org/grpc v1.66.0 // indirect
google.golang.org/protobuf v1.36.5 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
Loading