Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #38495 > unrolled thread

Re: Use JavaMail API

Started bykumarimeenu09@gmail.com
First post2018-07-25 04:00 -0700
Last post2018-08-01 00:49 +0000
Articles 4 — 4 participants

Back to article view | Back to comp.lang.java.programmer

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Use JavaMail API kumarimeenu09@gmail.com - 2018-07-25 04:00 -0700
    Re: Use JavaMail API Eric Sosman <esosman@comcast-dot-net.invalid> - 2018-07-25 10:05 -0400
      Re: Use JavaMail API Eric Douglas <e.d.programmer@gmail.com> - 2018-07-25 08:40 -0700
        Re: Use JavaMail API Martin Gregorie <martin@mydomain.invalid> - 2018-08-01 00:49 +0000

#38495 — Re: Use JavaMail API

Fromkumarimeenu09@gmail.com
Date2018-07-25 04:00 -0700
SubjectRe: Use JavaMail API
Message-ID<42da993b-7e53-45e2-87e2-97163e01aa47@googlegroups.com>
On Thursday, 28 January 1999 13:30:00 UTC+5:30, 전정일  wrote:
> I try to use JavaMail API...
> but, I run "java msgshow" then
> 
> javax.mail.NoSuchProviderException: No provider for IMAP
>         at javax.mail.Session.getProvider(Session.java:232)
>         at javax.mail.Session.getStore(Session.java:306)
>         at javax.mail.Session.getStore(Session.java:286)
>         at msgshow.main(msgshow.java:23)
> 
> I install javamail classpath (mail.jar) and pop3(pop3.jar)
> 
> How to setup IMAP provider and POP3 provider?
> 
> Thanks in advance

Hi ,
I am getting the same error msg , when I used Imap for mailreding . Colud you please assist me , How can I proceed and resolved this problem .

Error Msg - 
javax.mail.NoSuchProviderException: No provider for imap
	at javax.mail.Session.getProvider(Session.java:479)
	at javax.mail.Session.getStore(Session.java:553)
	at javax.mail.Session.getStore(Session.java:533)

and my code is -
Properties properies = new Properties();
                        properies.setProperty("mail.store.protocol","imaps");   
                        Session emailSession= Session.getDefaultInstance(properies);
                        Store emailStore = emailSession.getStore("imaps");
                       emailStore.connect("imap.gmail.com","abc@gmail.com", password);

Thanks in Advance.

Kumari Meenu

[toc] | [next] | [standalone]


#38496

FromEric Sosman <esosman@comcast-dot-net.invalid>
Date2018-07-25 10:05 -0400
Message-ID<pja03l$ml6$1@dont-email.me>
In reply to#38495
On 7/25/2018 7:00 AM, kumarimeenu09@gmail.com wrote:
> On Thursday, 28 January 1999 13:30:00 UTC+5:30, 전정일  wrote:
>> I try to use JavaMail API...
>> [...]
>
> I am getting the same error msg , when I used Imap for mailreding .
> [...]

     (Nineteen and a half years between post and follow-up.  Is
this a record?)

     Try

https://javaee.github.io/javamail/FAQ.html#servletSecurityManager

or more generally,

https://javaee.github.io/javamail/FAQ.html

-- 
esosman@comcast-dot-net.invalid
Nine hundred ten days to go.

[toc] | [prev] | [next] | [standalone]


#38498

FromEric Douglas <e.d.programmer@gmail.com>
Date2018-07-25 08:40 -0700
Message-ID<b0f05abb-12d1-449b-a40d-44685cbb50c6@googlegroups.com>
In reply to#38496
On Wednesday, July 25, 2018 at 10:05:50 AM UTC-4, Eric Sosman wrote:
>      (Nineteen and a half years between post and follow-up.  Is
> this a record?)
> 
>      Try
> 
> https://javaee.github.io/javamail/FAQ.html#servletSecurityManager
> 
> or more generally,
> 
> https://javaee.github.io/javamail/FAQ.html
> 

That's not a follow up as in reply, just someone saying they have the same problem someone else had 19 years ago.  While that API has changed a bit(I haven't heard of a pop3.jar), if you only specifically need Gmail I just use their API (https://developers.google.com/api-client-library/java/apis/gmail/v1).

[toc] | [prev] | [next] | [standalone]


#38514

FromMartin Gregorie <martin@mydomain.invalid>
Date2018-08-01 00:49 +0000
Message-ID<pjr022$50i$1@news.albasani.net>
In reply to#38498
On Wed, 25 Jul 2018 08:40:29 -0700, Eric Douglas wrote:

> On Wednesday, July 25, 2018 at 10:05:50 AM UTC-4, Eric Sosman wrote:
>>      (Nineteen and a half years between post and follow-up.  Is
>> this a record?)
>> 
>>      Try
>> 
>> https://javaee.github.io/javamail/FAQ.html#servletSecurityManager
>> 
>> or more generally,
>> 
>> https://javaee.github.io/javamail/FAQ.html
>> 
>> 
> That's not a follow up as in reply, just someone saying they have the
> same problem someone else had 19 years ago.  While that API has changed
> a bit(I haven't heard of a pop3.jar), if you only specifically need
> Gmail I just use their API
> (https://developers.google.com/api-client-library/java/apis/gmail/v1).

Late reply (been away - just returned): I had that problem recently when 
compiling code under Java 8 that was written and last compiled under Java 
6 and that used the mstor provider to access mail held as multiple 
messages in each file. The cure was simple: download the current mstor 
source, compile it and use it. The problem seemed to be a change in the 
the security managed to made it incompatible with old mstor jarfiles, so 
presumably the same problem can happen with any old mail provider code.


-- 
Martin    | martin at
Gregorie  | gregorie dot org

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.java.programmer


csiph-web