output log for RDS stored procedure

1

Hi Team,

I have an RDS MySQL DB (one aurora serverless and one is normal MYSQL RDS), I created a stored procedure in my DB in which I do some logs outputs :

log("begin of my procedure")

.....

log("bla bla bla....")

....

log("End of my procedure")

where can I find the output log after my stored procedure is successfully finished?

in RDS console => logs & event; is empty no log there

in the DB cluster parameter group I enabled : slow_log, server_audit_logging, general_log

I see some logs in cloud watch but not my custom logs " "begin of my procedure", "End of my procedure"

also in RDS console => logs & event section I only see events, no logs generated

any ideas please to see my custom logs printed by my stored procedure in CWL or in rds logs & event? thanks a lot

1개 답변
0

Hi,

The standard logging mechanisms: general/slow/audit logs do not capture query results. Since RDS/Aurora do not provide access to the host, it would not be possible to access files that are written locally, so you will need to write to a file externally to a service like S3, for example.

AWS
Shiv
답변함 2년 전
  • Hi, thank you for your answer, in fact, I call my stored procedure from my was glue pyspark job not from a local machine. Is there a way to capture the result of the execution of my stored procedure from within the glue job? because the issue I'm facing now is that my glue job after loading => call the stored procedure => the stored procedure fail but the glue job is marked as succeeded.

    I'm looking at how to know from within my glue job whether or not the stored procedure runs successfully so that I can pass or fail the job.

    to avoid the scenario when the stored procedure fails but the job itself is marked as succeeded. Thank you

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인