2021-04-05 13:02:27 +03:00
export const MACOS_JAVA_CONTENT_POSTFIX = 'Contents/Home' ;
2020-07-15 19:53:39 -06:00
export const INPUT_JAVA_VERSION = 'java-version' ;
2022-12-13 12:45:14 +01:00
export const INPUT_JAVA_VERSION_FILE = 'java-version-file' ;
2020-07-15 19:53:39 -06:00
export const INPUT_ARCHITECTURE = 'architecture' ;
export const INPUT_JAVA_PACKAGE = 'java-package' ;
2021-04-05 13:02:27 +03:00
export const INPUT_DISTRIBUTION = 'distribution' ;
2026-07-08 12:44:58 -04:00
export const INPUT_JDK_FILE = 'jdk-file' ;
export const INPUT_JDK_FILE_DEPRECATED = 'jdkFile' ;
2021-04-05 13:02:27 +03:00
export const INPUT_CHECK_LATEST = 'check-latest' ;
2026-07-28 14:43:47 -04:00
export const INPUT_FORCE_DOWNLOAD = 'force-download' ;
2026-07-07 18:38:57 +02:00
export const INPUT_SET_DEFAULT = 'set-default' ;
2026-07-16 11:28:10 -04:00
export const INPUT_PROBLEM_MATCHER = 'problem-matcher' ;
2026-06-29 13:19:49 +01:00
export const INPUT_VERIFY_SIGNATURE = 'verify-signature' ;
export const INPUT_VERIFY_SIGNATURE_PUBLIC_KEY = 'verify-signature-public-key' ;
2026-09-03 13:27:24 -04:00
export const SIGNATURE_VERIFICATION_DOCUMENTATION_URL =
'https://github.com/actions/setup-java#download-integrity-and-signatures' ;
export const SIGNATURE_VERIFICATION_FAILURE_HELP = ` If this is a legitimate vendor signing-key rotation, see ${ SIGNATURE_VERIFICATION_DOCUMENTATION_URL } for instructions to configure the updated public key or temporarily disable signature verification. ` ;
2026-08-17 17:05:55 -04:00
export const INPUT_MVN_SERVER_CREDENTIALS = 'mvn-server-credentials' ;
2026-08-17 18:18:45 -04:00
export const INPUT_MVN_REPOSITORIES = 'mvn-repositories' ;
export const INPUT_MVN_REPOSITORIES_INCLUDE_CENTRAL =
'mvn-repositories-include-central' ;
export const INPUT_MVN_REPOSITORIES_PRIORITIZE_CENTRAL =
'mvn-repositories-prioritize-central' ;
2020-07-15 19:53:39 -06:00
export const INPUT_SERVER_ID = 'server-id' ;
2026-07-17 20:10:58 -04:00
export const INPUT_SERVER_USERNAME_ENV_VAR = 'server-username-env-var' ;
export const INPUT_SERVER_PASSWORD_ENV_VAR = 'server-password-env-var' ;
export const INPUT_SERVER_USERNAME_DEPRECATED = 'server-username' ;
export const INPUT_SERVER_PASSWORD_DEPRECATED = 'server-password' ;
2020-07-15 20:16:31 -06:00
export const INPUT_SETTINGS_PATH = 'settings-path' ;
2021-04-05 13:02:27 +03:00
export const INPUT_OVERWRITE_SETTINGS = 'overwrite-settings' ;
2020-07-15 19:53:39 -06:00
export const INPUT_GPG_PRIVATE_KEY = 'gpg-private-key' ;
2026-07-17 20:10:58 -04:00
export const INPUT_GPG_PASSPHRASE_ENV_VAR = 'gpg-passphrase-env-var' ;
export const INPUT_GPG_PASSPHRASE_DEPRECATED = 'gpg-passphrase' ;
2020-07-15 19:53:39 -06:00
2026-07-17 20:10:58 -04:00
export const INPUT_DEFAULT_SERVER_USERNAME = 'GITHUB_ACTOR' ;
export const INPUT_DEFAULT_SERVER_PASSWORD = 'GITHUB_TOKEN' ;
2020-07-15 21:15:27 -06:00
export const INPUT_DEFAULT_GPG_PRIVATE_KEY = undefined ;
2020-07-15 19:53:39 -06:00
export const INPUT_DEFAULT_GPG_PASSPHRASE = 'GPG_PASSPHRASE' ;
2026-07-15 10:33:09 -04:00
// The default name of the environment variable the maven-gpg-plugin reads the
// passphrase from (property `gpg.passphraseEnvName`). When the configured
// passphrase env var name matches this, no extra configuration is required.
export const MAVEN_GPG_PASSPHRASE_DEFAULT_ENV = 'MAVEN_GPG_PASSPHRASE' ;
// Id of the settings.xml profile used to set `gpg.passphraseEnvName`.
export const GPG_PASSPHRASE_PROFILE_ID = 'setup-java-gpg' ;
2026-08-17 18:18:45 -04:00
export const MAVEN_REPOSITORIES_PROFILE_ID = 'setup-java-repositories' ;
export const MAVEN_CENTRAL_REPOSITORY_ID = 'central' ;
export const MAVEN_CENTRAL_REPOSITORY_URL =
'https://repo.maven.apache.org/maven2' ;
2026-07-15 10:33:09 -04:00
2021-08-20 01:19:35 +08:00
export const INPUT_CACHE = 'cache' ;
Add conditional JDK caching (#1201)
* Add JDK caching
Cache resolved JDK tool-cache entries by exact platform and release identity, with a default-on cache-jdk input and explicit opt-out.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Apply batched suggestions from code review
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
* Fix JDK cache CI validation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Update brace-expansion security fix
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Refresh brace-expansion license metadata
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Refine JDK cache semantics
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Refine JDK cache documentation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Simplify JDK cache identity
Use one normalized runner OS dimension, reset the internal cache key schema for the unreleased feature, and align documentation, tests, and bundles.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Align JDK cache OS identity
Use the established RUNNER_OS value directly and retain process.platform only as a non-Actions fallback.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Harden JDK cache saves and document tool-cache reuse
Bind each JDK cache key to the installation identity it was computed for,
keep post-job saves best-effort per entry, and state the real reuse and
verification guarantee in the documentation.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* docs: restructure README caching section
Rename '## Caching dependencies' to '## Caching' and add a what-gets-cached
overview table covering the dependency, wrapper, and JDK caches. Lead with the
common 'cache: maven' example and the dependency-cache material, and demote JDK
caching into its own subsection.
Also corrects the IMPORTANT callout, which implied JDK caching required an
explicit opt-in; it is enabled implicitly whenever 'cache' is set.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* docs: fix caching documentation defects
- Remove pull-request framing that compared behavior to `main`; state the
tool-cache and `jdkfile` behavior directly and unconditionally.
- Clarify that the JDK cache is a separate cache *entry* from the dependency
and wrapper caches, while its *enablement* is coupled to `cache`, so the
opening paragraph agrees with the enablement matrix.
- Cite the actions/setup-java-benchmarks repository instead of an open PR and
a self-referential PR comment, keeping the measured figures and caveats.
- Keep the `cache`/`cache-jdk` matrix only in docs/advanced-usage.md and
summarize the rules in prose in README.md to avoid divergence.
- Describe the guarantee that a cache key is only saved with the installation
it was computed for, instead of documenting inode/size/timestamp internals.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* docs: add V6 what's new entry for JDK caching
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e2755464-4e83-47b6-ba71-731bb481b418
---------
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Copilot-Session: e2755464-4e83-47b6-ba71-731bb481b418
2026-08-04 21:54:10 -04:00
export const INPUT_CACHE_JDK = 'cache-jdk' ;
2023-11-23 00:43:14 +09:00
export const INPUT_CACHE_DEPENDENCY_PATH = 'cache-dependency-path' ;
2026-07-29 14:43:55 -04:00
export const INPUT_CACHE_PATH = 'cache-path' ;
2026-07-29 10:20:14 -04:00
export const INPUT_CACHE_READ_ONLY = 'cache-read-only' ;
2021-08-20 01:19:35 +08:00
export const INPUT_JOB_STATUS = 'job-status' ;
2026-08-05 18:05:36 +02:00
export const STATE_GPG_HOME = 'gpg-home' ;
2022-01-16 17:33:29 +01:00
export const M2_DIR = '.m2' ;
export const MVN_SETTINGS_FILE = 'settings.xml' ;
export const MVN_TOOLCHAINS_FILE = 'toolchains.xml' ;
export const INPUT_MVN_TOOLCHAIN_ID = 'mvn-toolchain-id' ;
export const INPUT_MVN_TOOLCHAIN_VENDOR = 'mvn-toolchain-vendor' ;
2026-07-02 17:12:50 -04:00
export const INPUT_SHOW_DOWNLOAD_PROGRESS = 'show-download-progress' ;
export const MAVEN_ARGS_ENV = 'MAVEN_ARGS' ;
export const MAVEN_NO_TRANSFER_PROGRESS_FLAG = '-ntp' ;
export const MAVEN_NO_TRANSFER_PROGRESS_LONG_FLAG = '--no-transfer-progress' ;
2022-12-13 12:45:14 +01:00
export const DISTRIBUTIONS_ONLY_MAJOR_VERSION = [ 'corretto' ] ;