Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-27 Thread Georgiy Rakov
On 24.06.2016 13:47, Daniel Fuchs wrote: Thanks Georgiy! On 24/06/16 11:25, Georgiy Rakov wrote: After some thoughts I agree, redefining createContext would just check that reflection deals with methods overriding properly. BTW if a factory is an instance of JAXBContextFactory it would seem m

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-24 Thread Daniel Fuchs
Thanks Georgiy! On 24/06/16 11:25, Georgiy Rakov wrote: After some thoughts I agree, redefining createContext would just check that reflection deals with methods overriding properly. BTW if a factory is an instance of JAXBContextFactory it would seem more natural to invoke createContext by firs

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-24 Thread Georgiy Rakov
Hi Daniel, please see my replies embedded below. On 23.06.2016 19:07, Daniel Fuchs wrote: Hi, Here is the new webrev: http://cr.openjdk.java.net/~dfuchs/webrev_8150173/webrev.03/ On 23/06/16 14:55, Daniel Fuchs wrote: if I understand correctly JAXBContextWithSubclassedFactory is supposed to

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-23 Thread Daniel Fuchs
Hi, Here is the new webrev: http://cr.openjdk.java.net/~dfuchs/webrev_8150173/webrev.03/ On 23/06/16 14:55, Daniel Fuchs wrote: if I understand correctly JAXBContextWithSubclassedFactory is supposed to capture the idea of Test9 but it doesn't. [...] Oh - I see, I missed that - I was chasing

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-23 Thread Daniel Fuchs
Hi Georgiy On 23/06/16 13:48, Georgiy Rakov wrote: Hi Daniel, if I understand correctly JAXBContextWithSubclassedFactory is supposed to capture the idea of Test9 but it doesn't. FactoryBase shouldn't implement JAXBContextFactory but Factory should: public static class FactoryBase {

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-23 Thread Georgiy Rakov
Hi Daniel, if I understand correctly JAXBContextWithSubclassedFactory is supposed to capture the idea of Test9 but it doesn't. FactoryBase shouldn't implement JAXBContextFactory but Factory should: public static class FactoryBase { public JAXBContext createContext(...) ...

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-22 Thread Mandy Chung
> On Jun 22, 2016, at 8:09 AM, Daniel Fuchs wrote: > > Hi Georgiy, > > I added the (reworked) promised testcases. > I believe I have captured the intent of what you suggested. > > http://cr.openjdk.java.net/~dfuchs/webrev_8150173/webrev.02/ Looks okay to me. I’ll let Georgiy to review the te

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-22 Thread Daniel Fuchs
Hi Georgiy, I added the (reworked) promised testcases. I believe I have captured the intent of what you suggested. http://cr.openjdk.java.net/~dfuchs/webrev_8150173/webrev.02/ best regards, -- daniel http://cr.openjdk.java.net/~dfuchs/webrev_8150173/webrev.02/ On 22/06/16 11:55, Georgiy Rakov

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-22 Thread Mandy Chung
> On Jun 22, 2016, at 12:06 AM, Daniel Fuchs wrote: > > Hi Mandy, > > On 21/06/16 20:51, Mandy Chung wrote: >>> 8150173: JAXBContext.newInstance causes PrivilegedActionException >>>when createContext's declared in absract class extended >>>by discovered JAXB implementation >>> h

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-22 Thread Daniel Fuchs
Thanks Georgiy, You're right - more tests can't harm :-) I'll add the two scenarios you described (Test9 from your other mail and the test case described below). My current test only has the Test7 that was described in JBS. Thanks for that BTW - the isolated test case made it so much easier to

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-22 Thread Georgiy Rakov
This is about backward compatibility, but anyway would it be good to add to tests static method case (also please see the attached file): public static class FactoryBase { public static JAXBContext createContext(Class[] classesToBeBound, Map properties) throws JAXBException {

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-22 Thread Georgiy Rakov
On 21.06.2016 22:51, Mandy Chung wrote: On Jun 21, 2016, at 10:39 AM, Daniel Fuchs wrote: Hi, Please find below a somewhat trivial patch for 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovere

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-22 Thread Daniel Fuchs
Hi Mandy, On 21/06/16 20:51, Mandy Chung wrote: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation https://bugs.openjdk.java.net/browse/JDK-8150173 Patch: http://cr.openjdk.j

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-21 Thread Mandy Chung
> On Jun 21, 2016, at 10:39 AM, Daniel Fuchs wrote: > > Hi, > > Please find below a somewhat trivial patch for > > 8150173: JAXBContext.newInstance causes PrivilegedActionException > when createContext's declared in absract class extended > by discovered JAXB implementation > h

Re: RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-21 Thread Lance Andersen
Hi Daniel, Looks OK. I know you have run the JCK tests as well. Best Lance > On Jun 21, 2016, at 1:39 PM, Daniel Fuchs wrote: > > Hi, > > Please find below a somewhat trivial patch for > > 8150173: JAXBContext.newInstance causes PrivilegedActionException > when createContext's decla

RFR: 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation

2016-06-21 Thread Daniel Fuchs
Hi, Please find below a somewhat trivial patch for 8150173: JAXBContext.newInstance causes PrivilegedActionException when createContext's declared in absract class extended by discovered JAXB implementation https://bugs.openjdk.java.net/browse/JDK-8150173 Patch: http://cr.open