Commit Graph

47 Commits

Author SHA1 Message Date
David Reiss
96dba8e7dd Add fairsim to gitignore and remove binary (#9439)
## What changed?
Add `fairsim` binary (from #8158) to `.gitignore` and `make clean` and
remove it from the repo. (Don't add it to `make bins` since it's not
generally useful.)

## Why
It accidentally got checked in.
2026-03-06 09:59:03 -08:00
Ulrich Romahn
45617a882c Fixing bug in retrieving archived workflows from Google Cloud Store (#9329)
## What changed?
Fixed a bug in the gcloud visibility_archiver.go file and added a new
unit test in visibility_archiver_test.go.

## Why?
There is a bug in the visibility-archiver implementation of the Google
Cloud archiver. All archived workflows are being retrieved and displayed
twice. This change fixes that bug.

## How did you test it?
- [X] built
- [X] run locally and tested manually
- [ ] covered by existing tests
- [X] added new unit test(s)
- [ ] added new functional test(s)

## Potential risks
No risk since the archiver is completely decoupled from the core
functionality.
2026-03-04 23:50:13 -05:00
Sean Kane
6d143a0fec flakes: add slack reporting on flaky tests (#8381)
## What changed?
Run our flaky test report on a cadence and send results in Slack

## Why?
Help oss team take action on our flaky alerts

## How did you test it?
- [ ] built
- [ ] run locally and tested manually
- [ ] covered by existing tests
- [ ] added new unit test(s)
- [ ] added new functional test(s)

## Potential risks
NA
2025-10-01 09:11:42 -06:00
Sean Kane
4adcdbf373 tests: expand testrunner support to alert on panics or dataraces (#8351)
## What changed?
Expanding `testrunner` tool to add alerts for panics and data races.
Sample table with an injected data race (and real panic):

<table><tr><th><th>Tests</th><th>Passed </th><th>Skipped
⏭️</th><th>Failed </th></tr><tr><td>JUnit Test Report</td><td>721
ran</td><td>340 passed</td><td>370 skipped</td><td>11
failed</td></tr></table>
<table><tr><th>Test</th><th>Result</th></tr><tr><td
colspan="2"><strong>JUnit Test
Report</strong></td></tr><tr><td>functional-test (crash)</td><td>
failure</td></tr><tr><td>io/server/tests.TestActivityApiBatchResetClientTestSuite/TestActivityBatchReset_DataRace</td><td>
failure</td></tr><tr><td>io/server/tests.TestTaskQueueStats_Pri_Suite/TestNoTasks_ValidateStats</td><td>
failure</td></tr><tr><td>io/server/tests.TestVersioning3FunctionalSuite/TestUnpinnedQuery_NoSticky/ForceTaskForwardForcePollForwardForceAsync</td><td>
failure</td></tr><tr><td>io/server/tests.TestVersioningFunctionalSuite/TestDispatchQueryOld/ForceTaskForwardForcePollForwardForceAsync</td><td>
failure</td></tr><tr><td>io/server/tests.TestActivityApiBatchResetClientTestSuite/TestActivityBatchReset_DataRace
(retry 1)</td><td>
failure</td></tr><tr><td>io/server/tests.TestActivityApiBatchResetClientTestSuite/TestActivityBatchReset_DataRace
(retry 2)</td><td> failure</td></tr><tr><td>func1.DATA RACE: Data race
detected — in
go.temporal.io/server/tests.(*ActivityApiBatchResetClientTestSuite).TestActivityBatchReset_DataRace.func1</td><td>
failure</td></tr><tr><td>PANIC: runtime error: invalid memory address or
nil pointer dereference — in
TestTaskQueueStats_Pri_Suite/TestAddMultipleTasks_MultiplePartitions_ValidateStats_Cached</td><td>
failure</td></tr><tr><td>func1.DATA RACE: Data race detected — in
go.temporal.io/server/tests.(*ActivityApiBatchResetClientTestSuite).TestActivityBatchReset_DataRace.func1</td><td>
failure</td></tr><tr><td>func1.DATA RACE: Data race detected — in
go.temporal.io/server/tests.(*ActivityApiBatchResetClientTestSuite).TestActivityBatchReset_DataRace.func1</td><td>
failure</td></tr></table>

Source:
https://github.com/temporalio/temporal/actions/runs/17870152469?pr=8351

## Why?
This change will help the temporal team find bugs sooner.

## How did you test it?
- [ ] built
- [ ] run locally and tested manually
- [ ] covered by existing tests
- [X] added new unit test(s)
- [ ] added new functional test(s)

## Potential risks
NA
2025-09-22 11:01:29 -06:00
Roey Berman
4c59cd15d7 Add support for protos in chasm libs (#8182)
## What changed?

Added support for defining protos in chasm libs.

## Why?

Keep everything local to the library.

## How did you test it?
- [x] built
- [x] run locally and tested manually
2025-08-15 18:09:58 +00:00
Prathyush PV
4983272da0 Revert "Remove .gitmodules (#7589)" (#7633)
## What changed?
This reverts commit 9cffbc016d.

## Why?
It broke a build action

## How did you test it?

## Potential risks

## Documentation

## Is hotfix candidate?
2025-04-18 14:44:02 -07:00
Stephan Behnke
9cffbc016d Remove .gitmodules (#7589)
## What changed?
<!-- Describe what has changed in this PR -->

Remove `temporalio-dashboards` submodule. Checkout and extract the
dashboard from `tar` instead.

## Why?
<!-- Tell your future self why have you made these changes -->

Remove top-level `.gitmodules` file (visually cluttering the top-level
of the repo).

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
2025-04-10 12:44:58 -07:00
David Reiss
d812429505 Check for breaking proto changes (#6114)
## What changed?
- Add (back) make target buf-breaking to run buf's breaking proto
changes check against the parent commit and the main branch.
- Add buf-breaking to ci-build-misc so it runs in CI.
- Fix goimports target to use shell variables instead of git variables
to make make faster, and also fix the binary name (was just broken).
- GitHub Actions: run tests on PR head, not merge.

## Why?
Detecting breaking proto changes early avoids bugs.

## How did you test it?
Manual testing with deliberate breaking changes.
2024-07-10 16:44:07 -07:00
David Reiss
6b8366ebcd Remove proto/api submodule (#5868)
## What changed?
- Remove `proto/api` submodule.
- Adds a new program that's automatically run by the Makefile as
required to output the api protos in binary form, which can be used by
most tools. The command is run by `go run` and uses the same api-go
reference as the rest of the server for the source protos.
- Removed http annotations from internal matchingservice proto.

## Why?
- Ensure that the api-go import (in go.mod) and the proto files imported
by this repo's proto files are always in sync.
- Simplify update process, stop having to mess with submodules.

## How did you test it?
running commands manually a lot

## Potential risks
Importing protos from somewhere other than our api and google well-known
protos may require some updates to the script's import path logic.

## Documentation
updated docs
2024-06-05 16:20:30 -07:00
Tim Deeb-Swihart
37b884fe28 Improve tooling management (#5692)
## What changed?
All tooling is now installed to and used from a local binary directory.
After these changes you'll never need to run `make install` or `make
update-BLAH` to keep our tools up to date; Make will do that for you.

## Why?
Keeping tool versions in sync across repos is a nightmare when each repo
installs its tooling globally. To fix that we're going to install all
our tools into a local bin directory and use those versions for
everything.

This is set up using two directories: a local binary directory (.bin)
and a stamp directory for state-tracking. The stamp directory is used
for programs that need to be named a certain way; the stampfile is
how we know if we've installed the right version.

## How did you test it?
I ran through our common makefile uses locally

## Potential risks
None that I'm aware of

## Documentation
No

## Is hotfix candidate?
No
2024-04-10 10:25:28 -07:00
David Reiss
222bdc05a3 Share built images in CI and more sharding for functional tests (#4589)
**What changed?**
- In CI, build most of the tests and dependencies and reuse them in
subsequent steps.
- Additionally pre-build dependencies separately on a weekly schedule
(in buildkite configuration) and reuse them when possible.
- Add more test sharding for functional tests (split the main functional
test suite into three).

**Why?**
Increase parallelism, reduce latency of getting test results, reduce
granularity of retries

**How did you test it?**
lots of testing on buildkite

**Potential risks**

**Is hotfix candidate?**
2023-10-26 23:34:23 -07:00
Michael Snowden
d4af86087f Add some documentation to the maximumInterval field of ExponentialRet… (#4318)
* Add some documentation to the maximumInterval field of ExponentialRetryPolicy

commit-id:09489711

* Ignore Git SPR config file

commit-id:aa42d8fc
2023-05-15 11:29:02 -07:00
Alex Shtin
cf754414db Move build proto dependencies to separate go.mod (#3377) 2022-09-13 17:45:45 -07:00
mastermanu
c0fbdf96c4 Adds ability to specify sanitizeOptions for prometheus metrics (#3170)
This PR adds the ability to set specific tally.SanitizeOptions via temporal configuration. If the configuration is not set, we rely on the default that is defined in code. Otherwise, we will generate a tally.SanitizeOptions by parsing the configuration file and converting it to a tally.SanitizeOptions.

Because configuration comes in via yaml, all relevant input fields are strings. The code converts the strings to runes and performs length check validations. Any invalid configuration will fail server startup.
2022-08-01 17:01:58 -04:00
Ruslan
ba585a97b4 Create binary tool for debugging Temporal (#2932)
* Create binary tool for debugging Temporal

* add missing license

* rename tdbg files

* remove version reporting for tdbg

* remove search attributes commands

* Update Makefile

Co-authored-by: Alex Shtin <alex@shtin.com>

* Update cmd/tools/tdbg/main.go

Co-authored-by: Alex Shtin <alex@shtin.com>

* Update tools/tdbg/commands.go

Co-authored-by: Alex Shtin <alex@shtin.com>

* address comments

* more cleanup

* Update .gitignore

Co-authored-by: Alex Shtin <alex@shtin.com>

* address comments

* remove cluster add and remove commands

* remove more of direct DB access

* clean unused code

* clean unused code

* clean unused code

* remove cluster commands

* Update tools/tdbg/tdbg_commands.go

Co-authored-by: Alex Shtin <alex@shtin.com>

* Update tools/tdbg/tdbg_commands.go

Co-authored-by: Alex Shtin <alex@shtin.com>

* Update tools/tdbg/tdbg_commands.go

Co-authored-by: Alex Shtin <alex@shtin.com>

* Update tools/tdbg/tdbg_commands.go

Co-authored-by: Alex Shtin <alex@shtin.com>

Co-authored-by: Alex Shtin <alex@shtin.com>
2022-07-20 16:31:58 -07:00
Jason Roselander
219240a914 Added history of active clusters to NamespaceDetail (#3106)
* Added /build to .gitignore

* Minor cleanup in metadata_test_config

* Added ReplicationHistory field to NamespaceDetail

* Initial checkin of writing Active Cluster History to NS

* Changed handler to write ReplicationHistory when status is changed to NORMAL

* Added test for handover failure

* Changed UpdateNamespace to record a replication history status if the active cluster changes without a handover

* Ran make goimports

* Moved ReplicationHistory into ReplicationConfig

* Limit number of replication history entries

* Use failoverVersion instead of cluster name

* Updated maybeUpdateFailoverHistory to handle the case where updateReplicationConfig is nil

* ran make goimports

* Reorganized imports

* Added comment about checking for configurationChanged
2022-07-18 17:38:14 -07:00
Matt McShane
f86b8d2c5f Per-service fx-ified OTEL tracing (#2896)
Build trace exporters from YAML and make TracerProvider instances available to the history/matching/worker/frontend services. Also puts gRPC instrumentation interceptors in place so that gRPC requests and responses are given their own spans.
2022-06-22 14:01:51 -07:00
Alex Shtin
af9130dcdb Remove custom build info script (#2635) 2022-03-22 16:23:19 -07:00
Alex Shtin
f6e84df104 Move goreleaser scripts to Makefile (#2508) 2022-02-14 21:44:51 -08:00
Alex Shtin
2a47cdf0e2 Replace ldflags with go:embed (#2085) 2021-12-01 12:43:47 -08:00
Mikhail Gryzykhin
a223a1188f Add fossa scan to buildkite (#1526) 2021-05-06 15:05:49 -07:00
Harsha Teja Kanna
f5b17bd15c Added goreleaser configuration to publish binaries (#1357)
* Added goreleaser configuration to publish binaries
* Make binaries usable with scratch or distroless Docker images
2021-03-05 14:26:02 -08:00
Alex Shtin
bc114eb29d Refactor Buildkite pipeline (#1174) 2021-01-11 19:42:21 -08:00
Alex Shtin
32d6a9219c Extract server struct and add server options (#826) 2020-10-10 22:26:09 -07:00
Alex Shtin
8090029272 Add proto breaking change detector (#747) 2020-09-21 13:08:17 -07:00
Maxim Fateev
0f92b5fc5d Workflow diagram (#529) 2020-07-10 14:48:06 -07:00
Alex Shtin
f685a88a79 Add proto generated go files (#506) 2020-07-08 09:25:23 -07:00
Ruslan
46fd32ed56 Add common vscode debug commands (#332)
* Add common vscode debug commands

* Add vscode workflow debug script

* Add showing call stack

* Make vscode launch scripts run go code directly

* Remove excess namespace arguments
2020-05-05 19:08:40 -07:00
Alex Shtin
b70271b98d Update LICENSE file and all go files with new license header (#285) 2020-04-08 20:39:01 -07:00
Samar Abbas
25949520a6 Rename temporal-cli to tctl (#199) 2020-03-10 12:42:27 -07:00
Samar Abbas
7005b7bc88 Rename all executables from cadence- to temporal- (#195)
Rename generated binaries:
- cadence -> temporal
- cadence-server -> temporal-server
- cadence-canary -> temporal-canary
- cadence-sql-tool -> temporal-sql-tool
- cadecne-cassandra-tool -> temporal-cassandra-tool

Moved core schema files for all database implementation to be under temporal folder.

Also used 'temporal' as keyspace or database name for core schema.

Renamed all environment variable to use TEMPORAL instead of CADENCE.

Renamed all docker scripts to references to point to new executables and mention
temporal.

Change reference to buildkite pipelines for temporal.
2020-03-09 12:43:13 -07:00
Alex Shtin
1d1efa2dd9 Update proto generated files for 12-26-2019 sync (#56) 2020-01-02 13:50:09 -08:00
Samar Abbas
5920d79117 Add workspace file to gitignore for vscode development (#1) 2019-10-22 17:30:44 -07:00
wxing1292
c27ca160ca Use gobin, instead of go get vendor for thriftrw & thriftrw-plugin-yarpc (#2517)
* Use gobin since go@1.13 disabled go get ./vendor/*
2019-09-06 12:04:46 -07:00
Quanzheng Long
ced0e3beed Implement Workflow Reset on Active Side (#1352)
* fix .gitignore

* IDL changes

* client/history/client.go

* metrics def

* dataInterfaces

* common/persistence/persistenceInterface.go

* schema

* schema

* common/persistence/cassandra/cassandraHistoryV2Persistence.go

* common/persistence/cassandra/cassandraPersistence.go

* common/persistence/historyV2Store.go

* common/persistence/persistence-tests/executionManagerTestForEventsV2.go

* common/persistence/persistence-tests/historyV2PersistenceTest.go

* done persistence rebase

* fix build

* done rebase all app layer

* fix small bugs

* rebase with latest master

* fix make

* add reset CLI

* fix ccli bug

*  fix bug

* Record visibility

* fix test

* Fix pollDecision bug

* readFullSize of v2

* fix npe

* Change decisionTaskCompletedEventID to decisionTaskFinishEventID

* fix cli help msg

* allow reset to trasient decision

* clear attemp in decsionInfo

* notify tasks

* clear stickyness

* fix validateLastBatchOfReset

* address comment for AddDecisionTaskFailedEvent

* fix unit test

* fix unit test

* address all comments, move code to new component

* fix lint

* fix unit test
2019-01-05 17:56:04 -08:00
Dustin Metzgar
79798a68df Move from glide to dep (#1010)
Dep generates a folder, _vendor-*, with copies of the source code for dependencies. Added this to .gitignore and set the "make copyright" check to skip that folder.

Pruning is not enabled in the toml since that deletes files used during build. Updated contribution guide to talk about dep instead of glide. Set cadence version to 0.7.2
2018-08-01 13:00:46 -07:00
wxing1292
edfa972c8f Mutiple Bugfixes (#794)
* fix workflow timeout version check bug
* fix task event ID check bug
* fix integtest race condition
* add tag to failover processor
2018-05-30 14:40:20 -07:00
wxing1292
7e5afe5aec Bugfix, reset mutable state empty UUID (#784)
* add .vscode to .gitignore

* bugfix: empty uuid in reset mutable state
2018-05-25 17:53:02 -07:00
Bowei Xu
23bb0db44a Add integration test for domain failover (#731)
* Add multi cluster setup for domain failover integration test

* comment test until background check is ready
2018-05-21 16:07:00 -07:00
Venkat
ef260bfdbd tooling: support for cassandra update-schema (#177) 2017-05-15 10:12:45 -07:00
Tamer Eldeeb
d8d54d3fbe Refactor loggingHelpers (#173)
Moves tags, events and common logging methods to the common package
2017-05-11 13:47:15 -07:00
Tamer Eldeeb
442c383fc9 Remove dependency on go-build (#4) 2017-02-22 17:32:17 -08:00
Tamer Eldeeb
e30332957d Rename to cadence 2017-02-21 16:06:49 -08:00
Siva Kalva
072a7f0a67 Panic integration.
Summary:
Split the runs into multiple activities.

Merge branch 'master' of code.uber.internal:devexp/minions into demo

Thrift integration to demo.

Add workflow ID to the demo logs.

Add persistence to MakeFile.

Demo changes.

Subscribers: jenkins

Differential Revision: https://code.uberinternal.com/D669739
2016-12-12 13:55:07 -08:00
Tamer Eldeeb
017f955349 Checkin autogenerated thrift files
Summary:
This change adds the files generated by thrift compiler to the repo.
This is needed to use this package in the uber-minions repo.
The good news is that the auto generated files will not change unless
the thrift IDL file changes, even when make clean is used so it would
not create a lot of overhead for other check-ins.

Reviewers: samar, sivakk

Reviewed By: sivakk

Differential Revision: https://code.uberinternal.com/D653858
2016-11-30 15:27:24 -08:00
Siva Kalva
76fa1ce7cc Port client framework changes to exercise the stress run.
Summary: linting.

Reviewers: samar

Reviewed By: samar

Subscribers: jenkins

Differential Revision: https://code.uberinternal.com/D649078
2016-11-25 16:32:29 -08:00
Siva Kalva
685242e53f The new beginning 2016-10-24 16:07:32 -07:00