There might be some kind of restrictions on your Network(Specially in Office Network) which won't allow you to sending e-mail using Gmail smtp port.
If this is not the case then attache log from error.log file of while sending email from Workflow.
Link talks about 5.4, but as I mentioned, I am using CQ 5.3. Also I am not using any java class to send mail, I am using norma author workflow, which just notify user on Email as well along with Inbox notification.
Below is the error related to sending mail I got:
*ERROR* [pool-3-thread-18-null(null)] com.day.cq.workflow.impl.email.EMailNotificationService error while sending email for -----------------------------
WorkItem Id: /etc/workflow/instances/2013-03-26/model_89457085531321/workItems/node1_etc_workflow_inst ances_2013-03-26_model_89457085531321
Workflow Id: /etc/workflow/instances/2013-03-26/model_89457085531321
Payload Type: JCR_PATH
key = historyEntryPath value = /etc/workflow/instances/2013-03-26/model_89457085531321/history/1364271444558
: org.apache.commons.mail.EmailException: Sending the email to the following server failed : smtp.gmail.com:25
I have one doubts: Why it says "smtp.gmail.com:25" here "25" is the port it is refering? If that so, I have given 465 in configuration as mentioned in my above post. Or it is jsut stack trace number?
That's odd. Was the port 465 opened in the box cq is running? Also enable debug in mail configuration & see.