How do I write messages to the output log on AWS Glue?

后端 未结 5 753
小鲜肉
小鲜肉 2021-02-05 06:00

AWS Glue jobs log output and errors to two different CloudWatch logs, /aws-glue/jobs/error and /aws-glue/jobs/output by default. When I include p

5条回答
  •  余生分开走
    2021-02-05 06:35

    Just in case this helps. This works to change the log level.

    sc = SparkContext()
    sc.setLogLevel('DEBUG')
    glueContext = GlueContext(sc)
    logger = glueContext.get_logger()
    logger.info('Hello Glue')
    

提交回复
热议问题