If you are getting invalid SSL certificate error in the browser when serving assets from the s3 bucket and using s3 bucket name as a subdomain. This quick tip might be a help.
In my case, I had a dot in the bucket name so the domain created was like https://akhil.bansal.s3.amazo…… I removed the dot from the bucket name and it worked perfectly. Looks like S3 ssl certificate does not support a dot in the subdomain.
Earlier whenever we wanted to create a HABTM join table, we do this like: Now, in edge rails after this commit we can use a migration helper for the same:
Most developers use ActiveRecord callbacks after_create/after_update/after_destroy to generate background job, expire cache, etc., but they don’t realize these callbacks are still wrapped in database transaction, they probably got unexpected results like the app queued a job but the record is not created/updated(transaction rolled back). For such situations after_commit callback should be used. after_commit is introduced … Continue reading ActiveRecord after_commit hook