1 2 3 Previous Next 35 Replies Latest reply on Jun 17, 2010 7:37 AM by virendra agarwal Go to original post
      • 30. Re: Unable to set the mail configuration properties in JBPM 4.0
        ciccio ciccio Newbie

        Thanks for reply. Look at http://community.jboss.org/message/529821#529821 to help me, there is explained my problem too.

        Thanks again

        • 31. Re: Unable to set the mail configuration properties in JBPM 4.0
          Anand Kumar Novice

          try to re-ordering your jbpm.mail.properties file with starttls be the first statement and other follow it

           

          jbpm supports smtps protocol.

          • 32. Re: Unable to set the mail configuration properties in JBPM 4.0
            ciccio ciccio Newbie

            akstifr ha scritto:

             

            try to re-ordering your jbpm.mail.properties file with starttls be the first statement and other follow it

             

            jbpm supports smtps protocol.

            Ok i'll try soon.

            Thanks

            • 33. Re: Unable to set the mail configuration properties in JBPM 4.0
              Ronald van Kuijk Master
              or leave the starttls out... it is not in the standalone example either...
              • 34. Re: Unable to set the mail configuration properties in JBPM 4.0
                virendra agarwal Newbie

                Hi,

                I am Using teh same jbpm.mail.properties file

                 

                mail.smtp.host    smtp.gmail.com
                mail.smtp.port    465
                mail.smtp.socketFactory.port 465
                mail.smtp.auth  true
                mail.from       mymail@gmail.com
                mail.user        mymail
                mail.password    viren123
                mail.debug      true

                 

                My process.jdpl.xml is

                 

                <?xml version="1.0" encoding="UTF-8"?>

                <process name="InlineMail" xmlns="http://jbpm.org/4.3/jpdl">

                  <start g="20,25,80,40">
                    <transition to="send rectify note" />
                  </start>

                 

                  <mail name="send rectify note" language="juel" g="99,25,115,45">
                    <to addresses="virendag@rsgsystems.com" />
                    <cc users="bb" groups="innerparty" />
                    <bcc groups="thinkpol" />
                    <subject>rectify ${newspaper}</subject>
                    <text>${newspaper} ${date} reporting bb dayorder doubleplusungood
                      refs unpersons rewrite fullwise upsub antefiling</text>

                    <transition to="end" />
                  </mail>

                 

                  <state name="end" g="240,25,98,45"/>

                 

                </process>

                 

                and my test case is

                 

                public class InlineMailTest extends JbpmTestCase {

                 

                  Wiser wiser = null;
                 
                  String groupId1;
                 
                  String groupId2;

                 

                  protected void setUp() throws Exception {
                    super.setUp();

                 

                    // deploy process
                    String deploymentId = repositoryService.createDeployment()
                        .addResourceFromClasspath("org/jbpm/examples/mail/inline/process.jpdl.xml")
                        .deploy();
                    registerDeployment(deploymentId);

                 

                    // create actors
                    identityService.createUser("bb", "Big Brother", null, "virendag@rsgsystems.com");
                    identityService.createUser("obrien", null, "O'Brien", "virendag@rsgsystems.com");
                    identityService.createUser("charr", null, "Charrington", "virendag@rsgsystems.com");
                    groupId1 = identityService.createGroup("thinkpol");
                    groupId2 = identityService.createGroup("innerparty");
                    identityService.createMembership("obrien", groupId2);
                    identityService.createMembership("charr", groupId1);
                    identityService.createMembership("obrien", groupId1);

                 

                  }

                 

                  protected void tearDown() throws Exception {
                   // wiser.stop();

                 

                    // delete actors
                    identityService.deleteUser("bb");
                    identityService.deleteUser("obrien");
                    identityService.deleteUser("charr");
                   
                    identityService.deleteGroup(groupId1);
                    identityService.deleteGroup(groupId2);
                   
                    super.tearDown();
                  }

                 

                  public void testInlineMail() throws MessagingException, IOException {
                    // prepare dynamic values
                    String newspaper = "times";
                    Calendar calendar = Calendar.getInstance();
                    calendar.clear();
                    calendar.set(1983, Calendar.DECEMBER, 3);
                    Date date = calendar.getTime();
                    // assemble variables
                    Map<String, Object> variables = new HashMap<String, Object>();
                    variables.put("newspaper", newspaper);
                    variables.put("date", date);
                    // start process instance

                    executionService.startProcessInstanceByKey("InlineMail", variables);
                  }
                }

                 

                But when run this test it always throw

                 

                Caused by: javax.mail.AuthenticationFailedException

                 

                Once i removed the mail.smtp.auth  false it works fine but can send mail to other domain server apart from gmail

                Please tell em what point i am missing here.

                I am really stuck with.

                Thanks

                • 35. Re: Unable to set the mail configuration properties in JBPM 4.0
                  virendra agarwal Newbie

                  Hi,

                  I am Using teh same jbpm.mail.properties file

                   

                  mail.smtp.host    smtp.gmail.com
                  mail.smtp.port    465
                  mail.smtp.socketFactory.port 465
                  mail.smtp.auth  true
                  mail.from       mymail@gmail.com
                  mail.user        mymail
                  mail.password    viren123
                  mail.debug      true

                   

                  My process.jdpl.xml is

                   

                  <?xml version="1.0" encoding="UTF-8"?>

                  <process name="InlineMail" xmlns="http://jbpm.org/4.3/jpdl">

                    <start g="20,25,80,40">
                      <transition to="send rectify note" />
                    </start>

                   

                    <mail name="send rectify note" language="juel" g="99,25,115,45">
                      <to addresses="virendag@rsgsystems.com" />
                      <cc users="bb" groups="innerparty" />
                      <bcc groups="thinkpol" />
                      <subject>rectify ${newspaper}</subject>
                      <text>${newspaper} ${date} reporting bb dayorder doubleplusungood
                        refs unpersons rewrite fullwise upsub antefiling</text>

                      <transition to="end" />
                    </mail>

                   

                    <state name="end" g="240,25,98,45"/>

                   

                  </process>

                   

                  and my test case is

                   

                  public class InlineMailTest extends JbpmTestCase {

                   

                    Wiser wiser = null;
                   
                    String groupId1;
                   
                    String groupId2;

                   

                    protected void setUp() throws Exception {
                      super.setUp();

                   

                      // deploy process
                      String deploymentId = repositoryService.createDeployment()
                          .addResourceFromClasspath("org/jbpm/examples/mail/inline/process.jpdl.xml")
                          .deploy();
                      registerDeployment(deploymentId);

                   

                      // create actors
                      identityService.createUser("bb", "Big Brother", null, "virendag@rsgsystems.com");
                      identityService.createUser("obrien", null, "O'Brien", "virendag@rsgsystems.com");
                      identityService.createUser("charr", null, "Charrington", "virendag@rsgsystems.com");
                      groupId1 = identityService.createGroup("thinkpol");
                      groupId2 = identityService.createGroup("innerparty");
                      identityService.createMembership("obrien", groupId2);
                      identityService.createMembership("charr", groupId1);
                      identityService.createMembership("obrien", groupId1);

                   

                    }

                   

                    protected void tearDown() throws Exception {
                     // wiser.stop();

                   

                      // delete actors
                      identityService.deleteUser("bb");
                      identityService.deleteUser("obrien");
                      identityService.deleteUser("charr");
                     
                      identityService.deleteGroup(groupId1);
                      identityService.deleteGroup(groupId2);
                     
                      super.tearDown();
                    }

                   

                    public void testInlineMail() throws MessagingException, IOException {
                      // prepare dynamic values
                      String newspaper = "times";
                      Calendar calendar = Calendar.getInstance();
                      calendar.clear();
                      calendar.set(1983, Calendar.DECEMBER, 3);
                      Date date = calendar.getTime();
                      // assemble variables
                      Map<String, Object> variables = new HashMap<String, Object>();
                      variables.put("newspaper", newspaper);
                      variables.put("date", date);
                      // start process instance

                      executionService.startProcessInstanceByKey("InlineMail", variables);
                    }
                  }

                   

                  But when run this test it always throw

                   

                  Caused by: javax.mail.AuthenticationFailedException

                   

                  Once i removed the mail.smtp.auth  false it works fine but can send mail to other domain server apart from gmail

                  Please tell em what point i am missing here.

                  I am really stuck with.

                  Thanks

                  1 2 3 Previous Next