java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IJobRef, IEnvironmentAware, IResource, IJob, IGrantable, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable
Direct Known Subclasses:
PythonShellJob, RayJob, SparkJob

@Generated(value="jsii-pacmak/1.139.0 (build 26a6b54)", date="2026-09-17T14:54:30.075Z") @Stability(Deprecated) @Deprecated public abstract class Job extends JobBase
Deprecated.
(deprecated) A Glue Job.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.glue.alpha.*;
 import software.amazon.awscdk.services.iam.*;
 Role role;
 IJob job = Job.fromJobAttributes(this, "MyJob", JobAttributes.builder()
         .jobName("jobName")
         // the properties below are optional
         .role(role)
         .build());
 
  • Constructor Details

    • Job

      protected Job(software.amazon.jsii.JsiiObjectRef objRef)
      Deprecated.
    • Job

      protected Job(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
      Deprecated.
    • Job

      @Stability(Stable) protected Job(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable ResourceProps props)
      Deprecated.
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      props -
    • Job

      @Stability(Stable) protected Job(@NotNull software.constructs.Construct scope, @NotNull String id)
      Deprecated.
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
  • Method Details

    • fromJobAttributes

      @Stability(Deprecated) @Deprecated @NotNull public static IJob fromJobAttributes(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull JobAttributes attrs)
      Deprecated.
      (deprecated) Identifies an existing Glue Job from a subset of attributes that can be referenced from within another Stack or Construct.

      Parameters:
      scope - The scope creating construct (usually this). This parameter is required.
      id - The construct's id. This parameter is required.
      attrs - Attributes for the Glue Job we want to import. This parameter is required.
    • codeS3ObjectUrl

      @Stability(Deprecated) @Deprecated @NotNull protected String codeS3ObjectUrl(@NotNull Code code)
      Deprecated.
      Parameters:
      code - This parameter is required.
    • mergeDefaultArguments

      @Stability(Deprecated) @Deprecated @NotNull protected Map<String,String> mergeDefaultArguments(@Nullable Map<String,String> defaultArguments)
      Deprecated.
      (deprecated) Merge the customer-supplied defaultArguments with the arguments this construct manages.

      The construct owns every argument it emits — whether the value comes from a dedicated typed prop (e.g. `continuousLogging`, `enableMetrics`, `sparkUI`) or from the job class itself (e.g. `--job-language`). Those arguments, plus the arguments Glue reserves for its own use, MUST be configured through their dedicated props rather than the untyped `defaultArguments` map, so there is exactly one way to express each intent. Passing such a key through `defaultArguments` therefore throws instead of silently winning or being silently dropped. A managed key whose supplied value is identical to the construct's value is not contradictory, so it is allowed rather than rejected (auto-correcting config is preferred over errors). Glue-reserved keys are never emitted by the construct, so there is no value to reconcile and they always throw. The reserved set is `_managedArgumentKeys` — every key the construct declared through setManagedArgument(java.lang.String,java.lang.String), whether or not a value was emitted for it. It is deliberately NOT derived from the keys that carry a value: a typed prop that turns a feature *off* (e.g. `enableMetrics: false`) emits no value but still reserves its key, so `defaultArguments` cannot silently re-enable it. Conflict detection relies on string equality of the argument keys, which cannot see through unresolved tokens (e.g. a key produced by `CfnJson` that only resolves at deploy time). If a key is a token, the check is skipped for that key and a synthesis-time warning is emitted, so the (rare) case where a token key resolves to a managed argument at deploy time — in which the construct-managed value would silently take precedence — is surfaced rather than hidden.

      Parameters:
      defaultArguments - the caller-supplied escape-hatch arguments, if any.
      See Also:
    • mergeDefaultArguments

      @Stability(Deprecated) @Deprecated @NotNull protected Map<String,String> mergeDefaultArguments()
      Deprecated.
      (deprecated) Merge the customer-supplied defaultArguments with the arguments this construct manages.

      The construct owns every argument it emits — whether the value comes from a dedicated typed prop (e.g. `continuousLogging`, `enableMetrics`, `sparkUI`) or from the job class itself (e.g. `--job-language`). Those arguments, plus the arguments Glue reserves for its own use, MUST be configured through their dedicated props rather than the untyped `defaultArguments` map, so there is exactly one way to express each intent. Passing such a key through `defaultArguments` therefore throws instead of silently winning or being silently dropped. A managed key whose supplied value is identical to the construct's value is not contradictory, so it is allowed rather than rejected (auto-correcting config is preferred over errors). Glue-reserved keys are never emitted by the construct, so there is no value to reconcile and they always throw. The reserved set is `_managedArgumentKeys` — every key the construct declared through setManagedArgument(java.lang.String,java.lang.String), whether or not a value was emitted for it. It is deliberately NOT derived from the keys that carry a value: a typed prop that turns a feature *off* (e.g. `enableMetrics: false`) emits no value but still reserves its key, so `defaultArguments` cannot silently re-enable it. Conflict detection relies on string equality of the argument keys, which cannot see through unresolved tokens (e.g. a key produced by `CfnJson` that only resolves at deploy time). If a key is a token, the check is skipped for that key and a synthesis-time warning is emitted, so the (rare) case where a token key resolves to a managed argument at deploy time — in which the construct-managed value would silently take precedence — is surfaced rather than hidden.

      See Also:
    • setManagedArgument

      @Stability(Deprecated) @Deprecated protected void setManagedArgument(@NotNull String key, @Nullable String value)
      Deprecated.
      (deprecated) Declare key as construct-managed and, when value is defined, emit it into the job's arguments.

      This is the single sink for every argument a job construct derives from its typed props (or from the job class itself). Call it once per managed key, passing undefined as the value when the corresponding feature is turned off or unset — the key is still reserved from defaultArguments either way, so a disabled feature cannot be re-enabled through the escape hatch. There is deliberately no other way for a subclass to emit a managed argument, so the reserved set can never drift from what is emitted.

      Parameters:
      key - the Glue argument key, e.g. --enable-metrics. This parameter is required.
      value - the value to emit, or undefined to reserve the key without emitting it.
    • setManagedArgument

      @Stability(Deprecated) @Deprecated protected void setManagedArgument(@NotNull String key)
      Deprecated.
      (deprecated) Declare key as construct-managed and, when value is defined, emit it into the job's arguments.

      This is the single sink for every argument a job construct derives from its typed props (or from the job class itself). Call it once per managed key, passing undefined as the value when the corresponding feature is turned off or unset — the key is still reserved from defaultArguments either way, so a disabled feature cannot be re-enabled through the escape hatch. There is deliberately no other way for a subclass to emit a managed argument, so the reserved set can never drift from what is emitted.

      Parameters:
      key - the Glue argument key, e.g. --enable-metrics. This parameter is required.
    • setupContinuousLogging

      @Stability(Deprecated) @Deprecated protected void setupContinuousLogging(@NotNull IRole role, @Nullable ContinuousLoggingProps props, @Nullable ISecurityConfiguration securityConfiguration)
      Deprecated.
      (deprecated) Register (and, when enabled, emit) the continuous-logging arguments this job manages.

      All five continuous-logging keys are reserved on every job type regardless of configuration: they are always registered through setManagedArgument(java.lang.String,java.lang.String), and carry a value only when logging is enabled. This keeps `defaultArguments` from re-enabling logging a user turned off.

      Parameters:
      role - The IAM role to grant write access to a custom log group, if one is provided. This parameter is required.
      props - The properties for continuous logging configuration.
      securityConfiguration - The security configuration attached to the job, if any.
    • setupContinuousLogging

      @Stability(Deprecated) @Deprecated protected void setupContinuousLogging(@NotNull IRole role, @Nullable ContinuousLoggingProps props)
      Deprecated.
      (deprecated) Register (and, when enabled, emit) the continuous-logging arguments this job manages.

      All five continuous-logging keys are reserved on every job type regardless of configuration: they are always registered through setManagedArgument(java.lang.String,java.lang.String), and carry a value only when logging is enabled. This keeps `defaultArguments` from re-enabling logging a user turned off.

      Parameters:
      role - The IAM role to grant write access to a custom log group, if one is provided. This parameter is required.
      props - The properties for continuous logging configuration.
    • setupContinuousLogging

      @Stability(Deprecated) @Deprecated protected void setupContinuousLogging(@NotNull IRole role)
      Deprecated.
      (deprecated) Register (and, when enabled, emit) the continuous-logging arguments this job manages.

      All five continuous-logging keys are reserved on every job type regardless of configuration: they are always registered through setManagedArgument(java.lang.String,java.lang.String), and carry a value only when logging is enabled. This keeps `defaultArguments` from re-enabling logging a user turned off.

      Parameters:
      role - The IAM role to grant write access to a custom log group, if one is provided. This parameter is required.
    • getRole

      @Stability(Deprecated) @Deprecated @NotNull public abstract IRole getRole()
      Deprecated.
      (deprecated) The IAM role Glue assumes to run this job.