From bugzilla-daemon at icedtea.classpath.org Mon Sep 1 12:01:17 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 01 Sep 2014 12:01:17 +0000 Subject: [Bug 1971] New: OpenJDK 64-Bit Server VM (24.65-b04 mixed mode linux-amd64 compressed oops) Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1971 Bug ID: 1971 Summary: OpenJDK 64-Bit Server VM (24.65-b04 mixed mode linux-amd64 compressed oops) Product: IcedTea Version: unspecified Hardware: x86_64 OS: Linux Status: NEW Severity: major Priority: P5 Component: AddVM Assignee: doko at ubuntu.com Reporter: pradeepkiruvale at gmail.com CC: unassigned at icedtea.classpath.org Hi, I was trying to run a tool called eclipseclp, it is a opensource tool based on prolog. After compilation it creates a java interface, I started the tool and pressed some options the following bug came up. # # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007f14cace92e4, pid=23011, tid=139728282662720 # # JRE version: OpenJDK Runtime Environment (7.0_65-b32) (build 1.7.0_65-b32) # Java VM: OpenJDK 64-Bit Server VM (24.65-b04 mixed mode linux-amd64 compressed oops) # Problematic frame: # C [libeclipse.so+0x312e4] ec_emulate+0xe0e4 Regards, Pradeep -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From helpcrypto at gmail.com Mon Sep 1 12:59:58 2014 From: helpcrypto at gmail.com (helpcrypto helpcrypto) Date: Mon, 1 Sep 2014 14:59:58 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <540180DB.4050109@gmx.de> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <1222082700.26083069.1409081718997.JavaMail.zimbra@redhat.com> <982339162.26695106.1409162928407.JavaMail.zimbra@redhat.com> <958305698.27235425.1409240834908.JavaMail.zimbra@redhat.com> <1885159478.27899833.1409329251634.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> Message-ID: On Sat, Aug 30, 2014 at 9:44 AM, Jacob Wisor wrote: > No no, do not start playing around with visible and hidden UI components. > It is even worse when they change their layout or start jumping around like > it is now. Generally, there is never any need to hide UI components. If > there seems to be, then either there is something wrong with the basic > design of a window or dialog, or you should have very good reasons to do > so. And, in this case there is surely *no* reason to hide any components > dynamically at all. Again, stick to disabling components. This should be > enough. > > @helpcrypto > Yes, it is against basic UI design principles to have hiding UI > components, unless there are really good reasons to do so. Can you point a style guide, or a gui-best-practices which advices on that? I have seen several GUIs wich only show the user what he needs to see, and I found them KISS-compliant Please do not start giving advice on something you do not know or have no > experience in. This only confuses young or new developers. > I didn't gave any advice, just gave my opinion (and said that it was only that many times). Unfortunately, because of your attempt to play around with hiding UI > components you have introduced a new bug. When "Limit cache size" is > checked and the spinner is 0 then all components for setting up the cache > location suddenly disappear. Limit checked, value=0->no cache, hence no need of location, compresion level or anything. It's not a bug. The warning under spinner informs about that. > And, as soon as the value becomes greater than 1, they become visible > again. This is very odd, weird, and confusing. Again, do not play around > with hiding UI components. > The reason why i suggested "no cach?" instead of 0. Is all this GUI discussion open (anyway) to discussion? @Lukas: i'll wait for patch update before testing (seems Jacob doesnt like what we did :P). Regards -------------- next part -------------- An HTML attachment was scrubbed... URL: From gnu.andrew at redhat.com Tue Sep 2 04:00:00 2014 From: gnu.andrew at redhat.com (Andrew Hughes) Date: Tue, 2 Sep 2014 00:00:00 -0400 (EDT) Subject: IcedTea 2.5.2 Released: Back in the Groovy! In-Reply-To: <54018991.4080800@redhat.com> References: <20140829232404.GA30397@carrie.the212.com> <54018991.4080800@redhat.com> Message-ID: <1334143567.16378945.1409630400127.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 30/08/14 00:24, Andrew Hughes wrote: > > With the previous release, a > > number of Java tools and applications, including Groovy, were broken. > > This release should resolve these issues. > > That's interesting. What was this regression, and what was the fix? I > can't tell from the release notes. > > Andrew. > > It's: S8051012 [0], LP1360392 [1]: Regression in verifier for method call from inside of a branch Fix is [2]. [0] https://bugs.openjdk.java.net/browse/JDK-8051012 [1] https://bugs.launchpad.net/bugs/1360392 [2] http://icedtea.classpath.org/hg/icedtea7-forest/hotspot/rev/bad107a5d096 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) PGP Key: 248BDC07 (https://keys.indymedia.org/) Fingerprint = EC5A 1F5E C0AD 1D15 8F1F 8F91 3B96 A578 248B DC07 From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 04:03:25 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:03:25 +0000 Subject: [Bug 1965] [IcedTea8] Allow builds on PaX kernels In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1965 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 04:03:26 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:03:26 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Bug 1282 depends on bug 1965, which changed state. Bug 1965 Summary: [IcedTea8] Allow builds on PaX kernels http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1965 What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 04:03:41 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:03:41 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Bug 1282 depends on bug 1970, which changed state. Bug 1970 Summary: [IcedTea8] Add AArch64 JIT port http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1970 What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 04:03:41 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:03:41 +0000 Subject: [Bug 1970] [IcedTea8] Add AArch64 JIT port In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1970 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 04:18:58 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:18:58 +0000 Subject: [Bug 1903] [IcedTea7] [REGRESSION] Bug reports now lack IcedTea version & distribution packaging information In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1903 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Tue Sep 2 04:20:13 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:20:13 +0000 Subject: /hg/release/icedtea7-forest-2.5: Added tag icedtea-2.5.2 for cha... Message-ID: changeset dfe93c56a5f6 in /hg/release/icedtea7-forest-2.5 details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5?cmd=changeset;node=dfe93c56a5f6 author: andrew date: Fri Aug 29 21:08:27 2014 +0100 Added tag icedtea-2.5.2 for changeset de1fbcb08558 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r de1fbcb08558 -r dfe93c56a5f6 .hgtags --- a/.hgtags Wed Jul 16 00:20:25 2014 +0100 +++ b/.hgtags Fri Aug 29 21:08:27 2014 +0100 @@ -486,3 +486,4 @@ fa242615607fa5f6cdd1ae93bc2fb9cc2100c179 jdk7u65-b18 64dbd70735c775bef1faf873e4bec65d73d597cb jdk7u65-b19 483622a291d726960c8ccca5650de9569f269d7a icedtea-2.5.1 +de1fbcb0855887e803b71a8da642c377c85c3780 icedtea-2.5.2 From andrew at icedtea.classpath.org Tue Sep 2 04:20:18 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:20:18 +0000 Subject: /hg/release/icedtea7-forest-2.5/corba: Added tag icedtea-2.5.2 f... Message-ID: changeset 1d178f96bc11 in /hg/release/icedtea7-forest-2.5/corba details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/corba?cmd=changeset;node=1d178f96bc11 author: andrew date: Fri Aug 29 21:08:14 2014 +0100 Added tag icedtea-2.5.2 for changeset 06663e4cfbbe diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r 06663e4cfbbe -r 1d178f96bc11 .hgtags --- a/.hgtags Wed Jul 16 00:20:14 2014 +0100 +++ b/.hgtags Fri Aug 29 21:08:14 2014 +0100 @@ -488,3 +488,4 @@ b7f66b9f9e8e099428ed7640a184f6135b77e40d jdk7u65-b18 50ddba8882e7e95150418a30bfc3ee62e3c28c6c jdk7u65-b19 895c6b10499623eaf8897a9ed0d28a34e4cd4a89 icedtea-2.5.1 +06663e4cfbbeade300222eeae55856940b2ffbee icedtea-2.5.2 From andrew at icedtea.classpath.org Tue Sep 2 04:20:25 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:20:25 +0000 Subject: /hg/release/icedtea7-forest-2.5/jaxp: Added tag icedtea-2.5.2 fo... Message-ID: changeset 771d2a0e90ae in /hg/release/icedtea7-forest-2.5/jaxp details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jaxp?cmd=changeset;node=771d2a0e90ae author: andrew date: Fri Aug 29 21:08:15 2014 +0100 Added tag icedtea-2.5.2 for changeset d77720c6a36f diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r d77720c6a36f -r 771d2a0e90ae .hgtags --- a/.hgtags Wed Jul 16 00:20:15 2014 +0100 +++ b/.hgtags Fri Aug 29 21:08:15 2014 +0100 @@ -489,3 +489,4 @@ 45db678253587755df4a00066e42e2fce04bbb71 jdk7u65-b18 4e323af07c47061109fb5f585613b0cc4b4208ca jdk7u65-b19 59a1a3e441089798763016eedfcc066e6f437bd2 icedtea-2.5.1 +d77720c6a36f0b9c995e47badb8efddd0e8f2021 icedtea-2.5.2 From andrew at icedtea.classpath.org Tue Sep 2 04:20:31 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:20:31 +0000 Subject: /hg/release/icedtea7-forest-2.5/jaxws: Added tag icedtea-2.5.2 f... Message-ID: changeset c46dd3a579f0 in /hg/release/icedtea7-forest-2.5/jaxws details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jaxws?cmd=changeset;node=c46dd3a579f0 author: andrew date: Fri Aug 29 21:08:17 2014 +0100 Added tag icedtea-2.5.2 for changeset aac78bd724c4 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r aac78bd724c4 -r c46dd3a579f0 .hgtags --- a/.hgtags Wed Jul 16 00:20:16 2014 +0100 +++ b/.hgtags Fri Aug 29 21:08:17 2014 +0100 @@ -488,3 +488,4 @@ dedfc93eeb5f4b28ad1a91902a0676aef0937e42 jdk7u65-b18 db4cccbfd72fc265b736a273797963754434a7d2 jdk7u65-b19 b5384b2fb987fc5310167a9524b4a5ee1880f56b icedtea-2.5.1 +aac78bd724c437cefd9ba8abb280df34609ca936 icedtea-2.5.2 From andrew at icedtea.classpath.org Tue Sep 2 04:20:37 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:20:37 +0000 Subject: /hg/release/icedtea7-forest-2.5/langtools: Added tag icedtea-2.5... Message-ID: changeset fe8926c95af9 in /hg/release/icedtea7-forest-2.5/langtools details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/langtools?cmd=changeset;node=fe8926c95af9 author: andrew date: Fri Aug 29 21:08:26 2014 +0100 Added tag icedtea-2.5.2 for changeset f444e2a77643 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r f444e2a77643 -r fe8926c95af9 .hgtags --- a/.hgtags Wed Jul 16 00:20:24 2014 +0100 +++ b/.hgtags Fri Aug 29 21:08:26 2014 +0100 @@ -488,3 +488,4 @@ 0f809f893588548a3b5c8441e28c9e0a62bc13ef jdk7u65-b18 eae289997f58ef6396dc323c3d5b93a56fb43573 jdk7u65-b19 4c827dc3de054b03008402f571ca645cbf7939e6 icedtea-2.5.1 +f444e2a7764393fa62cc1ec9dcaa3a9f7ebbc551 icedtea-2.5.2 From andrew at icedtea.classpath.org Tue Sep 2 04:20:43 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:20:43 +0000 Subject: /hg/release/icedtea7-forest-2.5/hotspot: 5 new changesets Message-ID: changeset e56036fb0f9e in /hg/release/icedtea7-forest-2.5/hotspot details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=e56036fb0f9e author: andrew date: Thu Aug 28 15:26:22 2014 +0100 RH1015432: java-1.7.0-openjdk: Fails on PPC with StackOverflowError (revised fix for PPC32) Contributed-by: chphilli at redhat.com changeset c7d38df7983b in /hg/release/icedtea7-forest-2.5/hotspot details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=c7d38df7983b author: andrew date: Tue Aug 26 17:14:48 2014 +0100 PR1948: Only try and symlink debuginfo if STRIP_POLICY is other than no_strip changeset 2266438ca53f in /hg/release/icedtea7-forest-2.5/hotspot details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=2266438ca53f author: andrew date: Wed Aug 27 19:47:02 2014 +0100 PR1948: Fix indenting changeset 4ad43b271fd4 in /hg/release/icedtea7-forest-2.5/hotspot details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=4ad43b271fd4 author: hseigel date: Tue Aug 05 23:10:45 2014 -0400 8051012: Regression in verifier for method call from inside of a branch Summary: Fix stackmap matching for branches. Reviewed-by: coleenp, lfoltan, acorn changeset 51c1c024f887 in /hg/release/icedtea7-forest-2.5/hotspot details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=51c1c024f887 author: andrew date: Fri Aug 29 21:08:29 2014 +0100 Added tag icedtea-2.5.2 for changeset 4ad43b271fd4 diffstat: .hgtags | 1 + make/linux/makefiles/vm.make | 32 ++++++++++++++++---------------- src/os/linux/vm/os_linux.cpp | 10 +++++++++- src/share/vm/classfile/stackMapTable.cpp | 23 +++++++++++------------ src/share/vm/classfile/stackMapTable.hpp | 6 +++--- src/share/vm/classfile/verifier.cpp | 13 ++----------- src/share/vm/classfile/verifier.hpp | 16 ---------------- 7 files changed, 42 insertions(+), 59 deletions(-) diffs (262 lines): diff -r f0d8ef4d9f93 -r 51c1c024f887 .hgtags --- a/.hgtags Wed Aug 13 15:49:58 2014 +0100 +++ b/.hgtags Fri Aug 29 21:08:29 2014 +0100 @@ -708,3 +708,4 @@ d006213be74730453cf5c3ce31f1d1d505334419 jdk7u65-b18 1d8226b3e9896656451801393eb3ae394faeb638 jdk7u65-b19 02066294d005e81a81d3a01ec549716ebcc65723 icedtea-2.5.1 +4ad43b271fd439317ec422b5ea35ea3483d40922 icedtea-2.5.2 diff -r f0d8ef4d9f93 -r 51c1c024f887 make/linux/makefiles/vm.make --- a/make/linux/makefiles/vm.make Wed Aug 13 15:49:58 2014 +0100 +++ b/make/linux/makefiles/vm.make Fri Aug 29 21:08:29 2014 +0100 @@ -355,28 +355,28 @@ fi \ } - ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) - ifneq ($(STRIP_POLICY),no_strip) +ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) + ifneq ($(STRIP_POLICY),no_strip) $(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJVM_DEBUGINFO) $(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJVM_DEBUGINFO) $@ - endif - ifeq ($(STRIP_POLICY),all_strip) + endif + ifeq ($(STRIP_POLICY),all_strip) $(QUIETLY) $(STRIP) $@ - else - ifeq ($(STRIP_POLICY),min_strip) + else + ifeq ($(STRIP_POLICY),min_strip) $(QUIETLY) $(STRIP) -g $@ - # implied else here is no stripping at all - endif - endif - endif - $(QUIETLY) [ -f $(LIBJVM_G_DEBUGINFO) ] || ln -s $(LIBJVM_DEBUGINFO) $(LIBJVM_G_DEBUGINFO) - ifeq ($(ZIP_DEBUGINFO_FILES),1) - ifneq ($(STRIP_POLICY),no_strip) - $(ZIPEXE) -q -y $(LIBJVM_DIZ) $(LIBJVM_DEBUGINFO) $(LIBJVM_G_DEBUGINFO) + # implied else here is no stripping at all + endif + endif + ifneq ($(STRIP_POLICY),no_strip) + $(QUIETLY) [ -f $(LIBJVM_G_DEBUGINFO) ] || ln -s $(LIBJVM_DEBUGINFO) $(LIBJVM_G_DEBUGINFO) + ifeq ($(ZIP_DEBUGINFO_FILES),1) + $(ZIPEXE) -q -y $(LIBJVM_DIZ) $(LIBJVM_DEBUGINFO) $(LIBJVM_G_DEBUGINFO) $(RM) $(LIBJVM_DEBUGINFO) $(LIBJVM_G_DEBUGINFO) [ -f $(LIBJVM_G_DIZ) ] || { ln -s $(LIBJVM_DIZ) $(LIBJVM_G_DIZ); } - endif - endif + endif + endif +endif DEST_SUBDIR = $(JDK_LIBDIR)/$(VM_SUBDIR) DEST_JVM = $(DEST_SUBDIR)/$(LIBJVM) diff -r f0d8ef4d9f93 -r 51c1c024f887 src/os/linux/vm/os_linux.cpp --- a/src/os/linux/vm/os_linux.cpp Wed Aug 13 15:49:58 2014 +0100 +++ b/src/os/linux/vm/os_linux.cpp Fri Aug 29 21:08:29 2014 +0100 @@ -4843,6 +4843,7 @@ pthread_mutex_init(&dl_mutex, NULL); +NOT_ZERO ( // If the pagesize of the VM is greater than 8K determine the appropriate // number of initial guard pages. The user can change this with the // command line arguments, if needed. @@ -4851,6 +4852,7 @@ StackRedPages = 1; StackShadowPages = round_to((StackShadowPages*Linux::vm_default_page_size()), vm_page_size()) / vm_page_size(); } + ) } // To install functions for atexit system call @@ -4903,10 +4905,16 @@ // size. Add a page for compiler2 recursion in main thread. // Add in 2*BytesPerWord times page size to account for VM stack during // class initialization depending on 32 or 64 bit VM. +NOT_ZERO ( os::Linux::min_stack_allowed = MAX2(os::Linux::min_stack_allowed, (size_t)(StackYellowPages+StackRedPages+StackShadowPages) * Linux::page_size() + (2*BytesPerWord COMPILER2_PRESENT(+1)) * Linux::vm_default_page_size()); - + ) +ZERO_ONLY ( + os::Linux::min_stack_allowed = MAX2(os::Linux::min_stack_allowed, + (size_t)(StackYellowPages+StackRedPages+StackShadowPages+ + 2*BytesPerWord COMPILER2_PRESENT(+1)) * Linux::page_size()); + ) size_t threadStackSizeInBytes = ThreadStackSize * K; if (threadStackSizeInBytes != 0 && threadStackSizeInBytes < os::Linux::min_stack_allowed) { diff -r f0d8ef4d9f93 -r 51c1c024f887 src/share/vm/classfile/stackMapTable.cpp --- a/src/share/vm/classfile/stackMapTable.cpp Wed Aug 13 15:49:58 2014 +0100 +++ b/src/share/vm/classfile/stackMapTable.cpp Fri Aug 29 21:08:29 2014 +0100 @@ -70,24 +70,26 @@ bool StackMapTable::match_stackmap( StackMapFrame* frame, int32_t target, - bool match, bool update, ErrorContext* ctx, TRAPS) const { + bool match, bool update, bool handler, ErrorContext* ctx, TRAPS) const { int index = get_index_from_offset(target); - return match_stackmap(frame, target, index, match, update, ctx, THREAD); + return match_stackmap(frame, target, index, match, update, handler, ctx, THREAD); } // Match and/or update current_frame to the frame in stackmap table with // specified offset and frame index. Return true if the two frames match. +// handler is true if the frame in stackmap_table is for an exception handler. // -// The values of match and update are: _match__update_ +// The values of match and update are: _match__update__handler // -// checking a branch target/exception handler: true false +// checking a branch target: true false false +// checking an exception handler: true false true // linear bytecode verification following an -// unconditional branch: false true +// unconditional branch: false true false // linear bytecode verification not following an -// unconditional branch: true true +// unconditional branch: true true false bool StackMapTable::match_stackmap( StackMapFrame* frame, int32_t target, int32_t frame_index, - bool match, bool update, ErrorContext* ctx, TRAPS) const { + bool match, bool update, bool handler, ErrorContext* ctx, TRAPS) const { if (frame_index < 0 || frame_index >= _frame_count) { *ctx = ErrorContext::missing_stackmap(frame->offset()); frame->verifier()->verify_error( @@ -98,11 +100,9 @@ StackMapFrame *stackmap_frame = _frame_array[frame_index]; bool result = true; if (match) { - // when checking handler target, match == true && update == false - bool is_exception_handler = !update; // Has direct control flow from last instruction, need to match the two // frames. - result = frame->is_assignable_to(stackmap_frame, is_exception_handler, + result = frame->is_assignable_to(stackmap_frame, handler, ctx, CHECK_VERIFY_(frame->verifier(), result)); } if (update) { @@ -126,7 +126,7 @@ StackMapFrame* frame, int32_t target, TRAPS) const { ErrorContext ctx; bool match = match_stackmap( - frame, target, true, false, &ctx, CHECK_VERIFY(frame->verifier())); + frame, target, true, false, false, &ctx, CHECK_VERIFY(frame->verifier())); if (!match || (target < 0 || target >= _code_length)) { frame->verifier()->verify_error(ctx, "Inconsistent stackmap frames at branch target %d", target); @@ -134,7 +134,6 @@ } // check if uninitialized objects exist on backward branches check_new_object(frame, target, CHECK_VERIFY(frame->verifier())); - frame->verifier()->update_furthest_jump(target); } void StackMapTable::check_new_object( diff -r f0d8ef4d9f93 -r 51c1c024f887 src/share/vm/classfile/stackMapTable.hpp --- a/src/share/vm/classfile/stackMapTable.hpp Wed Aug 13 15:49:58 2014 +0100 +++ b/src/share/vm/classfile/stackMapTable.hpp Fri Aug 29 21:08:29 2014 +0100 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -74,12 +74,12 @@ // specified offset. Return true if the two frames match. bool match_stackmap( StackMapFrame* current_frame, int32_t offset, - bool match, bool update, ErrorContext* ctx, TRAPS) const; + bool match, bool update, bool handler, ErrorContext* ctx, TRAPS) const; // Match and/or update current_frame to the frame in stackmap table with // specified offset and frame index. Return true if the two frames match. bool match_stackmap( StackMapFrame* current_frame, int32_t offset, int32_t frame_index, - bool match, bool update, ErrorContext* ctx, TRAPS) const; + bool match, bool update, bool handler, ErrorContext* ctx, TRAPS) const; // Check jump instructions. Make sure there are no uninitialized // instances on backward branch. diff -r f0d8ef4d9f93 -r 51c1c024f887 src/share/vm/classfile/verifier.cpp --- a/src/share/vm/classfile/verifier.cpp Wed Aug 13 15:49:58 2014 +0100 +++ b/src/share/vm/classfile/verifier.cpp Fri Aug 29 21:08:29 2014 +0100 @@ -630,8 +630,6 @@ // flow from current instruction to the next // instruction in sequence - set_furthest_jump(0); - Bytecodes::Code opcode; while (!bcs.is_last_bytecode()) { // Check for recursive re-verification before each bytecode. @@ -1788,7 +1786,7 @@ // If matched, current_frame will be updated by this method. bool matches = stackmap_table->match_stackmap( current_frame, this_offset, stackmap_index, - !no_control_flow, true, &ctx, CHECK_VERIFY_(this, 0)); + !no_control_flow, true, false, &ctx, CHECK_VERIFY_(this, 0)); if (!matches) { // report type error verify_error(ctx, "Instruction type does not match stack map"); @@ -1835,7 +1833,7 @@ } ErrorContext ctx; bool matches = stackmap_table->match_stackmap( - new_frame, handler_pc, true, false, &ctx, CHECK_VERIFY(this)); + new_frame, handler_pc, true, false, true, &ctx, CHECK_VERIFY(this)); if (!matches) { verify_error(ctx, "Stack map does not match the one at " "exception handler %d", handler_pc); @@ -2243,13 +2241,6 @@ return; } - // Make sure that this call is not jumped over. - if (bci < furthest_jump()) { - verify_error(ErrorContext::bad_code(bci), - "Bad method call from inside of a branch"); - return; - } - // Make sure that this call is not done from within a TRY block because // that can result in returning an incomplete object. Simply checking // (bci >= start_pc) also ensures that this call is not done after a TRY diff -r f0d8ef4d9f93 -r 51c1c024f887 src/share/vm/classfile/verifier.hpp --- a/src/share/vm/classfile/verifier.hpp Wed Aug 13 15:49:58 2014 +0100 +++ b/src/share/vm/classfile/verifier.hpp Fri Aug 29 21:08:29 2014 +0100 @@ -256,9 +256,6 @@ ErrorContext _error_context; // contains information about an error - // Used to detect illegal jumps over calls to super() and this() in ctors. - int32_t _furthest_jump; - void verify_method(methodHandle method, TRAPS); char* generate_code_data(methodHandle m, u4 code_length, TRAPS); void verify_exception_handler_table(u4 code_length, char* code_data, @@ -402,19 +399,6 @@ TypeOrigin ref_ctx(const char* str, TRAPS); - // Keep track of the furthest branch done in a method to make sure that - // there are no branches over calls to super() or this() from inside of - // a constructor. - int32_t furthest_jump() { return _furthest_jump; } - - void set_furthest_jump(int32_t target) { - _furthest_jump = target; - } - - void update_furthest_jump(int32_t target) { - if (target > _furthest_jump) _furthest_jump = target; - } - }; inline int ClassVerifier::change_sig_to_verificationType( From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 04:20:49 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:20:49 +0000 Subject: [Bug 1948] [IcedTea7] Only try and symlink debuginfo if STRIP_POLICY is other than no_strip In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1948 --- Comment #4 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=c7d38df7983b author: andrew date: Tue Aug 26 17:14:48 2014 +0100 PR1948: Only try and symlink debuginfo if STRIP_POLICY is other than no_strip -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 04:21:01 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:21:01 +0000 Subject: [Bug 1948] [IcedTea7] Only try and symlink debuginfo if STRIP_POLICY is other than no_strip In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1948 --- Comment #5 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=2266438ca53f author: andrew date: Wed Aug 27 19:47:02 2014 +0100 PR1948: Fix indenting -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Tue Sep 2 04:21:09 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 02 Sep 2014 04:21:09 +0000 Subject: /hg/release/icedtea7-forest-2.5/jdk: 3 new changesets Message-ID: changeset fe87c474cd59 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=fe87c474cd59 author: weijun date: Thu Jul 10 14:25:23 2014 +0800 8049480: Current versions of Java can't verify jars signed and timestamped with Java 9 Reviewed-by: xuelei, mullan changeset 1e6a8564aa34 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=1e6a8564aa34 author: andrew date: Fri Aug 29 18:35:06 2014 +0100 Bump package version to 2.5.2 changeset 229136ffcb00 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=229136ffcb00 author: andrew date: Fri Aug 29 21:08:23 2014 +0100 Added tag icedtea-2.5.2 for changeset 1e6a8564aa34 diffstat: .hgtags | 1 + make/jdk_generic_profile.sh | 2 +- src/share/classes/com/sun/crypto/provider/OAEPParameters.java | 19 +- src/share/classes/sun/security/pkcs/SignerInfo.java | 20 +- src/share/classes/sun/security/util/SignatureFileVerifier.java | 4 +- src/share/classes/sun/security/x509/AlgorithmId.java | 17 + test/sun/security/tools/jarsigner/TimestampAlg.java | 156 ++++++++++ 7 files changed, 182 insertions(+), 37 deletions(-) diffs (306 lines): diff -r c07c208fe259 -r 229136ffcb00 .hgtags --- a/.hgtags Thu Aug 14 19:44:12 2014 +0100 +++ b/.hgtags Fri Aug 29 21:08:23 2014 +0100 @@ -472,3 +472,4 @@ 7f7430459adfe7b7fb65da8c3fac2ac5e3495ea1 jdk7u65-b18 ba6cef21c369076be97dd8133fd4a158cd486bd8 jdk7u65-b19 d6d4b6c9f5b48254a6dc1430dee9ee85d7f86b97 icedtea-2.5.1 +1e6a8564aa3400fe8f84085c908f55a942d426f0 icedtea-2.5.2 diff -r c07c208fe259 -r 229136ffcb00 make/jdk_generic_profile.sh --- a/make/jdk_generic_profile.sh Thu Aug 14 19:44:12 2014 +0100 +++ b/make/jdk_generic_profile.sh Fri Aug 29 21:08:23 2014 +0100 @@ -573,7 +573,7 @@ # IcedTea versioning export ICEDTEA_NAME="IcedTea" -export PACKAGE_VERSION="2.5.2pre01" +export PACKAGE_VERSION="2.5.2" export DERIVATIVE_ID="${ICEDTEA_NAME} ${PACKAGE_VERSION}" if [ -e ${jdk_topdir} ] ; then diff -r c07c208fe259 -r 229136ffcb00 src/share/classes/com/sun/crypto/provider/OAEPParameters.java --- a/src/share/classes/com/sun/crypto/provider/OAEPParameters.java Thu Aug 14 19:44:12 2014 +0100 +++ b/src/share/classes/com/sun/crypto/provider/OAEPParameters.java Fri Aug 29 21:08:23 2014 +0100 @@ -106,20 +106,6 @@ } } - private static String convertToStandardName(String internalName) { - if (internalName.equals("SHA")) { - return "SHA-1"; - } else if (internalName.equals("SHA256")) { - return "SHA-256"; - } else if (internalName.equals("SHA384")) { - return "SHA-384"; - } else if (internalName.equals("SHA512")) { - return "SHA-512"; - } else { - return internalName; - } - } - protected void engineInit(byte[] encoded) throws IOException { DerInputStream der = new DerInputStream(encoded); @@ -131,7 +117,7 @@ DerValue data = datum[i]; if (data.isContextSpecific((byte) 0x00)) { // hash algid - mdName = convertToStandardName(AlgorithmId.parse + mdName = AlgorithmId.getStandardDigestName(AlgorithmId.parse (data.data.getDerValue()).getName()); } else if (data.isContextSpecific((byte) 0x01)) { // mgf algid @@ -141,7 +127,8 @@ } AlgorithmId params = AlgorithmId.parse( new DerValue(val.getEncodedParams())); - String mgfDigestName = convertToStandardName(params.getName()); + String mgfDigestName = AlgorithmId.getStandardDigestName( + params.getName()); if (mgfDigestName.equals("SHA-1")) { mgfSpec = MGF1ParameterSpec.SHA1; } else if (mgfDigestName.equals("SHA-256")) { diff -r c07c208fe259 -r 229136ffcb00 src/share/classes/sun/security/pkcs/SignerInfo.java --- a/src/share/classes/sun/security/pkcs/SignerInfo.java Thu Aug 14 19:44:12 2014 +0100 +++ b/src/share/classes/sun/security/pkcs/SignerInfo.java Fri Aug 29 21:08:23 2014 +0100 @@ -273,24 +273,6 @@ return certList; } - // Copied from com.sun.crypto.provider.OAEPParameters. - private static String convertToStandardName(String internalName) { - if (internalName.equals("SHA")) { - return "SHA-1"; - } else if (internalName.equals("SHA224")) { - return "SHA-224"; - } else if (internalName.equals("SHA256")) { - return "SHA-256"; - } else if (internalName.equals("SHA384")) { - return "SHA-384"; - } else if (internalName.equals("SHA512")) { - return "SHA-512"; - } else { - return internalName; - } - } - - /* Returns null if verify fails, this signerInfo if verify succeeds. */ SignerInfo verify(PKCS7 block, byte[] data) @@ -330,7 +312,7 @@ return null; MessageDigest md = MessageDigest.getInstance( - convertToStandardName(digestAlgname)); + AlgorithmId.getStandardDigestName(digestAlgname)); byte[] computedMessageDigest = md.digest(data); if (messageDigest.length != computedMessageDigest.length) diff -r c07c208fe259 -r 229136ffcb00 src/share/classes/sun/security/util/SignatureFileVerifier.java --- a/src/share/classes/sun/security/util/SignatureFileVerifier.java Thu Aug 14 19:44:12 2014 +0100 +++ b/src/share/classes/sun/security/util/SignatureFileVerifier.java Fri Aug 29 21:08:23 2014 +0100 @@ -39,6 +39,7 @@ import sun.misc.BASE64Decoder; import sun.security.jca.Providers; +import sun.security.x509.AlgorithmId; public class SignatureFileVerifier { @@ -613,7 +614,8 @@ throws NoSuchAlgorithmException, SignatureException { MessageDigest md = - MessageDigest.getInstance(token.getHashAlgorithm().getName()); + MessageDigest.getInstance(AlgorithmId.getStandardDigestName( + token.getHashAlgorithm().getName())); if (!Arrays.equals(token.getHashedMessage(), md.digest(signature))) { throw new SignatureException("Signature timestamp (#" + diff -r c07c208fe259 -r 229136ffcb00 src/share/classes/sun/security/x509/AlgorithmId.java --- a/src/share/classes/sun/security/x509/AlgorithmId.java Thu Aug 14 19:44:12 2014 +0100 +++ b/src/share/classes/sun/security/x509/AlgorithmId.java Fri Aug 29 21:08:23 2014 +0100 @@ -940,4 +940,21 @@ } return null; } + + // Copied from com.sun.crypto.provider.OAEPParameters.convertToStandardName() + public static String getStandardDigestName(String internalName) { + if (internalName.equals("SHA")) { + return "SHA-1"; + } else if (internalName.equals("SHA224")) { + return "SHA-224"; + } else if (internalName.equals("SHA256")) { + return "SHA-256"; + } else if (internalName.equals("SHA384")) { + return "SHA-384"; + } else if (internalName.equals("SHA512")) { + return "SHA-512"; + } else { + return internalName; + } + } } diff -r c07c208fe259 -r 229136ffcb00 test/sun/security/tools/jarsigner/TimestampAlg.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/sun/security/tools/jarsigner/TimestampAlg.java Fri Aug 29 21:08:23 2014 +0100 @@ -0,0 +1,156 @@ +/* + * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8049480 + * @summary Current versions of Java can't verify jars signed and timestamped with Java 9 + */ + +import java.io.InputStream; +import java.nio.file.Files; +import java.nio.file.Paths; +import java.util.jar.JarEntry; +import java.util.jar.JarFile; + +public class TimestampAlg { + + public static void main(String[] args) throws Exception { + // This is a very simple jar file signed by JDK 9 with a timestamp + // using the SHA-256 message digest algorithm. + String var = + "504b0304140008080800c28ee844000000000000000000000000140000004d45" + + "54412d494e462f4d414e49464553542e4d4615cd4d0b82301c80f1fb60df61c7" + + "42666a9928749846f4aa8924745cf9d716b6c59c48df3ebd3e87df73e152d4d0" + + "195a82ee849211716d07a344033750d1f83785d076e830b8be1fb80e15d28096" + + "bca535ef4c058fbe21b34cf3670b2451faab3437a333c708a3947f20220ca362" + + "cfa8e7afe95634e32b22af821df2d6786d5ff637cf3abfe3f05e4190a42779b5" + + "76470532cbd56a798105db4cd01f504b07082c3740c69c000000a6000000504b" + + "0304140008080800c28ee8440000000000000000000000000f0000004d455441" + + "2d494e462f4f4c442e534675cf416f823018c6f13b09dfa1c7ed50575014493c" + + "80bae8a6a091383db6f082955a595b86ecd34fb3db92dd9ed32fff67c74b494d" + + "a300ef41697e9501727ac4b6768b10bbde10cf7809dae03595bcf81d5ce2d018" + + "c5596340072872bdecd02554f17c70f16fc730cfb4a8c6b0ad934fdfb6d0e854" + + "fbb794ecd52eeecbe5e45f394071bd9ef30c34131f87a3e956c561efb0938e56" + + "b7573d5c6cd3599bbe2ddd28acfafe9d992aa006721c758fe2718fe0b6753c6f" + + "e410cca50125a9c005d52607d694e82951341380a657555f1535f7a3cfb6655b" + + "31bd4080c2bf55016a98a8f2512948f7e5968dfbbe495fcca6383bdfe753a467" + + "90ca41a297861544cd270fe807504b0708521a35550201000048010000504b03" + + "04140008080800c28ee844000000000000000000000000100000004d4554412d" + + "494e462f4f4c442e52534185947b38d37d1fc7fdb61923530eb39e688622a77e" + + "5b666ab9939c9544c831ee39d42c9511e576d8c8b9876745b5743b5414268718" + + "b969548e95d61c2224b47423a648393d73dd5d4fe5b9afe7f9f3f3b9deefeff5" + + "bd3e9ff7e7053210ba708476bc55fc6719400292c340a8800cc4460800e06441" + + "1938c23bde0af083c22080b81828fd5d08e430200f4006a41664003772a01000" + + "028145a66e3cba6af9a601a44516246e1d2805873ac1a0f2d093545f70b3920c" + + "ce00248246e04ec20e02e8262a09200e6ff0adfc2f3d0350fbf149d12fa00c40" + + "564cd497823000406cb4ef6571fdec06c95a370fde860e89425861e16e0b19a1" + + "4c6c4f52d6102dd3a6bf45e740d9a0bed342ee5e832885fa1a979dc7e6161253" + + "4c2cda0362e5ec02ae440e44e80c56bffc4ab4f349f3b1f6bddae8c2979fca4b" + + "5e7e46ac2fa529481dd8d750a26dcd7d74deb8dde7fc70c072465af0a1e359af" + + "4cf4b1aaa14fc4238cee096ca3133575d52179a7e7da8990f6ed5da71ca84c37" + + "2d3117c356b1ac2cdde3c8600ead44f8878b2f8f10831f4d5d590a28d95b316c" + + "cf456277a83533e12ea42a14c8fc05da6b2483b74ab7c4e70a2dd60f417d2f97" + + "3359bb233e3d6b5ab60202e7bd7b4fd7f228febd1f0403b0c62f4190b69264bf" + + "72426589ab516d00040a880137b0200654114d4d050943c11490e82d88b38ecd" + + "26a42c027cd749ffe67955e7d9357b81aece4e877d49ee62b8afeed7a755fa9e" + + "786d6edc5d7e5ae3603e5d6e39d0cbc74300c35eb354282842a183159763c67a" + + "35b0b1ac1929e7b8ad510da5aa454d5eb3034cf11d27f594326384873f7c8949" + + "1a7f4a3cfccb892faf873c621292bd597072cdcd732d1ee7490e611ec28c90f9" + + "81bbd71ef0e4b50c4e93869c9af8c9d3d154169bbf8dff7aa706ebac1f6d2589" + + "8078532a9867e31d7f576365bc0c6c132fb7719b58d88ebcf438715768aea361" + + "f7017f614acfaf465e6d794b84e317b2937d66a8f5cea13666d541cce02705a8" + + "cef2d6d2f69b96ac88fec9998228a7c1d96d09c315b29797ecda02250dc7383a" + + "6f2bf75b0f17d48c07afa48c640d3478dd3ad18963c0712003ae27ca3a885a9b" + + "bcef71fef1027e8e228c01885dede0446717674996f8f413f59a5c3f91a001c0" + + "b632f78891424ce58a58df39727a6cc492ea4c94d5f23f6ad1276561d6eb057f" + + "befab3e5baff5dec50224a891fb49c29ab6cd6cab3f7731d097fc3d65e949b33" + + "b7a578f0b379e47a98c0a91b5fb0ce685952a78afc5cfa0e373df4a035c15132" + + "bb62a6387ad8caaadab680b8a169805e49b69e5ad8409de9b7079b6def2af45a" + + "dada5e7cdee4b5359892d1803dfc765dd18849fd0bf44b64866ed654fc117ea6" + + "5e6b1922eff99b73f0c77257e994d307defc9a29cedd1ac7be68a626d6edf96e" + + "c692bdf22ee792369dd535a0dfa7d711396996f692895df223eaaa5f47414f45" + + "b2c3b39d65772575c5cf4a437319b00990011b834b7f1b0c623d048963c07a44" + + "4dfe4f60813d12b5b87f0b16ea0f6e0096e30973075d454238d411260ee2d6a8" + + "61aa68a6bb3119ab837aaa39abd612eab39f9da4665c977e0cff019201a19384" + + "d3222b5a160ffe07340620c10d220998e65d3431411e13916b4e44ae191143fa" + + "be91cb1605ff6d2db96470d220e2af3c40f6ed5d032ee2cfe022bafd240fa1fd" + + "5f6e3567dd9071543e381b57bdd80cb1575a376abcc947495167e61e6e32a1ae" + + "93d416c8bc197b6bda347e6bcc6553839ed0a78d7ac28d57f2f7f8cd857d14e4" + + "497caa1cd34e1829aa7574aa3984ad39934e765598bdf0356c31a8f5c4a316d6" + + "c6beedf3add584c5769a6901a7836d3b32e3a03c58c739a6969e0260a002f463" + + "2773e84174c7faa41086e0d5d0ceaefc4df5a443d4e8af8a462dd67181ce11be" + + "a6ef64ce907252a0d0e6f03ef467e6763c244c48574856017d294607d3f87d5b" + + "0eb9eba2c60dc6c70dddfb837914babf172574ef99a4bb1e361353de4d95c576" + + "c494e1e9bce62d4fd08ad5e731691d1895636525bb79d76b2f1ce07d1604aa95" + + "8d9dfc8b5b6ee01110b3ca2d75181a44c528300ede3c612715c04d7baf786a18" + + "87b5f95861180fa256055b006005b67aa0923a70405c5c022af903f0187b3458" + + "748cc0bdfeac15adcb7029a17883d0f5ef80573caa61574bb66747bc61aae3ca" + + "0c3fe8bcd223d54fd7f5a2270843f9559a99f76aff45d965ba91374fa05a706f" + + "479416999389d4e29eb74a1984a30face935fd2118a580a3cd5a6567c2e21e92" + + "bb358c54822aaa049a8f47712889ee4507ae4ffd150ba50f444f99701c49fa97" + + "72edc44e69cfcda9cffc9f75c49fdb6b28b9699a2567289979dfd42664626232" + + "75b682be2baf3856623e37bb47c15e3e8e084771e4f3e7b53265efbc48e616cd" + + "ed18c4a546de3f5bd793857c9c7a99615161b7cdcca53fa1d4c119a33bb150a4" + + "6e4996450724eed76ae3d2dbc02f147228353241beba27e585a3dd556b8e5c2e" + + "5f4a3328fd214663223ec27d4fb134873a85630026a204ee5e059ee29a807f3f" + + "82ffcd3b2437cc1bf95a6813dec5195b38cd227002c6f5f53dcd1212f7182038" + + "9877b7ddf1ff2c0c65993b9524d3b41eca82ded2b951471c871b741fddd9fdc7" + + "70a79bb91c3d91f3a9aa8f880ec22099418c65654a7e3a25c4d8925e98e1e390" + + "1437e8767c9debf521e5c93ad5026ab8e5ef9696983ba6d0335e17de6ba65747" + + "91a0fb6ecdf20bde55874082a7f19b4332ddbba24d4eb98a9b0e55e4294f37be" + + "edd62a3e3ebccf8ded49f3a029fa76becf3389a386d2d62faca4f85cbb643489" + + "2e2abfd66dbe727f4fe28d8f8d551e0f8f4c8eda346c66d1bc6fa7a68eabdfb7" + + "0d0a34e65910bba73413ad8680dfaa473753ae9e2fd032d8f6cc66d19c57e679" + + "7fcc33cce8df504b0708267c480f1b08000030090000504b0304140008080800" + + "b78ee844000000000000000000000000090004004d4554412d494e462ffeca00" + + "000300504b0708000000000200000000000000504b0304140008080800b78ee8" + + "440000000000000000000000000100000041f3cb2fc9c8cc4be70200504b0708" + + "3c0a34d30a00000008000000504b01021400140008080800c28ee8442c3740c6" + + "9c000000a60000001400000000000000000000000000000000004d4554412d49" + + "4e462f4d414e49464553542e4d46504b01021400140008080800c28ee844521a" + + "355502010000480100000f00000000000000000000000000de0000004d455441" + + "2d494e462f4f4c442e5346504b01021400140008080800c28ee844267c480f1b" + + "0800003009000010000000000000000000000000001d0200004d4554412d494e" + + "462f4f4c442e525341504b01021400140008080800b78ee84400000000020000" + + "00000000000900040000000000000000000000760a00004d4554412d494e462f" + + "feca0000504b01021400140008080800b78ee8443c0a34d30a00000008000000" + + "0100000000000000000000000000b30a000041504b0506000000000500050027" + + "010000ec0a00000000"; + byte[] data = new byte[var.length()/2]; + for (int i=0; i References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1948 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ptisnovs at icedtea.classpath.org Tue Sep 2 09:24:43 2014 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Tue, 02 Sep 2014 09:24:43 +0000 Subject: /hg/gfx-test: Yet another ten new tests added into BitBltBuffere... Message-ID: changeset bc3ca0c7b1e7 in /hg/gfx-test details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=bc3ca0c7b1e7 author: Pavel Tisnovsky date: Tue Sep 02 11:25:53 2014 +0200 Yet another ten new tests added into BitBltBufferedImageOp. diffstat: ChangeLog | 5 + src/org/gfxtest/testsuites/BitBltBufferedImageOp.java | 170 ++++++++++++++++++ 2 files changed, 175 insertions(+), 0 deletions(-) diffs (192 lines): diff -r c70c07e559a4 -r bc3ca0c7b1e7 ChangeLog --- a/ChangeLog Tue Aug 26 11:15:55 2014 +0200 +++ b/ChangeLog Tue Sep 02 11:25:53 2014 +0200 @@ -1,3 +1,8 @@ +2014-09-02 Pavel Tisnovsky + + * src/org/gfxtest/testsuites/BitBltBufferedImageOp.java: + Yet another ten new tests added into BitBltBufferedImageOp. + 2014-08-26 Pavel Tisnovsky * src/org/gfxtest/testsuites/BitBltBufferedImageOp.java: diff -r c70c07e559a4 -r bc3ca0c7b1e7 src/org/gfxtest/testsuites/BitBltBufferedImageOp.java --- a/src/org/gfxtest/testsuites/BitBltBufferedImageOp.java Tue Aug 26 11:15:55 2014 +0200 +++ b/src/org/gfxtest/testsuites/BitBltBufferedImageOp.java Tue Sep 02 11:25:53 2014 +0200 @@ -3458,6 +3458,176 @@ } /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_3BYTE_BGR}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientType3ByteBGR(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_3BYTE_BGR, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_4BYTE_ABGR}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientType4ByteABGR(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_4BYTE_ABGR, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_4BYTE_ABGR_PRE}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientType4ByteABGR_Pre(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_4BYTE_ABGR_PRE, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_BYTE_BINARY}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeByteBinary(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_BYTE_BINARY, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_BYTE_INDEXED}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeByteIndexed(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_BYTE_INDEXED, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_BYTE_GRAY}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeByteGray(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_BYTE_GRAY, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_INT_BGR}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeIntBGR(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_INT_BGR, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_INT_RGB}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeIntRGB(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_INT_RGB, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_INT_ARGB}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeIntARGB(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_INT_ARGB, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_INT_ARGB_PRE}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeIntARGB_Pre(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_INT_ARGB_PRE, rasterOp); + } + + /** * Entry point to the test suite. * * @param args not used in this case From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 14:07:59 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 14:07:59 +0000 Subject: [Bug 1972] New: Don't compil on arm Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1972 Bug ID: 1972 Summary: Don't compil on arm Product: IcedTea Version: 7-hg Hardware: arm OS: Linux Status: NEW Severity: major Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: alpha_one_x86 at first-world.info CC: unassigned at icedtea.classpath.org Created attachment 1157 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1157&action=edit error at compilation Hello, I have compiled from gcj the version 6.1.13.3, then now I try upgrate to 7.2.4.7, I'm on arm. I use the gentoo official ebuild, and I have: Attached file is the error and system info. Cheers, -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 14:11:11 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 14:11:11 +0000 Subject: [Bug 1972] Don't compil on arm In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1972 --- Comment #1 from BRULE Herman --- Created attachment 1158 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1158&action=edit system info -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at icedtea.classpath.org Tue Sep 2 15:46:25 2014 From: jkang at icedtea.classpath.org (jkang at icedtea.classpath.org) Date: Tue, 02 Sep 2014 15:46:25 +0000 Subject: /hg/icedtea-web: Fixed CacheUtil clearCache to also remove LRU e... Message-ID: changeset 2979fa371add in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=2979fa371add author: Jie Kang date: Tue Sep 02 11:46:09 2014 -0400 Fixed CacheUtil clearCache to also remove LRU entries. 2014-09-02 Jie Kang Fixed CacheUtils clearCache method to also clear the Least Recently Used entries. * netx/net/sourceforge/jnlp/cache/CacheUtil.java diffstat: ChangeLog | 6 ++++++ netx/net/sourceforge/jnlp/cache/CacheUtil.java | 5 +++++ 2 files changed, 11 insertions(+), 0 deletions(-) diffs (34 lines): diff -r c45cd47e962b -r 2979fa371add ChangeLog --- a/ChangeLog Wed Aug 20 15:49:58 2014 -0400 +++ b/ChangeLog Tue Sep 02 11:46:09 2014 -0400 @@ -1,3 +1,9 @@ +2014-09-02 Jie Kang + + Fixed CacheUtils clearCache method to also clear the Least Recently Used + entries. + * netx/net/sourceforge/jnlp/cache/CacheUtil.java: + 2014-08-20 Jie Kang Improved CacheEntry locking system to respect threads and processes. diff -r c45cd47e962b -r 2979fa371add netx/net/sourceforge/jnlp/cache/CacheUtil.java --- a/netx/net/sourceforge/jnlp/cache/CacheUtil.java Wed Aug 20 15:49:58 2014 -0400 +++ b/netx/net/sourceforge/jnlp/cache/CacheUtil.java Tue Sep 02 11:46:09 2014 -0400 @@ -134,12 +134,17 @@ } OutputController.getLogger().log(OutputController.Level.ERROR_DEBUG, "Clearing cache directory: " + cacheDir); + lruHandler.lock(); try { cacheDir = cacheDir.getCanonicalFile(); FileUtils.recursiveDelete(cacheDir, cacheDir); cacheDir.mkdir(); + lruHandler.clearLRUSortedEntries(); + lruHandler.store(); } catch (IOException e) { throw new RuntimeException(e); + } finally { + lruHandler.unlock(); } return true; } From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 16:13:11 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 16:13:11 +0000 Subject: [Bug 1730] javaws launcher cannot handle ampersand in Client.Security.sessionCookieNames In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1730 --- Comment #1 from Omair Majid --- Please be aware that your file is in fact incorrect. "The JNLP file is an XML document" [1]. An XML document must encode entities, including '&', correctly. What you have is a JNLP file that violates the specification. The easiest way to fix the problem is fix the file. If you rely on behaviour that is specific to the implemenation (and specifically violates the standard), it's not really sensible to expect that to work elsewhere. Anyway, this bug should be fixed in IcedTea-Web 1.5. We have switched to an html-like parser that should accept malfromed JNLP files. Can you please test it with that? [1] http://docs.oracle.com/javase/8/docs/technotes/guides/javaws/developersguide/syntax.html -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 16:19:09 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 16:19:09 +0000 Subject: [Bug 1676] enhance the list of secure jnlp properties to support useLegacyMergeSort In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1676 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #2 from Omair Majid --- Fixed in HEAD. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 16:20:14 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 16:20:14 +0000 Subject: [Bug 1614] javaws fails on special character in jnlp In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1614 --- Comment #4 from Omair Majid --- Can you try this with icedtea-web 1.5? The tagsoup-based parser should handle this better. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 16:35:20 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 16:35:20 +0000 Subject: [Bug 1973] New: Make configuration files easier to use Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1973 Bug ID: 1973 Summary: Make configuration files easier to use Product: Thermostat Version: hg Hardware: all OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: Thermostat Assignee: unassigned at icedtea.classpath.org Reporter: omajid at redhat.com CC: thermostat at icedtea.classpath.org >From [1]: """ Aside (some food for thought for 2.0): The number of thermostat configuration files tends to grow. From a sys-admin point of view this is hard to maintain. One needs to remember where the config file is, what it's name is and various properties files seem to use different casing/syntax. It would be nice to unify thermostat configuration somehow. Perhaps have one file in THERMOSTAT_HOME and another in USER_THERMOSTAT_HOME. How a suitable format of such a file could look like I'd leave up for discussion for the time being :) """ I agree with the assesment of the issue. We have too many config files. They all with their own syntax (or at least, style). They have different meanings and usage. They use different parsers. [1] http://icedtea.classpath.org/pipermail/thermostat/2014-September/010630.html -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From gnu.andrew at redhat.com Tue Sep 2 16:39:10 2014 From: gnu.andrew at redhat.com (Andrew Hughes) Date: Tue, 2 Sep 2014 12:39:10 -0400 (EDT) Subject: [IcedTea-Web] Fwd: hs err_pid2237/ 2356 /2624/2765 /3275 /3372 /3390/ 5803/ 6979.log In-Reply-To: <5405F19A.7010307@yahoo.fr> References: <5405F19A.7010307@yahoo.fr> Message-ID: <511532172.17115956.1409675950308.JavaMail.zimbra@redhat.com> Looks like an IcedTea-Web crash. ----- Forwarded Message ----- > Ref.link > It has been working only a few times.It is important for me.Can you help me > > -- > Jacques glass > > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) PGP Key: 248BDC07 (https://keys.indymedia.org/) Fingerprint = EC5A 1F5E C0AD 1D15 8F1F 8F91 3B96 A578 248B DC07 -------------- next part -------------- A non-text attachment was scrubbed... Name: 01.png Type: image/png Size: 269962 bytes Desc: not available URL: From jkang at redhat.com Tue Sep 2 18:23:10 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 2 Sep 2014 14:23:10 -0400 (EDT) Subject: [rfc][icedtea-web] ResourceTracker Download Performance Test In-Reply-To: <971492461.21673115.1408116714569.JavaMail.zimbra@redhat.com> References: <971492461.21673115.1408116714569.JavaMail.zimbra@redhat.com> Message-ID: <1257931795.29079856.1409682190254.JavaMail.zimbra@redhat.com> ----- Original Message ----- > Hello, > > > The attached patch adds a single test to ResourceTracker that downloads > multiple resources from a public github repo hosted by myself. The purpose > of this is to test that downloading simple resources works and to see the > performance of our ResourceTracker implementation. > > At the moment it is placed in the unit test file ResourceTrackerTest though I > would not call it a unit test as it does have a non-local dependency on the > repo. Should we consider adding a separate performance or integration test > section to our codebase? I think this is a good idea as there are some > "unit" tests in our codebase that aren't really unit tests and have extra > requirements when run (ie. not really standalone). Hello, Ping; I have improved the test by making it use a temporary cache. However I don't think downloading from a github repo is the best idea. Does anyone have any suggestions? I think having tests for the download functionality is quite important. Thanks, > > > > Regards, > > -- > > Jie Kang > -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-rt-download-test-1.patch Type: text/x-patch Size: 3708 bytes Desc: not available URL: From omajid at redhat.com Tue Sep 2 19:32:10 2014 From: omajid at redhat.com (Omair Majid) Date: Tue, 2 Sep 2014 15:32:10 -0400 Subject: [rfc][icedtea-web] ResourceTracker Download Performance Test In-Reply-To: <1257931795.29079856.1409682190254.JavaMail.zimbra@redhat.com> References: <971492461.21673115.1408116714569.JavaMail.zimbra@redhat.com> <1257931795.29079856.1409682190254.JavaMail.zimbra@redhat.com> Message-ID: <20140902193210.GD3151@redhat.com> Hi, * Jie Kang [2014-09-02 14:25]: > I have improved the test by making it use a temporary cache. However I > don't think downloading from a github repo is the best idea. Does > anyone have any suggestions? What capabilities do you need from the download URL? If you just need an alternative to github, you can also use a personal repo at icedtea.classpath.org. Let me know if you decide to use that and I can help you set it up. > I think having tests for the download > functionality is quite important. I agree. Tests to know that thing is working and working fast are great to have. However, these should be moved to integration tests and run using the web server that's part of the test suite. Here are my reasons for this: - The URL is an external resource; unit tests should not require network connectivity. - Since it's a performance test, the results need to be examined by a human to figure out if they are passing. Running it as a unit test (on every build) doesn't really help us. - For anything more complex than a simple http GET, running the test under a server that you can programmatically control to do unexpected things or handle corner cases would be nice to have. And that server is available for integration tests. Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From jkang at redhat.com Tue Sep 2 20:00:09 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 2 Sep 2014 16:00:09 -0400 (EDT) Subject: [rfc][icedtea-web] ResourceTracker Download Performance Test In-Reply-To: <20140902193210.GD3151@redhat.com> References: <971492461.21673115.1408116714569.JavaMail.zimbra@redhat.com> <1257931795.29079856.1409682190254.JavaMail.zimbra@redhat.com> <20140902193210.GD3151@redhat.com> Message-ID: <109438506.29117223.1409688009018.JavaMail.zimbra@redhat.com> ----- Original Message ----- > Hi, > > * Jie Kang [2014-09-02 14:25]: > > I have improved the test by making it use a temporary cache. However I > > don't think downloading from a github repo is the best idea. Does > > anyone have any suggestions? > > What capabilities do you need from the download URL? If you just need an > alternative to github, you can also use a personal repo at > icedtea.classpath.org. Let me know if you decide to use that and I can > help you set it up. > > > I think having tests for the download > > functionality is quite important. > > I agree. Tests to know that thing is working and working fast are great > to have. > > However, these should be moved to integration tests and run using the > web server that's part of the test suite. Here are my reasons for this: > > - The URL is an external resource; unit tests should not require network > connectivity. > > - Since it's a performance test, the results need to be examined by a human > to > figure out if they are passing. Running it as a unit test (on every > build) doesn't really help us. > > - For anything more complex than a simple http GET, running the test > under a server that you can programmatically control to do unexpected > things or handle corner cases would be nice to have. And that server > is available for integration tests. Hello, I agree completely that these tests should not be part of the unit test section. Could you elaborate on the integration tests and web server part? Do you mean the dist-test system that we're using for reproducers? Or something else that I'm not aware of; Thanks, > > Thanks, > Omair > > -- > PGP Key: 66484681 (http://pgp.mit.edu/) > Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 > -- Jie Kang From omajid at redhat.com Tue Sep 2 20:10:07 2014 From: omajid at redhat.com (Omair Majid) Date: Tue, 2 Sep 2014 16:10:07 -0400 Subject: [rfc][icedtea-web] ResourceTracker Download Performance Test In-Reply-To: <109438506.29117223.1409688009018.JavaMail.zimbra@redhat.com> References: <971492461.21673115.1408116714569.JavaMail.zimbra@redhat.com> <1257931795.29079856.1409682190254.JavaMail.zimbra@redhat.com> <20140902193210.GD3151@redhat.com> <109438506.29117223.1409688009018.JavaMail.zimbra@redhat.com> Message-ID: <20140902201005.GF3151@redhat.com> * Jie Kang [2014-09-02 16:00]: > I agree completely that these tests should not be part of the unit > test section. Could you elaborate on the integration tests and web > server part? Do you mean the dist-test system that we're using for > reproducers? Or something else that I'm not aware of; Yes, I meant the tests that get run on 'make run-netx-dist-tests'. You can find them under 'tests/reproducers'. Please see http://icedtea.classpath.org/wiki/Reproducers for much more complete information about these tests and how to write/use them. Cheers, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From bugzilla-daemon at icedtea.classpath.org Tue Sep 2 23:15:55 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 02 Sep 2014 23:15:55 +0000 Subject: [Bug 1972] Don't compil on arm In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1972 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Component|IcedTea |Thumb2 JIT Version|7-hg |2.4.7 Assignee|gnu.andrew at redhat.com |aph at redhat.com Severity|major |normal --- Comment #2 from Andrew John Hughes --- What USE flags are you using? Looking at the ebuild, it seems CACAO should be turned on for this architecture. As it isn't, this looks like a failure in the ARM32 JIT port. Trying with CACAO on may be a better option. Also, you should try with the latest version which is 2.5.2. 2.4.x will not receive any further updates. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 01:04:32 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 01:04:32 +0000 Subject: [Bug 1972] Don't compil on arm In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1972 --- Comment #3 from BRULE Herman --- I have tryied alternate all the flags, I will send the repport with cacao, for this I do: dev-java/icedtea-7.2.4.7:7 [6.1.13.3:6] USE="cacao pax_kernel -X -alsa -cjk -cups -debug -doc -examples -jamvm -javascript -jbootstrap -kerberos -nsplugin -nss -pulseaudio (-selinux) -source {-test} -webstart -zero" During the compilation I have: (null)*(null) Unable to trace static ELF: /lib/ld-linux-armhf.so.3: /lib/ld-linux-armhf.so.3 --verify ./a.out (null)*(null) Unable to trace static ELF: /sbin/ldconfig: ldconfig -n /var/tmp/portage/dev-java/icedtea-7.2.4.7/work/icedtea-2.4.7/cacao/install/lib ... And I'm into hardened profile and kernel. Attached log with cacao -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 01:05:39 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 01:05:39 +0000 Subject: [Bug 1972] Don't compil on arm In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1972 --- Comment #4 from BRULE Herman --- Created attachment 1159 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1159&action=edit cacao -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Wed Sep 3 07:15:57 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 03 Sep 2014 09:15:57 +0200 Subject: [IcedTea-Web] Fwd: hs err_pid2237/ 2356 /2624/2765 /3275 /3372 /3390/ 5803/ 6979.log In-Reply-To: <511532172.17115956.1409675950308.JavaMail.zimbra@redhat.com> References: <5405F19A.7010307@yahoo.fr> <511532172.17115956.1409675950308.JavaMail.zimbra@redhat.com> Message-ID: <5406C02D.8080706@redhat.com> Hi Andrew! Thank you for reporting, unluckily this info is very poor. Not even whole trace is visible:( Where this come from? May you address the person to distro list? Or to me or Andrew A.? Or us to this list? J. On 09/02/2014 06:39 PM, Andrew Hughes wrote: > Looks like an IcedTea-Web crash. The error window is definitely ITW's window :) > > ----- Forwarded Message ----- >> Ref.link >> It has been working only a few times.It is important for me.Can you help me >> >> -- >> Jacques glass >> >> > From jvanek at redhat.com Wed Sep 3 07:18:58 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 03 Sep 2014 09:18:58 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <540180DB.4050109@gmx.de> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <1222082700.26083069.1409081718997.JavaMail.zimbra@redhat.com> <982339162.26695106.1409162928407.JavaMail.zimbra@redhat.com> <958305698.27235425.1409240834908.JavaMail.zimbra@redhat.com> <1885159478.27899833.1409329251634.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> Message-ID: <5406C0E2.7010309@redhat.com> ... > > No no, do not start playing around with visible and hidden UI components. It is even worse when they > change their layout or start jumping around like it is now. Generally, there is never any need to ... > @helpcrypto > Yes, it is against basic UI design principles to have hiding UI components, unless there are really > good reasons to do so. Please do not start giving advice on something you do not know or have no > experience in. This only confuses young or new developers. > indeed :D https://bugzilla.redhat.com/show_bug.cgi?id=1136192 J:) From ptisnovs at icedtea.classpath.org Wed Sep 3 09:51:47 2014 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Wed, 03 Sep 2014 09:51:47 +0000 Subject: /hg/gfx-test: Ten new tests added into CAGOperationsOnTwoOverlap... Message-ID: changeset 52d612cf8db6 in /hg/gfx-test details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=52d612cf8db6 author: Pavel Tisnovsky date: Wed Sep 03 11:52:58 2014 +0200 Ten new tests added into CAGOperationsOnTwoOverlappingRoundRectangles. diffstat: ChangeLog | 5 + src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java | 250 ++++++++++ 2 files changed, 255 insertions(+), 0 deletions(-) diffs (272 lines): diff -r bc3ca0c7b1e7 -r 52d612cf8db6 ChangeLog --- a/ChangeLog Tue Sep 02 11:25:53 2014 +0200 +++ b/ChangeLog Wed Sep 03 11:52:58 2014 +0200 @@ -1,3 +1,8 @@ +2014-09-03 Pavel Tisnovsky + + * src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java: + Ten new tests added into CAGOperationsOnTwoOverlappingRoundRectangles. + 2014-09-02 Pavel Tisnovsky * src/org/gfxtest/testsuites/BitBltBufferedImageOp.java: diff -r bc3ca0c7b1e7 -r 52d612cf8db6 src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java --- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java Tue Sep 02 11:25:53 2014 +0200 +++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java Wed Sep 03 11:52:58 2014 +0200 @@ -306,6 +306,256 @@ return TestResult.PASSED; } + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using union operator. The shape is + * rendered using extra wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionExtraWideStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingUnionOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using subtract operator. The shape is + * rendered using extra wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractExtraWideStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingSubtractOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using inverse subtract operator. The + * shape is rendered using extra wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractExtraWideStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using intersect operator. The + * shape is rendered using extra wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testIntersectExtraWideStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d); + // create area using intersect operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingIntersectOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using XOR operator. The + * shape is rendered using extra wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorExtraWideStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d); + // create area using XOR operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingXorOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping round rectangles using union operator. The shape is rendered + * using zero wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionZeroStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeZeroThick(graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingUnionOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping round rectangles using subtract operator. The shape is + * rendered using zero stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractZeroStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeZeroThick(graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingSubtractOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping round rectangles using inverse subtract operator. The shape + * is rendered using zero stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractZeroStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeZeroThick(graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping round rectangles using intersect operator. The shape is + * rendered using zero stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testIntersectZeroStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeZeroThick(graphics2d); + // create area using intersect operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingIntersectOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping round rectangles using XOR operator. The shape is rendered + * using zero stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorZeroStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke width + CommonRenderingStyles.setStrokeZeroThick(graphics2d); + // create area using XOR operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingXorOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + /** * Entry point to the test suite. From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 11:26:32 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 11:26:32 +0000 Subject: [Bug 1974] New: i just updated my kalilinux , but it cudn't not start armitage. Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1974 Bug ID: 1974 Summary: i just updated my kalilinux ,but it cudn't not start armitage. Product: IcedTea Version: 2.4.0 Hardware: x86 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: neo.hilton2009 at gmail.com CC: unassigned at icedtea.classpath.org Created attachment 1160 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1160&action=edit how can it get fixed please i need your help i just updated my kalilinux ,but it cudn't not start armitage. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Wed Sep 3 12:45:01 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 03 Sep 2014 14:45:01 +0200 Subject: [rfc][icedtea-web] missing jnlpfile and securtydelegate for TemporaryPermissionsButton calls In-Reply-To: <53FE5CD3.4060602@redhat.com> References: <53FDA41B.4060801@redhat.com> <53FE5CD3.4060602@redhat.com> Message-ID: <54070D4D.70605@redhat.com> On 08/28/2014 12:33 AM, Andrew Azores wrote: > Hi, > > Still on PTO here and preparing to move back into my parents' place while I go back to finish > school, so I haven't really invested any real time into this bug. But... > > On 08/27/2014 05:25 AM, Jiri Vanek wrote: >> Hi! >> >> During testing of https probing, helpcrypto found and interesting issue >> in head. >> >> Under some circumstances calls to TemporaryPermissionsButton have >> jnlpfile and securitydelegate null. > > The SecurityDelegate can be instantiated much earlier in JNLPClassLoader if need be. It can even be > the first thing done after calling the super constructor AFAIK. Since the JNLPClassLoader is also > what eventually causes the security dialog to appear with the Temporary Permissions button on it, > this will probably resolve the null securityDelegate reference part. > >> >> Two things troubles me: >> - both those values are needed only when "tmeporarypermissions" are >> clicked, so they should not affect startup of ITW >> - how come that they are null? I blame >> http://icedtea.classpath.org/hg/icedtea-web/annotate/d87ee4e6e81a/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java#78 >> >> >> (looking into Looking to this, >> http://icedtea.classpath.org/hg/icedtea-web/file/b4363c984e1b/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java#l79 >> >> ) > > For the null jnlpFile - I can't think off the top of my head what is causing that. It could just be > again that the dialog is being shown before a field has been assigned a value, as it is with the > securityDelegate. If it's simply an ordering issue like this then that isn't *too* concerning. If we > truly just do not have a reference to any JNLPFile or PluginBridge for this applet then there's > something seriously wrong. > >> >> >> Atatched is the nasty workarorund and here is snippet of log >> >> Securitymanager=net.sourceforge.jnlp.runtime.JNLPSecurityManager at 19f17b1 >> Registering priority for string reference 2 >> Registering priority for reference 2 >> Returning value:0 >> Setting value:0 >> Setting value:null >> dummy string null, null, javax.swing.JButton[,0,0,0x0,inva...snip... >> plugin_in_pipe_callback return >> plugin_send_message_to_appletviewer return >> PIPE: plugin wrote(?): plugin PluginProxyInfo reference 1 DIRECT >> plugin_send_message_to_appletviewer >> Proxy info: plugin PluginProxyInfo reference 1 DIRECT >> >> >> >> Without the workarround itw dies: >> >> ITNP_SetWindow return >> ITNP_SetWindow: window already exists. >> ITNP_SetWindow >> at java.lang.Thread.run(Thread.java:745) >> at >> net.sourceforge.jnlp.security.SecurityDialogMessageHandler.run(SecurityDialogMessageHandler.java:81) >> >> at >> net.sourceforge.jnlp.security.SecurityDialogMessageHandler.handleMessage(SecurityDialogMessageHandler.java:102) >> >> >> at net.sourceforge.jnlp.security.SecurityDialog. >> (SecurityDialog.java:129) >> at >> net.sourceforge.jnlp.security.SecurityDialog.initDialog(SecurityDialog.java:255) >> >> at >> net.sourceforge.jnlp.security.SecurityDialog.installPanel(SecurityDialog.java:307) >> >> at net.sourceforge.jnlp.security.dialogs.CertWarningPane. >> (CertWarningPane.java:116) >> at >> net.sourceforge.jnlp.security.dialogs.CertWarningPane.addComponents(CertWarningPane.java:124) >> >> at >> net.sourceforge.jnlp.security.dialogs.CertWarningPane.addButtons(CertWarningPane.java:242) >> >> at >> net.sourceforge.jnlp.security.dialogs.TemporaryPermissionsButton. >> (TemporaryPermissionsButton.java:79) >> at java.util.Objects.requireNonNull(Objects.java:201) >> Exception in thread "NetxSecurityThread" java.lang.NullPointerException >> plugin_in_pipe_callback return >> plugin_send_message_to_appletviewer return >> PIPE: plugin wrote(?): plugin PluginProxyInfo reference 1 DIRECT >> plugin_send_message_to_appletviewer >> Proxy info: plugin PluginProxyInfo reference 1 DIRECT >> >> >> >> I think the AssertNotNUll are really really invasive here. But at least >> they cought probably more serious issue - to early call to the dialogue >> with tmppermissions button.... >> >> >> J. > > Yup. The PolicyEditor can't be sensibly launched if the jnlpFile is null (your nasty workaround > really is nasty - assigning the new permissions to all applets rather than only ones on the current > applet's codebase!), and the securityDelegate is needed if this button is to function at all. So > there's no sensible thing to do if either of those fields come up null. Perhaps rather than outright > failing to launch ITW we could have the button indicate a failure somehow and have the dialog simply > not install the button, however. Just another option for Lukasz or whomever to look into. If this > still hasn't been fixed by the time I come off PTO then I'll gladly take ownership of the bug. > Andrew have made some investigations, and this is moreover conclusion - its a bug - the tmp permissions dialogue is shared among javaws and applets, and in applets lifecycle can happen this NPE - however, the fix will take some time Even after it may be some cases, when this NPE will rise. We agreed that disabling the button n this case is probably best solution. The attache dpatch do so, Two nits : - is really the SecurityDelegate suddenly useless? - Why all apps reproducing this issue suddenly started to work? ( I mean without this patch) Still I think it is good thing to get rid of assers and disable button. J. -------------- next part -------------- A non-text attachment was scrubbed... Name: npe.patch Type: text/x-patch Size: 1966 bytes Desc: not available URL: From gitne at gmx.de Wed Sep 3 13:41:30 2014 From: gitne at gmx.de (Jacob Wisor) Date: Wed, 03 Sep 2014 15:41:30 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <1222082700.26083069.1409081718997.JavaMail.zimbra@redhat.com> <982339162.26695106.1409162928407.JavaMail.zimbra@redhat.com> <958305698.27235425.1409240834908.JavaMail.zimbra@redhat.com> <1885159478.27899833.1409329251634.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> Message-ID: <54071A8A.9050202@gmx.de> On 09/01/2014 at 02:59 PM, helpcrypto helpcrypto wrote: > On Sat, Aug 30, 2014 at 9:44 AM, Jacob Wisor wrote: > >> No no, do not start playing around with visible and hidden UI components. >> It is even worse when they change their layout or start jumping around like >> it is now. Generally, there is never any need to hide UI components. If >> there seems to be, then either there is something wrong with the basic >> design of a window or dialog, or you should have very good reasons to do >> so. And, in this case there is surely *no* reason to hide any components >> dynamically at all. Again, stick to disabling components. This should be >> enough. >> >> @helpcrypto >> Yes, it is against basic UI design principles to have hiding UI >> components, unless there are really good reasons to do so. > > Can you point a style guide, or a gui-best-practices which advices on that? Well, there are multiple guidelines available, depending on OS, window managers and/or desktop managers. It is difficult to point to a specific one in the case of SWT and Java because it is platform independent. But, I suppose one could take Microsoft's UI guidelines as a basis because of it's undeniable bread adoption. It also shares a large set of rules with other UI guidelines form other vendors. > I have seen several GUIs wich only show the user what he needs to see, and > I found them KISS-compliant I think you are mixing to concepts here. KISS is about technical solutions, that is how things should be solved in order for other engineers to comprehend the work of the original authors, and generally assumes that simple technical solutions are usually the most effective or efficient ones. UI design guidelines employ a similar concept but not exactly KISS. Good UI designs should not be overloaded with UI components and only display the right amount of components required to accomplish the current task at hand. Hence, users should not be overburdened with overloaded UIs. But, most importantly UIs must not be confusing to users, and their behavior must be intuitively and naturally predictable. Hiding and jumping UI controls feel absolutely unnatural and inorganic. This is indeed bad behavior for UI controls. I will give you a simple example why your way of thinking is flawed here. Take for example a dialog with a list view and an edit button to edit the list view items. Now, if no list view item would be selected then according to your reasoning the edit button should be hidden because the user can take no editing action while no list view item is selected. This is absolutely confusing to the user. The user is supposed to be able to see and know all the possible actions he can take at all times but should not be able to take invalid actions. This is why the edit button in this example has to stay always visible but not always enabled. Think about it. ;-) >> Unfortunately, because of your attempt to play around with hiding UI >> components you have introduced a new bug. When "Limit cache size" is >> checked and the spinner is 0 then all components for setting up the cache >> location suddenly disappear. > > Limit checked, value=0->no cache, hence no need of location, compression > level or anything. It's not a bug. > The warning under spinner informs about that. This is logically correct but it is against basic UI design guidelines. It is inorganic. >> And, as soon as the value becomes greater than 1, they become visible >> again. This is very odd, weird, and confusing. Again, do not play around >> with hiding UI components. >> > The reason why i suggested "no cach?" instead of 0. As mentioned before, the UI components handling the cache's location should simply be disabled in this case. No real reason to hide them. Jacob From jvanek at redhat.com Wed Sep 3 14:04:25 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 03 Sep 2014 16:04:25 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <53FC3C79.5040208@gmx.de> References: <53E3B68B.1090806@redhat.com> <53E3D58D.5030609@gmx.de> <53E48C38.30802@redhat.com> <53E8EB49.8000209@gmx.de> <20140818184605.GA2383@redhat.com> <53F3C0AD.5030400@gmx.de> <53F4E95B.30507@redhat.com> <53FC3461.5030401@redhat.com> <53FC3C79.5040208@gmx.de> Message-ID: <54071FE9.2000309@redhat.com> On 08/26/2014 09:51 AM, Jacob Wisor wrote: > On 08/26/2014 09:16 AM, Jiri Vanek wrote: >> ping? >> >> On 08/20/2014 08:30 PM, Jiri Vanek wrote: >>> On 08/19/2014 11:25 PM, Jacob Wisor wrote: >>>> On 08/18/2014 08:46 PM, Omair Majid wrote: >>>>> Hi, >>>>> >>>>> >>>>> * Jacob Wisor [2014-08-11 12:12]: >>>>>> On 08/08/2014 10:37 AM, Jiri Vanek wrote: >>>>>>> Unluckily this fix patch is not helping obscure servers to do exists. >>>>>>> It really fixes bugs. >>>>>>> >>>>>>> First part of fix is delivered to be able handle SSLv2 handshake, Those >>>>>>> servers >>>>>>> do exists, and have no reason nor need to update or patch or whatever. We are >>>>>>> wrong by not allowing it right now. >>>>>>> See System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); in code. >>>>>> >>>>>> Oh yes they do need fixing. SSLv2 is insecure and has been revoked by the >>>>>> IETF, period. Nobody should be using it. Even SSL 3.0 is deemed by the IETF >>>>>> as historic (https://datatracker.ietf.org/doc/rfc6101) although it is >>>>>> largely identical to TLS 1.0. Nevertheless, nobody should be using it >>>>>> either. Just one of many reasons is that it does not even support such a >>>>>> common hash algorithm as SHA1 (which by the way has been deprecated by NIST >>>>>> in favor of SHA256 too). Everybody should really upgrade to at least TLS >>>>>> 1.0, even though possible security leaks have been discovered in TLS 1.0 on >>>>>> specific configuration settings permutations. >>>>>> >>>>>> DO NOT use SSL anymore and DO NOT promote them in your software. Upgrade to >>>>>> TLS. >>>>> >>>>> This isn't SSv2, though. It's a SSLv2 hello packet wrapping an SSLv3 >>>>> packet: http://bugs.java.com/bugdatabase/view_bug.do?bug_id=4915862 >>>>> >>>>> It's actually part of the TLS 1.0 spec: >>>>> https://www.ietf.org/rfc/rfc2246.txt, Appendix E. >>>> >>>> This part describes backward compatibility of TLS 1.0 clients to SSL 3.0 and >>>> SSL 2.0 servers (and >>>> vice versa). >>>> >>>> "TLS 1.0 clients that support SSL Version 2.0 servers must send SSL >>>> Version 2.0 client hello messages [SSL2]. TLS servers should accept >>>> either client hello format if they wish to support SSL 2.0 clients on >>>> the same connection port. The only deviations from the Version 2.0 >>>> specification are the ability to specify a version with a value of >>>> three and the support for more ciphering types in the CipherSpec." >>>> >>>> Currently, IcedTea-Web is a TLS 1.0 or SSL 3.0 client. According to this >>>> paragraph, TLS 1.0 clients >>>> send SSL 2.0 client hello messages in order to connect to SSL 2.0 servers, >>>> that is, to negotiate a >>>> SSL 2.0 connection. So no, SSL 2.0 servers do not upgrade automagically to >>>> TLS 1.0 when they receive >>>> SSL 2.0 client hello messages from TLS 1.0 clients. Pure old SSL 2.0 servers >>>> will never speak >>>> anything later than SSL 2.0. >>>> >>>> One reason behind this paragraph was for TLS 1.0 clients to allow probing SSL >>>> 2.0 servers with >>>> cipher specifications in SSL 2.0 and those introduced in TLS 1.0. In >>>> practice, SSL 2.0 servers will >>>> _never_ negotiate to a cipher specification introduced since TLS 1.0 because >>>> they were simply not >>>> built for that. >>>> >>>> Another reason for this paragraph back in 1999 (!) was to allow implementors >>>> of TLS 1.0 to ease >>>> transition from SSL to TLS and to give them the option to merge TLS into >>>> their existing SSL >>>> libraries (or as much as possible build on top of them). Again, this has >>>> nothing to do with >>>> automagically upgrading SSL 2.0 servers to TLS. It is just a description of >>>> how TLS 1.0 clients >>>> could fallback to SSL 2.0, if they wish to. >>>> And, I am most certain nobody should want this, unless one has no clue what >>>> transport security is >>>> all about or is a complete lunatic. >>>> >>>> The next paragraph says it all: >>>> >>>> " Warning: The ability to send Version 2.0 client hello messages will be >>>> phased out with all due haste. Implementors should make every >>>> effort to move forward as quickly as possible. Version 3.0 >>>> provides better mechanisms for moving to newer versions." >>>> >>>> So, the Java API should have got rid of the option to fallback to SSL 2.0 >>>> years before. It's a shame >>>> that J2SE still supports SSL 2.0 connections in 2014. Why? Because this has >>>> nothing to do with >>>> compatibility but with *security*. >>>> >>> >>> Ok. Thank you for patience with me. (really!) >>> >>> So there is another approach. >>> >>> Now the ssl2 is tested as last attempt, and if it is possible to connect like >>> that, then the user is >>> warned and error is thrown (which leads to skipping resource from that >>> >>> >>> The not-checking certificate now can be allowed or forbidden by properties. By >>> default it asks user >>> by every such invalid certs its found. How to deal with human intraction is todo. >>> >>> >>> The reason for this message is to get verbose logical error emsssage, not only >>> "itw do not work again" >>> >>> >>> What do you think now? >>> >>> J. > > > > + DeploymentConfiguration.KEY_HTTPS_PROBINGALOWED, > > [...] > > + public static final String KEY_HTTPS_PROBINGALOWED = > > "deployment.security.https.probing.alowed"; > > [...] > > + public void disconect(URLConnection conn) { > > [...] > > + public synchronized void disconectHttps(HttpsURLConnection conn) { > > [...] > > + private final boolean unsecure; > > + > > + private HttpsSettings(boolean ssl2, boolean unsecure) { > > [...] > > + public static URLConnection openConnection(URL url, boolean ssl2, > > boolean unsecure) throws IOException { > > I am not testing this unless you have fixed your typos. > For god's sake, your are a programmer, right? You should know best that exact spelling is important. > Obviously, I am just talking till I am blue in the face. Noooo. I moreover overlooked :( Sorry. Now it should be as good as I'm able to do so without third party attendance. > > Also, please replace all occurrences of "ssl2" in text strings with "SSL2" (or "SSL 2.0" as used in > the specification). Acronyms of names are always upper case in English. > ok! > Here is updated version. Sorry for delay, I was hacking the documentation generator. Now its one (discussing with Lukas concurrently edited code), ad I think you will like it :) J. -------------- next part -------------- A non-text attachment was scrubbed... Name: httpsSolution_05.patch Type: text/x-patch Size: 39993 bytes Desc: not available URL: From andrew at icedtea.classpath.org Wed Sep 3 14:34:39 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Wed, 03 Sep 2014 14:34:39 +0000 Subject: /hg/release/icedtea7-forest-2.5/jdk: Start 2.5.3 release cycle Message-ID: changeset eb70b48e4211 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=eb70b48e4211 author: andrew date: Wed Sep 03 15:34:29 2014 +0100 Start 2.5.3 release cycle diffstat: make/jdk_generic_profile.sh | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diffs (12 lines): diff -r 229136ffcb00 -r eb70b48e4211 make/jdk_generic_profile.sh --- a/make/jdk_generic_profile.sh Fri Aug 29 21:08:23 2014 +0100 +++ b/make/jdk_generic_profile.sh Wed Sep 03 15:34:29 2014 +0100 @@ -573,7 +573,7 @@ # IcedTea versioning export ICEDTEA_NAME="IcedTea" -export PACKAGE_VERSION="2.5.2" +export PACKAGE_VERSION="2.5.3pre00" export DERIVATIVE_ID="${ICEDTEA_NAME} ${PACKAGE_VERSION}" if [ -e ${jdk_topdir} ] ; then From andrew at icedtea.classpath.org Wed Sep 3 14:34:57 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Wed, 03 Sep 2014 14:34:57 +0000 Subject: /hg/release/icedtea7-2.5: 3 new changesets Message-ID: changeset 7a5b620a054a in /hg/release/icedtea7-2.5 details: http://icedtea.classpath.org/hg/release/icedtea7-2.5?cmd=changeset;node=7a5b620a054a author: Andrew John Hughes date: Fri Aug 29 21:45:13 2014 +0100 Prepare for 2.5.2 release. 2014-08-29 Andrew John Hughes * NEWS: Set release date for 2.5.2. changeset 07567fde7651 in /hg/release/icedtea7-2.5 details: http://icedtea.classpath.org/hg/release/icedtea7-2.5?cmd=changeset;node=07567fde7651 author: Andrew John Hughes date: Tue Sep 02 05:18:16 2014 +0100 Added tag icedtea-2.5.2 for changeset 7a5b620a054a changeset 00016055e63f in /hg/release/icedtea7-2.5 details: http://icedtea.classpath.org/hg/release/icedtea7-2.5?cmd=changeset;node=00016055e63f author: Andrew John Hughes date: Wed Sep 03 15:33:40 2014 +0100 Start 2.5.3 release cycle. 2014-09-03 Andrew John Hughes * configure.ac: Set to 2.5.3pre00. * NEWS: Add release section for 2.5.3. diffstat: .hgtags | 1 + ChangeLog | 9 +++++++++ NEWS | 4 +++- configure.ac | 2 +- 4 files changed, 14 insertions(+), 2 deletions(-) diffs (47 lines): diff -r 6e9490f61562 -r 00016055e63f .hgtags --- a/.hgtags Fri Aug 29 21:14:22 2014 +0100 +++ b/.hgtags Wed Sep 03 15:33:40 2014 +0100 @@ -38,3 +38,4 @@ b3eb30a2db9022bf34c51794ebe66f623c359d4c icedtea-2.5-branchpoint 81ffee9f8143a9ced4e3c418924f2641ed72b2cc icedtea-2.5.0 a2d9b45d7491a9c84afb33a457533817a7f3e600 icedtea-2.5.1 +7a5b620a054a6276333c4b3009d1a0dd5248a7f3 icedtea-2.5.2 diff -r 6e9490f61562 -r 00016055e63f ChangeLog --- a/ChangeLog Fri Aug 29 21:14:22 2014 +0100 +++ b/ChangeLog Wed Sep 03 15:33:40 2014 +0100 @@ -1,3 +1,12 @@ +2014-09-03 Andrew John Hughes + + * configure.ac: Set to 2.5.3pre00. + * NEWS: Add release section for 2.5.3. + +2014-08-29 Andrew John Hughes + + * NEWS: Set release date for 2.5.2. + 2014-08-29 Andrew John Hughes * NEWS: Update OpenJDK bug URL. diff -r 6e9490f61562 -r 00016055e63f NEWS --- a/NEWS Fri Aug 29 21:14:22 2014 +0100 +++ b/NEWS Wed Sep 03 15:33:40 2014 +0100 @@ -12,7 +12,9 @@ CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY -New in release 2.5.2 (2014-10-XX): +New in release 2.5.3 (2014-10-XX): + +New in release 2.5.2 (2014-08-29): * Backports - S8049480: Current versions of Java can't verify jars signed and timestamped with Java 9 diff -r 6e9490f61562 -r 00016055e63f configure.ac --- a/configure.ac Fri Aug 29 21:14:22 2014 +0100 +++ b/configure.ac Wed Sep 03 15:33:40 2014 +0100 @@ -1,4 +1,4 @@ -AC_INIT([icedtea], [2.5.2], [distro-pkg-dev at openjdk.java.net]) +AC_INIT([icedtea], [2.5.3pre00], [distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AM_MAINTAINER_MODE([enable]) AC_CONFIG_FILES([Makefile]) From andrew at icedtea.classpath.org Wed Sep 3 14:37:32 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Wed, 03 Sep 2014 14:37:32 +0000 Subject: /hg/icedtea7: Add 2.5.2 release notes. Message-ID: changeset 941db1268ae7 in /hg/icedtea7 details: http://icedtea.classpath.org/hg/icedtea7?cmd=changeset;node=941db1268ae7 author: Andrew John Hughes date: Wed Sep 03 15:37:20 2014 +0100 Add 2.5.2 release notes. 2014-09-03 Andrew John Hughes * NEWS: Add 2.5.2 release notes. diffstat: ChangeLog | 4 ++++ NEWS | 11 +++++++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diffs (48 lines): diff -r 864ddd2fd71e -r 941db1268ae7 ChangeLog --- a/ChangeLog Fri Aug 29 21:57:28 2014 +0100 +++ b/ChangeLog Wed Sep 03 15:37:20 2014 +0100 @@ -1,3 +1,7 @@ +2014-09-03 Andrew John Hughes + + * NEWS: Add 2.5.2 release notes. + 2014-08-29 Andrew John Hughes * NEWS: Update OpenJDK bug URL. diff -r 864ddd2fd71e -r 941db1268ae7 NEWS --- a/NEWS Fri Aug 29 21:57:28 2014 +0100 +++ b/NEWS Wed Sep 03 15:37:20 2014 +0100 @@ -180,14 +180,12 @@ - S8048506: [macosx] javax.swing.PopupFactory issue with null owner - S8048887: SortingFocusTraversalPolicy throws IllegalArgumentException from the sort method - S8049250: Need a flag to invert the Card.disconnect(reset) argument - - S8049480: Current versions of Java can't verify jars signed and timestamped with Java 9 - S8049514: FEATURE_SECURE_PROCESSING can not be turned off on a validator through SchemaFactory - S8049542: C2: assert(size_in_words <= (julong)max_jint) failed: no overflow - S8050165: linux-sparcv9: NMT detail causes assert((intptr_t*)younger_sp[FP->sp_offset_in_saved_window()] == (intptr_t*)((intptr_t)sp - STACK_BIAS)) failed: younger_sp must be valid - S8050167: linux-sparcv9: hs_err file does not show any stack information - S8050386: javac, follow-up of fix for JDK-8049305 - S8051004: javac, incorrect bug id in tests for JDK-8050386 - - S8051012: Regression in verifier for method call from inside of a branch - S8051844: BootstrapMethods attribute cannot be empty again - S8052159: TEST_BUG: javax/swing/JTextField/8036819/bug8036819.java fails to compile - S8054841: (process) ProcessBuilder leaks native memory @@ -198,9 +196,18 @@ - PR1786: Allow x86 build to occur on x86_64 using a previously built x86_64 build - PR1846: Build fails when using IcedTea7 as bootstrap JDK with native ecj - PR1847: Synchronise javac.in with IcedTea6 + +New in release 2.5.2 (2014-08-29): + +* Backports + - S8049480: Current versions of Java can't verify jars signed and timestamped with Java 9 + - S8051012, LP1360392: Regression in verifier for method call from inside of a branch +* Bug fixes - PR1903: [REGRESSION] Bug reports now lack IcedTea version & distribution packaging information - PR1948: Only try and symlink debuginfo if STRIP_POLICY is other than no_strip - PR1948: Fix indenting + - PR1966: Move to new OpenJDK bug URL format + - RH1015432: java-1.7.0-openjdk: Fails on PPC with StackOverflowError (revised fix for PPC32) * PPC & AIX port - Adapt AIX port to 5049299: (process) Use posix_spawn, not fork, on S10 to avoid swap exhaustion - Adapt aix to 8022507 From andrew at icedtea.classpath.org Wed Sep 3 14:57:43 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Wed, 03 Sep 2014 14:57:43 +0000 Subject: /hg/icedtea7-forest/hotspot: RH1015432: java-1.7.0-openjdk: Fail... Message-ID: changeset 304c66cf5010 in /hg/icedtea7-forest/hotspot details: http://icedtea.classpath.org/hg/icedtea7-forest/hotspot?cmd=changeset;node=304c66cf5010 author: andrew date: Thu Aug 28 15:26:22 2014 +0100 RH1015432: java-1.7.0-openjdk: Fails on PPC with StackOverflowError (revised fix for PPC32) Contributed-by: chphilli at redhat.com diffstat: src/os/linux/vm/os_linux.cpp | 10 +++++++++- 1 files changed, 9 insertions(+), 1 deletions(-) diffs (37 lines): diff -r 69d9f2195369 -r 304c66cf5010 src/os/linux/vm/os_linux.cpp --- a/src/os/linux/vm/os_linux.cpp Wed Aug 27 23:07:43 2014 +0100 +++ b/src/os/linux/vm/os_linux.cpp Thu Aug 28 15:26:22 2014 +0100 @@ -4854,6 +4854,7 @@ pthread_mutex_init(&dl_mutex, NULL); +NOT_ZERO ( // If the pagesize of the VM is greater than 8K determine the appropriate // number of initial guard pages. The user can change this with the // command line arguments, if needed. @@ -4862,6 +4863,7 @@ StackRedPages = 1; StackShadowPages = round_to((StackShadowPages*Linux::vm_default_page_size()), vm_page_size()) / vm_page_size(); } + ) } // To install functions for atexit system call @@ -4914,10 +4916,16 @@ // size. Add a page for compiler2 recursion in main thread. // Add in 2*BytesPerWord times page size to account for VM stack during // class initialization depending on 32 or 64 bit VM. +NOT_ZERO ( os::Linux::min_stack_allowed = MAX2(os::Linux::min_stack_allowed, (size_t)(StackYellowPages+StackRedPages+StackShadowPages) * Linux::page_size() + (2*BytesPerWord COMPILER2_PRESENT(+1)) * Linux::vm_default_page_size()); - + ) +ZERO_ONLY ( + os::Linux::min_stack_allowed = MAX2(os::Linux::min_stack_allowed, + (size_t)(StackYellowPages+StackRedPages+StackShadowPages+ + 2*BytesPerWord COMPILER2_PRESENT(+1)) * Linux::page_size()); + ) size_t threadStackSizeInBytes = ThreadStackSize * K; if (threadStackSizeInBytes != 0 && threadStackSizeInBytes < os::Linux::min_stack_allowed) { From andrew at icedtea.classpath.org Wed Sep 3 15:32:51 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Wed, 03 Sep 2014 15:32:51 +0000 Subject: /hg/icedtea: PR1367: Support using the system installation of LCMS Message-ID: changeset 3680c74438e9 in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=3680c74438e9 author: Andrew John Hughes date: Wed Sep 03 16:32:44 2014 +0100 PR1367: Support using the system installation of LCMS 2014-09-03 Andrew John Hughes * NEWS: Add bug reference for system LCMS support. diffstat: ChangeLog | 4 ++++ NEWS | 1 + 2 files changed, 5 insertions(+), 0 deletions(-) diffs (22 lines): diff -r 715fa1507f8d -r 3680c74438e9 ChangeLog --- a/ChangeLog Fri Aug 29 19:20:28 2014 +0100 +++ b/ChangeLog Wed Sep 03 16:32:44 2014 +0100 @@ -1,3 +1,7 @@ +2014-09-03 Andrew John Hughes + + * NEWS: Add bug reference for system LCMS support. + 2014-08-29 Andrew John Hughes * NEWS: Add bug reference for AArch64 import. diff -r 715fa1507f8d -r 3680c74438e9 NEWS --- a/NEWS Fri Aug 29 19:20:28 2014 +0100 +++ b/NEWS Wed Sep 03 16:32:44 2014 +0100 @@ -32,6 +32,7 @@ - PR1357: Make XRender mandatory - PR1359: Check for /usr/lib64 JVMs and generic JPackage alternative - PR1364: Replace hgforest support + - PR1367: Support using the system installation of LCMS - PR1379: Add build support for Zero AArch64 - PR1766: Expand architecture support - PR1774: Support GIF lib v5 From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 15:33:00 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 15:33:00 +0000 Subject: [Bug 1367] [IcedTea8] Support using the system installation of LCMS In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1367 --- Comment #1 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea?cmd=changeset;node=3680c74438e9 author: Andrew John Hughes date: Wed Sep 03 16:32:44 2014 +0100 PR1367: Support using the system installation of LCMS 2014-09-03 Andrew John Hughes * NEWS: Add bug reference for system LCMS support. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 15:58:16 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 15:58:16 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Bug 1282 depends on bug 1367, which changed state. Bug 1367 Summary: [IcedTea8] Support using the system installation of LCMS http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1367 What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 15:58:16 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 15:58:16 +0000 Subject: [Bug 1367] [IcedTea8] Support using the system installation of LCMS In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1367 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 15:59:58 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 15:59:58 +0000 Subject: [Bug 1975] New: [IcedTea8] Add garbage collection probes for SystemTap Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1975 Bug ID: 1975 Summary: [IcedTea8] Add garbage collection probes for SystemTap Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:00:41 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:00:41 +0000 Subject: [Bug 1975] [IcedTea8] Add garbage collection probes for SystemTap In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1975 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Blocks| |1282 Target Milestone|--- |3.0.0 --- Comment #1 from Andrew John Hughes --- No file /home/andrew/build/icedtea8/tapset/hotspot_gc.stp -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:00:41 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:00:41 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1975 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:02:57 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:02:57 +0000 Subject: [Bug 1976] New: [IcedTea8] Support using the system installation of Glib/GIO Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1976 Bug ID: 1976 Summary: [IcedTea8] Support using the system installation of Glib/GIO Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org Comparing /home/andrew/build/icedtea7/jre/lib/amd64/libsctp.so and /home/andrew/build/icedtea8/jre/lib/amd64/libsctp.so linkage --- /tmp/.private/andrew/ld1 2014-09-03 16:50:39.080959765 +0100 +++ /tmp/.private/andrew/ld2 2014-09-03 16:50:39.092959935 +0100 @@ -1,11 +1,6 @@ /lib64/ld-linux-x86-64.so.2 libc.so.6 libdl.so.2 - libffi.so.6 - libgio-2.0.so.0 - libglib-2.0.so.0 - libgmodule-2.0.so.0 - libgobject-2.0.so.0 libjava.so libjvm.so libjvm.so Comparing /home/andrew/build/icedtea7/jre/lib/amd64/libnio.so and /home/andrew/build/icedtea8/jre/lib/amd64/libnio.so linkage --- /tmp/.private/andrew/ld1 2014-09-03 16:50:39.224961826 +0100 +++ /tmp/.private/andrew/ld2 2014-09-03 16:50:39.232961940 +0100 @@ -1,18 +1,11 @@ /lib64/ld-linux-x86-64.so.2 libc.so.6 libdl.so.2 - libffi.so.6 - libgio-2.0.so.0 - libglib-2.0.so.0 - libgmodule-2.0.so.0 - libgobject-2.0.so.0 Comparing /home/andrew/build/icedtea7/jre/lib/amd64/libnet.so and /home/andrew/build/icedtea8/jre/lib/amd64/libnet.so linkage --- /tmp/.private/andrew/ld1 2014-09-03 16:50:39.444964975 +0100 +++ /tmp/.private/andrew/ld2 2014-09-03 16:50:39.456965146 +0100 @@ -1,17 +1,10 @@ /lib64/ld-linux-x86-64.so.2 libc.so.6 libdl.so.2 - libffi.so.6 - libgio-2.0.so.0 - libglib-2.0.so.0 - libgmodule-2.0.so.0 - libgobject-2.0.so.0 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:03:17 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:03:17 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1976 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:03:17 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:03:17 +0000 Subject: [Bug 1976] [IcedTea8] Support using the system installation of Glib/GIO In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1976 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Blocks| |1282 Target Milestone|--- |3.0.0 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:06:09 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:06:09 +0000 Subject: [Bug 1977] New: [IcedTea8] Support using the system installation of Zlib Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1977 Bug ID: 1977 Summary: [IcedTea8] Support using the system installation of Zlib Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org - libz.so.1 in libnet.so, libsctp.so, libnio.so. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:07:57 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:07:57 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1977 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:07:57 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:07:57 +0000 Subject: [Bug 1977] [IcedTea8] Support using the system installation of Zlib In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1977 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Blocks| |1282 Target Milestone|--- |3.0.0 --- Comment #1 from Andrew John Hughes --- Actually seems to be already using the system version and this missing libz linkage is perhaps down to PR1976 system libGIO/Glib. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:10:24 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:10:24 +0000 Subject: [Bug 1281] [IcedTea8] Shared class data archive should be generated post-build on architectures with the client VM In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1281 --- Comment #2 from Andrew John Hughes --- No file /home/andrew/build/icedtea8/jre/lib/amd64/server/classes.jsa -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:11:54 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:11:54 +0000 Subject: [Bug 1978] New: [IcedTea8] Support using the system installation of libpcsclite Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1978 Bug ID: 1978 Summary: [IcedTea8] Support using the system installation of libpcsclite Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: major Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org 8 version of PR1660. Comparing /home/andrew/build/icedtea7/jre/lib/amd64/libj2pcsc.so and /home/andrew/build/icedtea8/jre/lib/amd64/libj2pcsc.so linkage --- /tmp/.private/andrew/ld1 2014-09-03 17:04:15.400590652 +0100 +++ /tmp/.private/andrew/ld2 2014-09-03 17:04:15.408590764 +0100 @@ -1,5 +1,4 @@ /lib64/ld-linux-x86-64.so.2 libc.so.6 - libpcsclite.so.1 - libpthread.so.0 + libdl.so.2 linux-vdso.so.1 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:12:09 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:12:09 +0000 Subject: [Bug 1978] [IcedTea8] Support using the system installation of libpcsclite In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1978 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Blocks| |1282 Target Milestone|--- |3.0.0 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:12:09 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:12:09 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1978 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:12:27 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:12:27 +0000 Subject: [Bug 1537] [IcedTea8] Allow use of system Kerberos to obtain cache location In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1537 --- Comment #1 from Andrew John Hughes --- No file /home/andrew/build/icedtea8/jre/lib/amd64/libj2krb5.so -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:13:17 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:13:17 +0000 Subject: [Bug 1979] New: [IcedTea8] Support using the system installation of libjpeg Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1979 Bug ID: 1979 Summary: [IcedTea8] Support using the system installation of libjpeg Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org Comparing /home/andrew/build/icedtea7/jre/lib/amd64/libjavajpeg.so and /home/andrew/build/icedtea8/jre/lib/amd64/libjavajpeg.so linkage --- /tmp/.private/andrew/ld1 2014-09-03 17:04:15.524592400 +0100 +++ /tmp/.private/andrew/ld2 2014-09-03 17:04:15.536592569 +0100 @@ -2,7 +2,6 @@ libc.so.6 libdl.so.2 libjava.so - libjpeg.so.62 libjvm.so libjvm.so libjvm.so -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:14:27 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:14:27 +0000 Subject: [Bug 1979] [IcedTea8] Support using the system installation of libjpeg In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1979 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED URL| |https://bugs.openjdk.java.n | |et/browse/JDK-8043805 Blocks| |1282 Target Milestone|--- |3.0.0 --- Comment #1 from Andrew John Hughes --- changeset: 10013:03f9102db2c0 tag: icedtea-3.0.0pre02 user: omajid date: Fri May 23 11:04:37 2014 -0400 summary: 8043805: Allow using a system-installed libjpeg -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:14:27 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:14:27 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1979 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:15:37 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:15:37 +0000 Subject: [Bug 1980] New: [IcedTea8] Support using the system installation of giflib Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1980 Bug ID: 1980 Summary: [IcedTea8] Support using the system installation of giflib Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org Comparing /home/andrew/build/icedtea7/jre/lib/amd64/libsplashscreen.so and /home/andrew/build/icedtea8/jre/lib/amd64/libsplashscreen.so linkage --- /tmp/.private/andrew/ld1 2014-09-03 17:04:15.628593866 +0100 +++ /tmp/.private/andrew/ld2 2014-09-03 17:04:15.644594091 +0100 @@ -1,10 +1,7 @@ /lib64/ld-linux-x86-64.so.2 libc.so.6 libdl.so.2 - libgif.so.6 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:17:22 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:17:22 +0000 Subject: [Bug 1980] [IcedTea8] Support using the system installation of giflib In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1980 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED URL| |https://bugs.openjdk.java.n | |et/browse/JDK-8011278 Blocks| |1282 Target Milestone|--- |3.0.0 --- Comment #1 from Andrew John Hughes --- changeset: 7011:9c76ea43d491 user: omajid date: Tue Apr 02 14:13:13 2013 -0400 summary: 8011278: Allow using a system-installed giflib -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:17:22 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:17:22 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1980 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:18:22 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:18:22 +0000 Subject: [Bug 1981] New: [IcedTea8] Support using the system installation of libpng Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1981 Bug ID: 1981 Summary: [IcedTea8] Support using the system installation of libpng Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org Comparing /home/andrew/build/icedtea7/jre/lib/amd64/libsplashscreen.so and /home/andrew/build/icedtea8/jre/lib/amd64/libsplashscreen.so linkage --- /tmp/.private/andrew/ld1 2014-09-03 17:04:15.628593866 +0100 +++ /tmp/.private/andrew/ld2 2014-09-03 17:04:15.644594091 +0100 @@ -1,10 +1,7 @@ /lib64/ld-linux-x86-64.so.2 libc.so.6 libdl.so.2 - libgif.so.6 - libjpeg.so.62 libm.so.6 - libpng16.so.16 libpthread.so.0 libX11.so.6 libXau.so.6 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:19:02 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:19:02 +0000 Subject: [Bug 1981] [IcedTea8] Support using the system installation of libpng In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1981 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED URL| |https://bugs.openjdk.java.n | |et/browse/JDK-8035341 Blocks| |1282 Target Milestone|--- |3.0.0 --- Comment #1 from Andrew John Hughes --- changeset: 9620:f1d3a9182ff9 user: omajid date: Thu Feb 20 10:07:54 2014 -0500 summary: 8035341: Allow using a system installed libpng -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:19:02 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:19:02 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1981 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:20:01 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:20:01 +0000 Subject: [Bug 1982] New: [IcedTea8] Support using the system installation of Gtk+ Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1982 Bug ID: 1982 Summary: [IcedTea8] Support using the system installation of Gtk+ Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org No file /home/andrew/build/icedtea8/jre/lib/amd64/libjavagtk.so -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:20:14 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:20:14 +0000 Subject: [Bug 1982] [IcedTea8] Support using the system installation of Gtk+ In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1982 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Blocks| |1282 Target Milestone|--- |3.0.0 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:20:14 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:20:14 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1982 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:25:06 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:25:06 +0000 Subject: [Bug 1983] New: [IcedTea8] Support using the system installation of NSS with the SunEC provider Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1983 Bug ID: 1983 Summary: [IcedTea8] Support using the system installation of NSS with the SunEC provider Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org See PR1699 and PR1742 for IcedTea 2.x -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:25:23 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:25:23 +0000 Subject: [Bug 1983] [IcedTea8] Support using the system installation of NSS with the SunEC provider In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1983 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Blocks| |1282 Target Milestone|--- |3.0.0 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:25:23 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:25:23 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1983 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 3 16:27:17 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 03 Sep 2014 16:27:17 +0000 Subject: [Bug 1368] [IcedTea8] Ensure debug data is available for all libraries and binaries without redundant files In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1368 --- Comment #5 from Andrew John Hughes --- No file /home/andrew/build/icedtea7/jre/lib/amd64/libjsig.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjsdt.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libmlib_image.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libattach.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/jli/libjli.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjavajpeg.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libsunec.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjava_crw_demo.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libsplashscreen.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libhprof.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libj2pcsc.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libinstrument.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libsctp.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libsaproc.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libawt_headless.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjaas_unix.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libfontmanager.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libnpt.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjava.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libawt_xawt.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libzip.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libunpack.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/server/libjsig.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/server/libjvm.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/liblcms.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libnet.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libmanagement.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libdt_socket.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjsound.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libsunec.so No file /home/andrew/build/icedtea7/jre/lib/amd64/libj2pkcs11.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libj2gss.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libverify.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjdwp.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjawt.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libawt.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libjsoundalsa.diz No file /home/andrew/build/icedtea7/jre/lib/amd64/libnio.diz No file /home/andrew/build/icedtea7/jre/lib/jexec.diz -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From helpcrypto at gmail.com Wed Sep 3 16:28:26 2014 From: helpcrypto at gmail.com (helpcrypto helpcrypto) Date: Wed, 3 Sep 2014 18:28:26 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <54071A8A.9050202@gmx.de> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <1222082700.26083069.1409081718997.JavaMail.zimbra@redhat.com> <982339162.26695106.1409162928407.JavaMail.zimbra@redhat.com> <958305698.27235425.1409240834908.JavaMail.zimbra@redhat.com> <1885159478.27899833.1409329251634.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> <54071A8A.9050202@gmx.de> Message-ID: I'll wait for a hidding patch then. On Wed, Sep 3, 2014 at 3:41 PM, Jacob Wisor wrote: > On 09/01/2014 at 02:59 PM, helpcrypto helpcrypto wrote: > >> On Sat, Aug 30, 2014 at 9:44 AM, Jacob Wisor wrote: >> >> No no, do not start playing around with visible and hidden UI components. >>> It is even worse when they change their layout or start jumping around >>> like >>> it is now. Generally, there is never any need to hide UI components. If >>> there seems to be, then either there is something wrong with the basic >>> design of a window or dialog, or you should have very good reasons to do >>> so. And, in this case there is surely *no* reason to hide any components >>> dynamically at all. Again, stick to disabling components. This should be >>> enough. >>> >>> @helpcrypto >>> Yes, it is against basic UI design principles to have hiding UI >>> components, unless there are really good reasons to do so. >>> >> >> Can you point a style guide, or a gui-best-practices which advices on >> that? >> > > Well, there are multiple guidelines available, depending on OS, window > managers and/or desktop managers. It is difficult to point to a specific > one in the case of SWT and Java because it is platform independent. But, I > suppose one could take Microsoft's UI guidelines as a basis because of it's > undeniable bread adoption. It also shares a large set of rules with other > UI guidelines form other vendors. > > > I have seen several GUIs wich only show the user what he needs to see, and >> I found them KISS-compliant >> > > I think you are mixing to concepts here. KISS is about technical > solutions, that is how things should be solved in order for other engineers > to comprehend the work of the original authors, and generally assumes that > simple technical solutions are usually the most effective or efficient ones. > > UI design guidelines employ a similar concept but not exactly KISS. Good > UI designs should not be overloaded with UI components and only display the > right amount of components required to accomplish the current task at hand. > Hence, users should not be overburdened with overloaded UIs. But, most > importantly UIs must not be confusing to users, and their behavior must be > intuitively and naturally predictable. Hiding and jumping UI controls feel > absolutely unnatural and inorganic. This is indeed bad behavior for UI > controls. > > I will give you a simple example why your way of thinking is flawed here. > Take for example a dialog with a list view and an edit button to edit the > list view items. Now, if no list view item would be selected then according > to your reasoning the edit button should be hidden because the user can > take no editing action while no list view item is selected. This is > absolutely confusing to the user. The user is supposed to be able to see > and know all the possible actions he can take at all times but should not > be able to take invalid actions. This is why the edit button in this > example has to stay always visible but not always enabled. Think about it. > ;-) > > Unfortunately, because of your attempt to play around with hiding UI >>> components you have introduced a new bug. When "Limit cache size" is >>> checked and the spinner is 0 then all components for setting up the cache >>> location suddenly disappear. >>> >> >> Limit checked, value=0->no cache, hence no need of location, compression >> >> level or anything. It's not a bug. >> The warning under spinner informs about that. >> > > This is logically correct but it is against basic UI design guidelines. It > is inorganic. > > > And, as soon as the value becomes greater than 1, they become visible >>> again. This is very odd, weird, and confusing. Again, do not play around >>> with hiding UI components. >>> >>> The reason why i suggested "no cach?" instead of 0. >> > > As mentioned before, the UI components handling the cache's location > should simply be disabled in this case. No real reason to hide them. > > Jacob > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Wed Sep 3 18:00:04 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 3 Sep 2014 14:00:04 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <958305698.27235425.1409240834908.JavaMail.zimbra@redhat.com> <1885159478.27899833.1409329251634.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> <54071A8A.9050202@gmx.de> Message-ID: <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> Hello, My two cents: In terms of this particular patch I believe that compared to hiding/showing UI elements, disabling UI elements is slightly more user-friendly and much more developer-friendly (in regards to Swing and Java). There are numerous other tasks that need to be done and I think we should consider pushing a working version of this improvement quickly, and then updating over that if necessary. In regards to UI design philosophy and KISS (keep it simple stupid), I think we can argue over it all day long but rather than point to basic design guidelines or philosophies (since it all comes down to opinion), I think there are some simple rules that we can state and agree on such as, but not limited to: UI must work : There are a set of actions that can be performed and the UI must support these actions. UI must be simple : There are a set of actions that must be supported and the UI should support said actions with minimal effort on the part of the developer in creating this support, and on the user in accessing these actions. When it comes to minimal effort for the user, hiding/showing versus disabling to me is a neutral difference. It is not harder for the user to perform all actions when UI is shown/hidden based on when an action can be performed, but it is also not harder for the user to perform all actions when the UI is disabled/enabled based on when an action can be performed. However I think that hidden UI is more difficult for a user to learn about than disabled UI which is why I prefer enabling/disabling if necessary. Regards, ----- Original Message ----- > I'll wait for a hidding patch then. > > On Wed, Sep 3, 2014 at 3:41 PM, Jacob Wisor wrote: > > > On 09/01/2014 at 02:59 PM, helpcrypto helpcrypto wrote: > > > >> On Sat, Aug 30, 2014 at 9:44 AM, Jacob Wisor wrote: > >> > >> No no, do not start playing around with visible and hidden UI components. > >>> It is even worse when they change their layout or start jumping around > >>> like > >>> it is now. Generally, there is never any need to hide UI components. If > >>> there seems to be, then either there is something wrong with the basic > >>> design of a window or dialog, or you should have very good reasons to do > >>> so. And, in this case there is surely *no* reason to hide any components > >>> dynamically at all. Again, stick to disabling components. This should be > >>> enough. > >>> > >>> @helpcrypto > >>> Yes, it is against basic UI design principles to have hiding UI > >>> components, unless there are really good reasons to do so. > >>> > >> > >> Can you point a style guide, or a gui-best-practices which advices on > >> that? > >> > > > > Well, there are multiple guidelines available, depending on OS, window > > managers and/or desktop managers. It is difficult to point to a specific > > one in the case of SWT and Java because it is platform independent. But, I > > suppose one could take Microsoft's UI guidelines as a basis because of it's > > undeniable bread adoption. It also shares a large set of rules with other > > UI guidelines form other vendors. > > > > > > I have seen several GUIs wich only show the user what he needs to see, and > >> I found them KISS-compliant > >> > > > > I think you are mixing to concepts here. KISS is about technical > > solutions, that is how things should be solved in order for other engineers > > to comprehend the work of the original authors, and generally assumes that > > simple technical solutions are usually the most effective or efficient > > ones. > > > > UI design guidelines employ a similar concept but not exactly KISS. Good > > UI designs should not be overloaded with UI components and only display the > > right amount of components required to accomplish the current task at hand. > > Hence, users should not be overburdened with overloaded UIs. But, most > > importantly UIs must not be confusing to users, and their behavior must be > > intuitively and naturally predictable. Hiding and jumping UI controls feel > > absolutely unnatural and inorganic. This is indeed bad behavior for UI > > controls. > > > > I will give you a simple example why your way of thinking is flawed here. > > Take for example a dialog with a list view and an edit button to edit the > > list view items. Now, if no list view item would be selected then according > > to your reasoning the edit button should be hidden because the user can > > take no editing action while no list view item is selected. This is > > absolutely confusing to the user. The user is supposed to be able to see > > and know all the possible actions he can take at all times but should not > > be able to take invalid actions. This is why the edit button in this > > example has to stay always visible but not always enabled. Think about it. > > ;-) > > > > Unfortunately, because of your attempt to play around with hiding UI > >>> components you have introduced a new bug. When "Limit cache size" is > >>> checked and the spinner is 0 then all components for setting up the cache > >>> location suddenly disappear. > >>> > >> > >> Limit checked, value=0->no cache, hence no need of location, compression > >> > >> level or anything. It's not a bug. > >> The warning under spinner informs about that. > >> > > > > This is logically correct but it is against basic UI design guidelines. It > > is inorganic. > > > > > > And, as soon as the value becomes greater than 1, they become visible > >>> again. This is very odd, weird, and confusing. Again, do not play around > >>> with hiding UI components. > >>> > >>> The reason why i suggested "no cach?" instead of 0. > >> > > > > As mentioned before, the UI components handling the cache's location > > should simply be disabled in this case. No real reason to hide them. > > > > Jacob > > > -- Jie Kang From helpcrypto at gmail.com Thu Sep 4 06:33:32 2014 From: helpcrypto at gmail.com (helpcrypto helpcrypto) Date: Thu, 4 Sep 2014 08:33:32 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <958305698.27235425.1409240834908.JavaMail.zimbra@redhat.com> <1885159478.27899833.1409329251634.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> Message-ID: On Wed, Sep 3, 2014 at 8:00 PM, Jie Kang wrote: > There are numerous other tasks that need to be done and I think we should > consider pushing a working version of this improvement quickly, and then > updating over that if necessary. > > In regards to UI design philosophy and KISS (keep it simple stupid), I > think we can argue over it all day long > Both of these reasons made me say: > I'll wait for a *disabling* patch then. ;) -------------- next part -------------- An HTML attachment was scrubbed... URL: From ptisnovs at icedtea.classpath.org Thu Sep 4 08:22:32 2014 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Thu, 04 Sep 2014 08:22:32 +0000 Subject: /hg/gfx-test: Ten new tests added into CAGOperationsOnTwoOverlap... Message-ID: changeset 9f7b40fa8ca1 in /hg/gfx-test details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=9f7b40fa8ca1 author: Pavel Tisnovsky date: Thu Sep 04 10:23:42 2014 +0200 Ten new tests added into CAGOperationsOnTwoOverlappingCircles. diffstat: ChangeLog | 5 + src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java | 251 ++++++++++ 2 files changed, 256 insertions(+), 0 deletions(-) diffs (280 lines): diff -r 52d612cf8db6 -r 9f7b40fa8ca1 ChangeLog --- a/ChangeLog Wed Sep 03 11:52:58 2014 +0200 +++ b/ChangeLog Thu Sep 04 10:23:42 2014 +0200 @@ -1,3 +1,8 @@ +2014-09-04 Pavel Tisnovsky + + * src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java: + Ten new tests added into CAGOperationsOnTwoOverlappingCircles. + 2014-09-03 Pavel Tisnovsky * src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java: diff -r 52d612cf8db6 -r 9f7b40fa8ca1 src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java --- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java Wed Sep 03 11:52:58 2014 +0200 +++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java Thu Sep 04 10:23:42 2014 +0200 @@ -1768,6 +1768,256 @@ * graphics canvas * @return test result status - PASSED, FAILED or ERROR */ + public TestResult testIntersectTextureFillUsingHorizontalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingHorizontalStripesTexture(image, graphics2d); + // create area using Intersect operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingIntersectOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using Xor operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorTextureFillUsingHorizontalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingHorizontalStripesTexture(image, graphics2d); + // create area using Xor operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingXorOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using union operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingUnionOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using inverse subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using Intersect operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testIntersectTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d); + // create area using Intersect operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingIntersectOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using Xor operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d); + // create area using Xor operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingXorOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using union operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionTextureFillUsingHorizontalColorStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingHorizontalColorStripesTexture(image, graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingUnionOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractTextureFillUsingHorizontalColorStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingHorizontalColorStripesTexture(image, graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using inverse subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractTextureFillUsingHorizontalColorStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingHorizontalColorStripesTexture(image, graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingCirclesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping circles using Intersect operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ public TestResult testIntersectTextureFillUsingRGBTexture6(TestImage image, Graphics2D graphics2d) { // set stroke color @@ -1807,6 +2057,7 @@ return TestResult.PASSED; } + /** * Entry point to the test suite. * From gitne at gmx.de Thu Sep 4 11:48:50 2014 From: gitne at gmx.de (Jacob Wisor) Date: Thu, 04 Sep 2014 13:48:50 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <958305698.27235425.1409240834908.JavaMail.zimbra@redhat.com> <1885159478.27899833.1409329251634.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> Message-ID: <540851A2.2080807@gmx.de> On 09/03/2014 at 08:00 PM, Jie Kang wrote: > In regards to UI design philosophy and KISS (keep it simple stupid), I think we can argue over it all day long but rather than point to basic design guidelines or philosophies (since it all comes down to opinion), No, it does not. Scientific studies in social sciences on human-machine interaction have clearly revealed two decades ago already what the basic design principles of UIs should be. And, since science is all about facts and not opinions, I do not think we should open this discussion here. The problem I see here, is that often people recite or refer to scientific results without actually having read them or only picking out one issue that they remember and then filling in the missing parts by resorting to their guts. This is not how professional work is done. Results on scientific studies are not gut feelings but facts. Getting an interpretation on studies right is a different thing. However, time (like 20 years ago) has proven that social sciences on human-machine interaction have gotten the interpretation of their studies quite right, thus the same applies to the UI design guidelines which in turn are based on those interpretations. So, long story short, in this case the design should be disabling/enabling. > I think there are some simple rules that we can state and agree on such as, but not limited to: Yes, we may agree, but as I have already mentioned, it is not about opinion or consensus but about scientific facts. ;-) Of course, anyone is still entitled to their opinion on scientific facts, but then... usually those people have some kind of disorders or are just lunatics. :-D > UI must work : There are a set of actions that can be performed and the UI must support these actions. > UI must be simple : There are a set of actions that must be supported and the UI should support said actions with minimal effort on the part of the developer in creating this support, and on the user in accessing these actions. > > When it comes to minimal effort for the user, hiding/showing versus disabling to me is a neutral difference. It is not harder for the user to perform all actions when UI is shown/hidden based on when an action can be performed, but it is also not harder for the user to perform all actions when the UI is disabled/enabled based on when an action can be performed. However I think that hidden UI is more difficult for a user to learn about than disabled UI which is why I prefer enabling/disabling if necessary. Jacob From bugzilla-daemon at icedtea.classpath.org Thu Sep 4 14:01:49 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 04 Sep 2014 14:01:49 +0000 Subject: [Bug 1284] [TRACKER] IcedTea 2.5.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1284 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED --- Comment #1 from Andrew John Hughes --- Released: http://bitly.com/1l7n3Qq -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From helpcrypto at gmail.com Thu Sep 4 14:07:32 2014 From: helpcrypto at gmail.com (helpcrypto helpcrypto) Date: Thu, 4 Sep 2014 16:07:32 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <540851A2.2080807@gmx.de> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <958305698.27235425.1409240834908.JavaMail.zimbra@redhat.com> <1885159478.27899833.1409329251634.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> Message-ID: As I said, I'm waiting for the enabling/disablind patch. ;) -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Thu Sep 4 15:02:13 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 04 Sep 2014 15:02:13 +0000 Subject: [Bug 1348] [IcedTea8] java -version output is broken In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1348 --- Comment #6 from Andrew John Hughes --- Perfect. openjdk version "1.8.0_20" OpenJDK Runtime Environment (IcedTea 3.0.0pre02+rc3b3c0cb05d3+) (Gentoo build 1.8.0_20-b23) OpenJDK 64-Bit Server VM (build 25.20-b22, mixed mode) -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Thu Sep 4 15:06:10 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Thu, 04 Sep 2014 15:06:10 +0000 Subject: /hg/icedtea: 2 new changesets Message-ID: changeset c3b3c0cb05d3 in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=c3b3c0cb05d3 author: Andrew John Hughes date: Thu Sep 04 15:22:54 2014 +0100 PR1348: Make versioning variables more obvious and name tarballs better. 2013-09-10 Andrew John Hughes * Makefile.am: (BUILD_VERSION): Renamed from OPENJDK_VERSION. (COMBINED_VERSION): Use BUILD_VERSION. (ICEDTEA_ENV): Likewise. (dist-openjdk): Should really use COMBINED_VERSION. (dist-openjdk-fsg): Likewise. (dist-openjdk-fsg-tz): Additional target which makes an xz tarball instead of a zip (for Jiri ;) changeset b27c53ea4272 in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=b27c53ea4272 author: Andrew John Hughes date: Thu Sep 04 16:05:29 2014 +0100 PR1348: Move version settings to OpenJDK configure from OpenJDK make. 2014-09-04 Andrew John Hughes * Makefile.am: (ICEDTEA_CONFIGURE): Add update version, build number and milestone options. (ICEDTEA_ENV): Drop BUILD_NUMBER, JDK_UPDATE_VERSION, JRE_RELEASE_VERSION and MILESTONE, which appear to be no longer used. diffstat: ChangeLog | 21 +++++++++++++++++++++ Makefile.am | 21 ++++++++++++--------- 2 files changed, 33 insertions(+), 9 deletions(-) diffs (83 lines): diff -r 3680c74438e9 -r b27c53ea4272 ChangeLog --- a/ChangeLog Wed Sep 03 16:32:44 2014 +0100 +++ b/ChangeLog Thu Sep 04 16:05:29 2014 +0100 @@ -1,3 +1,24 @@ +2014-09-04 Andrew John Hughes + + * Makefile.am: + (ICEDTEA_CONFIGURE): Add update version, + build number and milestone options. + (ICEDTEA_ENV): Drop BUILD_NUMBER, + JDK_UPDATE_VERSION, JRE_RELEASE_VERSION + and MILESTONE, which appear to be no + longer used. + +2013-09-10 Andrew John Hughes + + * Makefile.am: + (BUILD_VERSION): Renamed from OPENJDK_VERSION. + (COMBINED_VERSION): Use BUILD_VERSION. + (ICEDTEA_ENV): Likewise. + (dist-openjdk): Should really use COMBINED_VERSION. + (dist-openjdk-fsg): Likewise. + (dist-openjdk-fsg-tz): Additional target which + makes an xz tarball instead of a zip (for Jiri ;) + 2014-09-03 Andrew John Hughes * NEWS: Add bug reference for system LCMS support. diff -r 3680c74438e9 -r b27c53ea4272 Makefile.am --- a/Makefile.am Wed Sep 03 16:32:44 2014 +0100 +++ b/Makefile.am Thu Sep 04 16:05:29 2014 +0100 @@ -1,8 +1,8 @@ # Dependencies -OPENJDK_VERSION = b23 JDK_UPDATE_VERSION = 20 -COMBINED_VERSION = $(JDK_UPDATE_VERSION)-$(OPENJDK_VERSION) +BUILD_VERSION = b23 +COMBINED_VERSION = $(JDK_UPDATE_VERSION)-$(BUILD_VERSION) CORBA_CHANGESET = 83ebbcc0dda5 JAXP_CHANGESET = 888f90c5e7da @@ -273,7 +273,10 @@ --enable-unlimited-crypto \ --with-cacerts-file=$(SYSTEM_JDK_DIR)/jre/lib/security/cacerts \ --with-zlib=system --with-stdc++lib=dynamic \ - --with-boot-jdk=$(BOOT_DIR) + --with-boot-jdk=$(BOOT_DIR) \ + --with-update-version=$(JDK_UPDATE_VERSION) \ + --with-build-number=$(BUILD_VERSION) \ + --with-milestone="fcs" if ENABLE_CACAO ICEDTEA_CONFIGURE += \ @@ -294,10 +297,6 @@ endif ICEDTEA_ENV = \ - BUILD_NUMBER="$(OPENJDK_VERSION)" \ - JDK_UPDATE_VERSION="$(JDK_UPDATE_VERSION)" \ - JRE_RELEASE_VERSION="1.8.0_$(COMBINED_VERSION)" \ - MILESTONE="fcs" \ LANG="C" \ PATH="$(BOOT_DIR)/bin:$(OS_PATH):$$PATH" \ CLASSPATH="" \ @@ -553,11 +552,15 @@ # Creates archive of openjdk. dist-openjdk: stamps/extract-cacao.stamp find openjdk/ -name \\.hg* | xargs rm -rf - $(ZIP) -r openjdk-$(OPENJDK_VERSION) openjdk/ + $(ZIP) -r openjdk-$(COMBINED_VERSION) openjdk/ # Creates archive of openjdk that is compliant with Free Software guidelines. dist-openjdk-fsg: stamps/patch-fsg.stamp - $(ZIP) -r openjdk-fsg-$(OPENJDK_VERSION) openjdk/ + $(ZIP) -r openjdk-fsg-$(COMBINED_VERSION) openjdk/ + +dist-openjdk-fsg-xz: stamps/patch-fsg.stamp + tardir=openjdk/ && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c \ + >openjdk-fsg-$(COMBINED_VERSION).tar.xz # OpenJDK Source Preparation Targets # ================================== From bugzilla-daemon at icedtea.classpath.org Thu Sep 4 15:06:25 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 04 Sep 2014 15:06:25 +0000 Subject: [Bug 1348] [IcedTea8] java -version output is broken In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1348 --- Comment #7 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea?cmd=changeset;node=b27c53ea4272 author: Andrew John Hughes date: Thu Sep 04 16:05:29 2014 +0100 PR1348: Move version settings to OpenJDK configure from OpenJDK make. 2014-09-04 Andrew John Hughes * Makefile.am: (ICEDTEA_CONFIGURE): Add update version, build number and milestone options. (ICEDTEA_ENV): Drop BUILD_NUMBER, JDK_UPDATE_VERSION, JRE_RELEASE_VERSION and MILESTONE, which appear to be no longer used. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Thu Sep 4 15:07:08 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 04 Sep 2014 15:07:08 +0000 Subject: [Bug 1348] [IcedTea8] java -version output is broken In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1348 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Thu Sep 4 15:07:08 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 04 Sep 2014 15:07:08 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Bug 1282 depends on bug 1348, which changed state. Bug 1348 Summary: [IcedTea8] java -version output is broken http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1348 What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ldracz at redhat.com Thu Sep 4 15:15:33 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Thu, 4 Sep 2014 11:15:33 -0400 (EDT) Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <53FDB53A.90301@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <53FB2893.4050303@redhat.com> <53FB2938.6040201@redhat.com> <471810972.25519307.1408998763566.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> Message-ID: <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> Hello, I have taken in as much of your suggestions as I could. I have attached the updated Option Parser. I rewrote how the parser works and changed it from parsing inside a method to parsing in the constructor, as you should only really need to parse once. It stores the options in a Map with Options as Keys and a List of Strings for the values. The getValue(s) methods return based on the option from that map. >> + public String[] getOptionValues(Option option) { >> + List result = new ArrayList(); >> >> + return result.toArray(new String[result.size()]); >> + } >> >Why not just return a `List` instead? In Boot it gets used by being put in a Map which is then passed into the Launcher class. I didn't want to change that up in this patch too. If you want I can add another method that could be used in the future called getListOfValues. >> + public String[] getArgs() { >> + return Arrays.copyOf(args, args.length); >> + } > >Eh? Why expose internal state? Think about what needs to use this, and >if an alternate implementation that does not expose the internals would >be possible and/or better. I looked into what was using this and it was ParserSettings so I redid the method to accept two booleans instead of args which it would then look for the "-strict" and "-xml" tags inside of. This also meant changing the ParserSettingsTest which in my opinion don't make sense in their current state. I plan on looking into Parser and ParserSetting in the future and see how they are used and if it makes sense for them to be changed to incorporate the OptionParser. The OptionsDefinitions Class is a shared class Jiri made that I have helped a bit on, I will update my optionsDefinitions Class with any further changes if required by Jiri. Also will update with the version Jiri sends out to the list. For the parser I tried my best to make it as flexible as possible to cover as many possible various cases of how users might input their commands. For example, the user can use the same tag multiple times and it won't matter command -headless -headless -headless File.jnlp -headless -headless -headless is the same as command -headless File.jnlp also for ones that take multiple inputs you can have the tag multiple times command -arg blue green red -headless File.jnlp -arg yellow purple will have blue, green, red, yellow, purple all under arg Notice however that -headless need to be before File.jnlp since the parser wouldn't know whether File.jnlp was just another arg or the main argument but after -headless which it knows takes no arguments it can be sure that File.jnlp is the main arg. Currently writing a few more unit tests and testing out other cases but wanted to get feedback before I spent too much time on more unit tests. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: optionParser-10.patch Type: text/x-patch Size: 38729 bytes Desc: not available URL: From jvanek at redhat.com Thu Sep 4 15:18:19 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 04 Sep 2014 17:18:19 +0200 Subject: Fwd: docs generator - prereview In-Reply-To: <5405E4C0.9050909@redhat.com> References: <5405E4C0.9050909@redhat.com> Message-ID: <540882BB.5070100@redhat.com> Hi! Proudly :) presenting... documentation generator for ITW. Lukas Dracz already seen the preversion, because we shares one peace of code - OptionsDefinitions.java - also he was trying to impelmetn first versions of this. Now his patch is built on top of this. Well, it does a lot of things - generates man pages and html doc* and palintext docs** - unified files declarations - unified options declarations * html docs - are usleless in offlien mode (maybe we can publish them on classapth org after each release - but are used (generated in runtime) in help dialogue - which is really really nice. ** plain text docs - even les susefull then html docs, but are used in runtime commandlinehel/and about - which removed all the duplicated string providers. Various files and properties are sorted in javaws pages, have theyrs defaults and for sure none is missing. So finally no duplicated texts in various "about" and "help"! The patch is missing localization - I'm going to do so in some next changeset, and I hope to get rid of RepalcingFormater and its @@ substitution. As for review - anybody, please be specially careful about the files declaration. I hope I did it error-less and complete :( The design is 1docprovider - have 2formater is providing 3output eg: 1 - itw, itw-settings, javaws... 2 - html, plain, man 3 - man pages (generated during build, loclaized), runtime help - both console and "nice" html one. The runtime help have evaluated varibales and properties For runtime help I had to refactor about dialog a bit - only make some parts singletons and added an tab.... make check, install, dist and install form dist and unnstall works. J. -------------- next part -------------- A non-text attachment was scrubbed... Name: docsGenerator_2.diff Type: text/x-patch Size: 189441 bytes Desc: not available URL: From jkang at redhat.com Thu Sep 4 15:31:23 2014 From: jkang at redhat.com (Jie Kang) Date: Thu, 4 Sep 2014 11:31:23 -0400 (EDT) Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <355049774.398737.1409842794092.JavaMail.zimbra@redhat.com> Message-ID: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> Hello, This patch adds a logger dependency injection to TeeOutputStream so that the tests no longer require a protected function in order to run. Thoughts? Regards, -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-teeos-dep-1.patch Type: text/x-patch Size: 7324 bytes Desc: not available URL: From jkang at redhat.com Thu Sep 4 18:11:23 2014 From: jkang at redhat.com (Jie Kang) Date: Thu, 4 Sep 2014 14:11:23 -0400 (EDT) Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <53FB2893.4050303@redhat.com> <53FB2938.6040201@redhat.com> <471810972.25519307.1408998763566.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> Message-ID: <1896202438.535479.1409854283129.JavaMail.zimbra@redhat.com> ----- Original Message ----- > Hello, > > I have taken in as much of your suggestions as I could. I have attached the > updated Option Parser. I rewrote how the parser works and changed it from > parsing inside a method to parsing in the constructor, as you should only > really need to parse once. It stores the options in a Map with Options as > Keys and a List of Strings for the values. The getValue(s) methods return > based on the option from that map. > > > >> + public String[] getOptionValues(Option option) { > >> + List result = new ArrayList(); > >> > >> + return result.toArray(new String[result.size()]); > >> + } > >> > >Why not just return a `List` instead? > > In Boot it gets used by being put in a Map which is then > passed into the Launcher class. > I didn't want to change that up in this patch too. If you want I can add > another method that could be used in the future called getListOfValues. > > >> + public String[] getArgs() { > >> + return Arrays.copyOf(args, args.length); > >> + } > > > >Eh? Why expose internal state? Think about what needs to use this, and > >if an alternate implementation that does not expose the internals would > >be possible and/or better. > > I looked into what was using this and it was ParserSettings so I redid the > method to accept two booleans instead of > args which it would then look for the "-strict" and "-xml" tags inside of. > This also meant changing the ParserSettingsTest which in my opinion don't > make sense in their current state. I plan on looking into Parser and > ParserSetting in the future and see how they are used and if it makes sense > for them to be changed to incorporate the OptionParser. > > The OptionsDefinitions Class is a shared class Jiri made that I have helped a > bit on, I will update my optionsDefinitions Class with any further changes > if required by Jiri. Also will update with the version Jiri sends out to the > list. > > For the parser I tried my best to make it as flexible as possible to cover as > many possible various cases of how users might input their commands. > > For example, the user can use the same tag multiple times and it won't matter > > command -headless -headless -headless File.jnlp -headless -headless -headless > > is the same as > > command -headless File.jnlp > > also for ones that take multiple inputs you can have the tag multiple times > > command -arg blue green red -headless File.jnlp -arg yellow purple > > will have blue, green, red, yellow, purple all under arg > Notice however that -headless need to be before File.jnlp since the parser > wouldn't know whether File.jnlp was just another arg or the main argument > but after -headless which it knows takes no arguments it can be sure that > File.jnlp is the main arg. > > Currently writing a few more unit tests and testing out other cases but > wanted to get feedback before I spent too much time on more unit tests. > > Thank you, > Lukasz Dracz Hello, Review in-line with code: +public class OptionParser { + + private String[] args; + private Map> parsedOptions; Please make both args and parsedOptions final as well + private final List possibleOptions; + private final String MAINARG = "mainArg"; + private final OptionsDefinitions.OPTIONS mainArg = null; Not a big fan of using the null key. Please add a comment to clarify that it is meant to be null and what it represents. + private final boolean lookForMainArg; + + public OptionParser(String[] args, List options, boolean lookForMainArg) { + this.args = Arrays.copyOf(args, args.length); + this.possibleOptions = options; + this.lookForMainArg = lookForMainArg; + List result = new ArrayList(); + String lastOption = ""; + parsedOptions = new HashMap<>(); Moving the parsing of arguments into the constructor is fine but please extract it into it's own private function or possibly their own functions and have them called in the constructor. + int i = 0; + while (i < args.length) { + if (isOption(args[i])) { + result.clear(); + if (args[i].contains("=")) { + result.add(args[i].split("=")[1]); + lastOption = args[i].split("=")[0]; + parsedOptions.put(getOption(lastOption), new ArrayList(result)); + } else { + lastOption = args[i]; + if (parsedOptions.keySet().contains(getOption(lastOption))) { + if (getOption(lastOption).hasManyArguments()) { + result = new ArrayList<>(parsedOptions.get(getOption(lastOption))); + } + } + if (getOption(lastOption).hasNoArguments()) { + parsedOptions.put(getOption(lastOption), null); + lastOption = MAINARG; + } + } + } else { + result.add(args[i]); + parsedOptions.put(getOption(lastOption), new ArrayList(result)); + if (getOption(lastOption) != null) { + if (getOption(lastOption).hasOneArgument()) { + lastOption = MAINARG; + result.clear(); + } + } + } + i++; + } + + if(this.lookForMainArg) { + if (!(parsedOptions.keySet().contains(mainArg))) { + i--; This is a style nit but having this 'i--' in here requires more code-reading than say 'i = args.length - 1'. With the latter it's more quickly understood that you are iterating args in reverse. Up to you; + while (i >= 0) { + if (!args[i].startsWith("-")) { + for (OptionsDefinitions.OPTIONS op : parsedOptions.keySet()) { + if (!(parsedOptions.get(op) == null)) { + if (parsedOptions.get(op).contains(args[i])) { + result.clear(); + result.add(args[i]); + parsedOptions.get(op).remove(parsedOptions.get(op).indexOf(args[i])); + break; + } + } + } + parsedOptions.put(mainArg, result); + break; + } + i--; + } + } + } + + } + public String getLocalizedEscription() { typo?; + return R(decriptionKey); + } Regards, -- Jie Kang From omajid at redhat.com Thu Sep 4 18:18:31 2014 From: omajid at redhat.com (Omair Majid) Date: Thu, 4 Sep 2014 14:18:31 -0400 Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <53FB2893.4050303@redhat.com> <53FB2938.6040201@redhat.com> <471810972.25519307.1408998763566.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> Message-ID: <20140904181831.GB3074@redhat.com> * Lukasz Dracz [2014-09-04 11:15]: > I looked into what was using this and it was ParserSettings so I redid > the method to accept two booleans instead of args which it would then > look for the "-strict" and "-xml" tags inside of. This also meant > changing the ParserSettingsTest which in my opinion don't make sense > in their current state. I plan on looking into Parser and > ParserSetting in the future and see how they are used and if it makes > sense for them to be changed to incorporate the OptionParser. Looking quickly through the code, I am a little surprised. It seems like the simple/obvious thing to do is to create a new ParserSettings object based on settings to use for the parser (like, `ParserSettings(boolean strict)`), not from program arguments. I will be perfectly happy if you modified the ParserSettings class to move in this direction. It's fine to do it in a separate patch. Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From ldracz at redhat.com Thu Sep 4 18:39:48 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Thu, 4 Sep 2014 14:39:48 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> Message-ID: <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> Hello, Okay so this patch, uses disabling/enabling instead of hiding/showing. Also put the "Java stores application ..." description to always be at the top where as the rest of the components will be centered. Also changed from powers of two to increments of 10 but not jumps of 1,10,100,1000,10000 etc. but instead to 0,1,2,3,...,7,8,9,10,20,30...80,90,100,200,300...800,900,1000,2000,3000 etc. I think this way is best as it does not jump to the larger values too quickly. As for my opinion, I think disabling is better than hiding, as it still shows the user the possibilities in the panel even though they are not active. I also liked the powers of two spinner much more personally but from a user's point of view I agree that increments of 10 are more intuitive and easier to understand. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: cacheSizeSpinner-18.patch Type: text/x-patch Size: 22635 bytes Desc: not available URL: From jkang at redhat.com Thu Sep 4 18:55:33 2014 From: jkang at redhat.com (Jie Kang) Date: Thu, 4 Sep 2014 14:55:33 -0400 (EDT) Subject: docs generator - prereview In-Reply-To: <540882BB.5070100@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> Message-ID: <2127323249.558740.1409856933886.JavaMail.zimbra@redhat.com> ----- Original Message ----- > > Hi! > > > Proudly :) presenting... documentation generator for ITW. > > Lukas Dracz already seen the preversion, because we shares one peace of code > - > OptionsDefinitions.java - also he was trying to impelmetn first versions > of this. > > Now his patch is built on top of this. > > Well, it does a lot of things > - generates man pages and html doc* and palintext docs** > - unified files declarations > - unified options declarations > > * html docs > - are usleless in offlien mode (maybe we can publish them on classapth > org after each release - > but are used (generated in runtime) in help dialogue - which is really really > nice. > > ** plain text docs - even les susefull then html docs, but are used in > runtime commandlinehel/and > about - which removed all the duplicated string providers. > > Various files and properties are sorted in javaws pages, have theyrs defaults > and for sure none is > missing. > > So finally no duplicated texts in various "about" and "help"! > > The patch is missing localization - I'm going to do so in some next > changeset, and I hope to get > rid of RepalcingFormater and its @@ substitution. > > > > As for review - anybody, please be specially careful about the files > declaration. I hope I did it > error-less and complete :( > > > The design is > > 1docprovider - have 2formater is providing 3output > > eg: > 1 - itw, itw-settings, javaws... > 2 - html, plain, man > 3 - man pages (generated during build, loclaized), runtime help - both > console and "nice" html one. > The runtime help have evaluated varibales and properties > > > For runtime help I had to refactor about dialog a bit - only make some parts > singletons and added > an tab.... > > > make check, install, dist and install form dist and unnstall works. > > > > J. Hello, This patch is really large, is there any way you can split this into smaller iterations? For example, maybe have one patch that moves all paths and files into the PathsAndFiles.java, then one patch for the net.sourceforge.jnlp.docprovider addition, and then another patch for the makefile changes to use the docprovider. As well as a patch for refactoring the 'about dialog'. Or something along those lines; One thing as well when you look at doing the localization part. Right now Translator just delegates to JNLPRuntime. e.g: public static String R(String message, Object... params) { return JNLPRuntime.getMessage(message, params); } I think we should move the translating parts from JNLPRuntime into Translator. Thoughts? Regards, > > > > > > -- Jie Kang From ldracz at redhat.com Thu Sep 4 20:22:26 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Thu, 4 Sep 2014 16:22:26 -0400 (EDT) Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <20140904181831.GB3074@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <53FB2893.4050303@redhat.com> <53FB2938.6040201@redhat.com> <471810972.25519307.1408998763566.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> <20140904181831.GB3074@redhat.com> Message-ID: <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> Hello, > Looking quickly through the code, I am a little surprised. It seems like > the simple/obvious thing to do is to create a new ParserSettings object > based on settings to use for the parser (like, `ParserSettings(boolean > strict)`), not from program arguments. I will be perfectly happy if you > modified the ParserSettings class to move in this direction. > > It's fine to do it in a separate patch. > > Thanks, > Omair Alright, hmm ParserSettings already has a constructor with (boolean strict, boolean extensionAllowed, boolean malformedXmlAllowed) as parameters, the one difference between method and the constructor is that it assigns a new ParserSettings to the private static globalParserSettings, I'll look into it and see how this is all setup in a separate patch >Please make both args and parsedOptions final as well Okay >Not a big fan of using the null key. Please add a comment to clarify that it is meant to be null and what it >represents. Sure >Moving the parsing of arguments into the constructor is fine but please extract it into it's own private function >or possibly their own functions and have them called in the constructor. Sounds good >This is a style nit but having this 'i--' in here requires more code-reading than say 'i = args.length - 1'. With >the latter it's more quickly understood that you are iterating args in reverse. Up to you; Yeah I agree that makes it more readable. >+ public String getLocalizedEscription() { >typo?; Yes, I have updated OptionsDescriptions to match the one released in Jiri's patch, some small differences from the one I posted before, which includes Jiri fixing this typo. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: optionParser-11.patch Type: text/x-patch Size: 37258 bytes Desc: not available URL: From aazores at redhat.com Thu Sep 4 20:46:15 2014 From: aazores at redhat.com (Andrew Azores) Date: Thu, 04 Sep 2014 16:46:15 -0400 Subject: [rfc][icedtea-web] missing jnlpfile and securtydelegate for TemporaryPermissionsButton calls In-Reply-To: <54070D4D.70605@redhat.com> References: <53FDA41B.4060801@redhat.com> <53FE5CD3.4060602@redhat.com> <54070D4D.70605@redhat.com> Message-ID: <5408CF97.3030305@redhat.com> On 03/09/14 08:45 AM, Jiri Vanek wrote: > On 08/28/2014 12:33 AM, Andrew Azores wrote: >> Hi, >> >> Still on PTO here and preparing to move back into my parents' place >> while I go back to finish >> school, so I haven't really invested any real time into this bug. But... >> >> On 08/27/2014 05:25 AM, Jiri Vanek wrote: >>> Hi! >>> >>> During testing of https probing, helpcrypto found and interesting issue >>> in head. >>> >>> Under some circumstances calls to TemporaryPermissionsButton have >>> jnlpfile and securitydelegate null. >> >> The SecurityDelegate can be instantiated much earlier in >> JNLPClassLoader if need be. It can even be >> the first thing done after calling the super constructor AFAIK. Since >> the JNLPClassLoader is also >> what eventually causes the security dialog to appear with the >> Temporary Permissions button on it, >> this will probably resolve the null securityDelegate reference part. >> >>> >>> Two things troubles me: >>> - both those values are needed only when "tmeporarypermissions" are >>> clicked, so they should not affect startup of ITW >>> - how come that they are null? I blame >>> http://icedtea.classpath.org/hg/icedtea-web/annotate/d87ee4e6e81a/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java#78 >>> >>> >>> >>> (looking into Looking to this, >>> http://icedtea.classpath.org/hg/icedtea-web/file/b4363c984e1b/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java#l79 >>> >>> >>> ) >> >> For the null jnlpFile - I can't think off the top of my head what is >> causing that. It could just be >> again that the dialog is being shown before a field has been assigned >> a value, as it is with the >> securityDelegate. If it's simply an ordering issue like this then >> that isn't *too* concerning. If we >> truly just do not have a reference to any JNLPFile or PluginBridge >> for this applet then there's >> something seriously wrong. >> >>> >>> >>> Atatched is the nasty workarorund and here is snippet of log >>> >>> Securitymanager=net.sourceforge.jnlp.runtime.JNLPSecurityManager at 19f17b1 >>> >>> Registering priority for string reference 2 >>> Registering priority for reference 2 >>> Returning value:0 >>> Setting value:0 >>> Setting value:null >>> dummy string null, null, javax.swing.JButton[,0,0,0x0,inva...snip... >>> plugin_in_pipe_callback return >>> plugin_send_message_to_appletviewer return >>> PIPE: plugin wrote(?): plugin PluginProxyInfo reference 1 DIRECT >>> plugin_send_message_to_appletviewer >>> Proxy info: plugin PluginProxyInfo reference 1 DIRECT >>> >>> >>> >>> Without the workarround itw dies: >>> >>> ITNP_SetWindow return >>> ITNP_SetWindow: window already exists. >>> ITNP_SetWindow >>> at java.lang.Thread.run(Thread.java:745) >>> at >>> net.sourceforge.jnlp.security.SecurityDialogMessageHandler.run(SecurityDialogMessageHandler.java:81) >>> >>> >>> at >>> net.sourceforge.jnlp.security.SecurityDialogMessageHandler.handleMessage(SecurityDialogMessageHandler.java:102) >>> >>> >>> >>> at net.sourceforge.jnlp.security.SecurityDialog. >>> (SecurityDialog.java:129) >>> at >>> net.sourceforge.jnlp.security.SecurityDialog.initDialog(SecurityDialog.java:255) >>> >>> >>> at >>> net.sourceforge.jnlp.security.SecurityDialog.installPanel(SecurityDialog.java:307) >>> >>> >>> at net.sourceforge.jnlp.security.dialogs.CertWarningPane. >>> (CertWarningPane.java:116) >>> at >>> net.sourceforge.jnlp.security.dialogs.CertWarningPane.addComponents(CertWarningPane.java:124) >>> >>> >>> at >>> net.sourceforge.jnlp.security.dialogs.CertWarningPane.addButtons(CertWarningPane.java:242) >>> >>> >>> at >>> net.sourceforge.jnlp.security.dialogs.TemporaryPermissionsButton. >>> (TemporaryPermissionsButton.java:79) >>> at java.util.Objects.requireNonNull(Objects.java:201) >>> Exception in thread "NetxSecurityThread" java.lang.NullPointerException >>> plugin_in_pipe_callback return >>> plugin_send_message_to_appletviewer return >>> PIPE: plugin wrote(?): plugin PluginProxyInfo reference 1 DIRECT >>> plugin_send_message_to_appletviewer >>> Proxy info: plugin PluginProxyInfo reference 1 DIRECT >>> >>> >>> >>> I think the AssertNotNUll are really really invasive here. But at least >>> they cought probably more serious issue - to early call to the dialogue >>> with tmppermissions button.... >>> >>> >>> J. >> >> Yup. The PolicyEditor can't be sensibly launched if the jnlpFile is >> null (your nasty workaround >> really is nasty - assigning the new permissions to all applets rather >> than only ones on the current >> applet's codebase!), and the securityDelegate is needed if this >> button is to function at all. So >> there's no sensible thing to do if either of those fields come up >> null. Perhaps rather than outright >> failing to launch ITW we could have the button indicate a failure >> somehow and have the dialog simply >> not install the button, however. Just another option for Lukasz or >> whomever to look into. If this >> still hasn't been fixed by the time I come off PTO then I'll gladly >> take ownership of the bug. >> > > Andrew have made some investigations, and this is moreover conclusion > - its a bug - the tmp permissions dialogue is shared among javaws > and applets, and in applets lifecycle can happen this NPE > - however, the fix will take some time Eh, not necessarily :) see below. > > Even after it may be some cases, when this NPE will rise. We agreed > that disabling the button n this case is probably best solution. > > > The attache dpatch do so, > > Two nits : > - is really the SecurityDelegate suddenly useless? Yes - this NPE bug only occurs when the button is being installed by a CertWarningPane invoked by the VariableX509TrustManager. In other words, it only occurs when the dialog is asking the user whether they trust the certificate presented for the current HTTPS connection, not when the dialog is asking the user if they trust a certificate used to sign an applet. IMO it doesn't make sense to decide to apply sandboxing rules to an applet at this point, based on trusting the HTTPS certificate, although maybe that is something to explore. If we do want this to be an option then the VariableX509TrustManager will have to have some work done so it can carry the extra state of the JNLPFile and SecurityDelegate corresponding to the current applet/application as well. This would take some extra time, but if we don't want to add allowing sandboxing based on the HTTPS certificate trust, then your patch or mine are basically sufficient. > - Why all apps reproducing this issue suddenly started to work? ( I > mean without this patch) Do they? I haven't tried to verify this but that's surprising to me. The only validation currently done by the CertWarningPane is checking if the JNLPFile is null (which is a pretty fragile check - it's been changed to check the type of the CertVerifier instead), and if it is, then the button is not installed into the button panel. This decision is made well after the TemporaryPermissionsButton has been instantiated, which means that the Objects.requireNonNull checks have been performed. And the VariableX509TrustManager is still hard-coded to specifically provide "null" for the "file" and "securityDelegate" parameters... > > > Still I think it is good thing to get rid of assers and disable button. I think it's better to just not show the button (buttonS really, it's the Sandbox as well as Temporary Permissions) in this context, but it's an easy change to make either way. > > > J. > > Attached is my take on the patch. I also corrected the buttons on the dialog so that their labels and tooltips make more sense in the context of trusting an HTTPS certificate rather than an applet certificate. This looks a little messy with all the if statements added, but maybe it's not worth abstracting this class and making two subclasses just to change the labels on the buttons (and ignore two buttons from the button panel). Up to you. I can refactor it into two classes no problem but I know you expressed distaste for this approach on IRC ;) Thanks, -- Andrew A -------------- next part -------------- A non-text attachment was scrubbed... Name: temporarypermissionsbutton-npe-fix.patch Type: text/x-patch Size: 6120 bytes Desc: not available URL: From ptisnovs at icedtea.classpath.org Fri Sep 5 11:26:31 2014 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Fri, 05 Sep 2014 11:26:31 +0000 Subject: /hg/gfx-test: Ten new tests added into CAGOperationsOnChordAndRe... Message-ID: changeset 6cb398621693 in /hg/gfx-test details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=6cb398621693 author: Pavel Tisnovsky date: Fri Sep 05 13:27:38 2014 +0200 Ten new tests added into CAGOperationsOnChordAndRectangle. diffstat: ChangeLog | 5 + src/org/gfxtest/testsuites/CAGOperationsOnChordAndRectangle.java | 236 ++++++++++ 2 files changed, 241 insertions(+), 0 deletions(-) diffs (258 lines): diff -r 9f7b40fa8ca1 -r 6cb398621693 ChangeLog --- a/ChangeLog Thu Sep 04 10:23:42 2014 +0200 +++ b/ChangeLog Fri Sep 05 13:27:38 2014 +0200 @@ -1,3 +1,8 @@ +2014-09-05 Pavel Tisnovsky + + * src/org/gfxtest/testsuites/CAGOperationsOnChordAndRectangle.java: + Ten new tests added into CAGOperationsOnChordAndRectangle. + 2014-09-04 Pavel Tisnovsky * src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java: diff -r 9f7b40fa8ca1 -r 6cb398621693 src/org/gfxtest/testsuites/CAGOperationsOnChordAndRectangle.java --- a/src/org/gfxtest/testsuites/CAGOperationsOnChordAndRectangle.java Thu Sep 04 10:23:42 2014 +0200 +++ b/src/org/gfxtest/testsuites/CAGOperationsOnChordAndRectangle.java Fri Sep 05 13:27:38 2014 +0200 @@ -2250,6 +2250,242 @@ } /** + * Checks the process of creating and rendering new geometric shape + * constructed from chord and rectangle using inverse subtract operator. + * The shape is rendered using wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleInverseSubtractExtraWideStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set extra wide stroke width + CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingInverseSubtractOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from chord and rectangle using intersect operator. The shape + * is rendered using wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleIntersectExtraWideStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set extra wide stroke width + CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d); + // create area using intersect operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingIntersectOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from chord and rectangle using XOR operator. The shape is + * rendered using extra wide stroke. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleXorExtraWideStrokePaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set stroke extra width + CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d); + // create area using XOR operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingXorOperator(image); + // draw the area + graphics2d.draw(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from a chord inside a rectangle using union operator. The shape is + * rendered using color fill. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleUnionColorPaint(TestImage image, Graphics2D graphics2d) + { + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingUnionOperator(image); + // fill the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from a chord inside a rectangle using subtract operator. The shape is + * rendered using color fill. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleSubtractColorPaint(TestImage image, Graphics2D graphics2d) + { + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingSubtractOperator(image); + // fill the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from a chord inside a rectangle using inverse subtract operator. + * The shape is rendered using color fill. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleInverseSubtractColorPaint(TestImage image, Graphics2D graphics2d) + { + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingInverseSubtractOperator(image); + // fill the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from a chord inside a rectangle using intersect operator. + * The shape is rendered using color fill. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleIntersectColorPaint(TestImage image, Graphics2D graphics2d) + { + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using intersect operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingIntersectOperator(image); + // fill the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from a chord inside a rectangle using XOR operator. + * The shape is rendered using color fill. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleXorColorPaint(TestImage image, Graphics2D graphics2d) + { + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using Xor operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingXorOperator(image); + // fill the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from a chord inside a rectangle using union operator. The shape is + * rendered using radial gradient fill. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleUnionRadialGradientPaint(TestImage image, Graphics2D graphics2d) + { + // set radial gradient fill + CommonRenderingStyles.setRadialGradientFill(image, graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingUnionOperator(image); + // fill the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from a chord inside a rectangle using subtract operator. The shape is + * rendered using radial gradient fill. + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testOverlappingChordAndRectangleSubtractRadialGradientPaint(TestImage image, Graphics2D graphics2d) + { + // set radial gradient fill + CommonRenderingStyles.setRadialGradientFill(image, graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromOverlappingChordAndRectangleUsingSubtractOperator(image); + // fill the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** * Entry point to the test suite. * * @param args not used in this case From jvanek at redhat.com Fri Sep 5 12:45:12 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 05 Sep 2014 14:45:12 +0200 Subject: docs generator - prereview In-Reply-To: <2127323249.558740.1409856933886.JavaMail.zimbra@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> <2127323249.558740.1409856933886.JavaMail.zimbra@redhat.com> Message-ID: <5409B058.4040809@redhat.com> On 09/04/2014 08:55 PM, Jie Kang wrote: > ----- Original Message ----- >> >> Hi! >> >> >> Proudly :) presenting... documentation generator for ITW. >> >> Lukas Dracz already seen the preversion, because we shares one peace of code >> - >> OptionsDefinitions.java - also he was trying to impelmetn first versions >> of this. >> >> Now his patch is built on top of this. >> >> Well, it does a lot of things >> - generates man pages and html doc* and palintext docs** >> - unified files declarations >> - unified options declarations >> >> * html docs >> - are usleless in offlien mode (maybe we can publish them on classapth >> org after each release - >> but are used (generated in runtime) in help dialogue - which is really really >> nice. >> >> ** plain text docs - even les susefull then html docs, but are used in >> runtime commandlinehel/and >> about - which removed all the duplicated string providers. >> >> Various files and properties are sorted in javaws pages, have theyrs defaults >> and for sure none is >> missing. >> >> So finally no duplicated texts in various "about" and "help"! >> >> The patch is missing localization - I'm going to do so in some next >> changeset, and I hope to get >> rid of RepalcingFormater and its @@ substitution. >> >> >> >> As for review - anybody, please be specially careful about the files >> declaration. I hope I did it >> error-less and complete :( >> >> >> The design is >> >> 1docprovider - have 2formater is providing 3output >> >> eg: >> 1 - itw, itw-settings, javaws... >> 2 - html, plain, man >> 3 - man pages (generated during build, loclaized), runtime help - both >> console and "nice" html one. >> The runtime help have evaluated varibales and properties >> >> >> For runtime help I had to refactor about dialog a bit - only make some parts >> singletons and added >> an tab.... >> >> >> make check, install, dist and install form dist and unnstall works. >> >> >> >> J. > > > Hello, > > This patch is really large, is there any way you can split this into smaller iterations? For example, maybe have one patch that moves all paths and files into the PathsAndFiles.java, then one patch for the net.sourceforge.jnlp.docprovider addition, and then another patch for the makefile changes to use the docprovider. As well as a patch for refactoring the 'about dialog'. Or something along those lines; Right now no. I wonted at first, but the individual changes are so wired together that I failed to separate. (not that it is impossible, but that it is too costly) Also - considering nature of patch, - immediately visible result - no soemhow at least a bit important part affected I'm very inclined to push it as it is, and tune on flow. Except the design itself, the only part needing careful review is the part refactoring the files. > > One thing as well when you look at doing the localization part. Right now Translator just delegates to JNLPRuntime. > > e.g: > public static String R(String message, Object... params) { > return JNLPRuntime.getMessage(message, params); > } > > I think we should move the translating parts from JNLPRuntime into Translator. Thoughts? Maybe? But not inside this already big chngeset :) J. From aazores at redhat.com Fri Sep 5 17:16:43 2014 From: aazores at redhat.com (Andrew Azores) Date: Fri, 05 Sep 2014 13:16:43 -0400 Subject: [rfc][icedtea-web] javaws.1 man page update In-Reply-To: <53F8D650.5090702@redhat.com> References: <53F8D650.5090702@redhat.com> Message-ID: <5409EFFB.8030504@redhat.com> On 08/23/2014 01:58 PM, Andrew Azores wrote: > Hi, > > I looked at `man javaws` for some reason yesterday - no idea what I was > looking for or why - and thought it could do with some minor > improvement. I've fixed a few minor typos, improved the phrasing in a > few areas, and made it more consistent with capitalizing acronyms such > as XML, HTML, and JNLP. > > Thanks, Since the generated man pages feature is finally shaping up and looks like it might actually be done soon(ish), I suppose this patch is obsoleted? Thanks, -- Andrew Azores From jvanek at redhat.com Fri Sep 5 20:43:04 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 05 Sep 2014 22:43:04 +0200 Subject: [rfc][icedtea-web] javaws.1 man page update In-Reply-To: <5409EFFB.8030504@redhat.com> References: <53F8D650.5090702@redhat.com> <5409EFFB.8030504@redhat.com> Message-ID: <540A2058.2030304@redhat.com> On 09/05/2014 07:16 PM, Andrew Azores wrote: > On 08/23/2014 01:58 PM, Andrew Azores wrote: >> Hi, >> >> I looked at `man javaws` for some reason yesterday - no idea what I was >> looking for or why - and thought it could do with some minor >> improvement. I've fixed a few minor typos, improved the phrasing in a >> few areas, and made it more consistent with capitalizing acronyms such >> as XML, HTML, and JNLP. >> >> Thanks, > > Since the generated man pages feature is finally shaping up and looks like it might actually be done soon(ish), I suppose this patch is obsoleted? > > Thanks, > I hope so :) J. From jvanek at redhat.com Fri Sep 5 20:43:24 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 05 Sep 2014 22:43:24 +0200 Subject: [rfc][icedtea-web] javaws.1 man page update In-Reply-To: <5409EFFB.8030504@redhat.com> References: <53F8D650.5090702@redhat.com> <5409EFFB.8030504@redhat.com> Message-ID: <540A206C.9000805@redhat.com> On 09/05/2014 07:16 PM, Andrew Azores wrote: > On 08/23/2014 01:58 PM, Andrew Azores wrote: >> Hi, >> >> I looked at `man javaws` for some reason yesterday - no idea what I was >> looking for or why - and thought it could do with some minor >> improvement. I've fixed a few minor typos, improved the phrasing in a >> few areas, and made it more consistent with capitalizing acronyms such >> as XML, HTML, and JNLP. >> >> Thanks, > > Since the generated man pages feature is finally shaping up and looks like it might actually be done soon(ish), I suppose this patch is obsoleted? > > Thanks, > But.. Isnt it valid for 1.5? From gitne at gmx.de Fri Sep 5 23:38:18 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sat, 06 Sep 2014 01:38:18 +0200 Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> References: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> Message-ID: <540A496A.5050804@gmx.de> On 09/04/2014 at 05:31 PM, Jie Kang wrote: > Hello, > > This patch adds a logger dependency injection to TeeOutputStream so that the tests no longer require a protected function in order to run. > > Thoughts? I am not sure whether this approach makes the existing flaw better or worse. :-\ I am going to go with probably worse. Again, why cannot we use reflection here to get TeeOutputStream.byteArrayOutputStream and then monitor its flow during the test? Really, this is one reason why reflection has been introduced to Java. Jacob From gitne at gmx.de Fri Sep 5 23:47:13 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sat, 06 Sep 2014 01:47:13 +0200 Subject: [rfc][icedtea-web] javaws.1 man page update In-Reply-To: <5409EFFB.8030504@redhat.com> References: <53F8D650.5090702@redhat.com> <5409EFFB.8030504@redhat.com> Message-ID: <540A4B81.4090306@gmx.de> On 09/05/2014 at 07:16 PM, Andrew Azores wrote: > On 08/23/2014 01:58 PM, Andrew Azores wrote: >> Hi, >> >> I looked at `man javaws` for some reason yesterday - no idea what I was >> looking for or why - and thought it could do with some minor >> improvement. I've fixed a few minor typos, improved the phrasing in a >> few areas, and made it more consistent with capitalizing acronyms such >> as XML, HTML, and JNLP. >> >> Thanks, > > Since the generated man pages feature is finally shaping up and looks like it > might actually be done soon(ish), I suppose this patch is obsoleted? Not really. Actually, you should probably check the generated documentation output against the improvements you have made in your patch. AFAICT, most of the stuff in your patch is about punctuation and formatting. So, since you seem to have a keen eye on this you could check the generated documentation output. ;-) From gitne at gmx.de Sat Sep 6 00:07:44 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sat, 06 Sep 2014 02:07:44 +0200 Subject: docs generator - prereview In-Reply-To: <2127323249.558740.1409856933886.JavaMail.zimbra@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> <2127323249.558740.1409856933886.JavaMail.zimbra@redhat.com> Message-ID: <540A5050.2050706@gmx.de> W dniu 04.09.2014 20:55, Jie Kang pisze: > ----- Original Message ----- >> >> Hi! >> >> >> Proudly :) presenting... documentation generator for ITW. >> >> Lukas Dracz already seen the preversion, because we shares one peace of code >> - >> OptionsDefinitions.java - also he was trying to impelmetn first versions >> of this. >> >> Now his patch is built on top of this. >> >> Well, it does a lot of things >> - generates man pages and html doc* and palintext docs** >> - unified files declarations >> - unified options declarations >> >> * html docs >> - are usleless in offlien mode (maybe we can publish them on classapth >> org after each release - >> but are used (generated in runtime) in help dialogue - which is really really >> nice. >> >> ** plain text docs - even les susefull then html docs, but are used in >> runtime commandlinehel/and >> about - which removed all the duplicated string providers. >> >> Various files and properties are sorted in javaws pages, have theyrs defaults >> and for sure none is >> missing. >> >> So finally no duplicated texts in various "about" and "help"! >> >> The patch is missing localization - I'm going to do so in some next >> changeset, and I hope to get >> rid of RepalcingFormater and its @@ substitution. >> >> >> >> As for review - anybody, please be specially careful about the files >> declaration. I hope I did it >> error-less and complete :( >> >> >> The design is >> >> 1docprovider - have 2formater is providing 3output >> >> eg: >> 1 - itw, itw-settings, javaws... >> 2 - html, plain, man >> 3 - man pages (generated during build, loclaized), runtime help - both >> console and "nice" html one. >> The runtime help have evaluated varibales and properties >> >> >> For runtime help I had to refactor about dialog a bit - only make some parts >> singletons and added >> an tab.... >> >> >> make check, install, dist and install form dist and unnstall works. >> >> >> >> J. > > > Hello, > > This patch is really large, is there any way you can split this into smaller iterations? For example, maybe have one patch that moves all paths and files into the PathsAndFiles.java, then one patch for the net.sourceforge.jnlp.docprovider addition, and then another patch for the makefile changes to use the docprovider. As well as a patch for refactoring the 'about dialog'. Or something along those lines; Yeah, this patch is really big. Smaller logical chucks would be better. But, I admit it may become difficult or even impossible to split up due to its interdependent nature. > One thing as well when you look at doing the localization part. Right now Translator just delegates to JNLPRuntime. > > e.g: > public static String R(String message, Object... params) { > return JNLPRuntime.getMessage(message, params); > } > > I think we should move the translating parts from JNLPRuntime into Translator. Thoughts? Without taking a close look at this, I would say so too. From gitne at gmx.de Sat Sep 6 00:14:17 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sat, 06 Sep 2014 02:14:17 +0200 Subject: Fwd: docs generator - prereview In-Reply-To: <540882BB.5070100@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> Message-ID: <540A51D9.8070503@gmx.de> On 09/04/2014 at 05:18 PM, Jiri Vanek wrote: > > Hi! > > > Proudly :) presenting... documentation generator for ITW. > > Lukas Dracz already seen the preversion, because we shares one peace of code - > OptionsDefinitions.java - also he was trying to impelmetn first versions of > this. > > Now his patch is built on top of this. > > Well, it does a lot of things > - generates man pages and html doc* and palintext docs** > - unified files declarations > - unified options declarations > > * html docs > - are usleless in offlien mode (maybe we can publish them on classapth org > after each release - > but are used (generated in runtime) in help dialogue - which is really really nice. > > ** plain text docs - even les susefull then html docs, but are used in runtime > commandlinehel/and about - which removed all the duplicated string providers. > > Various files and properties are sorted in javaws pages, have theyrs defaults > and for sure none is > missing. > > So finally no duplicated texts in various "about" and "help"! > > The patch is missing localization - I'm going to do so in some next > changeset, and I hope to get > rid of RepalcingFormater and its @@ substitution. > > > > As for review - anybody, please be specially careful about the files > declaration. I hope I did it error-less and complete :( > > > The design is > > 1docprovider - have 2formater is providing 3output > > eg: > 1 - itw, itw-settings, javaws... > 2 - html, plain, man > 3 - man pages (generated during build, loclaized), runtime help - both console > and "nice" html one. > The runtime help have evaluated varibales and properties > > > For runtime help I had to refactor about dialog a bit - only make some parts > singletons and added > an tab.... > > > make check, install, dist and install form dist and unnstall works. This is a *lot* of text. :-o I am going to require some time to digest it, so please do not expect any qualitative comment on this patch from me any time soon. Anyway, I appreciate that you have finally come to embark on this problem. :-) Jacob From bugzilla-daemon at icedtea.classpath.org Sat Sep 6 09:06:13 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Sat, 06 Sep 2014 09:06:13 +0000 Subject: [Bug 1984] New: My eclipse interrupted acciently... Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1984 Bug ID: 1984 Summary: My eclipse interrupted acciently... Product: IcedTea Version: 6-1.13.4 Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: zhehua_xiao at 163.com CC: unassigned at icedtea.classpath.org Created attachment 1161 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1161&action=edit Automatically It occurs very time I run it. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From helpcrypto at gmail.com Mon Sep 8 06:59:50 2014 From: helpcrypto at gmail.com (helpcrypto helpcrypto) Date: Mon, 8 Sep 2014 08:59:50 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <540180DB.4050109@gmx.de> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> Message-ID: Hi - Add a semicolon for JAR compression level - I would set warning text to " " / "Available:xxx" when limit is disabled (hence, not hiding neither jumping, but not showing wrong/invalid information) Ok for me. On Thu, Sep 4, 2014 at 8:39 PM, Lukasz Dracz wrote: > Hello, > > Okay so this patch, uses disabling/enabling instead of hiding/showing. > Also put the "Java stores application ..." description to always be at the > top where as the rest of the components will be centered. > Also changed from powers of two to increments of 10 but not jumps of > 1,10,100,1000,10000 etc. but instead to > 0,1,2,3,...,7,8,9,10,20,30...80,90,100,200,300...800,900,1000,2000,3000 > etc. I think this way is best as it does not jump to the larger values too > quickly. > > As for my opinion, I think disabling is better than hiding, as it still > shows the user the possibilities in the panel even though they are not > active. I also liked the powers of two spinner much more personally but > from a user's point of view I agree that increments of 10 are more > intuitive and easier to understand. > > Thank you, > Lukasz Dracz -------------- next part -------------- An HTML attachment was scrubbed... URL: From helpcrypto at gmail.com Mon Sep 8 07:00:47 2014 From: helpcrypto at gmail.com (helpcrypto helpcrypto) Date: Mon, 8 Sep 2014 09:00:47 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <54071FE9.2000309@redhat.com> References: <53E3B68B.1090806@redhat.com> <53E3D58D.5030609@gmx.de> <53E48C38.30802@redhat.com> <53E8EB49.8000209@gmx.de> <20140818184605.GA2383@redhat.com> <53F3C0AD.5030400@gmx.de> <53F4E95B.30507@redhat.com> <53FC3461.5030401@redhat.com> <53FC3C79.5040208@gmx.de> <54071FE9.2000309@redhat.com> Message-ID: Hi Jiri. Should i apply/test this patch? Does it solve my TLS problems? Regards. On Wed, Sep 3, 2014 at 4:04 PM, Jiri Vanek wrote: > On 08/26/2014 09:51 AM, Jacob Wisor wrote: > >> On 08/26/2014 09:16 AM, Jiri Vanek wrote: >> >>> ping? >>> >>> On 08/20/2014 08:30 PM, Jiri Vanek wrote: >>> >>>> On 08/19/2014 11:25 PM, Jacob Wisor wrote: >>>> >>>>> On 08/18/2014 08:46 PM, Omair Majid wrote: >>>>> >>>>>> Hi, >>>>>> >>>>>> >>>>>> * Jacob Wisor [2014-08-11 12:12]: >>>>>> >>>>>>> On 08/08/2014 10:37 AM, Jiri Vanek wrote: >>>>>>> >>>>>>>> Unluckily this fix patch is not helping obscure servers to do >>>>>>>> exists. >>>>>>>> It really fixes bugs. >>>>>>>> >>>>>>>> First part of fix is delivered to be able handle SSLv2 handshake, >>>>>>>> Those >>>>>>>> servers >>>>>>>> do exists, and have no reason nor need to update or patch or >>>>>>>> whatever. We are >>>>>>>> wrong by not allowing it right now. >>>>>>>> See System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); >>>>>>>> in code. >>>>>>>> >>>>>>> >>>>>>> Oh yes they do need fixing. SSLv2 is insecure and has been revoked >>>>>>> by the >>>>>>> IETF, period. Nobody should be using it. Even SSL 3.0 is deemed by >>>>>>> the IETF >>>>>>> as historic (https://datatracker.ietf.org/doc/rfc6101) although it >>>>>>> is >>>>>>> largely identical to TLS 1.0. Nevertheless, nobody should be using it >>>>>>> either. Just one of many reasons is that it does not even support >>>>>>> such a >>>>>>> common hash algorithm as SHA1 (which by the way has been deprecated >>>>>>> by NIST >>>>>>> in favor of SHA256 too). Everybody should really upgrade to at least >>>>>>> TLS >>>>>>> 1.0, even though possible security leaks have been discovered in TLS >>>>>>> 1.0 on >>>>>>> specific configuration settings permutations. >>>>>>> >>>>>>> DO NOT use SSL anymore and DO NOT promote them in your software. >>>>>>> Upgrade to >>>>>>> TLS. >>>>>>> >>>>>> >>>>>> This isn't SSv2, though. It's a SSLv2 hello packet wrapping an SSLv3 >>>>>> packet: http://bugs.java.com/bugdatabase/view_bug.do?bug_id=4915862 >>>>>> >>>>>> It's actually part of the TLS 1.0 spec: >>>>>> https://www.ietf.org/rfc/rfc2246.txt, Appendix E. >>>>>> >>>>> >>>>> This part describes backward compatibility of TLS 1.0 clients to SSL >>>>> 3.0 and >>>>> SSL 2.0 servers (and >>>>> vice versa). >>>>> >>>>> "TLS 1.0 clients that support SSL Version 2.0 servers must send SSL >>>>> Version 2.0 client hello messages [SSL2]. TLS servers should accept >>>>> either client hello format if they wish to support SSL 2.0 clients >>>>> on >>>>> the same connection port. The only deviations from the Version 2.0 >>>>> specification are the ability to specify a version with a value of >>>>> three and the support for more ciphering types in the CipherSpec." >>>>> >>>>> Currently, IcedTea-Web is a TLS 1.0 or SSL 3.0 client. According to >>>>> this >>>>> paragraph, TLS 1.0 clients >>>>> send SSL 2.0 client hello messages in order to connect to SSL 2.0 >>>>> servers, >>>>> that is, to negotiate a >>>>> SSL 2.0 connection. So no, SSL 2.0 servers do not upgrade >>>>> automagically to >>>>> TLS 1.0 when they receive >>>>> SSL 2.0 client hello messages from TLS 1.0 clients. Pure old SSL 2.0 >>>>> servers >>>>> will never speak >>>>> anything later than SSL 2.0. >>>>> >>>>> One reason behind this paragraph was for TLS 1.0 clients to allow >>>>> probing SSL >>>>> 2.0 servers with >>>>> cipher specifications in SSL 2.0 and those introduced in TLS 1.0. In >>>>> practice, SSL 2.0 servers will >>>>> _never_ negotiate to a cipher specification introduced since TLS 1.0 >>>>> because >>>>> they were simply not >>>>> built for that. >>>>> >>>>> Another reason for this paragraph back in 1999 (!) was to allow >>>>> implementors >>>>> of TLS 1.0 to ease >>>>> transition from SSL to TLS and to give them the option to merge TLS >>>>> into >>>>> their existing SSL >>>>> libraries (or as much as possible build on top of them). Again, this >>>>> has >>>>> nothing to do with >>>>> automagically upgrading SSL 2.0 servers to TLS. It is just a >>>>> description of >>>>> how TLS 1.0 clients >>>>> could fallback to SSL 2.0, if they wish to. >>>>> And, I am most certain nobody should want this, unless one has no clue >>>>> what >>>>> transport security is >>>>> all about or is a complete lunatic. >>>>> >>>>> The next paragraph says it all: >>>>> >>>>> " Warning: The ability to send Version 2.0 client hello messages will >>>>> be >>>>> phased out with all due haste. Implementors should make >>>>> every >>>>> effort to move forward as quickly as possible. Version 3.0 >>>>> provides better mechanisms for moving to newer versions." >>>>> >>>>> So, the Java API should have got rid of the option to fallback to SSL >>>>> 2.0 >>>>> years before. It's a shame >>>>> that J2SE still supports SSL 2.0 connections in 2014. Why? Because >>>>> this has >>>>> nothing to do with >>>>> compatibility but with *security*. >>>>> >>>>> >>>> Ok. Thank you for patience with me. (really!) >>>> >>>> So there is another approach. >>>> >>>> Now the ssl2 is tested as last attempt, and if it is possible to >>>> connect like >>>> that, then the user is >>>> warned and error is thrown (which leads to skipping resource from that >>>> >>>> >>>> The not-checking certificate now can be allowed or forbidden by >>>> properties. By >>>> default it asks user >>>> by every such invalid certs its found. How to deal with human >>>> intraction is todo. >>>> >>>> >>>> The reason for this message is to get verbose logical error emsssage, >>>> not only >>>> "itw do not work again" >>>> >>>> >>>> What do you think now? >>>> >>>> J. >>>> >>> > >> > + DeploymentConfiguration.KEY_ >> HTTPS_PROBINGALOWED, >> > [...] >> > + public static final String KEY_HTTPS_PROBINGALOWED = >> > "deployment.security.https.probing.alowed"; >> > [...] >> > + public void disconect(URLConnection conn) { >> > [...] >> > + public synchronized void disconectHttps(HttpsURLConnection conn) >> { >> > [...] >> > + private final boolean unsecure; >> > + >> > + private HttpsSettings(boolean ssl2, boolean unsecure) { >> > [...] >> > + public static URLConnection openConnection(URL url, boolean >> ssl2, >> > boolean unsecure) throws IOException { >> >> I am not testing this unless you have fixed your typos. >> For god's sake, your are a programmer, right? You should know best that >> exact spelling is important. >> Obviously, I am just talking till I am blue in the face. >> > > Noooo. I moreover overlooked :( Sorry. > > Now it should be as good as I'm able to do so without third party > attendance. > >> >> Also, please replace all occurrences of "ssl2" in text strings with >> "SSL2" (or "SSL 2.0" as used in >> the specification). Acronyms of names are always upper case in English. >> >> > ok! > >> >> > > Here is updated version. > > > Sorry for delay, I was hacking the documentation generator. Now its one > (discussing with Lukas concurrently edited code), ad I think you will like > it :) > > > J. > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From volker.simonis at gmail.com Mon Sep 8 09:32:37 2014 From: volker.simonis at gmail.com (Volker Simonis) Date: Mon, 8 Sep 2014 11:32:37 +0200 Subject: Template interpreter status in JDK7/IcedTea 2.5.2 for PPC64/PPC64LE Message-ID: Hi Tiago, we already have the template interpreter in our http://hg.openjdk.java.net/ppc-aix-port/jdk7u/hotspot repository (even for ppc64le :) since quite some time (~March 2014). See: 8050942: PPC64: implement template interpreter for ppc64le http://hg.openjdk.java.net/ppc-aix-port/jdk7u/hotspot/rev/1176e8ff9f90 New files for template interpreter Missed from 8036976: PPC64: implement the template interpreter http://hg.openjdk.java.net/ppc-aix-port/jdk7u/hotspot/rev/6f0b8f13db4d 8036976: PPC64: implement the template interpreter http://hg.openjdk.java.net/ppc-aix-port/jdk7u/hotspot/rev/7b62421e491e Without additional parameters the template interpreter is being build as the default interpreter on ppc64 - at least if you build right from our PPC-AIX-Port repository (see for example http://cr.openjdk.java.net/~simonis/ppc-aix-port/logs/linuxppc64/nightly/output-jdk7u-fastdebug.log.gz for recent build logs). Maybe the IcedTea build still sets "CC_INTERP=true" when building on linux/ppc64? This isn't required any more and should be removed as we don't actively support the cpp interpreter any more. Regarding the question on how to detect the template interpreter - I don't know a perfect answer either. But you could for example use "-XX:+UnlockDiagnosticVMOptions -XX:+PrintInterpreter". If you're running with the template interpreter, the output will be much longer and print the code templates for each bytecode (if you have the hsdis-ppc64.so library in the library path it will even print the disassembly of each bytecode tempalate). Regards, Volker On Sat, Sep 6, 2014 at 7:29 AM, Tiago St?rmer Daitx wrote: > All- > > What's the status of the template interpreter for JDK7 in the > ppc-aix-port? > > I can see that JDK 9 does build with the Template Interpreter for both > PPC64 and PPC64LE, but JDK7 seems to be still using the C++ Interpreter > on both archs - at least when build from IcedTea 2.5.2, which supposedly > merged the head from PPC-AIX-Port repo (I haven't build JDK 7 directly > from the PPC-AIX-Port repo to compare the results... yet). > > What am I missing? How should/can I be sure to enable the template > interpreter in a JDK7 build? > > I used > > $ nm -C libjvm.so | grep TemplateTable::initialize > $ nm -C libjvm.so | grep CppInterpreter::initialize > > to identify which interpreter was build (stolen from [1]), let me know > if there an easier way to do that. > > Regards, > Tiago > > [1] > http://mail.openjdk.java.net/pipermail/hotspot-dev/2013-October/011431.html > > > -- > Tiago St?rmer Daitx > Linux Technology Center [LTC|IBM] > tdaitx at br.ibm.com > From jvanek at redhat.com Mon Sep 8 09:44:00 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 08 Sep 2014 11:44:00 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: References: <53E3B68B.1090806@redhat.com> <53E3D58D.5030609@gmx.de> <53E48C38.30802@redhat.com> <53E8EB49.8000209@gmx.de> <20140818184605.GA2383@redhat.com> <53F3C0AD.5030400@gmx.de> <53F4E95B.30507@redhat.com> <53FC3461.5030401@redhat.com> <53FC3C79.5040208@gmx.de> <54071FE9.2000309@redhat.com> Message-ID: <540D7A60.9080904@redhat.com> On 09/08/2014 09:00 AM, helpcrypto helpcrypto wrote: > Hi Jiri. > Should i apply/test this patch? > Does it solve my TLS problems? Nope. :( Although thjis patch is base ston for all simialr issues, now is handling only two cases. Your's one will have to be solved, and later added as probe case. J. > > Regards. > > On Wed, Sep 3, 2014 at 4:04 PM, Jiri Vanek > wrote: > > On 08/26/2014 09:51 AM, Jacob Wisor wrote: > > On 08/26/2014 09:16 AM, Jiri Vanek wrote: > > ping? > > On 08/20/2014 08:30 PM, Jiri Vanek wrote: > > On 08/19/2014 11:25 PM, Jacob Wisor wrote: > > On 08/18/2014 08:46 PM, Omair Majid wrote: > > Hi, > > > * Jacob Wisor > [2014-08-11 12:12]: > > On 08/08/2014 10:37 AM, Jiri Vanek wrote: > > Unluckily this fix patch is not helping obscure servers to do exists. > It really fixes bugs. > > First part of fix is delivered to be able handle SSLv2 handshake, Those > servers > do exists, and have no reason nor need to update or patch or > whatever. We are > wrong by not allowing it right now. > See System.setProperty("https.__protocols", "SSLv3,SSLv2Hello"); > in code. > > > Oh yes they do need fixing. SSLv2 is insecure and has been revoked by the > IETF, period. Nobody should be using it. Even SSL 3.0 is deemed by the IETF > as historic (https://datatracker.ietf.org/__doc/rfc6101 > ) although it is > largely identical to TLS 1.0. Nevertheless, nobody should be using it > either. Just one of many reasons is that it does not even support such a > common hash algorithm as SHA1 (which by the way has been deprecated by NIST > in favor of SHA256 too). Everybody should really upgrade to at least TLS > 1.0, even though possible security leaks have been discovered in TLS 1.0 on > specific configuration settings permutations. > > DO NOT use SSL anymore and DO NOT promote them in your software. Upgrade to > TLS. > > > This isn't SSv2, though. It's a SSLv2 hello packet wrapping an SSLv3 > packet: http://bugs.java.com/__bugdatabase/view_bug.do?bug___id=4915862 > > > It's actually part of the TLS 1.0 spec: > https://www.ietf.org/rfc/__rfc2246.txt > , Appendix E. > > > This part describes backward compatibility of TLS 1.0 clients to SSL 3.0 and > SSL 2.0 servers (and > vice versa). > > "TLS 1.0 clients that support SSL Version 2.0 servers must send SSL > Version 2.0 client hello messages [SSL2]. TLS servers should accept > either client hello format if they wish to support SSL 2.0 clients on > the same connection port. The only deviations from the Version 2.0 > specification are the ability to specify a version with a value of > three and the support for more ciphering types in the CipherSpec." > > Currently, IcedTea-Web is a TLS 1.0 or SSL 3.0 client. According to this > paragraph, TLS 1.0 clients > send SSL 2.0 client hello messages in order to connect to SSL 2.0 servers, > that is, to negotiate a > SSL 2.0 connection. So no, SSL 2.0 servers do not upgrade automagically to > TLS 1.0 when they receive > SSL 2.0 client hello messages from TLS 1.0 clients. Pure old SSL 2.0 servers > will never speak > anything later than SSL 2.0. > > One reason behind this paragraph was for TLS 1.0 clients to allow probing SSL > 2.0 servers with > cipher specifications in SSL 2.0 and those introduced in TLS 1.0. In > practice, SSL 2.0 servers will > _never_ negotiate to a cipher specification introduced since TLS 1.0 because > they were simply not > built for that. > > Another reason for this paragraph back in 1999 (!) was to allow implementors > of TLS 1.0 to ease > transition from SSL to TLS and to give them the option to merge TLS into > their existing SSL > libraries (or as much as possible build on top of them). Again, this has > nothing to do with > automagically upgrading SSL 2.0 servers to TLS. It is just a description of > how TLS 1.0 clients > could fallback to SSL 2.0, if they wish to. > And, I am most certain nobody should want this, unless one has no clue what > transport security is > all about or is a complete lunatic. > > The next paragraph says it all: > > " Warning: The ability to send Version 2.0 client hello messages will be > phased out with all due haste. Implementors should make every > effort to move forward as quickly as possible. Version 3.0 > provides better mechanisms for moving to newer versions." > > So, the Java API should have got rid of the option to fallback to SSL 2.0 > years before. It's a shame > that J2SE still supports SSL 2.0 connections in 2014. Why? Because this has > nothing to do with > compatibility but with *security*. > > > Ok. Thank you for patience with me. (really!) > > So there is another approach. > > Now the ssl2 is tested as last attempt, and if it is possible to connect like > that, then the user is > warned and error is thrown (which leads to skipping resource from that > > > The not-checking certificate now can be allowed or forbidden by properties. By > default it asks user > by every such invalid certs its found. How to deal with human intraction is todo. > > > The reason for this message is to get verbose logical error emsssage, not only > "itw do not work again" > > > What do you think now? > > J. > > > > > + DeploymentConfiguration.KEY___HTTPS_PROBINGALOWED, > > [...] > > + public static final String KEY_HTTPS_PROBINGALOWED = > > "deployment.security.https.__probing.alowed"; > > [...] > > + public void disconect(URLConnection conn) { > > [...] > > + public synchronized void disconectHttps(__HttpsURLConnection conn) { > > [...] > > + private final boolean unsecure; > > + > > + private HttpsSettings(boolean ssl2, boolean unsecure) { > > [...] > > + public static URLConnection openConnection(URL url, boolean ssl2, > > boolean unsecure) throws IOException { > > I am not testing this unless you have fixed your typos. > For god's sake, your are a programmer, right? You should know best that exact spelling is > important. > Obviously, I am just talking till I am blue in the face. > > > Noooo. I moreover overlooked :( Sorry. > > Now it should be as good as I'm able to do so without third party attendance. > > > Also, please replace all occurrences of "ssl2" in text strings with "SSL2" (or "SSL 2.0" as > used in > the specification). Acronyms of names are always upper case in English. > > > ok! > > > > > Here is updated version. > > > Sorry for delay, I was hacking the documentation generator. Now its one (discussing with Lukas > concurrently edited code), ad I think you will like it :) > > > J. > > > From ptisnovs at icedtea.classpath.org Mon Sep 8 09:45:07 2014 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Mon, 08 Sep 2014 09:45:07 +0000 Subject: /hg/gfx-test: Nine tests added into BitBltBufferedImageOp. Message-ID: changeset e18a753d1d48 in /hg/gfx-test details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=e18a753d1d48 author: Pavel Tisnovsky date: Mon Sep 08 11:46:21 2014 +0200 Nine tests added into BitBltBufferedImageOp. diffstat: ChangeLog | 5 + src/org/gfxtest/testsuites/BitBltBufferedImageOp.java | 151 ++++++++++++++++++ 2 files changed, 156 insertions(+), 0 deletions(-) diffs (173 lines): diff -r 6cb398621693 -r e18a753d1d48 ChangeLog --- a/ChangeLog Fri Sep 05 13:27:38 2014 +0200 +++ b/ChangeLog Mon Sep 08 11:46:21 2014 +0200 @@ -1,3 +1,8 @@ +2014-09-08 Pavel Tisnovsky + + * src/org/gfxtest/testsuites/BitBltBufferedImageOp.java: + Nine tests added into BitBltBufferedImageOp. + 2014-09-05 Pavel Tisnovsky * src/org/gfxtest/testsuites/CAGOperationsOnChordAndRectangle.java: diff -r 6cb398621693 -r e18a753d1d48 src/org/gfxtest/testsuites/BitBltBufferedImageOp.java --- a/src/org/gfxtest/testsuites/BitBltBufferedImageOp.java Fri Sep 05 13:27:38 2014 +0200 +++ b/src/org/gfxtest/testsuites/BitBltBufferedImageOp.java Mon Sep 08 11:46:21 2014 +0200 @@ -3628,6 +3628,157 @@ } /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_USHORT_555_RGB}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeUshort555RGB(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_USHORT_555_RGB, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_USHORT_565_RGB}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeUshort565RGB(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_USHORT_565_RGB, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_USHORT_GRAY}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltHorizontalRedGradientTypeUshortGray(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithHorizontalRedGradientImage(image, graphics2d, BufferedImage.TYPE_USHORT_GRAY, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_3BYTE_BGR}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltVerticalRedGradientType3ByteBGR(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithVerticalRedGradientImage(image, graphics2d, BufferedImage.TYPE_3BYTE_BGR, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_4BYTE_ABGR}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltVerticalRedGradientType4ByteABGR(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithVerticalRedGradientImage(image, graphics2d, BufferedImage.TYPE_4BYTE_ABGR, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_4BYTE_ABGR_PRE}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltVerticalRedGradientType4ByteABGR_Pre(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithVerticalRedGradientImage(image, graphics2d, BufferedImage.TYPE_4BYTE_ABGR_PRE, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_BYTE_BINARY}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltVerticalRedGradientTypeByteBinary(TestImage image, Graphics2D graphics2d, + BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithVerticalRedGradientImage(image, graphics2d, BufferedImage.TYPE_BYTE_BINARY, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_BYTE_INDEXED}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltVerticalRedGradientTypeByteIndexed(TestImage image, Graphics2D graphics2d, BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithVerticalRedGradientImage(image, graphics2d, BufferedImage.TYPE_BYTE_INDEXED, rasterOp); + } + + /** + * Test basic BitBlt operation for buffered image with type {@link BufferedImage#TYPE_BYTE_GRAY}. + * + * @param image + * image used as a destination for BitBlt-type operations + * @param graphics2d + * graphics canvas + * @param rasterOp + * selected raster operation + * @return test result status - PASSED, FAILED or ERROR + */ + protected TestResult doBitBltVerticalRedGradientTypeByteGray(TestImage image, Graphics2D graphics2d, BufferedImageOp rasterOp) + { + return CommonBitmapOperations.doBitBltTestWithVerticalRedGradientImage(image, graphics2d, BufferedImage.TYPE_BYTE_GRAY, rasterOp); + } + + /** * Entry point to the test suite. * * @param args not used in this case From jvanek at redhat.com Mon Sep 8 09:47:20 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 08 Sep 2014 11:47:20 +0200 Subject: Fwd: docs generator - prereview In-Reply-To: <540A51D9.8070503@gmx.de> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> <540A51D9.8070503@gmx.de> Message-ID: <540D7B28.1020706@redhat.com> >> >> >> make check, install, dist and install form dist and unnstall works. > > This is a *lot* of text. :-o I am going to require some time to digest it, so please do not expect > any qualitative comment on this patch from me any time soon. Anyway, I appreciate that you have > finally come to embark on this problem. :-) Well, All the texts in this patch will go into properties as separate change sets. Then Perhaps then it will be good time to purify those? (both in language, and in typography (eg the - and \- in man pages.) The possibilities to handle those are implemented in this patch. J. From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 10:25:13 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 10:25:13 +0000 Subject: [Bug 1986] New: Eclipse just crashed Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1986 Bug ID: 1986 Summary: Eclipse just crashed Product: IcedTea Version: unspecified Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: paul.manners at gmail.com CC: unassigned at icedtea.classpath.org Created attachment 1163 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1163&action=edit Crash log I think all the details are contained in the error log file. If they aren't please let me know. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 10:26:30 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 10:26:30 +0000 Subject: [Bug 1986] Eclipse just crashed In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1986 --- Comment #1 from Paul --- # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007fa556626af6, pid=5199, tid=140348639536896 # # JRE version: OpenJDK Runtime Environment (7.0_55-b14) (build 1.7.0_55-b14) # Java VM: OpenJDK 64-Bit Server VM (24.51-b03 mixed mode linux-amd64 compressed oops) # Problematic frame: # C [libgdk-3.so.0+0x32af6] gdk_window_get_support_multidevice+0x16 # # Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again # -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 11:21:06 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 11:21:06 +0000 Subject: [Bug 1894] JRE running Tomcat crashes with SIGSEGV In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1894 --- Comment #4 from Christian Schr?der --- Created attachment 1164 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1164&action=edit Stack trace with default GC configuration Any news on this issue? Meanwhile, we have changed the JVM arguments and removed the GC tuning parameters so the default GC configuration would be used. It first seemed to have solved the problem since no further segmentation violations occurred; however, the problem now occurred again. I have attached a recent stack trace. Can we do anything to help you track down this bug? Or should we report it elsewhere (e.g. Tomcat bugzilla)? Kind regards, Christian -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 11:53:13 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 11:53:13 +0000 Subject: [Bug 1987] New: JVM crashes V [libjvm.so+0x71c359] Parse::array_addressing(BasicType, int, Type const**) Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1987 Bug ID: 1987 Summary: JVM crashes V [libjvm.so+0x71c359] Parse::array_addressing(BasicType, int, Type const**) Product: IcedTea Version: unspecified Hardware: 64-bit OS: Linux Status: NEW Severity: critical Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: nickjkings+bz at gmail.com CC: unassigned at icedtea.classpath.org Created attachment 1165 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1165&action=edit stack dump produced by OpenSearch Server Whilst running OpenSearch Server the JVM crashes (with the enclosed error report) Software installed, as per http://www.opensearchserver.com/documentation/installation/linux.html Java version: opensearch at li674-145:~/opensearchserver$ java -version java version "1.6.0_32" OpenJDK Runtime Environment (IcedTea6 1.13.4) (6b32-1.13.4-1~deb7u1) OpenJDK 64-Bit Server VM (build 23.25-b01, mixed mode) opensearch at li674-145:~/opensearchserver$ uname -a Linux li674-145 3.15.4-x86_64-linode45 #1 SMP Mon Jul 7 08:42:36 EDT 2014 x86_64 GNU/Linux -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 12:05:10 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 12:05:10 +0000 Subject: [Bug 1987] JVM crashes V [libjvm.so+0x71c359] Parse::array_addressing(BasicType, int, Type const**) In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1987 --- Comment #1 from nickjkings+bz at gmail.com --- Created attachment 1166 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1166&action=edit Additional error log -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 12:11:19 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 12:11:19 +0000 Subject: [Bug 1987] JVM crashes V [libjvm.so+0x71c359] Parse::array_addressing(BasicType, int, Type const**) In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1987 --- Comment #2 from nickjkings+bz at gmail.com --- I have set the OpenSearch Server script to produce a core dump, but the gzipped core file is over 80Mbytes, so cannot be directly included I have placed the core file on a webserver at http://opensearch.res.cm-hosting.com/core.gz -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 15:23:33 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 15:23:33 +0000 Subject: [Bug 1896] vm crashes on IMAGEIO.read multithreaded / liblcms2-2 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1896 claudio changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |claudio.a.delgado at gmail.com --- Comment #4 from claudio --- Using: Linux 3.11.0-12-generic #19-Ubuntu SMP Wed Oct 9 16:20:46 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux # # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007fc008813965, pid=1482, tid=140462821066496 # # JRE version: 7.0_25-b30 # Java VM: OpenJDK 64-Bit Server VM (23.7-b01 mixed mode linux-amd64 compressed oops) # Problematic frame: # C [liblcms2.so.2+0x15965] cmsSaveProfileToIOhandler+0x25 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ldracz at redhat.com Mon Sep 8 15:24:11 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Mon, 8 Sep 2014 11:24:11 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> Message-ID: <662236471.1776114.1410189851576.JavaMail.zimbra@redhat.com> Hello, > Hi > > - Add a semicolon for JAR compression level I assumed you meant colon(:) like the other labels have, if it really is to be a semicolon(;) I can change it. > - I would set warning text to " " / "Available:xxx" when limit is disabled > (hence, not hiding neither jumping, but not showing wrong/invalid > information) Okay, I made it "Available: xxx" > Ok for me. Good to push? Thanks, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: cacheSizeSpinner-19.patch Type: text/x-patch Size: 23110 bytes Desc: not available URL: From gnu.andrew at redhat.com Mon Sep 8 16:00:05 2014 From: gnu.andrew at redhat.com (Andrew Hughes) Date: Mon, 8 Sep 2014 12:00:05 -0400 (EDT) Subject: Template interpreter status in JDK7/IcedTea 2.5.2 for PPC64/PPC64LE In-Reply-To: References: Message-ID: <867767601.19633722.1410192005519.JavaMail.zimbra@redhat.com> ----- Original Message ----- > Hi Tiago, > > we already have the template interpreter in our > http://hg.openjdk.java.net/ppc-aix-port/jdk7u/hotspot repository (even > for ppc64le :) since quite some time (~March 2014). See: > > 8050942: PPC64: implement template interpreter for ppc64le > http://hg.openjdk.java.net/ppc-aix-port/jdk7u/hotspot/rev/1176e8ff9f90 > > New files for template interpreter Missed from 8036976: PPC64: > implement the template interpreter > http://hg.openjdk.java.net/ppc-aix-port/jdk7u/hotspot/rev/6f0b8f13db4d > > 8036976: PPC64: implement the template interpreter > http://hg.openjdk.java.net/ppc-aix-port/jdk7u/hotspot/rev/7b62421e491e > > Without additional parameters the template interpreter is being build > as the default interpreter on ppc64 - at least if you build right from > our PPC-AIX-Port repository (see for example > http://cr.openjdk.java.net/~simonis/ppc-aix-port/logs/linuxppc64/nightly/output-jdk7u-fastdebug.log.gz > for recent build logs). Maybe the IcedTea build still sets > "CC_INTERP=true" when building on linux/ppc64? This isn't required any > more and should be removed as we don't actively support the cpp > interpreter any more. It does. README-ppc.html still says it should. I never understood why it wasn't just set by the makefiles anyway, then you could have taken it out again when it was no longer needed. Instead, we end up with dated build instructions like this :( To be specific, IcedTea has: ifeq ($(ARCH), ppc64) CC_INTERP=true endif and I'll now remove this for 2.5.3. > > Regarding the question on how to detect the template interpreter - I > don't know a perfect answer either. But you could for example use > "-XX:+UnlockDiagnosticVMOptions -XX:+PrintInterpreter". If you're > running with the template interpreter, the output will be much longer > and print the code templates for each bytecode (if you have the > hsdis-ppc64.so library in the library path it will even print the > disassembly of each bytecode tempalate). > > Regards, > Volker > > On Sat, Sep 6, 2014 at 7:29 AM, Tiago St?rmer Daitx > wrote: > > All- > > > > What's the status of the template interpreter for JDK7 in the > > ppc-aix-port? > > > > I can see that JDK 9 does build with the Template Interpreter for both > > PPC64 and PPC64LE, but JDK7 seems to be still using the C++ Interpreter > > on both archs - at least when build from IcedTea 2.5.2, which supposedly > > merged the head from PPC-AIX-Port repo (I haven't build JDK 7 directly > > from the PPC-AIX-Port repo to compare the results... yet). > > > > What am I missing? How should/can I be sure to enable the template > > interpreter in a JDK7 build? > > > > I used > > > > $ nm -C libjvm.so | grep TemplateTable::initialize > > $ nm -C libjvm.so | grep CppInterpreter::initialize > > > > to identify which interpreter was build (stolen from [1]), let me know > > if there an easier way to do that. > > > > Regards, > > Tiago > > > > [1] > > http://mail.openjdk.java.net/pipermail/hotspot-dev/2013-October/011431.html > > > > > > -- > > Tiago St?rmer Daitx > > Linux Technology Center [LTC|IBM] > > tdaitx at br.ibm.com > > > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) PGP Key: 248BDC07 (https://keys.indymedia.org/) Fingerprint = EC5A 1F5E C0AD 1D15 8F1F 8F91 3B96 A578 248B DC07 From aazores at redhat.com Mon Sep 8 16:26:01 2014 From: aazores at redhat.com (Andrew Azores) Date: Mon, 8 Sep 2014 12:26:01 -0400 (EDT) Subject: docs generator - prereview In-Reply-To: <540882BB.5070100@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> Message-ID: <1043198503.19642577.1410193561218.JavaMail.zimbra@redhat.com> Hi, This is a huge patch and I can't say I've thoroughly and fully reviewed it, but I have at least read through it and tried to understand what's going on. Generally, I think it's okay. Even if not, this patch is so huge that making further improvements on top of this diff is going to be just incredibly unwieldy. Perhaps, if you feel that it's "good enough" as it is, it can be pushed and further refined with subsequent changesets at this point. I honestly did not take any time whatsoever to really review the "files declaration" part, assuming you mean the new PathsAndFiles class. A quick glance looks okay but that's all I can say about it. Few very minor nits which can very well be addressed in subsequent changesets: - Typos! "PolicyEditorTextxsProvider" for example, or OptionsDefinitions.getPoliciEditorOptions, or TextsProvider.ITW_BUGZILAHOME - OptionsDefinitions should probably have (private) data structures to group the various options by who they belong to (eg PolicyEditor vs javaws) and by if they are documented or not, etc. Then the various methods can simply be defined as various operations on these structures. Also extremely minor but I think Set might be a better ADT than List for these structures and the methods used for essentially querying them, so perhaps this can all be implemented nicely with EnumSet. - Does the configure --disable-docs flag do anything to this generation step? Should it? Thanks. ----- Original Message ----- > > Hi! > > > Proudly :) presenting... documentation generator for ITW. > > Lukas Dracz already seen the preversion, because we shares one peace of code > - > OptionsDefinitions.java - also he was trying to impelmetn first versions > of this. > > Now his patch is built on top of this. > > Well, it does a lot of things > - generates man pages and html doc* and palintext docs** > - unified files declarations > - unified options declarations > > * html docs > - are usleless in offlien mode (maybe we can publish them on classapth > org after each release - > but are used (generated in runtime) in help dialogue - which is really really > nice. > > ** plain text docs - even les susefull then html docs, but are used in > runtime commandlinehel/and > about - which removed all the duplicated string providers. > > Various files and properties are sorted in javaws pages, have theyrs defaults > and for sure none is > missing. > > So finally no duplicated texts in various "about" and "help"! > > The patch is missing localization - I'm going to do so in some next > changeset, and I hope to get > rid of RepalcingFormater and its @@ substitution. > > > > As for review - anybody, please be specially careful about the files > declaration. I hope I did it > error-less and complete :( > > > The design is > > 1docprovider - have 2formater is providing 3output > > eg: > 1 - itw, itw-settings, javaws... > 2 - html, plain, man > 3 - man pages (generated during build, loclaized), runtime help - both > console and "nice" html one. > The runtime help have evaluated varibales and properties > > > For runtime help I had to refactor about dialog a bit - only make some parts > singletons and added > an tab.... > > > make check, install, dist and install form dist and unnstall works. > > > > J. > > > > > > From omajid at redhat.com Mon Sep 8 16:37:52 2014 From: omajid at redhat.com (Omair Majid) Date: Mon, 8 Sep 2014 12:37:52 -0400 Subject: Fwd: docs generator - prereview In-Reply-To: <540882BB.5070100@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> Message-ID: <20140908163752.GA3236@redhat.com> * Jiri Vanek [2014-09-04 11:20]: > +public class PathsAndFiles { > + public static final String USER_CONFIG_HOME; > + public static final String USER_CACHE_HOME; > + public static final String USER_SECURITY; > + public static final String ICEDTEA_SO = "IcedTeaPlugin.so"; > + public static final InfrastructureFileDescriptor PIPES_DIR > + public static final InfrastructureFileDescriptor MOZILA_USER > + public static final InfrastructureFileDescriptor MOZILA_GLOBAL_64 > + public static final InfrastructureFileDescriptor MOZILA_GLOBAL_32 > + public static final InfrastructureFileDescriptor OPERA_64 > + public static final InfrastructureFileDescriptor OPERA_32 > + > + public static final InfrastructureFileDescriptor CACHE_DIR > + public static final InfrastructureFileDescriptor PCACHE_DIR > + public static final InfrastructureFileDescriptor LOG_DIR > + public static final InfrastructureFileDescriptor APPLET_TRUST_SETTINGS_USER > + public static final InfrastructureFileDescriptor APPLET_TRUST_SETTINGS_SYS > + public static final InfrastructureFileDescriptor ETC_DEPLOYMENT_CFG > + public static final InfrastructureFileDescriptor TMP_DIR > + > + public static final InfrastructureFileDescriptor LOCKS_DIR > + public static final InfrastructureFileDescriptor MAIN_LOCK > + > + public static final InfrastructureFileDescriptor JAVA_POLICY > + public static final InfrastructureFileDescriptor USER_CACERTS > + public static final InfrastructureFileDescriptor USER_JSSECAC > + public static final InfrastructureFileDescriptor USER_CERTS > + public static final InfrastructureFileDescriptor USER_JSSECER > + public static final InfrastructureFileDescriptor USER_CLIENTCERT > + > + public static final InfrastructureFileDescriptor SYS_CACERT > + public static final InfrastructureFileDescriptor SYS_JSSECAC > + public static final InfrastructureFileDescriptor SYS_CERT > + public static final InfrastructureFileDescriptor SYS_JSSECERT > + public static final InfrastructureFileDescriptor SYS_CLIENTCERT > + > + public static final InfrastructureFileDescriptor JAVA_DEPLOYMENT_PROP_FILE > + public static final InfrastructureFileDescriptor USER_DEPLOYMENT_FILE These are public fields in a public class. Can applets look at these variables and identify restricted user information (such as username)? We had similar security issues in the past: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=2010-3860 Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From jvanek at redhat.com Mon Sep 8 16:41:22 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 08 Sep 2014 18:41:22 +0200 Subject: docs generator - prereview In-Reply-To: <1043198503.19642577.1410193561218.JavaMail.zimbra@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> <1043198503.19642577.1410193561218.JavaMail.zimbra@redhat.com> Message-ID: <540DDC32.5040909@redhat.com> On 09/08/2014 06:26 PM, Andrew Azores wrote: > Hi, > > This is a huge patch and I can't say I've thoroughly and fully reviewed it, but I have at least read through it and tried to understand what's going on. Generally, I think it's okay. Even if not, this patch is so huge that making further improvements on top of this diff is going to be just incredibly unwieldy. Perhaps, if you feel that it's "good enough" as it is, it can be pushed and further refined with subsequent changesets at this point. I honestly did not take any time whatsoever to really review the "files declaration" part, assuming you mean the new PathsAndFiles class. A quick glance looks okay but that's all I can say about it. Ty very much for brave step! > Few very minor nits which can very well be addressed in subsequent changesets: > - Typos! "PolicyEditorTextxsProvider" for example, or OptionsDefinitions.getPoliciEditorOptions, or TextsProvider.ITW_BUGZILAHOME Ough. I will fix those, and seek for other before push (tomorrow morning CET) > - OptionsDefinitions should probably have (private) data structures to group the various options by who they belong to (eg PolicyEditor vs javaws) and by if they are documented or not, etc. Then the various methods can simply be defined as various operations on these structures. Also extremely minor but I think Set might be a better ADT than List for these structures and the methods used for essentially querying them, so perhaps this can all be implemented nicely with EnumSet. This suggestion is same approach I used in FilesDefinitions. I was thinking abut using it After considering the differences between option and file declaration, I decided intentionally to go by the way by which it is done now. If nothing else, It is much more simple :) Also the risk of not being added to any list is minimal - it can happen, But if not added to the list, then OptionsParser will not be able to parse it, so it will not happen. So I would rather stay with this one. Teh public api of this class is very simple - get{javaws,javaws-docummented,,policieditor,itweb-settings}options... > - Does the configure --disable-docs flag do anything to this generation step? Should it? Nope. The reason is make . The man pages are part of it. I know javadoc to, but I'm seeing them as different things. Also the time consumption is really low comapred to javadoc. But I'm leaving this to open discussion. We can make it dependent on --disable-docs, or have different switch for it. Anyway it can be done as separate chnage set. Again, TYVM! J. > > Thanks. > > ----- Original Message ----- >> >> Hi! >> >> >> Proudly :) presenting... documentation generator for ITW. >> >> Lukas Dracz already seen the preversion, because we shares one peace of code >> - >> OptionsDefinitions.java - also he was trying to impelmetn first versions >> of this. >> >> Now his patch is built on top of this. >> >> Well, it does a lot of things >> - generates man pages and html doc* and palintext docs** >> - unified files declarations >> - unified options declarations >> >> * html docs >> - are usleless in offlien mode (maybe we can publish them on classapth >> org after each release - >> but are used (generated in runtime) in help dialogue - which is really really >> nice. >> >> ** plain text docs - even les susefull then html docs, but are used in >> runtime commandlinehel/and >> about - which removed all the duplicated string providers. >> >> Various files and properties are sorted in javaws pages, have theyrs defaults >> and for sure none is >> missing. >> >> So finally no duplicated texts in various "about" and "help"! >> >> The patch is missing localization - I'm going to do so in some next >> changeset, and I hope to get >> rid of RepalcingFormater and its @@ substitution. >> >> >> >> As for review - anybody, please be specially careful about the files >> declaration. I hope I did it >> error-less and complete :( >> >> >> The design is >> >> 1docprovider - have 2formater is providing 3output >> >> eg: >> 1 - itw, itw-settings, javaws... >> 2 - html, plain, man >> 3 - man pages (generated during build, loclaized), runtime help - both >> console and "nice" html one. >> The runtime help have evaluated varibales and properties >> >> >> For runtime help I had to refactor about dialog a bit - only make some parts >> singletons and added >> an tab.... >> >> >> make check, install, dist and install form dist and unnstall works. >> >> >> >> J. >> >> >> >> >> >> From jvanek at redhat.com Mon Sep 8 16:42:41 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 08 Sep 2014 18:42:41 +0200 Subject: Fwd: docs generator - prereview In-Reply-To: <20140908163752.GA3236@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> <20140908163752.GA3236@redhat.com> Message-ID: <540DDC81.90301@redhat.com> On 09/08/2014 06:37 PM, Omair Majid wrote: > * Jiri Vanek [2014-09-04 11:20]: >> +public class PathsAndFiles { > >> + public static final String USER_CONFIG_HOME; >> + public static final String USER_CACHE_HOME; >> + public static final String USER_SECURITY; > >> + public static final String ICEDTEA_SO = "IcedTeaPlugin.so"; > >> + public static final InfrastructureFileDescriptor PIPES_DIR >> + public static final InfrastructureFileDescriptor MOZILA_USER >> + public static final InfrastructureFileDescriptor MOZILA_GLOBAL_64 >> + public static final InfrastructureFileDescriptor MOZILA_GLOBAL_32 >> + public static final InfrastructureFileDescriptor OPERA_64 >> + public static final InfrastructureFileDescriptor OPERA_32 >> + >> + public static final InfrastructureFileDescriptor CACHE_DIR >> + public static final InfrastructureFileDescriptor PCACHE_DIR >> + public static final InfrastructureFileDescriptor LOG_DIR >> + public static final InfrastructureFileDescriptor APPLET_TRUST_SETTINGS_USER >> + public static final InfrastructureFileDescriptor APPLET_TRUST_SETTINGS_SYS >> + public static final InfrastructureFileDescriptor ETC_DEPLOYMENT_CFG >> + public static final InfrastructureFileDescriptor TMP_DIR >> + >> + public static final InfrastructureFileDescriptor LOCKS_DIR >> + public static final InfrastructureFileDescriptor MAIN_LOCK >> + >> + public static final InfrastructureFileDescriptor JAVA_POLICY >> + public static final InfrastructureFileDescriptor USER_CACERTS >> + public static final InfrastructureFileDescriptor USER_JSSECAC >> + public static final InfrastructureFileDescriptor USER_CERTS >> + public static final InfrastructureFileDescriptor USER_JSSECER >> + public static final InfrastructureFileDescriptor USER_CLIENTCERT >> + >> + public static final InfrastructureFileDescriptor SYS_CACERT >> + public static final InfrastructureFileDescriptor SYS_JSSECAC >> + public static final InfrastructureFileDescriptor SYS_CERT >> + public static final InfrastructureFileDescriptor SYS_JSSECERT >> + public static final InfrastructureFileDescriptor SYS_CLIENTCERT >> + >> + public static final InfrastructureFileDescriptor JAVA_DEPLOYMENT_PROP_FILE >> + public static final InfrastructureFileDescriptor USER_DEPLOYMENT_FILE > > These are public fields in a public class. Can applets look at these > variables and identify restricted user information (such as username)? > We had similar security issues in the past: > http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=2010-3860 > Signed one can, unsigned can not. ty! J. From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 16:43:39 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 16:43:39 +0000 Subject: [Bug 1988] New: [IcedTea7] C++ Interpreter should no longer be used on ppc64 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1988 Bug ID: 1988 Summary: [IcedTea7] C++ Interpreter should no longer be used on ppc64 Product: IcedTea Version: 7-hg Hardware: ppc64 OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org http://mail.openjdk.java.net/pipermail/ppc-aix-port-dev/2014-September/002090.html -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 16:45:28 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 16:45:28 +0000 Subject: [Bug 1988] [IcedTea7] C++ Interpreter should no longer be used on ppc64 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1988 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Mon Sep 8 16:46:24 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 08 Sep 2014 16:46:24 +0000 Subject: /hg/icedtea7-forest/hotspot: PR1988: C++ Interpreter should no l... Message-ID: changeset 6d5ec408f4ca in /hg/icedtea7-forest/hotspot details: http://icedtea.classpath.org/hg/icedtea7-forest/hotspot?cmd=changeset;node=6d5ec408f4ca author: andrew date: Mon Sep 08 17:44:42 2014 +0100 PR1988: C++ Interpreter should no longer be used on ppc64 diffstat: make/defs.make | 4 ---- make/linux/platform_ppc64 | 2 +- 2 files changed, 1 insertions(+), 5 deletions(-) diffs (23 lines): diff -r 304c66cf5010 -r 6d5ec408f4ca make/defs.make --- a/make/defs.make Thu Aug 28 15:26:22 2014 +0100 +++ b/make/defs.make Mon Sep 08 17:44:42 2014 +0100 @@ -307,10 +307,6 @@ LP64_ARCH = sparcv9 amd64 ia64 ppc64 zero endif -ifeq ($(ARCH), ppc64) - CC_INTERP=true -endif - # Required make macro settings for all platforms MAKE_ARGS += JAVA_HOME=$(ABS_BOOTDIR) MAKE_ARGS += OUTPUTDIR=$(ABS_OUTPUTDIR) diff -r 304c66cf5010 -r 6d5ec408f4ca make/linux/platform_ppc64 --- a/make/linux/platform_ppc64 Thu Aug 28 15:26:22 2014 +0100 +++ b/make/linux/platform_ppc64 Mon Sep 08 17:44:42 2014 +0100 @@ -14,4 +14,4 @@ gnu_dis_arch = ppc64 -sysdefs = -DLINUX -D_GNU_SOURCE -DPPC64 -DCC_INTERP +sysdefs = -DLINUX -D_GNU_SOURCE -DPPC64 From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 16:46:31 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 16:46:31 +0000 Subject: [Bug 1988] [IcedTea7] C++ Interpreter should no longer be used on ppc64 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1988 --- Comment #1 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7-forest/hotspot?cmd=changeset;node=6d5ec408f4ca author: andrew date: Mon Sep 08 17:44:42 2014 +0100 PR1988: C++ Interpreter should no longer be used on ppc64 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Mon Sep 8 17:39:43 2014 From: jkang at redhat.com (Jie Kang) Date: Mon, 8 Sep 2014 13:39:43 -0400 (EDT) Subject: docs generator - prereview In-Reply-To: <540882BB.5070100@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> Message-ID: <2041820985.1850516.1410197983120.JavaMail.zimbra@redhat.com> Hello, I haven't fully checked everything but it looks nice so far. The generated docs seem fine and the Makefile additions work for me. Just some very minor nits along with what aazores has said on the typos :D Patch review in-line with code below: diff -r c45cd47e962b netx/net/sourceforge/jnlp/OptionsDefinitions.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 04 17:11:31 2014 +0200 @@ -0,0 +1,181 @@ ... + //javaws undocummented swithces + TRUSTALL("-Xtrustall","BOTrustall"), + //javaws control-options + ABOUT("-about", "BOAbout"), + VIEWER("-viewer", "BOViewer"), + CLEARCACHE("-Xclearcache", "BXclearcache"), + LICENSE("-license", "BOLicense"), + HELP("-help", "BOHelp"), + //javaws run-options + VERSION("-version", "BOVersion"), + ARG("-arg", "arg", "BOArg", NumberOfArguments.ONE_OR_MORE), + PARAM("-param", "name=value", "BOParam", NumberOfArguments.ONE_OR_MORE), + PROPERTY("-property", "name=value", "BOProperty", NumberOfArguments.ONE_OR_MORE), + UPDATE("-update", "seconds", "BOUpdate", NumberOfArguments.ONE), + VERBOSE("-verbose", "BOVerbose"), + NOSEC("-nosecurity", "BONosecurity"), + NOUPDATE("-noupdate", "BONoupdate"), + HEADLESS("-headless", "BOHeadless"), + STRICT("-strict", "BOStrict"), + XML("-xml", "BOXml"), + REDIRECT("-allowredirect", "BOredirect"), + NOFORK("-Xnofork", "BXnofork"), + NOHEADERS("-Xignoreheaders", "BXignoreheaders"), + OFFLINE("-Xoffline", "BXoffline"), + TRUSTNONE("-Xtrustnone","BOTrustnone"), + //itweb settings + NODASHHELP("help", "IBOhelp"), + LIST("list", "IBOlist"), + GET("get", "name", "IBOget"), + INFO("info", "name", "IBOinfo"), + SET("set", "name value", "IBOset"), + RESETALL("reset", "all", "IBOresetAll"), + RESET("reset", "name", "IBOreset"), + CHECK("check", "name", "IBOcheck"), + //policyeditor + //-help + FILE("-file", "policy_file", "PBOfile"), + CODEBASE("-codebase", "url", "PBOcodebase"); For the values such as PBOcodebase, BOredirect, BOStrict, etc. can you make the capitalization consistent throughout? e.g. BOStrict vs BOstrict : up to you how to do it, but please make them all the same if possible. ... diff -r c45cd47e962b netx/net/sourceforge/jnlp/config/PathsAndFiles.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/config/PathsAndFiles.java Thu Sep 04 17:11:31 2014 +0200 @@ -0,0 +1,361 @@ ... + public static class InfrastructureFileDescriptor { I'm not a fan of multiple classes within one file, could you move all the various FileDescriptors into their own file? ... diff -r c45cd47e962b netx/net/sourceforge/jnlp/config/Defaults.java --- a/netx/net/sourceforge/jnlp/config/Defaults.java Wed Aug 20 15:49:58 2014 -0400 +++ b/netx/net/sourceforge/jnlp/config/Defaults.java Thu Sep 04 17:11:31 2014 +0200 @@ -37,47 +37,19 @@ ... /** * Get the default settings for deployment @@ -85,10 +57,13 @@ public static Map> getDefaults() { SecurityManager sm = System.getSecurityManager(); if (sm != null) { - sm.checkRead(userFile.toString()); + sm.checkRead(USER_DEPLOYMENT_FILE.getFullPath()); } + + + Are these three new-lines necessary? I think it looks a little awkward since there are now 5 new-lines in total. ... diff -r c45cd47e962b netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java --- a/netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java Wed Aug 20 15:49:58 2014 -0400 +++ b/netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java Thu Sep 04 17:11:31 2014 +0200 @@ -42,11 +42,7 @@ + aboutItwButtonAction = new ActionListener() { + @Override + public void actionPerformed(final ActionEvent e) { + AboutDialog.display(false, TextsProvider.POLICY_EDITOR); This new addition to policy editor is bugged when launched from the security dialog. The AboutDialog for Icedtea-Web does not gain focus and cannot be manipulated (apart from moving the frame) until policyeditor is closed. Reproduce by: Run a java applet (http://docs.oracle.com/javase/tutorial/deployment/applet/deployingApplet.html) from browser such as firefox. When the security dialog appears asking for approval, open the menu and click "Launch policyeditor". From there, open Help -> About Icedtea-Web. Try to manipulate the dialog, for example, right-click on the frame and choose 'close'. Note that these actions do not work. Close policyeditor and note that the AboutDialog is now accessible. Using AboutDialog.display(true, ...); prevents this bug from occuring as the boolean represents modality of the Dialog. Regards, ----- Original Message ----- > > Hi! > > > Proudly :) presenting... documentation generator for ITW. > > Lukas Dracz already seen the preversion, because we shares one peace of code > - > OptionsDefinitions.java - also he was trying to impelmetn first versions > of this. > > Now his patch is built on top of this. > > Well, it does a lot of things > - generates man pages and html doc* and palintext docs** > - unified files declarations > - unified options declarations > > * html docs > - are usleless in offlien mode (maybe we can publish them on classapth > org after each release - > but are used (generated in runtime) in help dialogue - which is really really > nice. > > ** plain text docs - even les susefull then html docs, but are used in > runtime commandlinehel/and > about - which removed all the duplicated string providers. > > Various files and properties are sorted in javaws pages, have theyrs defaults > and for sure none is > missing. > > So finally no duplicated texts in various "about" and "help"! > > The patch is missing localization - I'm going to do so in some next > changeset, and I hope to get > rid of RepalcingFormater and its @@ substitution. > > > > As for review - anybody, please be specially careful about the files > declaration. I hope I did it > error-less and complete :( > > > The design is > > 1docprovider - have 2formater is providing 3output > > eg: > 1 - itw, itw-settings, javaws... > 2 - html, plain, man > 3 - man pages (generated during build, loclaized), runtime help - both > console and "nice" html one. > The runtime help have evaluated varibales and properties > > > For runtime help I had to refactor about dialog a bit - only make some parts > singletons and added > an tab.... > > > make check, install, dist and install form dist and unnstall works. > > > > J. > > > > > > -- Jie Kang From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 17:45:19 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 17:45:19 +0000 Subject: [Bug 1989] New: [IcedTea7] Make jdk_generic_profiles.sh handle missing programs better and be more verbose Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1989 Bug ID: 1989 Summary: [IcedTea7] Make jdk_generic_profiles.sh handle missing programs better and be more verbose Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: enhancement Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 17:45:37 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 17:45:37 +0000 Subject: [Bug 1989] [IcedTea7] Make jdk_generic_profiles.sh handle missing programs better and be more verbose In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1989 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 17:45:46 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 17:45:46 +0000 Subject: [Bug 1989] [IcedTea7] Make jdk_generic_profile.sh handle missing programs better and be more verbose In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1989 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|[IcedTea7] Make |[IcedTea7] Make |jdk_generic_profiles.sh |jdk_generic_profile.sh |handle missing programs |handle missing programs |better and be more verbose |better and be more verbose -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Mon Sep 8 17:45:59 2014 From: jkang at redhat.com (Jie Kang) Date: Mon, 8 Sep 2014 13:45:59 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> Message-ID: <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> ----- Original Message ----- > Hello, > > Okay so this patch, uses disabling/enabling instead of hiding/showing. Also > put the "Java stores application ..." description to always be at the top > where as the rest of the components will be centered. > Also changed from powers of two to increments of 10 but not jumps of > 1,10,100,1000,10000 etc. but instead to > 0,1,2,3,...,7,8,9,10,20,30...80,90,100,200,300...800,900,1000,2000,3000 etc. > I think this way is best as it does not jump to the larger values too > quickly. > > As for my opinion, I think disabling is better than hiding, as it still shows > the user the possibilities in the panel even though they are not active. I > also liked the powers of two spinner much more personally but from a user's > point of view I agree that increments of 10 are more intuitive and easier to > understand. > > Thank you, > Lukasz Dracz Hello, When you check the 'limit cache size box' with a size of 0, the JAR compression option and cache location option are disabled. At the moment, limiting cache size to 0 means that once icedtea-web finishes, the cache is cleared of all files. I think the description for Caching should be reworded a little to make this known. E.g. "No files will be cached. Cached files will be deleted." can be reworded to something like: "Cached files will be deleted on icedtea-web close. As well, the ability to choose where icedtea-web downloads file should still be enabled even if cache has a limit of 0. In terms of code, it functionally looks okay but I would strongly suggest adding logically placed line spaces throughout the code for easier reading. E.g. I think the code below could be spaced out. + //Override getNextValue and getPreviousValue to make it jump to the closest increment/decrement of step size + final Long configCacheSize = parseLong(this.config.getProperty(Properties.CACHE_MAX_SIZE.toString())); + final Long initialCacheSize = configCacheSize < CACHE_MIN_SIZE ? CACHE_MIN_SIZE : configCacheSize; + final SpinnerNumberModel snmCacheSize = new PowerOfSpinnerNumberModel(initialCacheSize, TemporaryInternetFilesPanel.CACHE_MIN_SIZE, TemporaryInternetFilesPanel.CACHE_MAX_SIZE, TemporaryInternetFilesPanel.SPINNER_STEP_SIZE); + cacheSizeSpinner.setModel(snmCacheSize); + final SpinnerChangeListener listener = new SpinnerChangeListener(); + cacheSizeSpinner.addChangeListener(listener); + cacheSizeSpinner.setToolTipText(Translator.R("TIFPCacheSizeSpinnerTooltip", CACHE_MIN_SIZE, CACHE_MAX_SIZE)); + limitCacheSizeCheckBox.setSelected(configCacheSize >= CACHE_MIN_SIZE); + limitCacheSizeCheckBox.addItemListener(new CheckboxItemListener()); Regards, -- Jie Kang From andrew at icedtea.classpath.org Mon Sep 8 17:47:22 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 08 Sep 2014 17:47:22 +0000 Subject: /hg/icedtea7-forest/jdk: 2 new changesets Message-ID: changeset 223137954781 in /hg/icedtea7-forest/jdk details: http://icedtea.classpath.org/hg/icedtea7-forest/jdk?cmd=changeset;node=223137954781 author: xuelei date: Thu Apr 18 22:23:56 2013 -0700 8006935: Need to take care of long secret keys in HMAC/PRF compuation Reviewed-by: valeriep changeset e97e34bd3cc9 in /hg/icedtea7-forest/jdk details: http://icedtea.classpath.org/hg/icedtea7-forest/jdk?cmd=changeset;node=e97e34bd3cc9 author: andrew date: Mon Sep 08 18:46:06 2014 +0100 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose diffstat: make/jdk_generic_profile.sh | 82 ++++++++- src/share/classes/com/sun/crypto/provider/TlsPrfGenerator.java | 21 ++- 2 files changed, 88 insertions(+), 15 deletions(-) diffs (337 lines): diff -r 9caf15ac18b8 -r e97e34bd3cc9 make/jdk_generic_profile.sh --- a/make/jdk_generic_profile.sh Wed Aug 27 23:07:42 2014 +0100 +++ b/make/jdk_generic_profile.sh Mon Sep 08 18:46:06 2014 +0100 @@ -245,11 +245,27 @@ PATH="${path4sdk}" export PATH +# Obtain pkgconfig for libs +pkgconfig=$(which pkg-config 2>/dev/null) +echo "pkgconfig=${pkgconfig}" + +# Find source location +jdk_topdir=$(dirname ${BASH_SOURCE})/.. +if [ ! -e ${jdk_topdir}/src ] ; then + jdk_topdir=$(hg root) ; +fi +echo "jdk_topdir=${jdk_topdir}" + # Export variables required for Zero +if [ "x${ZERO_BUILD}" = "x" ] ; then ZERO_BUILD=false; fi +if [ "x${SHARK_BUILD}" = "x" ] ; then SHARK_BUILD=false; fi if [ "${SHARK_BUILD}" = true ] ; then ZERO_BUILD=true export ZERO_BUILD fi +echo "Building Zero: ${ZERO_BUILD}" +echo "Building Shark: ${SHARK_BUILD}" + if [ "${ZERO_BUILD}" = true ] ; then # ZERO_LIBARCH is the name of the architecture-specific # subdirectory under $JAVA_HOME/jre/lib @@ -264,6 +280,7 @@ *) ZERO_LIBARCH="$(arch)" esac export ZERO_LIBARCH + echo "Zero library architecture: ${ZERO_LIBARCH}" # ARCH_DATA_MODEL is the number of bits in a pointer case "${ZERO_LIBARCH}" in @@ -278,6 +295,7 @@ exit 1 esac export ARCH_DATA_MODEL + echo "Zero architecture data model: ${ARCH_DATA_MODEL}" # ZERO_ENDIANNESS is the endianness of the processor case "${ZERO_LIBARCH}" in @@ -292,6 +310,7 @@ exit 1 esac export ZERO_ENDIANNESS + echo "Zero endianness: ${ZERO_ENDIANNESS}" # ZERO_ARCHDEF is used to enable architecture-specific code case "${ZERO_LIBARCH}" in @@ -302,6 +321,7 @@ *) ZERO_ARCHDEF=$(echo "${ZERO_LIBARCH}" | tr a-z A-Z) esac export ZERO_ARCHDEF + echo "Zero architecture definition: ${ZERO_ARCHDEF}" # ZERO_ARCHFLAG tells the compiler which mode to build for case "${ZERO_LIBARCH}" in @@ -315,10 +335,10 @@ ZERO_ARCHFLAG="-m${ARCH_DATA_MODEL}" esac export ZERO_ARCHFLAG + echo "Zero architecture flag: ${ZERO_ARCHFLAG}" # LIBFFI_CFLAGS and LIBFFI_LIBS tell the compiler how to compile and # link against libffi - pkgconfig=$(which pkg-config 2>/dev/null) if [ -x "${pkgconfig}" ] ; then if [ "${LIBFFI_CFLAGS}" = "" ] ; then LIBFFI_CFLAGS=$("${pkgconfig}" --cflags libffi) @@ -328,11 +348,14 @@ fi fi if [ "${LIBFFI_LIBS}" = "" ] ; then + echo "No libffi detected."; LIBFFI_LIBS="-lffi" fi export LIBFFI_CFLAGS export LIBFFI_LIBS - + echo "Using LIBFFI_CFLAGS=${LIBFFI_CFLAGS}" + echo "Using LIBFFI_LIBS=${LIBFFI_LIBS}" + # LLVM_CFLAGS, LLVM_LDFLAGS and LLVM_LIBS tell the compiler how to # compile and link against LLVM if [ "${SHARK_BUILD}" = true ] ; then @@ -382,12 +405,12 @@ export LLVM_CFLAGS export LLVM_LDFLAGS export LLVM_LIBS + echo "Using LLVM_CFLAGS=${LLVM_CFLAGS}" + echo "Using LLVM_LDFLAGS=${LLVM_LDFLAGS}" + echo "Using LLVM_LIBS=${LLVM_LIBS}" fi fi -# Obtain pkgconfig for libs -pkgconfig=$(which pkg-config 2>/dev/null) - # Export variables for system zlib # ZLIB_CFLAGS and ZLIB_LIBS tell the compiler how to compile and # link against zlib @@ -400,10 +423,13 @@ fi fi if [ "${ZLIB_LIBS}" = "" ] ; then + echo "No zlib detected."; ZLIB_LIBS="-lz" fi export ZLIB_CFLAGS export ZLIB_LIBS +echo "Using ZLIB_CFLAGS=${ZLIB_CFLAGS}" +echo "Using ZLIB_LIBS=${ZLIB_LIBS}" # Export variables for system LCMS # LCMS_CFLAGS and LCMS_LIBS tell the compiler how to compile and @@ -417,10 +443,13 @@ fi fi if [ "${LCMS_LIBS}" = "" ] ; then + echo "No LCMS detected."; LCMS_LIBS="-llcms2" fi export LCMS_CFLAGS export LCMS_LIBS +echo "Using LCMS_CFLAGS=${LCMS_CFLAGS}" +echo "Using LCMS_LIBS=${LCMS_LIBS}" # Export variables for system jpeg # JPEG_CFLAGS and JPEG_LIBS tell the compiler how to compile and @@ -429,6 +458,7 @@ JPEG_LIBS="-ljpeg" fi export JPEG_LIBS +echo "Using JPEG_LIBS=${JPEG_LIBS}" # Export variables for system libpng # PNG_CFLAGS and PNG_LIBS tell the compiler how to compile and @@ -442,10 +472,13 @@ fi fi if [ "${PNG_LIBS}" = "" ] ; then + echo "No libpng detected."; PNG_LIBS="-lpng" fi export PNG_CFLAGS export PNG_LIBS +echo "Using PNG_CFLAGS=${PNG_CFLAGS}" +echo "Using PNG_LIBS=${PNG_LIBS}" # Export variables for system giflib # GIF_CFLAGS and GIF_LIBS tell the compiler how to compile and @@ -454,6 +487,7 @@ GIF_LIBS="-lgif" fi export GIF_LIBS +echo "Using GIF_LIBS=${GIF_LIBS}" # Export variables for system krb5 # KRB5_CFLAGS and KRB5_LIBS tell the compiler how to compile and @@ -462,6 +496,7 @@ KRB5_LIBS="-lkrb5" fi export KRB5_LIBS +echo "Using KRB5_LIBS=${KRB5_LIBS}" # Export variables for system CUPS # CUPS_CFLAGS and CUPS_LIBS tell the compiler how to compile and @@ -470,6 +505,7 @@ CUPS_LIBS="-lcups" fi export CUPS_LIBS +echo "Using CUPS_LIBS=${CUPS_LIBS}" # Export variables for system libgtk # GTK_CFLAGS and GTK_LIBS tell the compiler how to compile and @@ -484,6 +520,8 @@ fi export GTK_CFLAGS export GTK_LIBS +echo "Using GTK_CFLAGS=${GTK_CFLAGS}" +echo "Using GTK_LIBS=${GTK_LIBS}" # Export variables for system libgio # GIO_CFLAGS and GIO_LIBS tell the compiler how to compile and @@ -500,6 +538,8 @@ fi export GIO_CFLAGS export GIO_LIBS +echo "Using GIO_CFLAGS=${GIO_CFLAGS}" +echo "Using GIO_LIBS=${GIO_LIBS}" # Export variables for system libpcsc # PCSC_CFLAGS and PCSC_LIBS tell the compiler how to compile and @@ -515,10 +555,13 @@ fi fi if [ "${PCSC_LIBS}" = "" ] ; then + echo "No libpcsclite detected."; PCSC_LIBS="-lpcsclite" fi export PCSC_CFLAGS export PCSC_LIBS +echo "Using PCSC_CFLAGS=${PCSC_CFLAGS}" +echo "Using PCSC_LIBS=${PCSC_LIBS}" # Export variables for system fontconfig # FONTCONFIG_CFLAGS and FONTCONFIG_LIBS tell the compiler how to compile and @@ -532,21 +575,28 @@ fi fi if [ "${FONTCONFIG_LIBS}" = "" ] ; then + echo "No fontconfig detected."; FONTCONFIG_LIBS="-lfontconfig" fi export FONTCONFIG_CFLAGS export FONTCONFIG_LIBS +echo "Using FONTCONFIG_CFLAGS=${FONTCONFIG_CFLAGS}" +echo "Using FONTCONFIG_LIBS=${FONTCONFIG_LIBS}" # Setup nss.cfg using location of NSS libraries if [ -x "${pkgconfig}" ] ; then - jdk_topdir=$(dirname ${BASH_SOURCE})/.. - if [ ! -e ${jdk_topdir}/src ] ; then - jdk_topdir=$(hg root) ; + if [ "${NSS_LIBDIR}" = "" ] ; then + NSS_LIBDIR=$("${pkgconfig}" --variable=libdir nss) fi - sed -e "s#@NSS_LIBDIR@#$(${pkgconfig} --variable=libdir nss)#" \ - ${jdk_topdir}/src/share/lib/security/nss.cfg.in \ - > ${jdk_topdir}/src/share/lib/security/nss.cfg fi +if [ "${NSS_LIBDIR}" = "" ] ; then + NSS_LIBDIR="/usr/lib"; + echo "No NSS library directory detected."; +fi +echo "Using NSS_LIBDIR=${NSS_LIBDIR}" +sed -e "s#@NSS_LIBDIR@#$()#" \ + ${jdk_topdir}/src/share/lib/security/nss.cfg.in \ + > ${jdk_topdir}/src/share/lib/security/nss.cfg # IcedTea defaults; use system libraries export SYSTEM_LCMS=true @@ -561,10 +611,12 @@ export COMPILE_AGAINST_SYSCALLS=true if [ "x${GTK_LIBS}" != "x" ] ; then + echo "Gtk+ detected; enabling system linking."; export SYSTEM_GTK=true fi if [ "x${GIO_LIBS}" != "x" ] ; then + echo "GIO detected; enabling system linking."; export SYSTEM_GIO=true fi @@ -575,21 +627,25 @@ export ICEDTEA_NAME="IcedTea" export PACKAGE_VERSION="2.6pre06" export DERIVATIVE_ID="${ICEDTEA_NAME} ${PACKAGE_VERSION}" +echo "Building ${DERIVATIVE_ID}" if [ -e ${jdk_topdir} ] ; then if hg -R ${jdk_topdir} id &>/dev/null ; then export JDK_REVID="r$(hg -R ${jdk_topdir} id -i)"; + echo "JDK Mercurial revision: ${JDK_REVID}" fi fi hotspot_topdir=${jdk_topdir}/../hotspot if [ -e ${hotspot_topdir} ] ; then if hg -R ${hotspot_topdir} id &>/dev/null ; then export HOTSPOT_BUILD_VERSION="r$(hg -R ${hotspot_topdir} id -i)"; + echo "HotSpot Mercurial revision: ${HOTSPOT_BUILD_VERSION}" fi fi lsbrelease=$(which lsb_release 2>/dev/null) -if [ -x ${lsbrelease} ] ; then +echo "lsbrelease=${lsbrelease}" +if [ -x "${lsbrelease}" ] ; then lsbinfo="$(${lsbrelease} -ds | sed 's/^"//;s/"$//')" if test "x${PKGVERSION}" = "x"; then export DISTRIBUTION_ID="Built on ${lsbinfo} ($(date))" @@ -597,4 +653,6 @@ export DISTRIBUTION_ID="${lsbinfo}, package $PKGVERSION" fi export DISTRO_NAME="$(${lsbrelease} -is | sed 's/^"//;s/"$//')" + echo "Distribution ID: ${DISTRIBUTION_ID}" + echo "Distribution Name: ${DISTRO_NAME}" fi diff -r 9caf15ac18b8 -r e97e34bd3cc9 src/share/classes/com/sun/crypto/provider/TlsPrfGenerator.java --- a/src/share/classes/com/sun/crypto/provider/TlsPrfGenerator.java Wed Aug 27 23:07:42 2014 +0100 +++ b/src/share/classes/com/sun/crypto/provider/TlsPrfGenerator.java Mon Sep 08 18:46:06 2014 +0100 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -241,14 +241,29 @@ int off = secret.length >> 1; int seclen = off + (secret.length & 1); + byte[] secKey = secret; + int keyLen = seclen; byte[] output = new byte[outputLength]; // P_MD5(S1, label + seed) - expand(md5, 16, secret, 0, seclen, labelBytes, seed, output, + // If we have a long secret, digest it first. + if (seclen > 64) { // 64: block size of HMAC-MD5 + md5.update(secret, 0, seclen); + secKey = md5.digest(); + keyLen = secKey.length; + } + expand(md5, 16, secKey, 0, keyLen, labelBytes, seed, output, HMAC_ipad64.clone(), HMAC_opad64.clone()); // P_SHA-1(S2, label + seed) - expand(sha, 20, secret, off, seclen, labelBytes, seed, output, + // If we have a long secret, digest it first. + if (seclen > 64) { // 64: block size of HMAC-SHA1 + sha.update(secret, off, seclen); + secKey = sha.digest(); + keyLen = secKey.length; + off = 0; + } + expand(sha, 20, secKey, off, keyLen, labelBytes, seed, output, HMAC_ipad64.clone(), HMAC_opad64.clone()); return output; From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 17:47:28 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 17:47:28 +0000 Subject: [Bug 1989] [IcedTea7] Make jdk_generic_profile.sh handle missing programs better and be more verbose In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1989 --- Comment #1 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7-forest/jdk?cmd=changeset;node=e97e34bd3cc9 author: andrew date: Mon Sep 08 18:46:06 2014 +0100 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 18:21:05 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 18:21:05 +0000 Subject: [Bug 1990] New: iced tea plugin problem with remote login to wdmycloud Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1990 Bug ID: 1990 Summary: iced tea plugin problem with remote login to wdmycloud Product: IcedTea-Web Version: unspecified Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: Plugin Assignee: dbhole at redhat.com Reporter: martinrooyakkers at yahoo.com CC: unassigned at icedtea.classpath.org Created attachment 1167 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1167&action=edit ICEDTEAPLUGIN_DEBUG=true firefox 2>&1 | tee plugin.log -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 8 18:24:44 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 08 Sep 2014 18:24:44 +0000 Subject: [Bug 1991] New: ice tea problem with remote login to wdmycloud Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1991 Bug ID: 1991 Summary: ice tea problem with remote login to wdmycloud Product: IcedTea-Web Version: unspecified Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: NetX (javaws) Assignee: omajid at redhat.com Reporter: martinrooyakkers at yahoo.com CC: unassigned at icedtea.classpath.org Created attachment 1168 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1168&action=edit terminal output from; javaws -verbose [problem JNLP file] 2>&1 | tee javaws.log -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ldracz at redhat.com Mon Sep 8 18:38:35 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Mon, 8 Sep 2014 14:38:35 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> Message-ID: <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> Hello, > Hello, > > When you check the 'limit cache size box' with a size of 0, the JAR > compression option and cache location option are disabled. At the moment, > limiting cache size to 0 means that once icedtea-web finishes, the cache is > cleared of all files. > > I think the description for Caching should be reworded a little to make this > known. E.g. > > "No files will be cached. Cached files will be deleted." can be reworded to > something like: > "Cached files will be deleted on icedtea-web close. Okay > As well, the ability to choose where icedtea-web downloads file should still > be enabled even if cache has a limit of 0. Yes since it still downloads the files even if they are deleted after use. This provides the user with more choice on where they want the files to be temporarily. > In terms of code, it functionally looks okay but I would strongly suggest > adding logically placed line spaces throughout the code for easier reading. Yes, sorry about that, I added spaces in a bunch of places now to increase readability. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: cacheSizeSpinner-21.patch Type: text/x-patch Size: 22989 bytes Desc: not available URL: From jkang at redhat.com Mon Sep 8 19:53:23 2014 From: jkang at redhat.com (Jie Kang) Date: Mon, 8 Sep 2014 15:53:23 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> Message-ID: <228406470.1910132.1410206003976.JavaMail.zimbra@redhat.com> Hello, Two minor nits. You have my +1 after the changes :) + private final String prop; + Properties(final String prop) { + this.prop = prop; + } I'd prefer the name property instead of prop. Short forms should be used sparingly in my opinion. + this.addComponentListener(new ComponentListener() { Instead of using new ComponentListener() you should use ComponentAdapter(). That way you won't need to implement 3 empty methods. "The class that is interested in processing a component event either implements this interface (and all the methods it contains) or extends the abstract ComponentAdapter class (overriding only the methods of interest)." [1] [1] http://docs.oracle.com/javase/7/docs/api/java/awt/event/ComponentListener.html + @Override + public void componentResized(final ComponentEvent componentEvent) { + } + + @Override + public void componentMoved(final ComponentEvent componentEvent) { + } + + @Override + public void componentShown(final ComponentEvent componentEvent) { + listener.stateChanged(null); + } + + @Override + public void componentHidden(final ComponentEvent componentEvent) { + } + }); + final int powersListSize = (int) Math.floor(Math.log(cacheMaxSize) / Math.log(spinnerStepSize) + 1); ... + final Long result = original - (original % powersOf.get(String.valueOf(original).length() - 1)) + powersOf.get(String.valueOf(original).length() - 1); For code like this I think comments describing the basics of what is occurring and/or why it is occurring would be very helpful. Also in the future I would suggest creating unit tests in conjunction with new features (apply TDD!!!) so that we can be assured things work as expected without manual testing. E.g. the operation of the spinner could definitely be unit tested to make sure it increments/decrements by powers of 10 as expected. Regards, ----- Original Message ----- > > Hello, > > > Hello, > > > > When you check the 'limit cache size box' with a size of 0, the JAR > > compression option and cache location option are disabled. At the moment, > > limiting cache size to 0 means that once icedtea-web finishes, the cache is > > cleared of all files. > > > > I think the description for Caching should be reworded a little to make > > this > > known. E.g. > > > > "No files will be cached. Cached files will be deleted." can be reworded to > > something like: > > "Cached files will be deleted on icedtea-web close. > > Okay > > > As well, the ability to choose where icedtea-web downloads file should > > still > > be enabled even if cache has a limit of 0. > > Yes since it still downloads the files even if they are deleted after use. > This provides the user with more choice on where they want the files to be > temporarily. > > > In terms of code, it functionally looks okay but I would strongly suggest > > adding logically placed line spaces throughout the code for easier reading. > > Yes, sorry about that, I added spaces in a bunch of places now to increase > readability. > > Thank you, > Lukasz Dracz > -- Jie Kang From gitne at gmx.de Tue Sep 9 03:31:54 2014 From: gitne at gmx.de (Jacob Wisor) Date: Tue, 09 Sep 2014 05:31:54 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> Message-ID: <540E74AA.6010902@gmx.de> On 09/08/2014 08:38 PM, Lukasz Dracz wrote: >> As well, the ability to choose where icedtea-web downloads file should still >> be enabled even if cache has a limit of 0. > > Yes since it still downloads the files even if they are deleted after use. > This provides the user with more choice on where they want the files to be temporarily. No, the UI components to choose a cache location should be kept disabled in this case indeed. 0 means *no* *cache*. Hence, IcedTea-Web should behave as expected which would be to store all downloaded resources in memory and if, and only if, it should turn out to be impossible to implement proper working of IcedTea-Web without storing resources into files then they should be stored in the system configured user's temporary directory. In other words, if cache size is 0 then downloaded resources /could/ go into the user's temporary directory, although this should practically never happen because IcedTea-Web should error out with an OutOfMemoryException before anything else in this case. Also, the UI components denoting the cache location /could/ display the path to the user's temporary directory if cache size is 0. So in any event the UI components must be disabled at cache size 0. Jacob From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 07:03:41 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 07:03:41 +0000 Subject: [Bug 1990] iced tea plugin problem with remote login to wdmycloud In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1990 JiriVanek changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jvanek at redhat.com --- Comment #1 from JiriVanek --- Seeing this: Caused by: java.lang.RuntimeException: Unsupported OS: LINUX at com.wd.nas4g.mapdrive.command.WebDAVCmdFactory.(WebDAVCmdFactory.java:26) ... 9 more in log, making me feel sad that it is not ITW bug. May you verify that the applet support linux? (or that it hsould work at least partially?) -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Tue Sep 9 09:20:39 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 09 Sep 2014 11:20:39 +0200 Subject: docs generator - prereview In-Reply-To: <2041820985.1850516.1410197983120.JavaMail.zimbra@redhat.com> References: <5405E4C0.9050909@redhat.com> <540882BB.5070100@redhat.com> <2041820985.1850516.1410197983120.JavaMail.zimbra@redhat.com> Message-ID: <540EC667.7020206@redhat.com> On 09/08/2014 07:39 PM, Jie Kang wrote: > Hello, > > I haven't fully checked everything but it looks nice so far. The generated docs seem fine and the Makefile additions work for me. Just some very minor nits along with what aazores has said on the typos :D > > Patch review in-line with code below: > > diff -r c45cd47e962b netx/net/sourceforge/jnlp/OptionsDefinitions.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 04 17:11:31 2014 +0200 > @@ -0,0 +1,181 @@ > ... > + //javaws undocummented swithces > + TRUSTALL("-Xtrustall","BOTrustall"), > + //javaws control-options > + ABOUT("-about", "BOAbout"), > + VIEWER("-viewer", "BOViewer"), > + CLEARCACHE("-Xclearcache", "BXclearcache"), > + LICENSE("-license", "BOLicense"), > + HELP("-help", "BOHelp"), > + //javaws run-options > + VERSION("-version", "BOVersion"), > + ARG("-arg", "arg", "BOArg", NumberOfArguments.ONE_OR_MORE), > + PARAM("-param", "name=value", "BOParam", NumberOfArguments.ONE_OR_MORE), > + PROPERTY("-property", "name=value", "BOProperty", NumberOfArguments.ONE_OR_MORE), > + UPDATE("-update", "seconds", "BOUpdate", NumberOfArguments.ONE), > + VERBOSE("-verbose", "BOVerbose"), > + NOSEC("-nosecurity", "BONosecurity"), > + NOUPDATE("-noupdate", "BONoupdate"), > + HEADLESS("-headless", "BOHeadless"), > + STRICT("-strict", "BOStrict"), > + XML("-xml", "BOXml"), > + REDIRECT("-allowredirect", "BOredirect"), > + NOFORK("-Xnofork", "BXnofork"), > + NOHEADERS("-Xignoreheaders", "BXignoreheaders"), > + OFFLINE("-Xoffline", "BXoffline"), > + TRUSTNONE("-Xtrustnone","BOTrustnone"), > + //itweb settings > + NODASHHELP("help", "IBOhelp"), > + LIST("list", "IBOlist"), > + GET("get", "name", "IBOget"), > + INFO("info", "name", "IBOinfo"), > + SET("set", "name value", "IBOset"), > + RESETALL("reset", "all", "IBOresetAll"), > + RESET("reset", "name", "IBOreset"), > + CHECK("check", "name", "IBOcheck"), > + //policyeditor > + //-help > + FILE("-file", "policy_file", "PBOfile"), > + CODEBASE("-codebase", "url", "PBOcodebase"); Sure, I will focus on that. TY! > For the values such as PBOcodebase, BOredirect, BOStrict, etc. can you make the capitalization consistent throughout? > e.g. BOStrict vs BOstrict : up to you how to do it, but please make them all the same if possible. > ... > diff -r c45cd47e962b netx/net/sourceforge/jnlp/config/PathsAndFiles.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/config/PathsAndFiles.java Thu Sep 04 17:11:31 2014 +0200 > @@ -0,0 +1,361 @@ > ... > + public static class InfrastructureFileDescriptor { > I'm not a fan of multiple classes within one file, could you move all the various FileDescriptors into their own file? Nope. If you look closely, all the subcalses are private, pnly making declarations of singletons more simple and readable. The only exposed class is the public one, so I will keep this as it is. > ... > diff -r c45cd47e962b netx/net/sourceforge/jnlp/config/Defaults.java > --- a/netx/net/sourceforge/jnlp/config/Defaults.java Wed Aug 20 15:49:58 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/config/Defaults.java Thu Sep 04 17:11:31 2014 +0200 > @@ -37,47 +37,19 @@ > ... > /** > * Get the default settings for deployment > @@ -85,10 +57,13 @@ > public static Map> getDefaults() { > SecurityManager sm = System.getSecurityManager(); > if (sm != null) { > - sm.checkRead(userFile.toString()); > + sm.checkRead(USER_DEPLOYMENT_FILE.getFullPath()); > } > > > + > + > + > Are these three new-lines necessary? I think it looks a little awkward since there are now 5 new-lines in total. :) good eye :) > ... > diff -r c45cd47e962b netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java > --- a/netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java Wed Aug 20 15:49:58 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java Thu Sep 04 17:11:31 2014 +0200 > @@ -42,11 +42,7 @@ > + aboutItwButtonAction = new ActionListener() { > + @Override > + public void actionPerformed(final ActionEvent e) { > + AboutDialog.display(false, TextsProvider.POLICY_EDITOR); > This new addition to policy editor is bugged when launched from the security dialog. The AboutDialog for Icedtea-Web does not gain focus and cannot be manipulated (apart from moving the frame) until policyeditor is closed. > Reproduce by: > Run a java applet (http://docs.oracle.com/javase/tutorial/deployment/applet/deployingApplet.html) from browser such as firefox. When the security dialog appears asking for approval, open the menu and click "Launch policyeditor". From there, open Help -> About Icedtea-Web. Try to manipulate the dialog, for example, right-click on the frame and choose 'close'. Note that these actions do not work. > Close policyeditor and note that the AboutDialog is now accessible. > > Using AboutDialog.display(true, ...); prevents this bug from occuring as the boolean represents modality of the Dialog. > > Oh thats interesting. I will look into it, ty! And yes, the policy dialog is shown as modal in this case, so it have to be modal too. I will fix it by AboutDialog.display(policiedtior.ismodal(), ...); J. From ptisnovs at icedtea.classpath.org Tue Sep 9 09:22:44 2014 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Tue, 09 Sep 2014 09:22:44 +0000 Subject: /hg/gfx-test: New tests added into CAGOperationsOnTwoTouchingCir... Message-ID: changeset a4f0a599cecb in /hg/gfx-test details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=a4f0a599cecb author: Pavel Tisnovsky date: Tue Sep 09 11:23:49 2014 +0200 New tests added into CAGOperationsOnTwoTouchingCircles. diffstat: ChangeLog | 5 + src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java | 156 +++++++++- 2 files changed, 158 insertions(+), 3 deletions(-) diffs (189 lines): diff -r e18a753d1d48 -r a4f0a599cecb ChangeLog --- a/ChangeLog Mon Sep 08 11:46:21 2014 +0200 +++ b/ChangeLog Tue Sep 09 11:23:49 2014 +0200 @@ -1,3 +1,8 @@ +2014-09-09 Pavel Tisnovsky + + * src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java: + New tests added into CAGOperationsOnTwoTouchingCircles. + 2014-09-08 Pavel Tisnovsky * src/org/gfxtest/testsuites/BitBltBufferedImageOp.java: diff -r e18a753d1d48 -r a4f0a599cecb src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java --- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java Mon Sep 08 11:46:21 2014 +0200 +++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java Tue Sep 09 11:23:49 2014 +0200 @@ -2935,7 +2935,7 @@ /** * Checks the process of creating and rendering new geometric shape * constructed from two touching circles using union operator. The shape is rendered - * using radial gradient paint (fill). + * using texture paint (fill). * * @param image * image to which area is to be drawn @@ -2943,12 +2943,162 @@ * graphics canvas * @return test result status - PASSED, FAILED or ERROR */ - public TestResult testSubtractRadialGradientPaint(TestImage image, Graphics2D graphics2d) + public TestResult testUnionTextureFillUsingRGBTexture5(TestImage image, Graphics2D graphics2d) { // set stroke color CommonRenderingStyles.setStrokeColor(graphics2d); // set fill color - CommonRenderingStyles.setRadialGradientFill(image, graphics2d); + CommonRenderingStyles.setTextureFillUsingRGBTexture5(image, graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingUnionOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two touching circles using subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractTextureFillUsingRGBTexture5(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingRGBTexture5(image, graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two touching circles using inverse subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractTextureFillUsingRGBTexture5(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingRGBTexture5(image, graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two touching circles using Intersect operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testIntersectTextureFillUsingRGBTexture5(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingRGBTexture5(image, graphics2d); + // create area using Intersect operator + Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingIntersectOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two touching circles using Xor operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorTextureFillUsingRGBTexture5(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingRGBTexture5(image, graphics2d); + // create area using Xor operator + Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingXorOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two touching circles using union operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionTextureFillUsingRGBTexture6(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingRGBTexture6(image, graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingUnionOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two touching circles using subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractTextureFillUsingRGBTexture6(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingRGBTexture6(image, graphics2d); // create area using subtract operator Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingSubtractOperator(image); // draw the area From jvanek at icedtea.classpath.org Tue Sep 9 12:52:12 2014 From: jvanek at icedtea.classpath.org (jvanek at icedtea.classpath.org) Date: Tue, 09 Sep 2014 12:52:12 +0000 Subject: /hg/icedtea-web: Outdated documentation replaced by documentatio... Message-ID: changeset b0690979967f in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=b0690979967f author: Jiri Vanek date: Tue Sep 09 14:51:16 2014 +0200 Outdated documentation replaced by documentation generation diffstat: ChangeLog | 86 + Makefile.am | 66 +- netx/itweb-settings.1 | 90 - netx/javaws.1 | 149 -- netx/net/sourceforge/jnlp/OptionsDefinitions.java | 217 +++ netx/net/sourceforge/jnlp/about/AboutDialog.java | 173 +- netx/net/sourceforge/jnlp/about/HTMLPanel.java | 16 +- netx/net/sourceforge/jnlp/about/InternalHTMLPanel.java | 69 + netx/net/sourceforge/jnlp/config/Defaults.java | 84 +- netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java | 89 +- netx/net/sourceforge/jnlp/config/PathsAndFiles.java | 397 +++++ netx/net/sourceforge/jnlp/config/Setting.java | 7 + netx/net/sourceforge/jnlp/controlpanel/AboutPanel.java | 3 +- netx/net/sourceforge/jnlp/controlpanel/CommandLine.java | 59 +- netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java | 3 +- netx/net/sourceforge/jnlp/resources/Messages.properties | 53 +- netx/net/sourceforge/jnlp/resources/Messages_cs.properties | 18 +- netx/net/sourceforge/jnlp/resources/Messages_de.properties | 4 +- netx/net/sourceforge/jnlp/resources/Messages_pl.properties | 2 - netx/net/sourceforge/jnlp/resources/about.html | 44 - netx/net/sourceforge/jnlp/runtime/Boot.java | 97 +- netx/net/sourceforge/jnlp/security/appletextendedsecurity/ExtendedAppletSecurityHelp.java | 11 +- netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java | 74 +- netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditorAboutDialog.java | 3 +- netx/net/sourceforge/jnlp/splashscreen/impls/DefaultSplashScreens2012Commons.java | 3 +- netx/net/sourceforge/jnlp/splashscreen/parts/JEditorPaneBasedExceptionDialog.java | 7 +- netx/net/sourceforge/jnlp/util/docprovider/IcedTeaWebTextsProvider.java | 137 ++ netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java | 151 ++ netx/net/sourceforge/jnlp/util/docprovider/ItwebSettingsTextsProvider.java | 175 ++ netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java | 120 + netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java | 122 + netx/net/sourceforge/jnlp/util/docprovider/TextsProvider.java | 678 ++++++++++ netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/Formatter.java | 38 + netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/HtmlFormatter.java | 149 ++ netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/ManFormatter.java | 162 ++ netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/PlainTextFormatter.java | 168 ++ netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/ReplacingTextFormatter.java | 45 + netx/net/sourceforge/jnlp/util/logging/UnixSystemLog.java | 4 +- netx/policyeditor.1 | 85 - 39 files changed, 3184 insertions(+), 674 deletions(-) diffs (truncated from 4905 to 500 lines): diff -r 2979fa371add -r b0690979967f ChangeLog --- a/ChangeLog Tue Sep 02 11:46:09 2014 -0400 +++ b/ChangeLog Tue Sep 09 14:51:16 2014 +0200 @@ -1,3 +1,89 @@ +2014-09-09 Jiri Vanek + + Outdated documentation replaced by documentation generation + * Makefile.am: aded (DOCS_DIR) pointing to target directory for generated docs + (clean-local) and (.PHONY) now cleaning also clean-generated-docs + (install-data-local) removed usage of old man pages, copied all generated + man pages + (uninstall-local) added removal of javaws_splash.png, all known man pages cleaned + (stamps/generate-docs.stamp) new target, generates all known language mutations + of all known man pages to correct directories. + (stamps/netx-dist.stamp) depends on stamps/generate-docs.stamp + (clean-generated-docs) new target, removes DOCS_DIR and stamp + * netx/itweb-settings.1: removed + * netx/javaws.1: removed + * netx/policyeditor.1: removed + * netx/net/sourceforge/jnlp/OptionsDefinitions.java: new class, contains + definitions of all command-line arguments + * netx/net/sourceforge/jnlp/about/AboutDialog.java:improved to contains + window with generated localized help. Default welcome screen points to + localized mutation (if available). Loading of pages made lazy, and only + once per app. run. Added possibility to chose start page. + * netx/net/sourceforge/jnlp/about/HTMLPanel.java: get rid of useless id + * netx/net/sourceforge/jnlp/about/InternalHTMLPanel.java: extension of + HTMLPanel, links are pointing to internal window (in HTMLPanel points to + external browser) + * netx/net/sourceforge/jnlp/config/Defaults.java: All files declarations + moved to PathsAndFiles. Defaults array now uses those. Iteration in + defaults now done by iterator. + * netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: All files + declarations moved to PathsAndFiles. Configuration now uses those. + * netx/net/sourceforge/jnlp/config/PathsAndFiles.java: New file. Gathers + all files declared in ITW. + * netx/net/sourceforge/jnlp/config/Setting.java: added human readable toString + * netx/net/sourceforge/jnlp/controlpanel/AboutPanel.java: set origin - + itweb-settings. + * netx/net/sourceforge/jnlp/controlpanel/CommandLine.java: options now uses + OptionsDefinitions and runtime help now uses TextsProvider's instances. + * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: uses PathsAndFiles + * netx/net/sourceforge/jnlp/resources/Messages.properties: BOUsage and BOUsage2 + stripped for javaws keyword. Added (BOTrustnone), added IBO and PBO and man + families. Removed PEUsage PEHelpFlag PEFileFlag PECodebaseFlag, PEAboutDialogTitle + PEAboutDialogContent CLHelpDescription SPLASHurl SPLASHurlLooks. All urls replaced by variables. + * netx/net/sourceforge/jnlp/resources/Messages_cs.properties: fixed BAboutITW,rmeove + * netx/net/sourceforge/jnlp/resources/Messages_de.properties: same + * netx/net/sourceforge/jnlp/resources/Messages_pl.properties: same + * netx/net/sourceforge/jnlp/resources/about.html: removed. replaced by generated, + and localized one. + * netx/net/sourceforge/jnlp/runtime/Boot.java: Handling of verbose moved to + be one of first switches. All runtime helps moved to TextsProvider's instances. + * netx/net/sourceforge/jnlp/security/appletextendedsecurity/ExtendedAppletSecurityHelp.java: + added parameter so (R). + * netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java: All runtime + helps moved to TextsProvider's instances. About policy editor replaced by About.help + Modlaity of About dialog recognized on state of underlying dialogue. Added + About icedtea-web menu entry. + * netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditorAboutDialog.java: + removed unused (title) + * netx/net/sourceforge/jnlp/splashscreen/impls/DefaultSplashScreens2012Commons.java: + AboutDialog displayed with reason + * netx/net/sourceforge/jnlp/splashscreen/parts/JEditorPaneBasedExceptionDialog.java: + Links here replaced by TextsProviders constants. + * netx/net/sourceforge/jnlp/util/docprovider/IcedTeaWebTextsProvider.java: + implementation of TextsProvider for icedtea-web package + * netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java: + implementation of TextsProvider for plugin + * netx/net/sourceforge/jnlp/util/docprovider/ItwebSettingsTextsProvider.java + implementation of TextsProvider for itweb-settings + * netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java + implementation of TextsProvider for javaws + * netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java + implementation of TextsProvider for policy editor + * netx/net/sourceforge/jnlp/util/docprovider/TextsProvider.java: + New abstract class to handle basic operations on texts and defining abstract methods. + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/Formatter.java + Definition interface for any Formatter used by TextsProvider + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/HtmlFormatter.java + html markup adding Formatter + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/ManFormatter.java + man pages markup adding Formatter + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/PlainTextFormatter.java + no markup adding Formatter + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/ReplacingTextFormatter.java + Stub for all formatters needing text substituitons. + * netx/net/sourceforge/jnlp/util/logging/UnixSystemLog.java: + Links here replaced by TextsProviders constants. + 2014-09-02 Jie Kang Fixed CacheUtils clearCache method to also clear the Least Recently Used diff -r 2979fa371add -r b0690979967f Makefile.am --- a/Makefile.am Tue Sep 02 11:46:09 2014 -0400 +++ b/Makefile.am Tue Sep 09 14:51:16 2014 +0200 @@ -3,6 +3,7 @@ export TOP_BUILD_DIR = $(abs_top_builddir) export NETX_DIR = $(abs_top_builddir)/netx.build +export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs export NETX_SRCDIR = $(abs_top_srcdir)/netx export NETX_RESOURCE_DIR=$(NETX_SRCDIR)/net/sourceforge/jnlp/resources @@ -232,13 +233,13 @@ check-local: $(RHINO_TESTS) $(JUNIT_TESTS) clean-local: clean-netx clean-plugin clean-liveconnect \ - clean-native-ecj clean-launchers clean-desktop-files clean-docs clean-tests clean-bootstrap-directory + clean-native-ecj clean-launchers clean-desktop-files clean-docs clean-generated-docs clean-tests clean-bootstrap-directory if [ -e stamps ] ; then \ rmdir stamps ; \ fi .PHONY: clean-IcedTeaPlugin clean-add-netx clean-add-netx-debug clean-add-plugin clean-add-plugin-debug \ - clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs \ + clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs clean-generated-docs \ clean-tests check-local clean-launchers stamps/check-pac-functions.stamp stamps/run-netx-unit-tests.stamp clean-netx-tests \ clean-junit-runner clean-netx-unit-tests @@ -254,11 +255,10 @@ ${INSTALL_PROGRAM} launcher.build/$(itweb_settings) $(DESTDIR)$(bindir) ${INSTALL_PROGRAM} launcher.build/$(policyeditor) $(DESTDIR)$(bindir) +# all generated manpages are installed in swarm install-data-local: - ${mkinstalldirs} -d $(DESTDIR)$(mandir)/man1 - ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(mandir)/man1 - ${INSTALL_DATA} $(NETX_SRCDIR)/itweb-settings.1 $(DESTDIR)$(mandir)/man1 - ${INSTALL_DATA} $(NETX_SRCDIR)/policyeditor.1 $(DESTDIR)$(mandir)/man1 + ${mkinstalldirs} -d $(DESTDIR)$(mandir) + cp -r $(DOCS_DIR)/man-$(FULL_VERSION)/man/* $(DESTDIR)$(mandir)/ if ENABLE_DOCS ${mkinstalldirs} $(DESTDIR)$(htmldir) (cd ${abs_top_builddir}/docs/netx; \ @@ -275,13 +275,19 @@ endif endif +# all generated manpages must be removed one by one uninstall-local: rm -f $(DESTDIR)$(libdir)/$(BUILT_PLUGIN_LIBRARY) rm -f $(DESTDIR)$(datadir)/$(PACKAGE_NAME)/plugin.jar rm -f $(DESTDIR)$(datadir)/$(PACKAGE_NAME)/netx.jar - rm -f $(DESTDIR)$(mandir)/man1/javaws.1 - rm -f $(DESTDIR)$(mandir)/man1/itweb-settings.1 - rm -f $(DESTDIR)$(mandir)/man1/policyeditor.1 + rm -r $(DESTDIR)$(datadir)/$(PACKAGE_NAME)/javaws_splash.png + KNOWN_MANS="icedtea-web.1 icedtea-web-plugin.1 itweb-settings.1 javaws.1 policyeditor.1" ; \ + KNOWN_DIRS="man1 de/man1 pl/man1 cs/man1" ; \ + for file in $$KNOWN_MANS ; do \ + for dir in $$KNOWN_DIRS ; do \ + rm -f $(DESTDIR)$(mandir)/$$dir/$$file ; \ + done ; \ + done rm -f $(DESTDIR)$(bindir)/$(javaws) rm -f $(DESTDIR)$(bindir)/$(itweb_settings) rm -f $(DESTDIR)$(bindir)/$(policyeditor) @@ -467,6 +473,42 @@ sed -i '/RhinoBasedPacEvaluator/ d' $@ endif +stamps/generate-docs.stamp: stamps/netx.stamp + mkdir $(DOCS_DIR) ; \ + HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html-$(FULL_VERSION) ; \ + PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain-$(FULL_VERSION) ; \ + MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man-$(FULL_VERSION)/man ; \ + mkdir $$HTML_DOCS_TARGET_DIR ; \ + mkdir $$PLAIN_DOCS_TARGET_DIR ; \ + mkdir -p $$MAN_DOCS_TARGET_DIR ; \ + HTML_DOCS_INDEX=$$HTML_DOCS_TARGET_DIR/index.html ; \ + TP_COMMAND="$(BOOT_DIR)/bin/java -cp $(NETX_DIR) net.sourceforge.jnlp.util.docprovider.TextsProvider" ; \ + TP_TAIL="false $(FULL_VERSION)" ; \ + LANG_BACKUP=$$LANG ; \ + echo "$(PLUGIN_VERSION)" > $$HTML_DOCS_INDEX ; \ + echo "

$(PLUGIN_VERSION) docs:

" >> $$HTML_DOCS_INDEX ; \ + for LANG_ID in en_US.UTF-8 cs_CZ.UTF-8 pl_PL.UTF-8 de_DE.UTF-8 ; do \ + ID=`echo "$$LANG_ID" | head -c 2` ; \ + ENCOD=`echo "$$LANG_ID" | tail -c 6` ; \ + export LANG=$$LANG_ID; \ + mkdir $$HTML_DOCS_TARGET_DIR/$$ID ; \ + echo "
  • $$LANG_ID
  • " >> $$HTML_DOCS_INDEX ; \ + $$TP_COMMAND html $$HTML_DOCS_TARGET_DIR/$$ID false $TP_TAIL ; \ + mkdir $$PLAIN_DOCS_TARGET_DIR/$$ID ; \ + $$TP_COMMAND plain $$PLAIN_DOCS_TARGET_DIR/$$ID 160 false $TP_TAIL; \ + if [ $$ID == "en" ] ; then \ + MAN_DESC=$$MAN_DOCS_TARGET_DIR/man1 ; \ + else \ + MAN_DESC=$$MAN_DOCS_TARGET_DIR/$$ID/man1 ; \ + fi ; \ + mkdir -p $$MAN_DESC ; \ + $$TP_COMMAND man $$ENCOD $$MAN_DESC $$TP_TAIL ; \ + $$TP_COMMAND htmlIntro $(NETX_DIR)/net/sourceforge/jnlp/resources/about_$$ID.html $$TP_TAIL; \ + done ; \ + export LANG=$$LANG_BACKUP ; \ + echo "" >> $$HTML_DOCS_INDEX ; \ + touch $@ + stamps/netx-html-gen.stamp: (cd $$NETX_SRCDIR/..; \ mkdir -p html-gen; \ @@ -499,7 +541,7 @@ mkdir -p stamps touch $@ -stamps/netx-dist.stamp: stamps/netx.stamp $(abs_top_builddir)/netx.manifest +stamps/netx-dist.stamp: stamps/netx.stamp $(abs_top_builddir)/netx.manifest stamps/generate-docs.stamp (cd $(NETX_DIR) ; \ mkdir -p lib ; \ $(BOOT_DIR)/bin/jar cfm lib/classes.jar \ @@ -608,6 +650,10 @@ rm -rf ${abs_top_builddir}/docs/plugin rm -f stamps/plugin-docs.stamp +clean-generated-docs: + rm -rf $(DOCS_DIR) + rm -f stamps/generate-docs.stamp + # check # ========================== diff -r 2979fa371add -r b0690979967f netx/itweb-settings.1 --- a/netx/itweb-settings.1 Tue Sep 02 11:46:09 2014 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,90 +0,0 @@ -.TH itweb-settings 1 "07 Mar 2014" - -.SH NAME - -itweb-settings - view and modify settings for -.B -javaws -and the browser plugin - -.SH SYNOPSIS - -.B itweb-settings -.br -.B itweb-settings -command arguments -.SH DESCRIPTION -.B itweb-settings -is a command line and a GUI program to modify and edit settings used by the -icedtea-web implementation of -.B javaws -and the browser plugin. - -If executed without any arguments, it starts up a GUI. Otherwise, it tries to -do what is specified in the argument. - -The command-line allows quickly searching, making a copy of and modifying -specific settings without having to hunt through a UI. - - -.SH COMMANDS - -.TP -help -Prints out information about supported command, descriptions and basic usage. -.TP 12 -list -Shows a list of all settings. -.TP -get -Shows the value of the named setting. -.TP -info -Shows additional information about the named setting. Includes a description, -the current value, the possible values, and the source of the setting. -.TP -set -Sets the setting to the new value, after checking that it is an appropriate -value. -.TP -reset all -Resets all settings to their original values. -.TP -reset -Resets the named setting to its original value. -.TP -check -Checks that the current value of the setting is a valid value. - -.SH EXAMPLES - -.TP -itweb-settings - -Show the GUI editor - -.TP -itweb-settings reset deployment.proxy.type - -Resets the value of 'deployment.proxy.type' setting. - - -.SH FILES - -$XDG_CONFIG_HOME/icedtea-web/deployment.properties specifies the settings used - -.SH BUGS - -There arent any known bugs. If you come across one, please file it at - http://icedtea.classpath.org/bugzilla/ - -.SH AUTHOR - -Written and maintained by the IcedTea contributors. - -.SH SEE ALSO - -.BR javaws (1), -.BR java (1) -.br -http://icedtea.classpath.org/wiki/IcedTea-Web diff -r 2979fa371add -r b0690979967f netx/javaws.1 --- a/netx/javaws.1 Tue Sep 02 11:46:09 2014 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,149 +0,0 @@ -.TH javaws 1 "9 Sep 2010" -.SH NAME -javaws - a Java Web Start client -.SH SYNOPSIS -.B javaws -[-run-options] jnlp-file -.br -.B javaws -[-control-option] -.SH DESCRIPTION -.B javaws -is an implementation of a JNLP client. It uses a JNLP (Java Network -Launch Protocol) file to securely run a remote Java application or -a Java applet. This implementation of -.B javaws -is from the IcedTea project and is based on the NetX project. -.PP -A JNLP file is an xml file that describes how to securely run a -remote Java application or a Java applet. - -.SH OPTIONS -When specifying options, the name of the jnlp file must be the last -argument to -.B javaws -- all the options must preceede it. -.PP -The jnlp-file can either be a url or a local path. -.PP -.B Control Options -.PP -By default -.B javaws -will launch the jnlp file specified on the command line. The control -options can be used to change this behaviour. -.TP 12 -\-about -Shows about dialog. -.TP -\-viewer -Shows the trusted certificate viewer. This allows a user to list, examine, remove -or export trusted certificates. Note that this only reflects the certificates -trusted by -.B javaws -and not any other certificates or programs. - -.PP -.B Run Options -.PP -In the default mode, the following run-options can be used: -.TP 12 -\-version -Prints out version and exit -.TP -\-arg arg -Adds an application argument before launching. -.TP -\-param name=value -Adds an applet parameter before launching. -.TP -\-property name=value -Sets a system property before launching. -.TP -\-update seconds -Update check if seconds since last checked. -.TP -\-license -Display the GPL license and exit. -.TP -\-verbose -Enable verbose output. Very useful in debugging. -.TP -\-nosecurity -Disables the secure runtime environment. -.TP -\-noupdate -Disables checking for updates. -.TP -\-headless -Disables download window, other UIs. -.TP -\-strict -Enables strict checking of JNLP file format. Any deviations from -the JNLP DTD will cause -.B javaws -to abort. -.TP -\-xml -The jnlp files will be checked more strictly for XML validity -.TP -\-allowredirect -Allow to follow 301, 302, 303, 307 and 308 redirections for javaws -applications -.TP -\-Xnofork -Do not create another JVM, even if the JNLP file asks for running in -a separate JVM. This is useful for debugging. -.TP -\-Xclearcache -Clean the JNLP application cache. -.TP -\-Xignoreheaders -Skip jar header verification. -.TP -\-Jjava-option -This passes along java-option to the java binary that is running -javaws. For example, to make javaws run with a max heap size -of 80m, use -J-Xmx80m. -.TP -\-help -Print a help message and exit. - -.SH FILES -$XDG_CONFIG_DIR/icedtea-web/deployment.properties specifies the settings used by javaws - -$XDG_CONFIG_DIR/icedtea-web/log (may be set to different location by you) contains file log files (if enabled). -itw-cplugin-date_time.log for native part of plugin, itw-javantx-date_time.log for everything else. - -$XDG_CONFIG_DIR/icedtea-web/security/java.policy contains granted permissions for selected unsigned apps - -$XDG_CONFIG_DIR/icedtea-web/security/trusted.*certs contains various stored certificates - -$XDG_CACHE_DIR/icedtea-web/cache contains cached runtime entries (amy be changed by you) - -$XDG_CACHE_DIR/icedtea-web/pcache contains saved application data - -$XDG_CACHE_DIR/icedtea-web/tmp contains temporary runtime files - -$XDG_RUNTIME_DIR/icedteaplugin-user-*/ contains in and out pipe for native<->java communication and -(if enabled) debugging pipe - -Where $XDG_CONFIG_DIR, $XDG_CACHE_DIR and $XDG_RUNTIME_DIR are set as ~/.config, ~/.cache and /tmp or /var/tmp if not set. - -.SH BUGS -There arent any known bugs. If you come across one, please file it at - http://icedtea.classpath.org/bugzilla/ -.br -Please run javaws in debug (-verbose switch or itw-settings setting or ICEDTEAPLUGIN_DEBUG variable set to true) -mode and include that output (best is from java console) with URL to jnlp or html file -(ot the jnlp/html file or application itself) when filing out the bug report. - -.SH AUTHOR -Originally written by Jon. A. Maxwell. -.br -Currently maintained by the IcedTea contributors. See javaws -about for more info - -.SH SEE ALSO -.BR java (1) -.br -http://icedtea.classpath.org/wiki/IcedTea-Web diff -r 2979fa371add -r b0690979967f netx/net/sourceforge/jnlp/OptionsDefinitions.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Tue Sep 09 14:51:16 2014 +0200 @@ -0,0 +1,217 @@ +/* + Copyright (C) 2008 Red Hat, Inc. + +This file is part of IcedTea. + +IcedTea is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License as published by +the Free Software Foundation, version 2. + +IcedTea is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with IcedTea; see the file COPYING. If not, write to +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +Linking this library statically or dynamically with other modules is +making a combined work based on this library. Thus, the terms and +conditions of the GNU General Public License cover the whole +combination. + +As a special exception, the copyright holders of this library give you +permission to link this library with independent modules to produce an +executable, regardless of the license terms of these independent +modules, and to copy and distribute the resulting executable under From jkang at redhat.com Tue Sep 9 13:08:11 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 9 Sep 2014 09:08:11 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <540E74AA.6010902@gmx.de> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> <540E74AA.6010902@gmx.de> Message-ID: <1477325712.2191320.1410268091407.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/08/2014 08:38 PM, Lukasz Dracz wrote: > >> As well, the ability to choose where icedtea-web downloads file should > >> still > >> be enabled even if cache has a limit of 0. > > > > Yes since it still downloads the files even if they are deleted after use. > > This provides the user with more choice on where they want the files to be > > temporarily. > > No, the UI components to choose a cache location should be kept disabled in > this > case indeed. 0 means *no* *cache*. Hence, IcedTea-Web should behave as > expected > which would be to store all downloaded resources in memory and if, and only > if, I disagree with disabling the cache location until this feature is implemented, or the feature for storing in a temporary directory is implemented > it should turn out to be impossible to implement proper working of > IcedTea-Web > without storing resources into files then they should be stored in the system > configured user's temporary directory. In other words, if cache size is 0 > then > downloaded resources /could/ go into the user's temporary directory, although > this should practically never happen because IcedTea-Web should error out > with > an OutOfMemoryException before anything else in this case. > Also, the UI components denoting the cache location /could/ display the path > to > the user's temporary directory if cache size is 0. > So in any event the UI components must be disabled at cache size 0. Regards, > > Jacob > -- Jie Kang From gitne at gmx.de Tue Sep 9 13:38:33 2014 From: gitne at gmx.de (Jacob Wisor) Date: Tue, 09 Sep 2014 15:38:33 +0200 Subject: /hg/icedtea-web: Outdated documentation replaced by documentatio... In-Reply-To: References: Message-ID: <540F02D9.8090001@gmx.de> On 09/09/2014 02:52 PM, jvanek at icedtea.classpath.org wrote: > changeset b0690979967f in /hg/icedtea-web > details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=b0690979967f > author: Jiri Vanek > date: Tue Sep 09 14:51:16 2014 +0200 > > Outdated documentation replaced by documentation generation > > > diffstat: > > ChangeLog | 86 + > Makefile.am | 66 +- > netx/itweb-settings.1 | 90 - > netx/javaws.1 | 149 -- > netx/net/sourceforge/jnlp/OptionsDefinitions.java | 217 +++ > netx/net/sourceforge/jnlp/about/AboutDialog.java | 173 +- > netx/net/sourceforge/jnlp/about/HTMLPanel.java | 16 +- > netx/net/sourceforge/jnlp/about/InternalHTMLPanel.java | 69 + > netx/net/sourceforge/jnlp/config/Defaults.java | 84 +- > netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java | 89 +- > netx/net/sourceforge/jnlp/config/PathsAndFiles.java | 397 +++++ > netx/net/sourceforge/jnlp/config/Setting.java | 7 + > netx/net/sourceforge/jnlp/controlpanel/AboutPanel.java | 3 +- > netx/net/sourceforge/jnlp/controlpanel/CommandLine.java | 59 +- > netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java | 3 +- > netx/net/sourceforge/jnlp/resources/Messages.properties | 53 +- > netx/net/sourceforge/jnlp/resources/Messages_cs.properties | 18 +- > netx/net/sourceforge/jnlp/resources/Messages_de.properties | 4 +- > netx/net/sourceforge/jnlp/resources/Messages_pl.properties | 2 - > netx/net/sourceforge/jnlp/resources/about.html | 44 - > netx/net/sourceforge/jnlp/runtime/Boot.java | 97 +- > netx/net/sourceforge/jnlp/security/appletextendedsecurity/ExtendedAppletSecurityHelp.java | 11 +- > netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java | 74 +- > netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditorAboutDialog.java | 3 +- > netx/net/sourceforge/jnlp/splashscreen/impls/DefaultSplashScreens2012Commons.java | 3 +- > netx/net/sourceforge/jnlp/splashscreen/parts/JEditorPaneBasedExceptionDialog.java | 7 +- > netx/net/sourceforge/jnlp/util/docprovider/IcedTeaWebTextsProvider.java | 137 ++ > netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java | 151 ++ > netx/net/sourceforge/jnlp/util/docprovider/ItwebSettingsTextsProvider.java | 175 ++ > netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java | 120 + > netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java | 122 + > netx/net/sourceforge/jnlp/util/docprovider/TextsProvider.java | 678 ++++++++++ > netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/Formatter.java | 38 + > netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/HtmlFormatter.java | 149 ++ > netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/ManFormatter.java | 162 ++ > netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/PlainTextFormatter.java | 168 ++ > netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/ReplacingTextFormatter.java | 45 + > netx/net/sourceforge/jnlp/util/logging/UnixSystemLog.java | 4 +- > netx/policyeditor.1 | 85 - > 39 files changed, 3184 insertions(+), 674 deletions(-) > > diffs (truncated from 4905 to 500 lines): > > diff -r 2979fa371add -r b0690979967f ChangeLog > --- a/ChangeLog Tue Sep 02 11:46:09 2014 -0400 > +++ b/ChangeLog Tue Sep 09 14:51:16 2014 +0200 > @@ -1,3 +1,89 @@ > +2014-09-09 Jiri Vanek > + > + Outdated documentation replaced by documentation generation > + * Makefile.am: aded (DOCS_DIR) pointing to target directory for generated docs > + (clean-local) and (.PHONY) now cleaning also clean-generated-docs > + (install-data-local) removed usage of old man pages, copied all generated > + man pages > + (uninstall-local) added removal of javaws_splash.png, all known man pages cleaned > + (stamps/generate-docs.stamp) new target, generates all known language mutations > + of all known man pages to correct directories. > + (stamps/netx-dist.stamp) depends on stamps/generate-docs.stamp > + (clean-generated-docs) new target, removes DOCS_DIR and stamp > + * netx/itweb-settings.1: removed > + * netx/javaws.1: removed > + * netx/policyeditor.1: removed > + * netx/net/sourceforge/jnlp/OptionsDefinitions.java: new class, contains > + definitions of all command-line arguments > + * netx/net/sourceforge/jnlp/about/AboutDialog.java:improved to contains > + window with generated localized help. Default welcome screen points to > + localized mutation (if available). Loading of pages made lazy, and only > + once per app. run. Added possibility to chose start page. > + * netx/net/sourceforge/jnlp/about/HTMLPanel.java: get rid of useless id > + * netx/net/sourceforge/jnlp/about/InternalHTMLPanel.java: extension of > + HTMLPanel, links are pointing to internal window (in HTMLPanel points to > + external browser) > + * netx/net/sourceforge/jnlp/config/Defaults.java: All files declarations > + moved to PathsAndFiles. Defaults array now uses those. Iteration in > + defaults now done by iterator. > + * netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: All files > + declarations moved to PathsAndFiles. Configuration now uses those. > + * netx/net/sourceforge/jnlp/config/PathsAndFiles.java: New file. Gathers > + all files declared in ITW. > + * netx/net/sourceforge/jnlp/config/Setting.java: added human readable toString > + * netx/net/sourceforge/jnlp/controlpanel/AboutPanel.java: set origin - > + itweb-settings. > + * netx/net/sourceforge/jnlp/controlpanel/CommandLine.java: options now uses > + OptionsDefinitions and runtime help now uses TextsProvider's instances. > + * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: uses PathsAndFiles > + * netx/net/sourceforge/jnlp/resources/Messages.properties: BOUsage and BOUsage2 > + stripped for javaws keyword. Added (BOTrustnone), added IBO and PBO and man > + families. Removed PEUsage PEHelpFlag PEFileFlag PECodebaseFlag, PEAboutDialogTitle > + PEAboutDialogContent CLHelpDescription SPLASHurl SPLASHurlLooks. All urls replaced by variables. > + * netx/net/sourceforge/jnlp/resources/Messages_cs.properties: fixed BAboutITW,rmeove > + * netx/net/sourceforge/jnlp/resources/Messages_de.properties: same > + * netx/net/sourceforge/jnlp/resources/Messages_pl.properties: same > + * netx/net/sourceforge/jnlp/resources/about.html: removed. replaced by generated, > + and localized one. > + * netx/net/sourceforge/jnlp/runtime/Boot.java: Handling of verbose moved to > + be one of first switches. All runtime helps moved to TextsProvider's instances. > + * netx/net/sourceforge/jnlp/security/appletextendedsecurity/ExtendedAppletSecurityHelp.java: > + added parameter so (R). > + * netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditor.java: All runtime > + helps moved to TextsProvider's instances. About policy editor replaced by About.help > + Modlaity of About dialog recognized on state of underlying dialogue. Added > + About icedtea-web menu entry. > + * netx/net/sourceforge/jnlp/security/policyeditor/PolicyEditorAboutDialog.java: > + removed unused (title) > + * netx/net/sourceforge/jnlp/splashscreen/impls/DefaultSplashScreens2012Commons.java: > + AboutDialog displayed with reason > + * netx/net/sourceforge/jnlp/splashscreen/parts/JEditorPaneBasedExceptionDialog.java: > + Links here replaced by TextsProviders constants. > + * netx/net/sourceforge/jnlp/util/docprovider/IcedTeaWebTextsProvider.java: > + implementation of TextsProvider for icedtea-web package > + * netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java: > + implementation of TextsProvider for plugin > + * netx/net/sourceforge/jnlp/util/docprovider/ItwebSettingsTextsProvider.java > + implementation of TextsProvider for itweb-settings > + * netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java > + implementation of TextsProvider for javaws > + * netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java > + implementation of TextsProvider for policy editor > + * netx/net/sourceforge/jnlp/util/docprovider/TextsProvider.java: > + New abstract class to handle basic operations on texts and defining abstract methods. > + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/Formatter.java > + Definition interface for any Formatter used by TextsProvider > + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/HtmlFormatter.java > + html markup adding Formatter > + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/ManFormatter.java > + man pages markup adding Formatter > + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/PlainTextFormatter.java > + no markup adding Formatter > + * netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/ReplacingTextFormatter.java > + Stub for all formatters needing text substituitons. > + * netx/net/sourceforge/jnlp/util/logging/UnixSystemLog.java: > + Links here replaced by TextsProviders constants. > + > 2014-09-02 Jie Kang > > Fixed CacheUtils clearCache method to also clear the Least Recently Used > diff -r 2979fa371add -r b0690979967f Makefile.am > --- a/Makefile.am Tue Sep 02 11:46:09 2014 -0400 > +++ b/Makefile.am Tue Sep 09 14:51:16 2014 +0200 > @@ -3,6 +3,7 @@ > export TOP_BUILD_DIR = $(abs_top_builddir) > > export NETX_DIR = $(abs_top_builddir)/netx.build > +export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs > export NETX_SRCDIR = $(abs_top_srcdir)/netx > export NETX_RESOURCE_DIR=$(NETX_SRCDIR)/net/sourceforge/jnlp/resources > > @@ -232,13 +233,13 @@ > check-local: $(RHINO_TESTS) $(JUNIT_TESTS) > > clean-local: clean-netx clean-plugin clean-liveconnect \ > - clean-native-ecj clean-launchers clean-desktop-files clean-docs clean-tests clean-bootstrap-directory > + clean-native-ecj clean-launchers clean-desktop-files clean-docs clean-generated-docs clean-tests clean-bootstrap-directory > if [ -e stamps ] ; then \ > rmdir stamps ; \ > fi > > .PHONY: clean-IcedTeaPlugin clean-add-netx clean-add-netx-debug clean-add-plugin clean-add-plugin-debug \ > - clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs \ > + clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs clean-generated-docs \ > clean-tests check-local clean-launchers stamps/check-pac-functions.stamp stamps/run-netx-unit-tests.stamp clean-netx-tests \ > clean-junit-runner clean-netx-unit-tests > > @@ -254,11 +255,10 @@ > ${INSTALL_PROGRAM} launcher.build/$(itweb_settings) $(DESTDIR)$(bindir) > ${INSTALL_PROGRAM} launcher.build/$(policyeditor) $(DESTDIR)$(bindir) > > +# all generated manpages are installed in swarm > install-data-local: > - ${mkinstalldirs} -d $(DESTDIR)$(mandir)/man1 > - ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(mandir)/man1 > - ${INSTALL_DATA} $(NETX_SRCDIR)/itweb-settings.1 $(DESTDIR)$(mandir)/man1 > - ${INSTALL_DATA} $(NETX_SRCDIR)/policyeditor.1 $(DESTDIR)$(mandir)/man1 > + ${mkinstalldirs} -d $(DESTDIR)$(mandir) > + cp -r $(DOCS_DIR)/man-$(FULL_VERSION)/man/* $(DESTDIR)$(mandir)/ > if ENABLE_DOCS > ${mkinstalldirs} $(DESTDIR)$(htmldir) > (cd ${abs_top_builddir}/docs/netx; \ > @@ -275,13 +275,19 @@ > endif > endif > > +# all generated manpages must be removed one by one > uninstall-local: > rm -f $(DESTDIR)$(libdir)/$(BUILT_PLUGIN_LIBRARY) > rm -f $(DESTDIR)$(datadir)/$(PACKAGE_NAME)/plugin.jar > rm -f $(DESTDIR)$(datadir)/$(PACKAGE_NAME)/netx.jar > - rm -f $(DESTDIR)$(mandir)/man1/javaws.1 > - rm -f $(DESTDIR)$(mandir)/man1/itweb-settings.1 > - rm -f $(DESTDIR)$(mandir)/man1/policyeditor.1 > + rm -r $(DESTDIR)$(datadir)/$(PACKAGE_NAME)/javaws_splash.png > + KNOWN_MANS="icedtea-web.1 icedtea-web-plugin.1 itweb-settings.1 javaws.1 policyeditor.1" ; \ > + KNOWN_DIRS="man1 de/man1 pl/man1 cs/man1" ; \ > + for file in $$KNOWN_MANS ; do \ > + for dir in $$KNOWN_DIRS ; do \ > + rm -f $(DESTDIR)$(mandir)/$$dir/$$file ; \ > + done ; \ > + done > rm -f $(DESTDIR)$(bindir)/$(javaws) > rm -f $(DESTDIR)$(bindir)/$(itweb_settings) > rm -f $(DESTDIR)$(bindir)/$(policyeditor) > @@ -467,6 +473,42 @@ > sed -i '/RhinoBasedPacEvaluator/ d' $@ > endif > > +stamps/generate-docs.stamp: stamps/netx.stamp > + mkdir $(DOCS_DIR) ; \ > + HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html-$(FULL_VERSION) ; \ > + PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain-$(FULL_VERSION) ; \ > + MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man-$(FULL_VERSION)/man ; \ > + mkdir $$HTML_DOCS_TARGET_DIR ; \ > + mkdir $$PLAIN_DOCS_TARGET_DIR ; \ > + mkdir -p $$MAN_DOCS_TARGET_DIR ; \ > + HTML_DOCS_INDEX=$$HTML_DOCS_TARGET_DIR/index.html ; \ > + TP_COMMAND="$(BOOT_DIR)/bin/java -cp $(NETX_DIR) net.sourceforge.jnlp.util.docprovider.TextsProvider" ; \ > + TP_TAIL="false $(FULL_VERSION)" ; \ > + LANG_BACKUP=$$LANG ; \ > + echo "$(PLUGIN_VERSION)" > $$HTML_DOCS_INDEX ; \ > + echo "

    $(PLUGIN_VERSION) docs:

    " >> $$HTML_DOCS_INDEX ; \ > + for LANG_ID in en_US.UTF-8 cs_CZ.UTF-8 pl_PL.UTF-8 de_DE.UTF-8 ; do \ > + ID=`echo "$$LANG_ID" | head -c 2` ; \ > + ENCOD=`echo "$$LANG_ID" | tail -c 6` ; \ > + export LANG=$$LANG_ID; \ > + mkdir $$HTML_DOCS_TARGET_DIR/$$ID ; \ > + echo "
  • $$LANG_ID
  • " >> $$HTML_DOCS_INDEX ; \ > + $$TP_COMMAND html $$HTML_DOCS_TARGET_DIR/$$ID false $TP_TAIL ; \ > + mkdir $$PLAIN_DOCS_TARGET_DIR/$$ID ; \ > + $$TP_COMMAND plain $$PLAIN_DOCS_TARGET_DIR/$$ID 160 false $TP_TAIL; \ > + if [ $$ID == "en" ] ; then \ > + MAN_DESC=$$MAN_DOCS_TARGET_DIR/man1 ; \ > + else \ > + MAN_DESC=$$MAN_DOCS_TARGET_DIR/$$ID/man1 ; \ > + fi ; \ > + mkdir -p $$MAN_DESC ; \ > + $$TP_COMMAND man $$ENCOD $$MAN_DESC $$TP_TAIL ; \ > + $$TP_COMMAND htmlIntro $(NETX_DIR)/net/sourceforge/jnlp/resources/about_$$ID.html $$TP_TAIL; \ > + done ; \ > + export LANG=$$LANG_BACKUP ; \ > + echo "" >> $$HTML_DOCS_INDEX ; \ > + touch $@ > + > stamps/netx-html-gen.stamp: > (cd $$NETX_SRCDIR/..; \ > mkdir -p html-gen; \ > @@ -499,7 +541,7 @@ > mkdir -p stamps > touch $@ > > -stamps/netx-dist.stamp: stamps/netx.stamp $(abs_top_builddir)/netx.manifest > +stamps/netx-dist.stamp: stamps/netx.stamp $(abs_top_builddir)/netx.manifest stamps/generate-docs.stamp > (cd $(NETX_DIR) ; \ > mkdir -p lib ; \ > $(BOOT_DIR)/bin/jar cfm lib/classes.jar \ > @@ -608,6 +650,10 @@ > rm -rf ${abs_top_builddir}/docs/plugin > rm -f stamps/plugin-docs.stamp > > +clean-generated-docs: > + rm -rf $(DOCS_DIR) > + rm -f stamps/generate-docs.stamp > + > > # check > # ========================== > diff -r 2979fa371add -r b0690979967f netx/itweb-settings.1 > --- a/netx/itweb-settings.1 Tue Sep 02 11:46:09 2014 -0400 > +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 > @@ -1,90 +0,0 @@ > -.TH itweb-settings 1 "07 Mar 2014" > - > -.SH NAME > - > -itweb-settings - view and modify settings for > -.B > -javaws > -and the browser plugin > - > -.SH SYNOPSIS > - > -.B itweb-settings > -.br > -.B itweb-settings > -command arguments > -.SH DESCRIPTION > -.B itweb-settings > -is a command line and a GUI program to modify and edit settings used by the > -icedtea-web implementation of > -.B javaws > -and the browser plugin. > - > -If executed without any arguments, it starts up a GUI. Otherwise, it tries to > -do what is specified in the argument. > - > -The command-line allows quickly searching, making a copy of and modifying > -specific settings without having to hunt through a UI. > - > - > -.SH COMMANDS > - > -.TP > -help > -Prints out information about supported command, descriptions and basic usage. > -.TP 12 > -list > -Shows a list of all settings. > -.TP > -get > -Shows the value of the named setting. > -.TP > -info > -Shows additional information about the named setting. Includes a description, > -the current value, the possible values, and the source of the setting. > -.TP > -set > -Sets the setting to the new value, after checking that it is an appropriate > -value. > -.TP > -reset all > -Resets all settings to their original values. > -.TP > -reset > -Resets the named setting to its original value. > -.TP > -check > -Checks that the current value of the setting is a valid value. > - > -.SH EXAMPLES > - > -.TP > -itweb-settings > - > -Show the GUI editor > - > -.TP > -itweb-settings reset deployment.proxy.type > - > -Resets the value of 'deployment.proxy.type' setting. > - > - > -.SH FILES > - > -$XDG_CONFIG_HOME/icedtea-web/deployment.properties specifies the settings used > - > -.SH BUGS > - > -There arent any known bugs. If you come across one, please file it at > - http://icedtea.classpath.org/bugzilla/ > - > -.SH AUTHOR > - > -Written and maintained by the IcedTea contributors. > - > -.SH SEE ALSO > - > -.BR javaws (1), > -.BR java (1) > -.br > -http://icedtea.classpath.org/wiki/IcedTea-Web > diff -r 2979fa371add -r b0690979967f netx/javaws.1 > --- a/netx/javaws.1 Tue Sep 02 11:46:09 2014 -0400 > +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 > @@ -1,149 +0,0 @@ > -.TH javaws 1 "9 Sep 2010" > -.SH NAME > -javaws - a Java Web Start client > -.SH SYNOPSIS > -.B javaws > -[-run-options] jnlp-file > -.br > -.B javaws > -[-control-option] > -.SH DESCRIPTION > -.B javaws > -is an implementation of a JNLP client. It uses a JNLP (Java Network > -Launch Protocol) file to securely run a remote Java application or > -a Java applet. This implementation of > -.B javaws > -is from the IcedTea project and is based on the NetX project. > -.PP > -A JNLP file is an xml file that describes how to securely run a > -remote Java application or a Java applet. > - > -.SH OPTIONS > -When specifying options, the name of the jnlp file must be the last > -argument to > -.B javaws > -- all the options must preceede it. > -.PP > -The jnlp-file can either be a url or a local path. > -.PP > -.B Control Options > -.PP > -By default > -.B javaws > -will launch the jnlp file specified on the command line. The control > -options can be used to change this behaviour. > -.TP 12 > -\-about > -Shows about dialog. > -.TP > -\-viewer > -Shows the trusted certificate viewer. This allows a user to list, examine, remove > -or export trusted certificates. Note that this only reflects the certificates > -trusted by > -.B javaws > -and not any other certificates or programs. > - > -.PP > -.B Run Options > -.PP > -In the default mode, the following run-options can be used: > -.TP 12 > -\-version > -Prints out version and exit > -.TP > -\-arg arg > -Adds an application argument before launching. > -.TP > -\-param name=value > -Adds an applet parameter before launching. > -.TP > -\-property name=value > -Sets a system property before launching. > -.TP > -\-update seconds > -Update check if seconds since last checked. > -.TP > -\-license > -Display the GPL license and exit. > -.TP > -\-verbose > -Enable verbose output. Very useful in debugging. > -.TP > -\-nosecurity > -Disables the secure runtime environment. > -.TP > -\-noupdate > -Disables checking for updates. > -.TP > -\-headless > -Disables download window, other UIs. > -.TP > -\-strict > -Enables strict checking of JNLP file format. Any deviations from > -the JNLP DTD will cause > -.B javaws > -to abort. > -.TP > -\-xml > -The jnlp files will be checked more strictly for XML validity > -.TP > -\-allowredirect > -Allow to follow 301, 302, 303, 307 and 308 redirections for javaws > -applications > -.TP > -\-Xnofork > -Do not create another JVM, even if the JNLP file asks for running in > -a separate JVM. This is useful for debugging. > -.TP > -\-Xclearcache > -Clean the JNLP application cache. > -.TP > -\-Xignoreheaders > -Skip jar header verification. > -.TP > -\-Jjava-option > -This passes along java-option to the java binary that is running > -javaws. For example, to make javaws run with a max heap size > -of 80m, use -J-Xmx80m. > -.TP > -\-help > -Print a help message and exit. > - > -.SH FILES > -$XDG_CONFIG_DIR/icedtea-web/deployment.properties specifies the settings used by javaws > - > -$XDG_CONFIG_DIR/icedtea-web/log (may be set to different location by you) contains file log files (if enabled). > -itw-cplugin-date_time.log for native part of plugin, itw-javantx-date_time.log for everything else. > - > -$XDG_CONFIG_DIR/icedtea-web/security/java.policy contains granted permissions for selected unsigned apps > - > -$XDG_CONFIG_DIR/icedtea-web/security/trusted.*certs contains various stored certificates > - > -$XDG_CACHE_DIR/icedtea-web/cache contains cached runtime entries (amy be changed by you) > - > -$XDG_CACHE_DIR/icedtea-web/pcache contains saved application data > - > -$XDG_CACHE_DIR/icedtea-web/tmp contains temporary runtime files > - > -$XDG_RUNTIME_DIR/icedteaplugin-user-*/ contains in and out pipe for native<->java communication and > -(if enabled) debugging pipe > - > -Where $XDG_CONFIG_DIR, $XDG_CACHE_DIR and $XDG_RUNTIME_DIR are set as ~/.config, ~/.cache and /tmp or /var/tmp if not set. > - > -.SH BUGS > -There arent any known bugs. If you come across one, please file it at > - http://icedtea.classpath.org/bugzilla/ > -.br > -Please run javaws in debug (-verbose switch or itw-settings setting or ICEDTEAPLUGIN_DEBUG variable set to true) > -mode and include that output (best is from java console) with URL to jnlp or html file > -(ot the jnlp/html file or application itself) when filing out the bug report. > - > -.SH AUTHOR > -Originally written by Jon. A. Maxwell. > -.br > -Currently maintained by the IcedTea contributors. See javaws -about for more info > - > -.SH SEE ALSO > -.BR java (1) > -.br > -http://icedtea.classpath.org/wiki/IcedTea-Web > diff -r 2979fa371add -r b0690979967f netx/net/sourceforge/jnlp/OptionsDefinitions.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Tue Sep 09 14:51:16 2014 +0200 > @@ -0,0 +1,217 @@ > +/* > + Copyright (C) 2008 Red Hat, Inc. > + > +This file is part of IcedTea. > + > +IcedTea is free software; you can redistribute it and/or > +modify it under the terms of the GNU General Public License as published by > +the Free Software Foundation, version 2. > + > +IcedTea is distributed in the hope that it will be useful, > +but WITHOUT ANY WARRANTY; without even the implied warranty of > +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +General Public License for more details. > + > +You should have received a copy of the GNU General Public License > +along with IcedTea; see the file COPYING. If not, write to > +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA > +02110-1301 USA. > + > +Linking this library statically or dynamically with other modules is > +making a combined work based on this library. Thus, the terms and > +conditions of the GNU General Public License cover the whole > +combination. > + > +As a special exception, the copyright holders of this library give you > +permission to link this library with independent modules to produce an > +executable, regardless of the license terms of these independent > +modules, and to copy and distribute the resulting executable under So this is how it works now? We do not need consensus anymore? I am a bit confused here. Jacob From gitne at gmx.de Tue Sep 9 13:58:27 2014 From: gitne at gmx.de (Jacob Wisor) Date: Tue, 09 Sep 2014 15:58:27 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <1477325712.2191320.1410268091407.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> <540E74AA.6010902@gmx.de> <1477325712.2191320.1410268091407.JavaMail.zimbra@redhat.com> Message-ID: <540F0783.1080505@gmx.de> On 09/09/2014 03:08 PM, Jie Kang wrote: > ----- Original Message ----- >> On 09/08/2014 08:38 PM, Lukasz Dracz wrote: >>>> As well, the ability to choose where icedtea-web downloads file should >>>> still >>>> be enabled even if cache has a limit of 0. >>> >>> Yes since it still downloads the files even if they are deleted after use. >>> This provides the user with more choice on where they want the files to be >>> temporarily. >> >> No, the UI components to choose a cache location should be kept disabled in >> this >> case indeed. 0 means *no* *cache*. Hence, IcedTea-Web should behave as >> expected >> which would be to store all downloaded resources in memory and if, and only >> if, > > I disagree with disabling the cache location until this feature is implemented, or the feature for storing in a temporary directory is implemented Then it's just about time to implement it, right? ;-) Not because of the UI rework but because IcedTea-Web has never behaved properly when the cache size was set to 0. And yes, I admit that this feature/behavior should probably be implemented in another patch. Nevertheless, I would advise to go with disabling now and then to start working on this "memory only" behavior right away. Why? Because it is always best do to things "the proper way" as soon as possible. Usually, postponing things leads to even more problems later on. This is mainly because human beings are forgettable, tend to be lazy, and constantly lack time to do work. Yes, this includes me. ;-) So, this does not only apply to programming but to life in general. @Lukasz Please, do it "the proper way" now and honor us with a followup patch. When you will be done you will feel even better. :-) Anyway, thank you for your resiliency on getting though with this patch already. >> it should turn out to be impossible to implement proper working of >> IcedTea-Web >> without storing resources into files then they should be stored in the system >> configured user's temporary directory. In other words, if cache size is 0 >> then >> downloaded resources /could/ go into the user's temporary directory, although >> this should practically never happen because IcedTea-Web should error out >> with >> an OutOfMemoryException before anything else in this case. >> Also, the UI components denoting the cache location /could/ display the path >> to >> the user's temporary directory if cache size is 0. >> So in any event the UI components must be disabled at cache size 0. From jvanek at redhat.com Tue Sep 9 14:03:42 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 09 Sep 2014 16:03:42 +0200 Subject: /hg/icedtea-web: Outdated documentation replaced by documentatio... In-Reply-To: <540F02D9.8090001@gmx.de> References: <540F02D9.8090001@gmx.de> Message-ID: <540F08BE.3040904@redhat.com> >> +executable, regardless of the license terms of these independent >> +modules, and to copy and distribute the resulting executable under > > So this is how it works now? We do not need consensus anymore? I am a bit confused here. > > Jacob Both Andrew and Jie had they careful ok(with nits I have fixed). One ok is ok to go, and one nope is ok to stop. So no confusion should be here. J. From gitne at gmx.de Tue Sep 9 14:11:32 2014 From: gitne at gmx.de (Jacob Wisor) Date: Tue, 09 Sep 2014 16:11:32 +0200 Subject: /hg/icedtea-web: Outdated documentation replaced by documentatio... In-Reply-To: <540F08BE.3040904@redhat.com> References: <540F02D9.8090001@gmx.de> <540F08BE.3040904@redhat.com> Message-ID: <540F0A94.4010906@gmx.de> On 09/09/2014 04:03 PM, Jiri Vanek wrote: >>> +executable, regardless of the license terms of these independent >>> +modules, and to copy and distribute the resulting executable under >> >> So this is how it works now? We do not need consensus anymore? I am a bit >> confused here. >> >> Jacob > Both Andrew and Jie had they careful ok(with nits I have fixed). One ok is ok to > go, and one nope is ok to stop. So no confusion should be here. Okay, I understand. But, what is the time frame for review then, or is it first come first serve (FIFO)? From jkang at redhat.com Tue Sep 9 14:25:49 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 9 Sep 2014 10:25:49 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve Icedtea-Web cache disk space In-Reply-To: <540F0783.1080505@gmx.de> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> <540E74AA.6010902@gmx.de> <1477325712.2191320.1410268091407.JavaMail.zimbra@redhat.com> <540F0783.1080505@gmx.de> Message-ID: <778279817.2241196.1410272749818.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/09/2014 03:08 PM, Jie Kang wrote: > > ----- Original Message ----- > >> On 09/08/2014 08:38 PM, Lukasz Dracz wrote: > >>>> As well, the ability to choose where icedtea-web downloads file should > >>>> still > >>>> be enabled even if cache has a limit of 0. > >>> > >>> Yes since it still downloads the files even if they are deleted after > >>> use. > >>> This provides the user with more choice on where they want the files to > >>> be > >>> temporarily. > >> > >> No, the UI components to choose a cache location should be kept disabled > >> in > >> this > >> case indeed. 0 means *no* *cache*. Hence, IcedTea-Web should behave as > >> expected > >> which would be to store all downloaded resources in memory and if, and > >> only > >> if, > > > > I disagree with disabling the cache location until this feature is > > implemented, or the feature for storing in a temporary directory is > > implemented > > Then it's just about time to implement it, right? ;-) Not because of the UI > rework but because IcedTea-Web has never behaved properly when the cache size > was set to 0. > > And yes, I admit that this feature/behavior should probably be implemented in > another patch. Nevertheless, I would advise to go with disabling now and then > to > start working on this "memory only" behavior right away. Why? Because it is > always best do to things "the proper way" as soon as possible. Usually, > postponing things leads to even more problems later on. This is mainly > because > human beings are forgettable, tend to be lazy, and constantly lack time to do > work. Yes, this includes me. ;-) So, this does not only apply to programming > but > to life in general. Reworks are in progress on the resource downloading + caching system :) Just nothing sent for review yet :\ > > @Lukasz > Please, do it "the proper way" now and honor us with a followup patch. When > you > will be done you will feel even better. :-) > Anyway, thank you for your resiliency on getting though with this patch > already. > > >> it should turn out to be impossible to implement proper working of > >> IcedTea-Web > >> without storing resources into files then they should be stored in the > >> system > >> configured user's temporary directory. In other words, if cache size is 0 > >> then > >> downloaded resources /could/ go into the user's temporary directory, > >> although > >> this should practically never happen because IcedTea-Web should error out > >> with > >> an OutOfMemoryException before anything else in this case. > >> Also, the UI components denoting the cache location /could/ display the > >> path > >> to > >> the user's temporary directory if cache size is 0. > >> So in any event the UI components must be disabled at cache size 0. > -- Jie Kang From jvanek at redhat.com Tue Sep 9 14:40:08 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 09 Sep 2014 16:40:08 +0200 Subject: /hg/icedtea-web: Outdated documentation replaced by documentatio... In-Reply-To: <540F0A94.4010906@gmx.de> References: <540F02D9.8090001@gmx.de> <540F08BE.3040904@redhat.com> <540F0A94.4010906@gmx.de> Message-ID: <540F1148.8080803@redhat.com> On 09/09/2014 04:11 PM, Jacob Wisor wrote: > On 09/09/2014 04:03 PM, Jiri Vanek wrote: >>>> +executable, regardless of the license terms of these independent >>>> +modules, and to copy and distribute the resulting executable under >>> >>> So this is how it works now? We do not need consensus anymore? I am a bit >>> confused here. >>> >>> Jacob >> Both Andrew and Jie had they careful ok(with nits I have fixed). One ok is ok to >> go, and one nope is ok to stop. So no confusion should be here. > > Okay, I understand. But, what is the time frame for review then, or is it first come first serve > (FIFO)? > Not exactly fifo. Anybody can review anything, even if it is already reviewed. Also anybody can stop anything - even if it was pushed. If more reviewers get involved, then it is necessary to wait for all of them. See the last paragraph. If there are concerns about already pushed stuff, then anybody can comment it after, and the author should fix it. If the concerns are to strong, patch can be reverted. On opposite - to much reviewers{however intentions are good}, the authors death.[1] So if somebody already reviewed something, it is (probably) good idea to stay away, and only scream on crucial things. If there is need to wait for more then two review "ok", then it can lead to . J. 1) [1] ... http://cs.wiktionary.org/wiki/Mnoho_ps%C5%AF_zaj%C3%ADcova_smrt .... angli?tina: Too many cooks spoil the broth., too many chiefs and not enough Indians From jvanek at redhat.com Tue Sep 9 15:01:35 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 09 Sep 2014 17:01:35 +0200 Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <540A496A.5050804@gmx.de> References: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> <540A496A.5050804@gmx.de> Message-ID: <540F164F.8070404@redhat.com> > I am going to go with probably worse. Again, why cannot we use reflection here to get > TeeOutputStream.byteArrayOutputStream and then monitor its flow during the test? Really, this is one > reason why reflection has been introduced to Java. Unluckily, yes, this have spread in ITW a lot. The api is being dirty by non-private utility methods which - should be private - should be tested I would probably like to set some kind of rule for this to future. To test such private methods via reflection stub. It will move test "api" issues from compile time to runtime, but by retrospective look, it is probably worthy. Options? J. From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 15:12:51 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 15:12:51 +0000 Subject: [Bug 1990] iced tea plugin problem with remote login to wdmycloud In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1990 Deepak Bhole changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|dbhole at redhat.com |jvanek at redhat.com -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From omajid at redhat.com Tue Sep 9 15:15:08 2014 From: omajid at redhat.com (Omair Majid) Date: Tue, 9 Sep 2014 11:15:08 -0400 Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <540F164F.8070404@redhat.com> References: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> <540A496A.5050804@gmx.de> <540F164F.8070404@redhat.com> Message-ID: <20140909151507.GB3726@redhat.com> * Jiri Vanek [2014-09-09 11:03]: > Unluckily, yes, this have spread in ITW a lot. The api is being dirty by > non-private utility methods which > - should be private > - should be tested Can you give some examples of this? If it's really, really private, maybe it shouldn't be tested? > I would probably like to set some kind of rule for this to future. To test > such private methods via reflection stub. It will move test "api" issues > from compile time to runtime, but by retrospective look, it is probably > worthy. Working in a language with static types, the type system can be a great friend, not only finding and helping fix errors before they can happen at runtime, but also helping discover things (for example, all pieces of code that invoke a certain method). Reflection can work against static typing and make things more difficult to see and figure out. Please be really, really sure you need to use reflection before you decide to use it (or worse, mandate it). Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From jvanek at redhat.com Tue Sep 9 15:26:18 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 09 Sep 2014 17:26:18 +0200 Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <20140909151507.GB3726@redhat.com> References: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> <540A496A.5050804@gmx.de> <540F164F.8070404@redhat.com> <20140909151507.GB3726@redhat.com> Message-ID: <540F1C1A.4020807@redhat.com> On 09/09/2014 05:15 PM, Omair Majid wrote: > * Jiri Vanek [2014-09-09 11:03]: >> Unluckily, yes, this have spread in ITW a lot. The api is being dirty by >> non-private utility methods which >> - should be private >> - should be tested > > Can you give some examples of this? If it's really, really private, > maybe it shouldn't be tested? What I mean are private methods which actually do the job, but are not intended to be visible. Artificial example: public String processStringByID(String s){ return processString(s, 10) } public String processStringByName(String s){ return processString(s, 20) } private String processString(String s, int x){ do a lot of magic } In this example is better to test both public methods, no metter of implementation in processString(s, i) But there are cases, where is better to test the final method doing the real work. In such case, it stops to be private and changes to package private. So I have started to incline to solution, where each public class ClassInITW have its public class TestClass extends Test in tests folder, which contains private class TestableClassInITW extends ClassInITW which is redeclaring all private such private methods, by theirs accessible siblings, calliung its super by reflection. And the tests are then run above tis artificial extension. What do you think? > >> I would probably like to set some kind of rule for this to future. To test >> such private methods via reflection stub. It will move test "api" issues >> from compile time to runtime, but by retrospective look, it is probably >> worthy. > > Working in a language with static types, the type system can be a great > friend, not only finding and helping fix errors before they can happen > at runtime, but also helping discover things (for example, all pieces of > code that invoke a certain method). Reflection can work against static > typing and make things more difficult to see and figure out. Please be > really, really sure you need to use reflection before you decide to use > it (or worse, mandate it). I 100% agree with you:( And I dont know clean way out. J. From ldracz at redhat.com Tue Sep 9 15:28:39 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Tue, 9 Sep 2014 11:28:39 -0400 (EDT) Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <53FB2893.4050303@redhat.com> <53FB2938.6040201@redhat.com> <471810972.25519307.1408998763566.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> <20140904181831.GB3074@redhat.com> <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> Message-ID: <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> Hello, Here is the updated patch that applies onto the push that added OptionsDefinitions. I have also added a few more unit tests and refactored a common check in two methods into a third method in the OptionParser. Also changed it so now the Option Parser accounts for the case where the user specifies a dash or not in front of the option, ex. 'command -arg blue yellow green -headless' will return the same result as 'command arg blue yellow green headless'. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: optionParser-12.patch Type: text/x-patch Size: 32908 bytes Desc: not available URL: From jkang at redhat.com Tue Sep 9 15:34:20 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 9 Sep 2014 11:34:20 -0400 (EDT) Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <540A496A.5050804@gmx.de> References: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> <540A496A.5050804@gmx.de> Message-ID: <126484288.2297739.1410276860596.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/04/2014 at 05:31 PM, Jie Kang wrote: > > Hello, > > > > This patch adds a logger dependency injection to TeeOutputStream so that > > the tests no longer require a protected function in order to run. > > > > Thoughts? > > I am not sure whether this approach makes the existing flaw better or worse. > :-\ > I am going to go with probably worse. Again, why cannot we use reflection > here To me the existing flaw is the existence of a protected method used solely for unit testing. This patch removes that method from existence using the DI pattern [1]. Can you elaborate on what is worse? [1] http://en.wikipedia.org/wiki/Dependency_injection Thanks, > to get TeeOutputStream.byteArrayOutputStream and then monitor its flow during > the test? Really, this is one reason why reflection has been introduced to > Java. > > Jacob > -- Jie Kang From omajid at redhat.com Tue Sep 9 15:39:49 2014 From: omajid at redhat.com (Omair Majid) Date: Tue, 9 Sep 2014 11:39:49 -0400 Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <540F1C1A.4020807@redhat.com> References: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> <540A496A.5050804@gmx.de> <540F164F.8070404@redhat.com> <20140909151507.GB3726@redhat.com> <540F1C1A.4020807@redhat.com> Message-ID: <20140909153949.GC3726@redhat.com> * Jiri Vanek [2014-09-09 11:26]: > But there are cases, where is better to test the final method doing the real work. > In such case, it stops to be private and changes to package private. What's wrong about using a package-private method for this case? > So I have started to incline to solution, where each > > public class ClassInITW > > have its > > public class TestClass extends Test > > in tests folder, which contains > > private class TestableClassInITW extends ClassInITW > > which is redeclaring all private such private methods, by theirs > accessible siblings, calliung its super by reflection. And the tests > are then run above tis artificial extension. > > What do you think? I don't know, this is not really testing the same method anymore. In fact, it's relying on the reflective testing code to be correct. For example, what if you make a mistake in the reflection code and call a method that looks really similar to another method? It also seems much more complicated than marking a package as for "testing" only using comments and/or annotations and/or package-private marker. This article mentions some alternatives and their pros and cons. http://www.artima.com/suiterunner/private.html These posts may also give you some costs and benefits of some possible approaches: http://stackoverflow.com/questions/34571/how-to-test-a-class-that-has-private-methods-fields-or-inner-classes http://programmers.stackexchange.com/questions/100959/how-do-you-unit-test-private-methods The overwhelming opinion seems to be "don't do it; test public interfaces only". Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From omajid at redhat.com Tue Sep 9 15:58:06 2014 From: omajid at redhat.com (Omair Majid) Date: Tue, 9 Sep 2014 11:58:06 -0400 Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> References: <355049774.398737.1409842794092.JavaMail.zimbra@redhat.com> <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> Message-ID: <20140909155806.GD3726@redhat.com> * Jie Kang [2014-09-04 11:32]: > This patch adds a logger dependency injection to TeeOutputStream so > that the tests no longer require a protected function in order to run. > > Thoughts? I like the approach. Comments in-line below. > +++ b/netx/net/sourceforge/jnlp/util/logging/JavaConsole.java > - System.setErr(new TeeOutputStream(System.err, true)); > - System.setOut(new TeeOutputStream(System.out, false)); > + System.setErr(new TeeOutputStream(System.err, true, OutputController.getLogger())); > + System.setOut(new TeeOutputStream(System.out, false, OutputController.getLogger())); You can avoid this change by creating a public constructor: public TeeOutputStream(PrintStream stdStream, boolean isError) { this(stdStream, isError, OutputController.getLogger()); } // maybe even package-private constructor is okay? public TeeOutputStream(PrintStream stdStream, boolean isError, MessageLogger logger) { // your new implementation Now, existing code will not see an API change, but your test can use the 3-arg variant. > +++ b/netx/net/sourceforge/jnlp/util/logging/MessageLogger.java > @@ -0,0 +1,7 @@ > +package net.sourceforge.jnlp.util.logging; Missing license. > +++ b/tests/netx/unit/net/sourceforge/jnlp/util/logging/TeeOutputStreamTest.java > + private class TestLogger implements MessageLogger { > + private ByteArrayOutputStream baos = new ByteArrayOutputStream(); > + > + @Override > + public void log(MessageWithHeader jm) { > + baos.write(jm.getMessage().getBytes(), 0, jm.getMessage().getBytes().length); > + } > + Now that you have a custom logger, you can even do things like record individual `jm` messages in a list and count how many times logging was triggered. I like it! :) Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From jvanek at redhat.com Tue Sep 9 16:16:54 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 09 Sep 2014 18:16:54 +0200 Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <53FB2893.4050303@redhat.com> <53FB2938.6040201@redhat.com> <471810972.25519307.1408998763566.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> <20140904181831.GB3074@redhat.com> <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> Message-ID: <540F27F6.4050602@redhat.com> On 09/09/2014 05:28 PM, Lukasz Dracz wrote: > Hello, > > Here is the updated patch that applies onto the push that added OptionsDefinitions. I have also added a few more unit tests and refactored a common check in two methods into a third method in the OptionParser. Also changed it so now the Option Parser accounts for the case where the user specifies a dash or not in front of the option, ex. 'command -arg blue yellow green -headless' will return the same result as 'command arg blue yellow green headless'. > > Thank you, > Lukasz Dracz > > > optionParser-12.patch I'm quite happy with the patch. Still few nits (really nits) and two questions Q1 - your patch tolerates more then one unknown parameter. This should be handled differrently. Q2 - By accident I found BOJnlp = Location of JNLP file to launch (url or file). in message.properties Now it is not supported. is it worthy of support? A2 - I dont know ;) I'm in temptation to return this param. If not, then it shold be removed from properties. A1 depends on A2 :) As it is now, if more then one main paramis found, then ITW should die. And print out that last parameter is expected to be jnlp file, and all those unknown params were found. (in error_all new LunchException) If we agree that Q2 answer is yes, then except above reaction there should be second one. If -jnlp is s found, then no unknown param is tolerated, and you can simply die. Anyway your parser ust live also with no -jnlp as is now. > > > diff -r b0690979967f netx/net/sourceforge/jnlp/ParserSettings.java > --- a/netx/net/sourceforge/jnlp/ParserSettings.java Tue Sep 09 14:51:16 2014 +0200 > - public static ParserSettings setGlobalParserSettingsFromArgs(String[] cmdArgs) { > - List argList = Arrays.asList(cmdArgs); > - boolean strict = argList.contains("-strict"); > - boolean malformedXmlAllowed = !argList.contains("-xml"); > - > - globalParserSettings = new ParserSettings(strict, true, malformedXmlAllowed); > + public static ParserSettings setGlobalParserSettingsFromArgs(boolean strict, boolean xml) { > + globalParserSettings = new ParserSettings(strict, true, !xml); > return globalParserSettings; Get rid of this factory method compeltely. you can simply ParserSettings settings = new ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT),optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); in smilar way as you have it now, or not? > } > > diff -r b0690979967f netx/net/sourceforge/jnlp/runtime/Boot.java > --- a/netx/net/sourceforge/jnlp/runtime/Boot.java Tue Sep 09 14:51:16 2014 +0200 ...SNIP... > + } > + > + private boolean stringEqualsOption(String s, OptionsDefinitions.OPTIONS opt) { Ouch this can be done much nicer... Just strip all leading "-" and all behind "="we are done. then you have only one simple s.equals[IgnoreCase?] > + if (s.equals(opt.option) || s.equals("-".concat(opt.option)) || s.split("=")[0].equals(opt.option) > + || s.split("=")[0].equals("-".concat(opt.option)) || "-".concat(s).equals(opt.option) || "-".concat(s).equals("-".concat(opt.option)) > + || "-".concat(s).split("=")[0].equals(opt.option) || "-".concat(s).split("=")[0].equals("-".concat(opt.option))) { > + return true; > + } Except above, its a msut that iweb-settings and policyeditor uses this option parser to. You may do it as different changeset but you have to. Mybe evennow is goo dtime to check if your parser will suit. Thank you! J. From gitne at gmx.de Tue Sep 9 16:22:22 2014 From: gitne at gmx.de (Jacob Wisor) Date: Tue, 09 Sep 2014 18:22:22 +0200 Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <20140909151507.GB3726@redhat.com> References: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> <540A496A.5050804@gmx.de> <540F164F.8070404@redhat.com> <20140909151507.GB3726@redhat.com> Message-ID: <540F293E.40006@gmx.de> On 09/09/2014 05:15 PM, Omair Majid wrote: > * Jiri Vanek [2014-09-09 11:03]: >> Unluckily, yes, this have spread in ITW a lot. The api is being dirty by >> non-private utility methods which >> - should be private >> - should be tested > > Can you give some examples of this? If it's really, really private, > maybe it shouldn't be tested? > >> I would probably like to set some kind of rule for this to future. To test >> such private methods via reflection stub. It will move test "api" issues >> from compile time to runtime, but by retrospective look, it is probably >> worthy. > > Working in a language with static types, the type system can be a great > friend, not only finding and helping fix errors before they can happen > at runtime, but also helping discover things (for example, all pieces of > code that invoke a certain method). This is true indeed. :-) > Reflection can work against static typing and make things more difficult > to see and figure out. Please be really, really sure you need to use > reflection before you decide to use it (or worse, mandate it). I am not sure I get your point, but reflection is subject to static typing like any other code and data in Java. You are right when you're saying that careless use of reflection in applications/programs may lead to disastrous mess and break things like finding calling hierarchies or method references etc. However, we are talking about code unit tests here, not about using reflection in the application itself. Their purpose it to test for the proper inner working of classes. In some cases application classes do some more or less complex stuff internally which should be protected from regressions when modifying or extending these classes. This internal stuff usually is or should be private, but should still be tested. Testing the public members only may not always reveal /all/ regressions introduced or may prove very difficult or impossible to test for their internal state, since classes are supposed to hide their internal state by design. Using reflection, we can monitor and thus test for the internal state of a class without providing hidden or undocumented public or protected members just for testing purposes. This approach keeps classes clean and still allows for proper testing. Jacob From gitne at gmx.de Tue Sep 9 16:45:06 2014 From: gitne at gmx.de (Jacob Wisor) Date: Tue, 09 Sep 2014 18:45:06 +0200 Subject: [rfc][icedtea-web] TeeOutputStream Dependency Fix In-Reply-To: <20140909153949.GC3726@redhat.com> References: <674136995.453135.1409844683435.JavaMail.zimbra@redhat.com> <540A496A.5050804@gmx.de> <540F164F.8070404@redhat.com> <20140909151507.GB3726@redhat.com> <540F1C1A.4020807@redhat.com> <20140909153949.GC3726@redhat.com> Message-ID: <540F2E92.2050601@gmx.de> On 09/09/2014 05:39 PM, Omair Majid wrote: > * Jiri Vanek [2014-09-09 11:26]: >> But there are cases, where is better to test the final method doing the real work. >> In such case, it stops to be private and changes to package private. > > What's wrong about using a package-private method for this case? Well yes, this is a possible approach. But, it has the side effect that you have to keep those methods in application code just for the purpose of testing. IMHO this makes a mess out of the beauty of clean application code. And then, there is always the risk of unwillingly introducing potential security holes as attackers may be able to exploit exactly the same methods which have been provided for testing only. I think that there is a lot more danger in unwittingly introducing side effects into "testing members" than the benefits they may offer just for the purpose of tests. My philosophy actually is to have no code (or as little as possible) which bears no functionality for the application in production code. This keeps you safe and clean. >> So I have started to incline to solution, where each >> >> public class ClassInITW >> >> have its >> >> public class TestClass extends Test >> >> in tests folder, which contains >> >> private class TestableClassInITW extends ClassInITW >> >> which is redeclaring all private such private methods, by theirs >> accessible siblings, calliung its super by reflection. And the tests >> are then run above tis artificial extension. >> >> What do you think? > > I don't know, this is not really testing the same method anymore. In > fact, it's relying on the reflective testing code to be correct. For > example, what if you make a mistake in the reflection code and call a > method that looks really similar to another method? Making mistakes applies to any code, application code as well as in test code. So this argument is actually invalid. > It also seems much more complicated than marking a package as for > "testing" only using comments and/or annotations and/or package-private > marker. Yes, is may be a little bit more complicated, but only just a bit. However, I do not accept the premise that just because human beings tend to be lazy, we should lower the standards for the our quality of work. ;-) > This article mentions some alternatives and their pros and cons. > http://www.artima.com/suiterunner/private.html > > These posts may also give you some costs and benefits of some > possible approaches: > http://stackoverflow.com/questions/34571/how-to-test-a-class-that-has-private-methods-fields-or-inner-classes > http://programmers.stackexchange.com/questions/100959/how-do-you-unit-test-private-methods > > The overwhelming opinion seems to be "don't do it; test public > interfaces only". And, this is true. However, as already mentioned in another posting, testing public member is sometimes not enough. Regards, Jacob From ldracz at redhat.com Tue Sep 9 18:21:18 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Tue, 9 Sep 2014 14:21:18 -0400 (EDT) Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <540F27F6.4050602@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <471810972.25519307.1408998763566.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> <20140904181831.GB3074@redhat.com> <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> <540F27F6.4050602@redhat.com> Message-ID: <1887532824.2369149.1410286878320.JavaMail.zimbra@redhat.com> Hello, > I'm quite happy with the patch. > > Still few nits (really nits) and two questions > > Q1 - your patch tolerates more then one unknown parameter. This should be > handled differrently. > Q2 - By accident I found > BOJnlp = Location of JNLP file to launch (url or file). > in message.properties > > Now it is not supported. is it worthy of support? Yeah I can support it, its just specifying the main arg in this case with an option. Also there was support before for -basedir which did exactly what -jnlp did. Should we support -basedir too ? I thought it was simpler to just expect the user to input the File as a main arg, but I can add support for having a -jnlp or -basedir option before the File if you want. > A2 - I dont know ;) I'm in temptation to return this param. If not, then it > shold be removed from > properties. > > A1 depends on A2 :) > As it is now, if more then one main paramis found, then ITW should die. And > print out that last > parameter is expected to be jnlp file, and all those unknown params were > found. (in error_all new > LunchException) > If we agree that Q2 answer is yes, then except above reaction there should > be second one. > If -jnlp is s found, then no unknown param is tolerated, and you can > simply die. Anyway your > parser ust live also with no -jnlp as is now. Yeah I am going to work on detecting unknown params. > > > > > > diff -r b0690979967f netx/net/sourceforge/jnlp/ParserSettings.java > > --- a/netx/net/sourceforge/jnlp/ParserSettings.java Tue Sep 09 14:51:16 > > 2014 +0200 > > > > - public static ParserSettings setGlobalParserSettingsFromArgs(String[] > > cmdArgs) { > > - List argList = Arrays.asList(cmdArgs); > > - boolean strict = argList.contains("-strict"); > > - boolean malformedXmlAllowed = !argList.contains("-xml"); > > - > > - globalParserSettings = new ParserSettings(strict, true, > > malformedXmlAllowed); > > + public static ParserSettings setGlobalParserSettingsFromArgs(boolean > > strict, boolean xml) { > > + globalParserSettings = new ParserSettings(strict, true, !xml); > > return globalParserSettings; > > Get rid of this factory method compeltely. > > you can simply > ParserSettings settings = new > ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT),optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); > > in smilar way as you have it now, or not? The problem with that is, there is a private static ParserSettings globalParserSettings = new ParserSettings(); with a getGlobalParserSettings() and setGlobalParserSettings(), so I assumed these methods that reference the static ParserSettings might have been used elsewhere so I thought it was a good idea to set the globalParserSettings as it was done before. The getGlobalParserSettings is used in the PluginBridge and NetxPanel. > > > } > > > > diff -r b0690979967f netx/net/sourceforge/jnlp/runtime/Boot.java > > --- a/netx/net/sourceforge/jnlp/runtime/Boot.java Tue Sep 09 14:51:16 2014 > > +0200 > > ...SNIP... > > > + } > > + > > + private boolean stringEqualsOption(String s, > > OptionsDefinitions.OPTIONS opt) { > > Ouch this can be done much nicer... > Just strip all leading "-" and all behind "="we are done. > then you have only one simple s.equals[IgnoreCase?] > > > + if (s.equals(opt.option) || s.equals("-".concat(opt.option)) || > > s.split("=")[0].equals(opt.option) > > + || s.split("=")[0].equals("-".concat(opt.option)) || > > "-".concat(s).equals(opt.option) || > > "-".concat(s).equals("-".concat(opt.option)) > > + || "-".concat(s).split("=")[0].equals(opt.option) || > > "-".concat(s).split("=")[0].equals("-".concat(opt.option))) { > > + return true; > > + } Yes, I will work on implementing this in a better way. > Except above, its a msut that iweb-settings and policyeditor uses this option > parser to. > > You may do it as different changeset but you have to. Mybe evennow is goo > dtime to check if your > parser will suit. Yeah I will begin to look and see how itweb-settings and policyeditor handle parsing and thinking about how OptionParser will be used by them. Thank you, Lukasz Dracz From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 19:06:36 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 19:06:36 +0000 Subject: [Bug 1990] iced tea plugin problem with remote login to wdmycloud In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1990 --- Comment #2 from Martin Rooyakkers --- Iced Tea Web Bug 1990 & 1991 Western Digital is working on the problem. http://wdc.custhelp.com/app/answers/detail/search/1/a_id/11387/c/130/p/85,392 This is an Iced Tea Web window that pops up after giving the password for the network drive. Note ??? I have followed the links and added them where appropriate. Window start The application com.wd.nas4g.mapdrive.MapDrive from https://wdmycloud-device1190496.wd2go.com/mapDrive.php?ma resources from the following remote locations: -- https://wdmycloud-device1190496.wd2go.com/mapdrive -- http://wdmycloud-device1190496.wd2go.com/mapdrive Are you sure you want to run this application? **-**-**.**.**** For more information see: JAR File Manifest Attributes - the link is; http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/manifest.html#app_library and Preventing the Repurposing of an Application ??? the link is; http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/no_redeploy.html window end -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 19:07:27 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 19:07:27 +0000 Subject: [Bug 1991] ice tea problem with remote login to wdmycloud In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1991 --- Comment #1 from Martin Rooyakkers --- Iced Tea Web Bug 1990 & 1991 Western Digital is working on the problem. http://wdc.custhelp.com/app/answers/detail/search/1/a_id/11387/c/130/p/85,392 This is an Iced Tea Web window that pops up after giving the password for the network drive. Note ??? I have followed the links and added them where appropriate. Window start The application com.wd.nas4g.mapdrive.MapDrive from https://wdmycloud-device1190496.wd2go.com/mapDrive.php?ma resources from the following remote locations: -- https://wdmycloud-device1190496.wd2go.com/mapdrive -- http://wdmycloud-device1190496.wd2go.com/mapdrive Are you sure you want to run this application? **-**-**.**.**** For more information see: JAR File Manifest Attributes - the link is; http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/manifest.html#app_library and Preventing the Repurposing of an Application ??? the link is; http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/no_redeploy.html window end -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ldracz at redhat.com Tue Sep 9 20:17:47 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Tue, 9 Sep 2014 16:17:47 -0400 (EDT) Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <1887532824.2369149.1410286878320.JavaMail.zimbra@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> <20140904181831.GB3074@redhat.com> <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> <540F27F6.4050602@redhat.com> <1887532824.2369149.1410286878320.JavaMail.zimbra@redhat.com> Message-ID: <1467651074.2470228.1410293867916.JavaMail.zimbra@redhat.com> Hello, I have added support for -jnlp and -basedir. In OptionsDefinitions I added JNLP to runtime options jawaws list and BASEDIR directly to the javaws list. I also got rid of the boolean in the constructor and the call to findMainArg from the constructor. I made findMainArg public since I found that really only want this called if -jnlp or -basedir is not found when parsed for. Added a getMainArgs() to return multiple arguments it finds as Main Args. The not valid args are dealt with in Boot's getJNLPFile. It determines whether it has more than 1 main arg or if it has additional main arg along with a JNLP and BASEDIR value, and then outputs that these main args are not valid arguments. Then it checks for JNLP, BASEDIR and a single main arg and returns a value based on what it finds. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: optionParser-13.patch Type: text/x-patch Size: 37369 bytes Desc: not available URL: From jkang at redhat.com Tue Sep 9 20:29:29 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 9 Sep 2014 16:29:29 -0400 (EDT) Subject: [rfc][icedtea-web] PropertiesFile Unit Tests In-Reply-To: <1814680083.2473637.1410294405383.JavaMail.zimbra@redhat.com> Message-ID: <1167005276.2474669.1410294569077.JavaMail.zimbra@redhat.com> Hello, This patch cleans up the tests for PropertiesFile and adds a number of basic unit tests. The clean-up involves removing any usage of 'cache' in the unit test as it is unnecessary and should not be part of unit testing for PropertiesFile. There is now no reliance on 'cache' or other outside code. The basic unit tests that are added should be self-explanatory. Thoughts? Regards, -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-pf-test-1.patch Type: text/x-patch Size: 7734 bytes Desc: not available URL: From jkang at redhat.com Tue Sep 9 20:36:32 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 9 Sep 2014 16:36:32 -0400 (EDT) Subject: [rfc][icedtea-web] Cache LRU Wrapper Locking and Unit Tests In-Reply-To: <560518340.2507362.1410294755362.JavaMail.zimbra@redhat.com> Message-ID: <1481142788.2535776.1410294992443.JavaMail.zimbra@redhat.com> Hello, This patch modifies the locking system for the CacheLRUWrapper in order to use the locking provided by PropertiesFile (which was introduced in the CacheEntry Locking Fix)[1]. Both CacheEntry and CacheLRUWrapper use a PropertiesFile and the locking mechanism is the same. Tests have also been added to more thoroughly test the CacheLRUWrapper class. [1] http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-August/029093.html Reproducers and manual testing have been performed in order to ensure no regressions. Thoughts? Regards, -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-cache-lru-lock-test-1.patch Type: text/x-patch Size: 9121 bytes Desc: not available URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:09:32 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:09:32 +0000 Subject: [Bug 1133] Handle DB connection failures more gracefully In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1133 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:10:08 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:10:08 +0000 Subject: [Bug 1168] Bad DB configuration makes GUI seemingly non-responsive In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1168 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:10:29 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:10:29 +0000 Subject: [Bug 1183] After a killall -9 java and restarting thermostat, it still thinks old java processes are alive In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1183 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:11:03 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:11:03 +0000 Subject: [Bug 1230] Some thermostat components should not be allowed to commit suicide In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1230 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:11:32 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:11:32 +0000 Subject: [Bug 1269] MenuAction may create duplicate top-level menus In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1269 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:12:58 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:12:58 +0000 Subject: [Bug 1420] Bring command line to feature-parity with the swing gui In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1420 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:13:06 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:13:06 +0000 Subject: [Bug 1441] Agent eats quite a lot CPU (>5%) when storage is stopped In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1441 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:13:23 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:13:23 +0000 Subject: [Bug 1447] Connect command stuck when connecting to remote http:// storage. In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1447 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:16:27 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:16:27 +0000 Subject: [Bug 1576] RFE: Make entire horizontal black strip of new hostvms accordian panel hide it, rather than just the little arrow icons In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1576 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:16:38 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:16:38 +0000 Subject: [Bug 1575] RFE: Provide better UI hint for whether optional feature is activated. In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1575 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 9 21:16:53 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 09 Sep 2014 21:16:53 +0000 Subject: [Bug 1476] list-vms in shell agentId vs hostId In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1476 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Wed Sep 10 09:42:03 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 10 Sep 2014 11:42:03 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <54071FE9.2000309@redhat.com> References: <54071FE9.2000309@redhat.com> Message-ID: <54101CEB.1040104@redhat.com> ping? -------- Original Message -------- Subject: Re: [rfc][icedtea-web] https probing Date: Wed, 03 Sep 2014 16:04:25 +0200 From: Jiri Vanek To: Jacob Wisor , distro-pkg-dev at openjdk.java.net On 08/26/2014 09:51 AM, Jacob Wisor wrote: > On 08/26/2014 09:16 AM, Jiri Vanek wrote: >> ping? >> >> On 08/20/2014 08:30 PM, Jiri Vanek wrote: >>> On 08/19/2014 11:25 PM, Jacob Wisor wrote: >>>> On 08/18/2014 08:46 PM, Omair Majid wrote: >>>>> Hi, >>>>> >>>>> >>>>> * Jacob Wisor [2014-08-11 12:12]: >>>>>> On 08/08/2014 10:37 AM, Jiri Vanek wrote: >>>>>>> Unluckily this fix patch is not helping obscure servers to do exists. >>>>>>> It really fixes bugs. >>>>>>> >>>>>>> First part of fix is delivered to be able handle SSLv2 handshake, Those >>>>>>> servers >>>>>>> do exists, and have no reason nor need to update or patch or whatever. We are >>>>>>> wrong by not allowing it right now. >>>>>>> See System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); in code. >>>>>> >>>>>> Oh yes they do need fixing. SSLv2 is insecure and has been revoked by the >>>>>> IETF, period. Nobody should be using it. Even SSL 3.0 is deemed by the IETF >>>>>> as historic (https://datatracker.ietf.org/doc/rfc6101) although it is >>>>>> largely identical to TLS 1.0. Nevertheless, nobody should be using it >>>>>> either. Just one of many reasons is that it does not even support such a >>>>>> common hash algorithm as SHA1 (which by the way has been deprecated by NIST >>>>>> in favor of SHA256 too). Everybody should really upgrade to at least TLS >>>>>> 1.0, even though possible security leaks have been discovered in TLS 1.0 on >>>>>> specific configuration settings permutations. >>>>>> >>>>>> DO NOT use SSL anymore and DO NOT promote them in your software. Upgrade to >>>>>> TLS. >>>>> >>>>> This isn't SSv2, though. It's a SSLv2 hello packet wrapping an SSLv3 >>>>> packet: http://bugs.java.com/bugdatabase/view_bug.do?bug_id=4915862 >>>>> >>>>> It's actually part of the TLS 1.0 spec: >>>>> https://www.ietf.org/rfc/rfc2246.txt, Appendix E. >>>> >>>> This part describes backward compatibility of TLS 1.0 clients to SSL 3.0 and >>>> SSL 2.0 servers (and >>>> vice versa). >>>> >>>> "TLS 1.0 clients that support SSL Version 2.0 servers must send SSL >>>> Version 2.0 client hello messages [SSL2]. TLS servers should accept >>>> either client hello format if they wish to support SSL 2.0 clients on >>>> the same connection port. The only deviations from the Version 2.0 >>>> specification are the ability to specify a version with a value of >>>> three and the support for more ciphering types in the CipherSpec." >>>> >>>> Currently, IcedTea-Web is a TLS 1.0 or SSL 3.0 client. According to this >>>> paragraph, TLS 1.0 clients >>>> send SSL 2.0 client hello messages in order to connect to SSL 2.0 servers, >>>> that is, to negotiate a >>>> SSL 2.0 connection. So no, SSL 2.0 servers do not upgrade automagically to >>>> TLS 1.0 when they receive >>>> SSL 2.0 client hello messages from TLS 1.0 clients. Pure old SSL 2.0 servers >>>> will never speak >>>> anything later than SSL 2.0. >>>> >>>> One reason behind this paragraph was for TLS 1.0 clients to allow probing SSL >>>> 2.0 servers with >>>> cipher specifications in SSL 2.0 and those introduced in TLS 1.0. In >>>> practice, SSL 2.0 servers will >>>> _never_ negotiate to a cipher specification introduced since TLS 1.0 because >>>> they were simply not >>>> built for that. >>>> >>>> Another reason for this paragraph back in 1999 (!) was to allow implementors >>>> of TLS 1.0 to ease >>>> transition from SSL to TLS and to give them the option to merge TLS into >>>> their existing SSL >>>> libraries (or as much as possible build on top of them). Again, this has >>>> nothing to do with >>>> automagically upgrading SSL 2.0 servers to TLS. It is just a description of >>>> how TLS 1.0 clients >>>> could fallback to SSL 2.0, if they wish to. >>>> And, I am most certain nobody should want this, unless one has no clue what >>>> transport security is >>>> all about or is a complete lunatic. >>>> >>>> The next paragraph says it all: >>>> >>>> " Warning: The ability to send Version 2.0 client hello messages will be >>>> phased out with all due haste. Implementors should make every >>>> effort to move forward as quickly as possible. Version 3.0 >>>> provides better mechanisms for moving to newer versions." >>>> >>>> So, the Java API should have got rid of the option to fallback to SSL 2.0 >>>> years before. It's a shame >>>> that J2SE still supports SSL 2.0 connections in 2014. Why? Because this has >>>> nothing to do with >>>> compatibility but with *security*. >>>> >>> >>> Ok. Thank you for patience with me. (really!) >>> >>> So there is another approach. >>> >>> Now the ssl2 is tested as last attempt, and if it is possible to connect like >>> that, then the user is >>> warned and error is thrown (which leads to skipping resource from that >>> >>> >>> The not-checking certificate now can be allowed or forbidden by properties. By >>> default it asks user >>> by every such invalid certs its found. How to deal with human intraction is todo. >>> >>> >>> The reason for this message is to get verbose logical error emsssage, not only >>> "itw do not work again" >>> >>> >>> What do you think now? >>> >>> J. > > > > + DeploymentConfiguration.KEY_HTTPS_PROBINGALOWED, > > [...] > > + public static final String KEY_HTTPS_PROBINGALOWED = > > "deployment.security.https.probing.alowed"; > > [...] > > + public void disconect(URLConnection conn) { > > [...] > > + public synchronized void disconectHttps(HttpsURLConnection conn) { > > [...] > > + private final boolean unsecure; > > + > > + private HttpsSettings(boolean ssl2, boolean unsecure) { > > [...] > > + public static URLConnection openConnection(URL url, boolean ssl2, > > boolean unsecure) throws IOException { > > I am not testing this unless you have fixed your typos. > For god's sake, your are a programmer, right? You should know best that exact spelling is important. > Obviously, I am just talking till I am blue in the face. Noooo. I moreover overlooked :( Sorry. Now it should be as good as I'm able to do so without third party attendance. > > Also, please replace all occurrences of "ssl2" in text strings with "SSL2" (or "SSL 2.0" as used in > the specification). Acronyms of names are always upper case in English. > ok! > Here is updated version. Sorry for delay, I was hacking the documentation generator. Now its one (discussing with Lukas concurrently edited code), ad I think you will like it :) J. -------------- next part -------------- A non-text attachment was scrubbed... Name: httpsSolution_05.patch Type: text/x-patch Size: 39994 bytes Desc: not available URL: From jvanek at redhat.com Wed Sep 10 09:50:53 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 10 Sep 2014 11:50:53 +0200 Subject: [rfc][icedtea-web] PropertiesFile Unit Tests In-Reply-To: <1167005276.2474669.1410294569077.JavaMail.zimbra@redhat.com> References: <1167005276.2474669.1410294569077.JavaMail.zimbra@redhat.com> Message-ID: <54101EFD.9040605@redhat.com> On 09/09/2014 10:29 PM, Jie Kang wrote: > Hello, > > This patch cleans up the tests for PropertiesFile and adds a number of basic unit tests. The clean-up involves removing any usage of 'cache' in the unit test as it is unnecessary and should not be part of unit testing for PropertiesFile. There is now no reliance on 'cache' or other outside code. The basic unit tests that are added should be self-explanatory. > > Thoughts? > > > Regards, > Looks ok to me. J. From jvanek at redhat.com Wed Sep 10 09:53:12 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 10 Sep 2014 11:53:12 +0200 Subject: [rfc][icedtea-web] Cache LRU Wrapper Locking and Unit Tests In-Reply-To: <1481142788.2535776.1410294992443.JavaMail.zimbra@redhat.com> References: <1481142788.2535776.1410294992443.JavaMail.zimbra@redhat.com> Message-ID: <54101F88.20008@redhat.com> On 09/09/2014 10:36 PM, Jie Kang wrote: > Hello, > > This patch modifies the locking system for the CacheLRUWrapper in order to use the locking provided by PropertiesFile (which was introduced in the CacheEntry Locking Fix)[1]. Both CacheEntry and CacheLRUWrapper use a PropertiesFile and the locking mechanism is the same. Tests have also been added to more thoroughly test the CacheLRUWrapper class. > > [1]http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-August/029093.html > > Reproducers and manual testing have been performed in order to ensure no regressions. > > Thoughts? > > ... > - return cacheOrder.contains(key); > - } > + public synchronized boolean containsKey(String key) { return cacheOrder.containsKey(key); } > + > + public synchronized boolean containsValue(String value) { return cacheOrder.containsValue(value); } > Please expand those to three (At least) liens each. Otherwise ok to go. > /** > * Generate a key given the path to file. May or may not generate the same ... From ptisnovs at icedtea.classpath.org Wed Sep 10 11:30:11 2014 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Wed, 10 Sep 2014 11:30:11 +0000 Subject: /hg/gfx-test: Ten new tests added into CAGOperationsOnTwoOverlap... Message-ID: changeset dc04b210f52b in /hg/gfx-test details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=dc04b210f52b author: Pavel Tisnovsky date: Wed Sep 10 13:31:21 2014 +0200 Ten new tests added into CAGOperationsOnTwoOverlappingRoundRectangles. diffstat: ChangeLog | 5 + src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java | 250 ++++++++++ 2 files changed, 255 insertions(+), 0 deletions(-) diffs (272 lines): diff -r a4f0a599cecb -r dc04b210f52b ChangeLog --- a/ChangeLog Tue Sep 09 11:23:49 2014 +0200 +++ b/ChangeLog Wed Sep 10 13:31:21 2014 +0200 @@ -1,3 +1,8 @@ +2014-09-10 Pavel Tisnovsky + + * src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java: + Ten new tests added into CAGOperationsOnTwoOverlappingRoundRectangles. + 2014-09-09 Pavel Tisnovsky * src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java: diff -r a4f0a599cecb -r dc04b210f52b src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java --- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java Tue Sep 09 11:23:49 2014 +0200 +++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java Wed Sep 10 13:31:21 2014 +0200 @@ -556,6 +556,256 @@ return TestResult.PASSED; } + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using union operator. The shape is + * rendered using color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionColorPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingUnionOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using subtract operator. The shape is + * rendered using color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractColorPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using inverse subtract operator. The + * shape is rendered using color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractColorPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using intersect operator. The + * shape is rendered using color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testIntersectColorPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using intersect operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingIntersectOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using XOR operator. The + * shape is rendered using color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorColorPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setFillColor(graphics2d); + // create area using XOR operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingXorOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using union operator. The shape is + * rendered using horizontal gradient color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionHorizontalGradientPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setHorizontalGradientFill(image, graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingUnionOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using subtract operator. The shape is + * rendered using horizontal gradient color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractHorizontalGradientPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setHorizontalGradientFill(image, graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using inverse subtract operator. The + * shape is rendered using horizontal gradient color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractHorizontalGradientPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setHorizontalGradientFill(image, graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using intersect operator. The + * shape is rendered using horizontal gradient color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testIntersectHorizontalGradientPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setHorizontalGradientFill(image, graphics2d); + // create area using intersect operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingIntersectOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two rectangles using XOR operator. The + * shape is rendered using horizontal gradient color paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorHorizontalGradientPaint(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setHorizontalGradientFill(image, graphics2d); + // create area using XOR operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRoundRectanglesUsingXorOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + /** * Entry point to the test suite. From jkang at icedtea.classpath.org Wed Sep 10 13:33:17 2014 From: jkang at icedtea.classpath.org (jkang at icedtea.classpath.org) Date: Wed, 10 Sep 2014 13:33:17 +0000 Subject: /hg/icedtea-web: Added unit tests for PropertiesFile.java and re... Message-ID: changeset faeb3e209001 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=faeb3e209001 author: Jie Kang date: Wed Sep 10 09:31:36 2014 -0400 Added unit tests for PropertiesFile.java and refactored existing unit tests to not use external code. 2014-09-10 Jie Kang Added unit tests to PropertiesFile.java and refactored existing unit tests to not use external code. * tests/netx/unit/net/sourceforge/jnlp/util/PopertiesFileTest.java diffstat: ChangeLog | 6 + tests/netx/unit/net/sourceforge/jnlp/util/PropertiesFileTest.java | 213 ++++++--- 2 files changed, 134 insertions(+), 85 deletions(-) diffs (261 lines): diff -r b0690979967f -r faeb3e209001 ChangeLog --- a/ChangeLog Tue Sep 09 14:51:16 2014 +0200 +++ b/ChangeLog Wed Sep 10 09:31:36 2014 -0400 @@ -1,3 +1,9 @@ +2014-09-10 Jie Kang + + Added unit tests to PropertiesFile.java and refactored existing unit tests + to not use external code. + * tests/netx/unit/net/sourceforge/jnlp/util/PopertiesFileTest.java + 2014-09-09 Jiri Vanek Outdated documentation replaced by documentation generation diff -r b0690979967f -r faeb3e209001 tests/netx/unit/net/sourceforge/jnlp/util/PropertiesFileTest.java --- a/tests/netx/unit/net/sourceforge/jnlp/util/PropertiesFileTest.java Tue Sep 09 14:51:16 2014 +0200 +++ b/tests/netx/unit/net/sourceforge/jnlp/util/PropertiesFileTest.java Wed Sep 10 09:31:36 2014 -0400 @@ -37,116 +37,159 @@ package net.sourceforge.jnlp.util; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; import java.io.File; import java.io.IOException; -import java.nio.channels.FileLock; -import java.nio.channels.OverlappingFileLockException; -import net.sourceforge.jnlp.cache.CacheLRUWrapper; +import java.nio.file.Files; -import net.sourceforge.jnlp.config.DeploymentConfiguration; -import net.sourceforge.jnlp.runtime.JNLPRuntime; - -import org.junit.BeforeClass; +import org.junit.Before; import org.junit.Test; public class PropertiesFileTest { - private int lockCount = 0; + private PropertiesFile propertiesFile; - /* lock for the file RecentlyUsed */ - private FileLock fl = null; - - private final String cacheDir = new File(JNLPRuntime.getConfiguration() - .getProperty(DeploymentConfiguration.KEY_USER_CACHE_DIR)).getPath(); - - // does no DeploymentConfiguration exist for this file name? - private final String cacheIndexFileName = CacheLRUWrapper.CACHE_INDEX_FILE_NAME; - - private final PropertiesFile cacheIndexFile = new PropertiesFile(new File(cacheDir + File.separatorChar + cacheIndexFileName)); - private final int noEntriesCacheFile = 1000; - - @BeforeClass - static public void setupJNLPRuntimeConfig() { - JNLPRuntime.getConfiguration().setProperty(DeploymentConfiguration.KEY_USER_CACHE_DIR, System.getProperty("java.io.tmpdir")); + @Before + public void setup() throws IOException { + File lru = Files.createTempFile("properties_file", ".tmp").toFile(); + lru.createNewFile(); + lru.deleteOnExit(); + propertiesFile = new PropertiesFile(lru); } - private void fillCacheIndexFile(int noEntries) { + @Test + public void testSetProperty() { + propertiesFile.setProperty("key", "value"); + assertTrue(propertiesFile.containsKey("key") && propertiesFile.containsValue("value")); + } - // fill cache index file + @Test + public void testGetProperty() { + propertiesFile.setProperty("key", "value"); + String v = propertiesFile.getProperty("key"); + assertEquals("value", v); + } + + @Test + public void testGetDefaultProperty() { + String v = propertiesFile.getProperty("key", "default"); + assertEquals("default", v); + } + + @Test + public void testStore() throws IOException { + String key = "key"; + String value = "value"; + propertiesFile.setProperty(key, value); + try { + propertiesFile.lock(); + propertiesFile.store(); + } finally { + propertiesFile.unlock(); + } + + File f = propertiesFile.getStoreFile(); + String output = new String(Files.readAllBytes(f.toPath())); + assertTrue(output.contains(key + "=" + value)); + } + + @Test + public void testReloadAfterStore() { + try { + boolean reloaded; + propertiesFile.lock(); + + // 1. clear entries + store + clearPropertiesFile(); + + // 2. load from file + reloaded = propertiesFile.load(); + assertTrue("File was not reloaded!", reloaded); + + // 3. add some entries and store + fillProperties(10); + + propertiesFile.store(); + reloaded = propertiesFile.load(); + + assertTrue("File was not reloaded!", reloaded); + } finally { + propertiesFile.unlock(); + } + } + + private void fillProperties(int noEntries) { for(int i = 0; i < noEntries; i++) { - String path = cacheDir + File.separatorChar + i + File.separatorChar + "test" + i + ".jar"; - String key = String.valueOf(System.currentTimeMillis()); - cacheIndexFile.setProperty(key, path); + propertiesFile.setProperty(String.valueOf(i), String.valueOf(i)); + } + } + + private void clearPropertiesFile() { + try { + propertiesFile.lock(); + + // clear cache + store file + propertiesFile.clear(); + propertiesFile.store(); + } finally { + propertiesFile.unlock(); } } @Test - public void testReloadAfterStore() { + public void testLoad() throws InterruptedException { + try { + propertiesFile.lock(); - lock(); + propertiesFile.setProperty("key", "value"); + propertiesFile.store(); - boolean reloaded = false; + propertiesFile.setProperty("shouldNotRemainAfterLoad", "def"); + propertiesFile.load(); - // 1. clear cache entries + store - clearCacheIndexFile(); + assertFalse(propertiesFile.contains("shouldNotRemainAfterLoad")); + } finally { + propertiesFile.unlock(); - // 2. load cache file - reloaded = cacheIndexFile.load(); - assertTrue("File was not reloaded!", reloaded); - - // 3. add some cache entries and store - fillCacheIndexFile(noEntriesCacheFile); - cacheIndexFile.store(); - reloaded = cacheIndexFile.load(); - assertTrue("File was not reloaded!", reloaded); - - unlock(); - } - - private void clearCacheIndexFile() { - - lock(); - - // clear cache + store file - cacheIndexFile.clear(); - cacheIndexFile.store(); - - unlock(); + } } - - // add locking, because maybe some JNLP runtime user is running. copy/paste from CacheLRUWrapper + @Test + public void testLoadWithNoChanges() throws InterruptedException { + try { + propertiesFile.lock(); - /** - * Lock the file to have exclusive access. - */ - private void lock() { - try { - fl = FileUtils.getFileLock(cacheIndexFile.getStoreFile().getPath(), false, true); - } catch (OverlappingFileLockException e) { // if overlap we just increase the count. - } catch (Exception e) { // We didn't get a lock.. - e.printStackTrace(); - } - if (fl != null) lockCount++; - } - - /** - * Unlock the file. - */ - private void unlock() { - if (fl != null) { - lockCount--; - try { - if (lockCount == 0) { - fl.release(); - fl.channel().close(); - fl = null; - } - } catch (IOException e) { - e.printStackTrace(); - } + propertiesFile.setProperty("key", "value"); + propertiesFile.store(); + + Thread.sleep(1000l); + + assertFalse(propertiesFile.load()); + } finally { + propertiesFile.unlock(); } } + + @Test + public void testLock() throws IOException { + try { + propertiesFile.lock(); + assertTrue(propertiesFile.isHeldByCurrentThread()); + } finally { + propertiesFile.unlock(); + } + } + + @Test + public void testUnlock() throws IOException { + try { + propertiesFile.lock(); + } finally { + propertiesFile.unlock(); + } + assertTrue(!propertiesFile.isHeldByCurrentThread()); + } } From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 14:02:15 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 14:02:15 +0000 Subject: [Bug 1984] My eclipse interrupted acciently... In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1984 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Version|6-1.13.4 |7-hg Resolution|--- |INVALID Severity|enhancement |normal --- Comment #1 from Andrew John Hughes --- This is a crash in libsoup, not OpenJDK. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at icedtea.classpath.org Wed Sep 10 14:11:47 2014 From: jkang at icedtea.classpath.org (jkang at icedtea.classpath.org) Date: Wed, 10 Sep 2014 14:11:47 +0000 Subject: /hg/icedtea-web: CacheLRUWrapper now uses PropertiesFile locking... Message-ID: changeset af89bcaa02a2 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=af89bcaa02a2 author: Jie Kang date: Wed Sep 10 09:45:10 2014 -0400 CacheLRUWrapper now uses PropertiesFile locking system. Unit tests added for CacheLRUWrapper. 2014-09-10 Jie Kang Changed CacheLRUWrapper to use PropertiesFile's provided locking system Added unit tests for CacheLRUWrapper * netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java * tests/netx/unit/net/sourceforge/jnlp/cache/CacheLRUWrapperTest.java diffstat: ChangeLog | 7 + netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java | 62 +-- tests/netx/unit/net/sourceforge/jnlp/cache/CacheLRUWrapperTest.java | 138 +++++++++- 3 files changed, 163 insertions(+), 44 deletions(-) diffs (327 lines): diff -r faeb3e209001 -r af89bcaa02a2 ChangeLog --- a/ChangeLog Wed Sep 10 09:31:36 2014 -0400 +++ b/ChangeLog Wed Sep 10 09:45:10 2014 -0400 @@ -1,3 +1,10 @@ +2014-09-10 Jie Kang + + Changed CacheLRUWrapper to use PropertiesFile's provided locking system + Added unit tests for CacheLRUWrapper + * netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java + * tests/netx/unit/net/sourceforge/jnlp/cache/CacheLRUWrapperTest.java + 2014-09-10 Jie Kang Added unit tests to PropertiesFile.java and refactored existing unit tests diff -r faeb3e209001 -r af89bcaa02a2 netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java --- a/netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java Wed Sep 10 09:31:36 2014 -0400 +++ b/netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java Wed Sep 10 09:45:10 2014 -0400 @@ -40,8 +40,6 @@ import java.io.File; import java.io.IOException; -import java.nio.channels.FileLock; -import java.nio.channels.OverlappingFileLockException; import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; @@ -66,11 +64,6 @@ public enum CacheLRUWrapper { INSTANCE; - private int lockCount = 0; - - /* lock for the file RecentlyUsed */ - private FileLock fl = null; - /* location of cache directory */ private final String setCachePath = JNLPRuntime.getConfiguration().getProperty(DeploymentConfiguration.KEY_USER_CACHE_DIR); String cacheDir = new File(setCachePath != null ? setCachePath : System.getProperty("java.io.tmpdir")).getPath(); @@ -80,9 +73,11 @@ * recently used items. The items are to be kept with key = (current time * accessed) followed by folder of item. value = path to file. */ + + public static final String CACHE_INDEX_FILE_NAME = "recently_used"; + PropertiesFile cacheOrder = new PropertiesFile( new File(cacheDir + File.separator + CACHE_INDEX_FILE_NAME)); - public static final String CACHE_INDEX_FILE_NAME = "recently_used"; private CacheLRUWrapper() { File f = cacheOrder.getStoreFile(); @@ -164,8 +159,12 @@ /** * Write file to disk. */ - public synchronized void store() { - cacheOrder.store(); + public synchronized boolean store() { + if (cacheOrder.isHeldByCurrentThread()) { + cacheOrder.store(); + return true; + } + return false; } /** @@ -176,7 +175,9 @@ * @return true if we successfully added to map, false otherwise. */ public synchronized boolean addEntry(String key, String path) { - if (cacheOrder.containsKey(key)) return false; + if (cacheOrder.containsKey(key)) { + return false; + } cacheOrder.setProperty(key, path); return true; } @@ -188,7 +189,9 @@ * @return true if we successfully removed key from map, false otherwise. */ public synchronized boolean removeEntry(String key) { - if (!cacheOrder.containsKey(key)) return false; + if (!cacheOrder.containsKey(key)) { + return false; + } cacheOrder.remove(key); return true; } @@ -243,31 +246,14 @@ * Lock the file to have exclusive access. */ public synchronized void lock() { - try { - fl = FileUtils.getFileLock(cacheOrder.getStoreFile().getPath(), false, true); - } catch (OverlappingFileLockException e) { // if overlap we just increase the count. - } catch (Exception e) { // We didn't get a lock.. - OutputController.getLogger().log(e); - } - if (fl != null) lockCount++; + cacheOrder.lock(); } /** * Unlock the file. */ public synchronized void unlock() { - if (fl != null) { - lockCount--; - try { - if (lockCount == 0) { - fl.release(); - fl.channel().close(); - fl = null; - } - } catch (IOException e) { - OutputController.getLogger().log(e); - } - } + cacheOrder.unlock(); } /** @@ -280,14 +266,12 @@ return cacheOrder.getProperty(key); } - /** - * Test if we the key provided is in use. - * - * @param key key to be tested. - * @return true if the key is in use. - */ - public synchronized boolean contains(String key) { - return cacheOrder.contains(key); + public synchronized boolean containsKey(String key) { + return cacheOrder.containsKey(key); + } + + public synchronized boolean containsValue(String value) { + return cacheOrder.containsValue(value); } /** diff -r faeb3e209001 -r af89bcaa02a2 tests/netx/unit/net/sourceforge/jnlp/cache/CacheLRUWrapperTest.java --- a/tests/netx/unit/net/sourceforge/jnlp/cache/CacheLRUWrapperTest.java Wed Sep 10 09:31:36 2014 -0400 +++ b/tests/netx/unit/net/sourceforge/jnlp/cache/CacheLRUWrapperTest.java Wed Sep 10 09:45:10 2014 -0400 @@ -37,11 +37,18 @@ package net.sourceforge.jnlp.cache; +import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; +import java.io.ByteArrayOutputStream; import java.io.File; +import java.io.IOException; +import java.io.PrintStream; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Executors; import org.junit.AfterClass; +import org.junit.Before; import org.junit.BeforeClass; import org.junit.Test; @@ -58,6 +65,13 @@ private final int noEntriesCacheFile = 1000; + private ByteArrayOutputStream baos; + private PrintStream out; + private ExecutorService executorService; + Object listener = new Object(); + + int num = 0; + @BeforeClass static public void setupJNLPRuntimeConfig() { cacheDirBackup = clw.cacheDir; @@ -72,14 +86,19 @@ clw.cacheDir = cacheDirBackup; clw.cacheOrder = cacheOrderBackup; } - + + @Before + public void setup() { + baos = new ByteArrayOutputStream(); + out = new PrintStream(baos); + executorService = Executors.newSingleThreadExecutor(); + } + @Test public void testLoadStoreTiming() throws InterruptedException { final File cacheIndexFile = new File(clw.cacheDir + File.separator + cacheIndexFileName); cacheIndexFile.delete(); - //ensure it exists, so we can lock - clw.store(); try{ int noLoops = 1000; @@ -131,8 +150,6 @@ final File cacheIndexFile = new File(clw.cacheDir + File.separator + cacheIndexFileName); cacheIndexFile.delete(); - //ensure it exists, so we can lock - clw.store(); try{ clw.lock(); @@ -179,4 +196,115 @@ clw.unlock(); } } + + @Test + public void testAddEntry() { + String key = "key"; + String value = "value"; + + clw.addEntry(key, value); + assertTrue(clw.containsKey(key) && clw.containsValue(value)); + } + + @Test + public void testRemoveEntry() { + String key = "key"; + String value = "value"; + + clw.addEntry(key, value); + clw.removeEntry(key); + assertFalse(clw.containsKey(key) && clw.containsValue(value)); + } + + @Test + public void testLock() throws IOException { + try { + clw.lock(); + assertTrue(clw.cacheOrder.isHeldByCurrentThread()); + } finally { + clw.unlock(); + } + } + + @Test + public void testUnlock() throws IOException { + try { + clw.lock(); + } finally { + clw.unlock(); + } + assertTrue(!clw.cacheOrder.isHeldByCurrentThread()); + } + + @Test + public void testStoreFailsWithoutLock() throws IOException { + assertTrue(!clw.store()); + } + + @Test + public void testStoreWorksWithLocK() throws IOException { + try { + clw.lock(); + assertTrue(clw.store()); + } finally { + clw.unlock(); + } + } + + @Test + public void testMultithreadLockPreventsStore() throws IOException, InterruptedException { + Thread a = new Thread(new StoreWorker()); + a.start(); + + Thread b = new Thread(new StoreWorker()); + b.start(); + + Thread.sleep(2000l); + + synchronized (listener) { + num = 1; + listener.notifyAll(); + } + + String out = baos.toString(); + System.out.println(); + assertTrue(out.contains("true") && out.contains("false")); + } + + private class StoreWorker implements Runnable { + + public StoreWorker() { + } + @Override + public void run() { + try { + clw.cacheOrder.tryLock(); + boolean result = clw.store(); + executorService.execute(new WriteRunnable(String.valueOf(result))); + while (num == 0) { + synchronized (listener) { + listener.wait(); + } + } + } catch (Exception e) { + e.printStackTrace(); + } finally { + clw.unlock(); + } + } + } + + private class WriteRunnable implements Runnable { + private String msg; + public WriteRunnable(String msg) { + this.msg = msg; + } + + @Override + public void run() { + out.println(msg); + out.flush(); + } + } + } From jvanek at redhat.com Wed Sep 10 14:43:47 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 10 Sep 2014 16:43:47 +0200 Subject: [rfc][icedtea-web] localizable files and icedtea-web about page Message-ID: <541063A3.8070201@redhat.com> ssia First of patches moving the individual liens to properties. Fixes to individual sentences welcomed. J. -------------- next part -------------- A non-text attachment was scrubbed... Name: localizableFilesArgsItw.patch Type: text/x-patch Size: 22131 bytes Desc: not available URL: From jvanek at redhat.com Wed Sep 10 14:47:57 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 10 Sep 2014 16:47:57 +0200 Subject: [fyi] [icedtea-web]failing unittest testSetFileNull Message-ID: <5410649D.2080506@redhat.com> FAILED: testSetFileNull(net.sourceforge.jnlp.security.policyeditor.PolicyFileModelTest) Expected exception: java.lang.NullPointerException Is now appearing. I think thatthis was actually fixed in sources, but obviously the test was not adapted. Can responsible person fix? J. From jkang at redhat.com Wed Sep 10 14:51:14 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 10 Sep 2014 10:51:14 -0400 (EDT) Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <472107989.3004062.1410360121065.JavaMail.zimbra@redhat.com> Message-ID: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> Hello, This patch moves the translation responsibility from JNLPRuntime to Translator. Previously, the Translator contained two one-line functions calling methods in JNLPRuntime to perform localization of text. This localization is now performed in Translator instead. Thoughts? Regards, -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-translator.patch Type: text/x-patch Size: 7911 bytes Desc: not available URL: From jvanek at redhat.com Wed Sep 10 15:36:57 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 10 Sep 2014 17:36:57 +0200 Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> Message-ID: <54107019.2030106@redhat.com> On 09/10/2014 04:51 PM, Jie Kang wrote: > Hello, > > This patch moves the translation responsibility from JNLPRuntime to Translator. Previously, the Translator contained two one-line functions calling methods in JNLPRuntime to perform localization of text. This localization is now performed in Translator instead. > > Thoughts? Moreover ok.. jsut few thoughts:) Main one - can we get rid of static context? Well the Transaltor.R() api will probably remain, it would be enormous and unnecessary refactroing of every file, but inside may be hidden call to correct lazy-loading singleton.... hm? > > ... > + */ > + private static String getMessage(String key, Object... args) { > + return MessageFormat.format(getMessage(key), args); > + } > Second though. Is this method worthy? if so(and it is..), should be tested :) And the testing will me much more simple if this class will be possible to instantiate.... ty! J. From jvanek at redhat.com Wed Sep 10 16:08:28 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 10 Sep 2014 18:08:28 +0200 Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <1467651074.2470228.1410293867916.JavaMail.zimbra@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <53FDB53A.90301@redhat.com> <374649378.440186.1409843733352.JavaMail.zimbra@redhat.com> <20140904181831.GB3074@redhat.com> <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> <540F27F6.4050602@redhat.com> <1887532824.2369149.1410286878320.JavaMail.zimbra@redhat.com> <1467651074.2470228.1410293867916.JavaMail.zimbra@redhat.com> Message-ID: <5410777C.6070506@redhat.com> On 09/09/2014 10:17 PM, Lukasz Dracz wrote: > Hello, > > I have added support for -jnlp and -basedir. In OptionsDefinitions I added JNLP to runtime options jawaws list and BASEDIR directly to the javaws list. > > I also got rid of the boolean in the constructor and the call to findMainArg from the constructor. I made findMainArg public since I found that really only want this called if -jnlp or -basedir is not found when parsed for. Added a getMainArgs() to return multiple arguments it finds as Main Args. > > The not valid args are dealt with in Boot's getJNLPFile. It determines whether it has more than 1 main arg or if it has additional main arg along with a JNLP and BASEDIR value, and then outputs that these main args are not valid arguments. Then it checks for JNLP, BASEDIR and a single main arg and returns a value based on what it finds. > > Thank you, > Lukasz Dracz As we agreed, drop basedri, and update NEWS Something like "dropped support for long unmaintained -basedir argument" And also "maybe returned support for -jnlp argument " :) Much more nits later > > > optionParser-13.patch > > > diff -r b0690979967f netx/net/sourceforge/jnlp/OptionsDefinitions.java > --- a/netx/net/sourceforge/jnlp/OptionsDefinitions.java Tue Sep 09 14:51:16 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Tue Sep 09 15:52:35 2014 -0400 > @@ -71,6 +71,8 @@ > NOHEADERS("-Xignoreheaders", "BXignoreheaders"), > OFFLINE("-Xoffline", "BXoffline"), > TRUSTNONE("-Xtrustnone","BOTrustnone"), > + JNLP("-jnlp","BOJnlp", NumberOfArguments.ONE), > + BASEDIR("-basedir", "BOBasedir",NumberOfArguments.ONE), > //itweb settings > NODASHHELP("help", "IBOHelp"), > LIST("list", "IBOList"), > @@ -200,7 +202,8 @@ > OPTIONS.NOFORK, > OPTIONS.NOHEADERS, > OPTIONS.OFFLINE, > - OPTIONS.TRUSTNONE}); > + OPTIONS.TRUSTNONE, > + OPTIONS.JNLP}); > } > > public static List getJavaWsOptions() { > @@ -210,6 +213,7 @@ > //trustall is not returned by getJavaWsRuntimeOptions > //or getJavaWsControlOptions, as it is not desitred in documentation > l.add(OPTIONS.TRUSTALL); > + l.add(OPTIONS.BASEDIR); > return l; > } > > diff -r b0690979967f netx/net/sourceforge/jnlp/ParserSettings.java > --- a/netx/net/sourceforge/jnlp/ParserSettings.java Tue Sep 09 14:51:16 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/ParserSettings.java Tue Sep 09 15:52:35 2014 -0400 > @@ -37,9 +37,6 @@ > > package net.sourceforge.jnlp; > > -import java.util.Arrays; > -import java.util.List; > - > /** > * Contains settings to be used by the Parser while parsing JNLP files. > * > @@ -99,12 +96,8 @@ > * at boot on the command line. These settings are also stored so they > * can be retrieved at a later time. > */ > - public static ParserSettings setGlobalParserSettingsFromArgs(String[] cmdArgs) { > - List argList = Arrays.asList(cmdArgs); > - boolean strict = argList.contains("-strict"); > - boolean malformedXmlAllowed = !argList.contains("-xml"); > - > - globalParserSettings = new ParserSettings(strict, true, malformedXmlAllowed); > + public static ParserSettings setGlobalParserSettingsFromArgs(boolean strict, boolean xml) { > + globalParserSettings = new ParserSettings(strict, true, !xml); > return globalParserSettings; > } Looking to the code, I really do not see an reason for this to do exists anymore (even withyour explanation). This is just creating new object. You can create it and set is reguraly If you decide to have helepr method here, then the bestargument for it is optionParser, and this helping method will read it on its own. eeing this: ParserSettings defaultSettings, noArgs; defaultSettings = new ParserSettings(); - noArgs = ParserSettings.setGlobalParserSettingsFromArgs(new String[0]); + noArgs = ParserSettings.setGlobalParserSettingsFromArgs(false, true); later, makes me think that combination of setGlobalParserSettingsFromArgs(boolean strict, boolean xml) { and setGlobalParserSettingsFromArgs(OptionParser)) { setGlobalParserSettingsFromArgs(getParsed1, getPArsed2...) { } Is the pointer... > > diff -r b0690979967f netx/net/sourceforge/jnlp/resources/Messages.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Tue Sep 09 14:51:16 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Tue Sep 09 15:52:35 2014 -0400 > @@ -238,6 +238,7 @@ > BOUsage=[-run-options] jnlp file > BOUsage2=[-control-options] > BOJnlp = Location of JNLP file to launch (url or file). > +BOBasedir = Location of JNLP file to launch (url or file). > BOArg = Adds an application argument before launching. > BOParam = Adds an applet parameter before launching. > BOProperty = Sets a system property before launching. > diff -r b0690979967f netx/net/sourceforge/jnlp/resources/Messages_cs.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages_cs.properties Tue Sep 09 14:51:16 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/resources/Messages_cs.properties Tue Sep 09 15:52:35 2014 -0400 > @@ -234,6 +234,7 @@ > BOUsage=javaws [-volby-spu\u0161t\u011bn\u00ed] > BOUsage2=javaws [-volby-ovl\u00e1d\u00e1n\u00ed] > BOJnlp= Um\u00edst\u011bn\u00ed souboru JNLP ke spu\u0161t\u011bn\u00ed (URL nebo soubor) > +BOBasedir= Um\u00edst\u011bn\u00ed souboru JNLP ke spu\u0161t\u011bn\u00ed (URL nebo soubor) > BOArg= P\u0159id\u00e1 p\u0159ed spu\u0161t\u011bn\u00edm parametr aplikace. Dont forget to drop also those lines and thirs mutations ... > */ > private static String getJNLPFile() { > + if (optionParser.getMainArgs().length > 1 || optionParser.mainArgExists() > + && (optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP) > + || optionParser.hasOption(OptionsDefinitions.OPTIONS.BASEDIR))) { > + for (String s : optionParser.getMainArgs()) { > + OutputController.getLogger().printOutLn("The argument '"+ s +"' is not a valid expected argument"); use getLogger.log() for all outputs. There is actually no exception... > + } > + } else if (optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP)) { > + return optionParser.getValue(OptionsDefinitions.OPTIONS.JNLP); I would encapsulate this in OptionParser something like optionParser.validateMainArg() or similar. There is still question how to handle them. But right now, the best way is to die once some unrecognized arg is found. Its not celar for me where this happens in code. AFAIK it does not. So validateMainArg should throw lunchError with invalid options found. > + } else if (optionParser.hasOption(OptionsDefinitions.OPTIONS.BASEDIR)) { > + return optionParser.getValue(OptionsDefinitions.OPTIONS.BASEDIR); > + } else if (optionParser.mainArgExists()) { > + return optionParser.getMainArg(); > + } > > - if (args.length == 0) { > - handleMessage(); > - JNLPRuntime.exit(0); > - } else if (args.length == 1) { > - return args[args.length - 1]; > - } else { > - String lastArg = args[args.length - 1]; > - String secondLastArg = args[args.length - 2]; > - > - if (doubleArgs.indexOf(secondLastArg) == -1) { > - return lastArg; > - } else { > - handleMessage(); > - JNLPRuntime.exit(0); > - } > - } > + handleMessage(); > + JNLPRuntime.exit(0); > return null; > } ... > + > + private final String[] args; > + private final Map> parsedOptions; You have list here, and it is correct. Do not vaste time converting it to array. Rather fix the users of those methods. > + private final List possibleOptions; > + private final String MAINARG = "mainArg"; > + //null represents all values that are parsed that don't have a corresponding option which are potential main args > + private final OptionsDefinitions.OPTIONS mainArg = null; > + private List result; > + > + > + public OptionParser(String[] args, List options) { > + this.args = Arrays.copyOf(args, args.length); > + this.possibleOptions = options; > + > + result = new ArrayList(); > + parsedOptions = new HashMap<>(); > + result = parseContents(args, result); > + > + } > + > + private List parseContents(final String[] args, List result) { > + String lastOption = ""; > + int i = 0; > + while (i < args.length) { > + if (isOption(args[i])) { > + result.clear(); > + if (args[i].contains("=")) { > + result.add(args[i].split("=")[1]); > + lastOption = args[i].split("=")[0]; > + parsedOptions.put(getOption(lastOption), new ArrayList(result)); > + } else { > + lastOption = args[i]; > + if (parsedOptions.keySet().contains(getOption(lastOption))) { > + if (getOption(lastOption).hasOneOrMoreArguments()) { > + result = new ArrayList<>(parsedOptions.get(getOption(lastOption))); > + } > + } > + if (getOption(lastOption).hasNoArguments()) { > + parsedOptions.put(getOption(lastOption), null); > + lastOption = MAINARG; > + } > + } > + } else { > + result.add(args[i]); > + parsedOptions.put(getOption(lastOption), new ArrayList(result)); > + if (getOption(lastOption) != null) { > + if (getOption(lastOption).hasOneArgument()) { > + lastOption = MAINARG; > + result.clear(); > + } > + } > + } > + i++; > + } > + return result; > + } > + > + public void findMainArg() { > + int i = args.length - 1; > + if (!(parsedOptions.keySet().contains(mainArg))) { > + while (i >= 0) { > + if (!args[i].startsWith("-")) { > + for (OptionsDefinitions.OPTIONS op : parsedOptions.keySet()) { > + if (!(parsedOptions.get(op) == null)) { > + if (parsedOptions.get(op).contains(args[i])) { > + result.clear(); > + result.add(args[i]); > + parsedOptions.get(op).remove(parsedOptions.get(op).indexOf(args[i])); > + break; > + } > + } > + } > + parsedOptions.put(mainArg, result); > + break; > + } > + i--; > + } > + } > + } > + > + private boolean isOption(String s) { > + for(OptionsDefinitions.OPTIONS opt : possibleOptions){ > + if (stringEqualsOption(s, opt)) { > + return true; > + } > + } > + return false; > + } > + > + private OptionsDefinitions.OPTIONS getOption(String s) { > + for(OptionsDefinitions.OPTIONS opt : possibleOptions){ > + if (stringEqualsOption(s, opt)) { > + return opt; > + } > + } > + return mainArg; > + } > + > + private boolean stringEqualsOption(String s, OptionsDefinitions.OPTIONS opt) { > + String option = opt.option.replace("-","").split("=")[0]; This is actually still wrong. You shoudl remove only leading dashes. So you may change your algorithm to some while (s.starts) or use repalceAll with "^-*" regex > + s = s.replace("-","").split("=")[0]; This is s surprising but not guaranted that if split argument mathces nothing then whole original is returens. But I guess we can live with that. Anyway this method needs test. > + public boolean mainArgExists() { > + if (parsedOptions.keySet().contains(mainArg)) { > + return true; > + } > + return false; > + } > + > + public String getMainArg() { > + if (mainArgExists()) { > + return parsedOptions.get(mainArg).toArray()[0].toString(); > + } > + return ""; > + } > + > + public String[] getMainArgs() { > + if (mainArgExists()) { > + return parsedOptions.get(mainArg).toArray(new String[0]); here and lower > + } > + return new String[] { }; > + } > + > + public String getValue(OptionsDefinitions.OPTIONS option) { > + if (parsedOptions.get(option) != null) { > + return parsedOptions.get(option).toString().substring(1, parsedOptions.get(option).toString().length() - 1); > + } > + return ""; > + } > + > + public String[] getValues(OptionsDefinitions.OPTIONS option) { > + if (parsedOptions.get(option) != null) { > + return parsedOptions.get(option).toArray(new String[0]); ere is lower and here - do not connvert to array. Wotking with list is much more comfortable. Keep returning list, and fix the users of those calls rather. > + } > + return new String[]{}; > + } From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 16:11:30 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 16:11:30 +0000 Subject: [Bug 1992] New: [IcedTea7] Support retrieving proxy settings on GNOME 3 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1992 Bug ID: 1992 Summary: [IcedTea7] Support retrieving proxy settings on GNOME 3 Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: enhancement Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org https://bugzilla.redhat.com/show_bug.cgi?id=735336 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 16:11:48 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 16:11:48 +0000 Subject: [Bug 1992] [IcedTea7] Support retrieving proxy settings on GNOME 3 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1992 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED URL| |https://bugzilla.redhat.com | |/show_bug.cgi?id=735336 Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Wed Sep 10 16:13:23 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Wed, 10 Sep 2014 16:13:23 +0000 Subject: /hg/icedtea7-forest/jdk: PR1992, RH735336: Support retrieving pr... Message-ID: changeset 9702c7936ed8 in /hg/icedtea7-forest/jdk details: http://icedtea.classpath.org/hg/icedtea7-forest/jdk?cmd=changeset;node=9702c7936ed8 author: andrew date: Wed Sep 10 17:12:24 2014 +0100 PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 diffstat: src/solaris/native/sun/net/spi/DefaultProxySelector.c | 97 +++++++++++------- 1 files changed, 61 insertions(+), 36 deletions(-) diffs (122 lines): diff -r e97e34bd3cc9 -r 9702c7936ed8 src/solaris/native/sun/net/spi/DefaultProxySelector.c --- a/src/solaris/native/sun/net/spi/DefaultProxySelector.c Mon Sep 08 18:46:06 2014 +0100 +++ b/src/solaris/native/sun/net/spi/DefaultProxySelector.c Wed Sep 10 17:12:24 2014 +0100 @@ -149,7 +149,6 @@ if (use_gio == JNI_TRUE || gconf_ver > 0) { jstring jhost; const char *cproto; - char *used_proto; cproto = (*env)->GetStringUTFChars(env, proto, &isCopy); @@ -159,49 +158,75 @@ settings = g_settings_new ("org.gnome.system.proxy"); - use_same_proxy = g_settings_get_boolean (settings, "use-same-proxy"); - if (use_same_proxy) { - used_proto = "http"; - } else { - used_proto = (char*) cproto; - } + if (settings != NULL) { + mode = g_settings_get_string (settings, "mode"); + use_proxy = (mode != NULL && strcasecmp (mode, "manual") == 0); - mode = g_settings_get_string (settings, "mode"); - use_proxy = (mode != NULL && strcasecmp (mode, "manual") == 0); + if (use_proxy) { + child_settings = g_settings_get_child (settings, cproto); + if (child_settings != NULL) { + phost = g_settings_get_string (child_settings, "host"); + pport = g_settings_get_int (child_settings, "port"); + g_object_unref (child_settings); + } - child_settings = g_settings_get_child (settings, used_proto); - if (use_proxy && strcasecmp (used_proto, "http") == 0) { - use_proxy = g_settings_get_boolean (child_settings, "enabled"); - } + /** No specific proxy specified; check fallbacks **/ - if (use_proxy) { - phost = g_settings_get_string (child_settings, "host"); - pport = g_settings_get_int (child_settings, "port"); - } - - ignored = g_settings_get_strv (settings, "ignore-hosts"); - if (ignored != NULL) { - char **ptr; - size_t urlhost_len, s_len; - - urlhost = (*env)->GetStringUTFChars(env, host, &isCopy); - urlhost_len = strlen (urlhost); - if (urlhost != NULL) { - for (ptr = ignored; *ptr != NULL; ++ptr) { - s_len = strlen (*ptr); - if (s_len <= urlhost_len) { - if (strcasecmp (urlhost + (urlhost_len - s_len), *ptr) == 0) { - use_proxy = 0; - break; + /** A http proxy is used for https if https is not set **/ + if (phost == NULL || strlen(phost) == 0 || pport == 0) { + if (strcasecmp(cproto, "https") == 0) { + child_settings = g_settings_get_child (settings, "http"); + if (child_settings != NULL) { + phost = g_settings_get_string (child_settings, "host"); + pport = g_settings_get_int (child_settings, "port"); + g_object_unref (child_settings); } } } - if (isCopy == JNI_TRUE) - (*env)->ReleaseStringUTFChars(env, host, urlhost); + + /** If we requested something else, but have SOCKS, use that **/ + if (phost == NULL || strlen(phost) == 0 || pport == 0) { + if (strcasecmp(cproto, "socks") != 0) { + child_settings = g_settings_get_child (settings, "socks"); + if (child_settings != NULL) { + phost = g_settings_get_string (child_settings, "host"); + pport = g_settings_get_int (child_settings, "port"); + g_object_unref (child_settings); + } + } + } + + /** No proxy set at all **/ + if (phost == NULL || strlen(phost) == 0 || pport == 0) { + use_proxy = 0; + } } + + /** Disable proxy if this is listed as an ignored host **/ + ignored = g_settings_get_strv (settings, "ignore-hosts"); + if (ignored != NULL) { + char **ptr; + size_t urlhost_len, s_len; + + urlhost = (*env)->GetStringUTFChars(env, host, &isCopy); + urlhost_len = strlen (urlhost); + if (urlhost != NULL) { + for (ptr = ignored; *ptr != NULL; ++ptr) { + s_len = strlen (*ptr); + if (s_len <= urlhost_len) { + if (strcasecmp (urlhost + (urlhost_len - s_len), *ptr) == 0) { + use_proxy = 0; + break; + } + } + } + if (isCopy == JNI_TRUE) + (*env)->ReleaseStringUTFChars(env, host, urlhost); + } - g_strfreev (ignored); - g_object_unref (child_settings); + g_strfreev (ignored); + } + g_object_unref (settings); } } else { From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 16:13:32 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 16:13:32 +0000 Subject: [Bug 1992] [IcedTea7] Support retrieving proxy settings on GNOME 3 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1992 --- Comment #1 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7-forest/jdk?cmd=changeset;node=9702c7936ed8 author: andrew date: Wed Sep 10 17:12:24 2014 +0100 PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 16:15:11 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 16:15:11 +0000 Subject: [Bug 1993] New: [IcedTea8] Support retrieving proxy settings on GNOME 3 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1993 Bug ID: 1993 Summary: [IcedTea8] Support retrieving proxy settings on GNOME 3 Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: enhancement Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org https://bugzilla.redhat.com/show_bug.cgi?id=735336 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 16:15:44 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 16:15:44 +0000 Subject: [Bug 1993] [IcedTea8] Support retrieving proxy settings on GNOME 3 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1993 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED URL| |https://bugzilla.redhat.com | |/show_bug.cgi?id=735336 Blocks| |1282 Target Milestone|--- |3.0.0 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 16:15:44 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 16:15:44 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1993 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ldracz at redhat.com Wed Sep 10 16:25:35 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Wed, 10 Sep 2014 12:25:35 -0400 (EDT) Subject: [fyi] [icedtea-web]failing unittest testSetFileNull In-Reply-To: <5410649D.2080506@redhat.com> References: <5410649D.2080506@redhat.com> Message-ID: <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> Hello, > FAILED: > testSetFileNull(net.sourceforge.jnlp.security.policyeditor.PolicyFileModelTest) > Expected > exception: java.lang.NullPointerException > > > Is now appearing. I think thatthis was actually fixed in sources, but > obviously the test was not > adapted. Can responsible person fix? I added a check for if it is null then throw a Null Pointer Exception. Okay to push ? Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: setFileThrowsNPE.patch Type: text/x-patch Size: 501 bytes Desc: not available URL: From jkang at redhat.com Wed Sep 10 17:50:33 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 10 Sep 2014 13:50:33 -0400 (EDT) Subject: [fyi] [icedtea-web]failing unittest testSetFileNull In-Reply-To: <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> References: <5410649D.2080506@redhat.com> <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> Message-ID: <586797042.3123592.1410371433512.JavaMail.zimbra@redhat.com> ----- Original Message ----- > Hello, > > > FAILED: > > testSetFileNull(net.sourceforge.jnlp.security.policyeditor.PolicyFileModelTest) > > Expected > > exception: java.lang.NullPointerException > > > > > > Is now appearing. I think thatthis was actually fixed in sources, but > > obviously the test was not > > adapted. Can responsible person fix? > > I added a check for if it is null then throw a Null Pointer Exception. > > Okay to push ? No. The null value was made acceptable and the test was not updated in response to the change. Please check code usages, etc. before changing functionality. PolicyFileModel::setFile -> PolicyEditorController::setFile : there are calls with setFile(null) that are accepted. This is for the case of a new file with no filepath. The test can probably be removed. Regards, > > Thank you, > Lukasz Dracz > > -- Jie Kang From jkang at redhat.com Wed Sep 10 17:55:11 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 10 Sep 2014 13:55:11 -0400 (EDT) Subject: [fyi] [icedtea-web]failing unittest testSetFileNull In-Reply-To: <586797042.3123592.1410371433512.JavaMail.zimbra@redhat.com> References: <5410649D.2080506@redhat.com> <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> <586797042.3123592.1410371433512.JavaMail.zimbra@redhat.com> Message-ID: <1859742716.3125841.1410371711313.JavaMail.zimbra@redhat.com> ----- Original Message ----- > ----- Original Message ----- > > Hello, > > > > > FAILED: > > > testSetFileNull(net.sourceforge.jnlp.security.policyeditor.PolicyFileModelTest) > > > Expected > > > exception: java.lang.NullPointerException > > > > > > > > > Is now appearing. I think thatthis was actually fixed in sources, but > > > obviously the test was not > > > adapted. Can responsible person fix? > > > > I added a check for if it is null then throw a Null Pointer Exception. > > > > Okay to push ? > > No. The null value was made acceptable and the test was not updated in > response to the change. > > Please check code usages, etc. before changing functionality. Also please run basic tests when you make changes. If you recompile and run policyeditor with this patch it immediately fails to open with an NPE. This is a good sign that the change needs more work. > > PolicyFileModel::setFile -> PolicyEditorController::setFile : there are calls > with setFile(null) that are accepted. This is for the case of a new file > with no filepath. > > > The test can probably be removed. > > > Regards, > > > > > Thank you, > > Lukasz Dracz > > > > > > -- > > Jie Kang > -- Jie Kang From ldracz at redhat.com Wed Sep 10 18:11:15 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Wed, 10 Sep 2014 14:11:15 -0400 (EDT) Subject: [fyi] [icedtea-web]failing unittest testSetFileNull In-Reply-To: <1859742716.3125841.1410371711313.JavaMail.zimbra@redhat.com> References: <5410649D.2080506@redhat.com> <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> <586797042.3123592.1410371433512.JavaMail.zimbra@redhat.com> <1859742716.3125841.1410371711313.JavaMail.zimbra@redhat.com> Message-ID: <637091988.3144804.1410372675019.JavaMail.zimbra@redhat.com> Hello, > > > Hello, > > > > > > > FAILED: > > > > testSetFileNull(net.sourceforge.jnlp.security.policyeditor.PolicyFileModelTest) > > > > Expected > > > > exception: java.lang.NullPointerException > > > > > > > > > > > > Is now appearing. I think thatthis was actually fixed in sources, but > > > > obviously the test was not > > > > adapted. Can responsible person fix? > > > > > > I added a check for if it is null then throw a Null Pointer Exception. > > > > > > Okay to push ? > > > > No. The null value was made acceptable and the test was not updated in > > response to the change. > > > > Please check code usages, etc. before changing functionality. > > > > The test can probably be removed. Alright, Sorry here is updated patch with removed test. Thanks, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: testSetFileNullRemoved.patch Type: text/x-patch Size: 753 bytes Desc: not available URL: From jkang at redhat.com Wed Sep 10 18:31:02 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 10 Sep 2014 14:31:02 -0400 (EDT) Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <54107019.2030106@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> <54107019.2030106@redhat.com> Message-ID: <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/10/2014 04:51 PM, Jie Kang wrote: > > Hello, > > > > This patch moves the translation responsibility from JNLPRuntime to > > Translator. Previously, the Translator contained two one-line functions > > calling methods in JNLPRuntime to perform localization of text. This > > localization is now performed in Translator instead. > > > > Thoughts? > > > Moreover ok.. jsut few thoughts:) > > > Main one - can we get rid of static context? > Well the Transaltor.R() api will probably remain, it would be enormous and > unnecessary refactroing > of every file, but inside may be hidden call to correct lazy-loading > singleton.... hm? > > > > > ... > > + */ > > + private static String getMessage(String key, Object... args) { > > + return MessageFormat.format(getMessage(key), args); > > + } > > > Second though. Is this method worthy? if so(and it is..), should be tested :) > > And the testing will me much more simple if this class will be possible to > instantiate.... Hello, Good points. I have made Translator an enum with a single instance where the public static String R still remains and added basic unit tests for Translator. Thoughts? Thanks, > > > ty! > > J. > > > -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-translator-1.patch Type: text/x-patch Size: 10406 bytes Desc: not available URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 20:35:16 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 20:35:16 +0000 Subject: [Bug 1994] New: [IcedTea8] make dist broken Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1994 Bug ID: 1994 Summary: [IcedTea8] make dist broken Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org make: *** No rule to make target '../icedtea8/patches/debian/*.patch', needed by 'distdir'. Stop. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 20:35:34 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 20:35:34 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |1994 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 10 20:35:34 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 10 Sep 2014 20:35:34 +0000 Subject: [Bug 1994] [IcedTea8] make dist broken In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1994 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Blocks| |1282 Target Milestone|--- |3.0.0 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From aazores at redhat.com Thu Sep 11 00:15:50 2014 From: aazores at redhat.com (Andrew Azores) Date: Wed, 10 Sep 2014 20:15:50 -0400 Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> <54107019.2030106@redhat.com> <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> Message-ID: <5410E9B6.2030808@redhat.com> On 09/10/2014 02:31 PM, Jie Kang wrote: > > Hello, > > > Good points. I have made Translator an enum with a single instance where the public static String R still remains and added basic unit tests for Translator. > > Overall I definitely like the idea behind this patch. Just a few minor implementation details I have some questions about. > public static String R(String message) { > - return JNLPRuntime.getMessage(message); > + return getInstance().getMessage(message); > } Can this be defined in terms of Translator.R(String, Object...) instead? Not a big deal but it seems natural to me. > + public static void loadResourceBundle(ResourceBundle bundle) { > + getInstance().resources = bundle; > + } Why is this still static? I think this makes sense as a method belonging to the singleton instance, and I only see one call site (TranslatorTest) that would need to be refactored. I would also rather see a (package-private?) setter method rather than direct field assignment here, but that's not a huge deal. > + } catch (Exception ex) { > + throw new IllegalStateException("Missing resource bundle in netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); > + } Is this path correct even for non-default (English) locales? Eg for Czech shouldn't it be attempting (and failing) to load net/sourceforge/jnlp/resource/Messages_cs.properties? I'm not sure how easy it is to get the name of the ResourceBundle that the runtime would attempt to load however, it may not be worth the effort - this is a pretty close approximation anyway even for other locales I suppose. Thanks, -- Andrew Azores From gitne at gmx.de Thu Sep 11 01:38:00 2014 From: gitne at gmx.de (Jacob Wisor) Date: Thu, 11 Sep 2014 03:38:00 +0200 Subject: [rfc][icedtea-web] IcedTea-Web for Windows Message-ID: <5410FCF8.7040600@gmx.de> Hello there! I was thinking about bringing IcedTea-Web to Windows for quite some time now. So I have looked into the current plug-in code for Un*x systems. Unfortunately, it has dependencies on pthreads and GTK+. Although these could be compiled in statically, this would actually not solve all the problems to it. Mainly, three things would not work. First, error logging. Because Windows has slightly different pipe and IPC semantics to POSIX the current code makes to many assumptions on their behavior while only applicable to POSIX. Although I am pretty sure the GTK+ library tries to resemble POSIX semantics as close as possible, or abstract them away with its concept of channels, I am also sure that we would run into some bogus and hard to track down bugs later on. Error logging from Java applications has to be designed on Windows quite differently. Second, sub-process shutdown. Windows has some quite different process semantics than POSIX. Terminating the JVM in-process server in Windows properly requires really Windows specific code. Ports of pthreads and GTK+ won't do much here. Third, plug-in registration, detection, and install/uninstall. These tasks involve the Windows registry, which of course is highly Windows specific. GTK+ has nothing to offer here. And lastly (or forth), getting the plug-in on the Internet Explorer is absolutely impossible without registering and providing a scriptable COM component. While Mozilla compatible browsers can load plug-ins from designated folders, the Internet Explorer relies entirely on the OLE server and COM infrastructure, so registration is required. So, why bother about IE anyway? Well, it's like the No. 1 browser on the Windows platform. Without support for IE, most people will have even less incentive to use open-source IcedTea-Web. Long story short, I came to the conclusion that it is probably best to start implementing Windows specific code now and to blend it with the existing Un*x code later. At this stage, the plug-in does not do much, except for registering the plug-in with Mozilla compatible browsers and COM. However, you won't see it in the list of Add-ons in IE. Simply because IE requires an implemented IOleObject interface, which I did not come to yet. ;-) But, the plug-in does show up in Mozilla compatible browsers! I have been trying to test the Chrome browser too but to no avail. So far, I have been building and testing the 64 bit version only. How to build True to IcedTea's motto, you will not need any proprietary or closed source tools to build. However, you will need MinGW, mingw-make, XulRunner SDK (a Linux package works too), and OpenJDK with Windows headers. Actually, I have been coding in F20 entirely, and the only thing I had to pull manually were the JVM Windows headers, hence you should be good on almost every Linux distro. Before building, look into the Makefile.mingw file to setup your paths or to find out about the make variables to set on the command line. Then invoke mingw-make -C plugin/icedteanp/windows -f Makefile.mingw all or for the 64 bit version mingw-make -C plugin/icedteanp/windows -f Makefile.mingw \ PROCESSOR_ARCHITECTURE=AMD64 all I have designed the make file to build on Un*x and Windows systems, although I have not tested building on Windows yet. Have fun and thank you for reviewing! Jacob -------------- next part -------------- A non-text attachment was scrubbed... Name: IcedTea-Web DLL properties.png Type: image/png Size: 12201 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: IcedTea-Web in Mozilla Nigtly x64 for Windows.png Type: image/png Size: 88363 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Windows plug-in.patch Type: text/x-patch Size: 163359 bytes Desc: not available URL: From jvanek at redhat.com Thu Sep 11 08:32:48 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 11 Sep 2014 10:32:48 +0200 Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <5410E9B6.2030808@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> <54107019.2030106@redhat.com> <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> <5410E9B6.2030808@redhat.com> Message-ID: <54115E30.70507@redhat.com> On 09/11/2014 02:15 AM, Andrew Azores wrote: > On 09/10/2014 02:31 PM, Jie Kang wrote: >> >> Hello, >> >> >> Good points. I have made Translator an enum with a single instance where the public static String >> R still remains and added basic unit tests for Translator. >> >> > > Overall I definitely like the idea behind this patch. Just a few minor implementation details I have > some questions about. > >> public static String R(String message) { >> - return JNLPRuntime.getMessage(message); >> + return getInstance().getMessage(message); >> } > > Can this be defined in terms of Translator.R(String, Object...) instead? Not a big deal but it seems > natural to me. > >> + public static void loadResourceBundle(ResourceBundle bundle) { >> + getInstance().resources = bundle; >> + } > > Why is this still static? I think this makes sense as a method belonging to the singleton instance, > and I only see one call site (TranslatorTest) that would need to be refactored. I would also rather > see a (package-private?) setter method rather than direct field assignment here, but that's not a > huge deal. good catch >> + } catch (Exception ex) { >> + throw new IllegalStateException("Missing resource bundle in >> netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); >> + } > > Is this path correct even for non-default (English) locales? Eg for Czech shouldn't it be attempting Afaik the patch is correct. The JVM is handling the locales rename. Anyway Jies responsibility to try vith various de_DE or de_DE..UTF8 or DE... and similar... > (and failing) to load net/sourceforge/jnlp/resource/Messages_cs.properties? I'm not sure how easy it > is to get the name of the ResourceBundle that the runtime would attempt to load however, it may not > be worth the effort - this is a pretty close approximation anyway even for other locales I suppose. > > Thanks, From zzambers at redhat.com Thu Sep 11 09:19:08 2014 From: zzambers at redhat.com (=?UTF-8?B?WmRlbsSbayDFvWFtYmVyc2vDvQ==?=) Date: Thu, 11 Sep 2014 11:19:08 +0200 Subject: patch: some initial fixes Message-ID: <5411690C.8000808@redhat.com> 2014-09-10 Zdenek Zambersky * Makefile: Removed references to non-existing classes IconCut and PatternDefinitionsGenerator, which prevented from successful build. * src/org/thermostat/qa/common/Configuration.java(readAllProperties): Fixed problem with paths not ending with separator. Added method getPathProperty. * patterns/1.1.0/AA/MainWindow/host_icon_with_arrow.png: Added missing files needed by DBGuiHeapDumpTest. (Copied from patterns/1.1.0/noAA/MainWindow.) * patterns/1.1.0/AA/MainWindow/vm_icon_blue2.png: same * patterns/1.1.0/AA/MainWindow/vm_icon_whiteblue.png: same * .hgignore: Excludes files generated (by makefile, tests, ...) from being tracked. * scripts/mongoPortNumber.txt: removed * scripts/run_thermostat_shell_with_commands.sh: removed Removed files. These are generated by tests. -------------- next part -------------- A non-text attachment was scrubbed... Name: ThermostatQA-initial-fixes.diff Type: text/x-patch Size: 4462 bytes Desc: not available URL: From jvanek at redhat.com Thu Sep 11 09:19:19 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 11 Sep 2014 11:19:19 +0200 Subject: [fyi] [icedtea-web]failing unittest testSetFileNull In-Reply-To: <637091988.3144804.1410372675019.JavaMail.zimbra@redhat.com> References: <5410649D.2080506@redhat.com> <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> <586797042.3123592.1410371433512.JavaMail.zimbra@redhat.com> <1859742716.3125841.1410371711313.JavaMail.zimbra@redhat.com> <637091988.3144804.1410372675019.JavaMail.zimbra@redhat.com> Message-ID: <54116917.5050001@redhat.com> On 09/10/2014 08:11 PM, Lukasz Dracz wrote: > Hello, > >>>> Hello, >>>> >>>>> FAILED: >>>>> testSetFileNull(net.sourceforge.jnlp.security.policyeditor.PolicyFileModelTest) >>>>> Expected >>>>> exception: java.lang.NullPointerException >>>>> >>>>> >>>>> Is now appearing. I think thatthis was actually fixed in sources, but >>>>> obviously the test was not >>>>> adapted. Can responsible person fix? >>>> >>>> I added a check for if it is null then throw a Null Pointer Exception. >>>> >>>> Okay to push ? >>> >>> No. The null value was made acceptable and the test was not updated in >>> response to the change. >>> >>> Please check code usages, etc. before changing functionality. >>> >>> The test can probably be removed. > > Alright, Sorry here is updated patch with removed test. > > Thanks, > Lukasz Dracz > No removal. Ensure that it works correctly even with null parameter. There is no similar test. J. From jvanek at redhat.com Thu Sep 11 09:27:08 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 11 Sep 2014 11:27:08 +0200 Subject: patch: some initial fixes In-Reply-To: <5411690C.8000808@redhat.com> References: <5411690C.8000808@redhat.com> Message-ID: <54116AEC.4090004@redhat.com> Hi Zdenek, Thank you for contribution. Unluckily I advised you bad list. This belongs to thermostat at icedtea.classpath.org. Few minor notes The subject should be more descriptive and with heading: [rfc][thermostatQA] making thermostat QA buildable again. On 09/11/2014 11:19 AM, Zden?k ?ambersk? wrote: > 2014-09-10 Zdenek Zambersky > Summary is missing here - it should be similar to subject. > * Makefile: Removed references to non-existing classes IconCut and PatternDefinitionsGenerator, > which prevented from successful build. > * src/org/thermostat/qa/common/Configuration.java(readAllProperties): > Fixed problem with paths not ending with separator. Added method getPathProperty. > * patterns/1.1.0/AA/MainWindow/host_icon_with_arrow.png: Added missing files needed by > DBGuiHeapDumpTest. (Copied from patterns/1.1.0/noAA/MainWindow.) > * patterns/1.1.0/AA/MainWindow/vm_icon_blue2.png: same > * patterns/1.1.0/AA/MainWindow/vm_icon_whiteblue.png: same > * .hgignore: Excludes files generated (by makefile, tests, ...) from being tracked. > * scripts/mongoPortNumber.txt: removed > * scripts/run_thermostat_shell_with_commands.sh: removed > Removed files. These are generated by tests. > > ThermostatQA-initial-fixes.diff > > > diff -r 5abf85c4d3ba .hgignore > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/.hgignore Thu Sep 11 10:49:44 2014 +0200 > @@ -0,0 +1,24 @@ > +syntax:glob > + > +bin/** # compiled classes > +thermostat/** # thermostat tested > +apache-tomcat/** # tomcat used for testing I'm not sure if thermostat and apache-tomcat should be there. They sould be compeltly awayand path to them should be .. somewhere specified. > +logs/** # logs from tests > +reports/** # reports from tests > +screenshots/** # screenshots from tests > +manifest.mf # generated by build phase > +.attach_pid* # created by tests > +prototype.flotr-0.2.0-alpha.zip # downloaded by makefile > + > +# auto-generated scripts and text files > +scripts/webStorage_*.sh > +scripts/thermostatPingHost.sh > +scripts/thermostatListVms.sh > +scripts/thermostatDumpHeap.sh > +scripts/xvfb*.sh > +scripts/guitests-cleanOneTest.sh > +scripts/run_thermostat_shell_with_commands.sh > +scripts/run_mongo_shell_with_commands.sh > +scripts/mongoPortNumber.txt > +scripts/dblogin.txt > + > diff -r 5abf85c4d3ba Makefile > --- a/Makefile Mon Apr 28 16:13:20 2014 +0200 > +++ b/Makefile Thu Sep 11 10:49:44 2014 +0200 > @@ -82,8 +82,6 @@ > $(BUILD_DIR)/$(FRAMEWORK_PACKAGE)/ThermostatOutputTextsGenerator.class \ > $(BUILD_DIR)/$(FRAMEWORK_PACKAGE)/GuiRobot.class \ > $(BUILD_DIR)/$(FRAMEWORK_PACKAGE)/Patterns.class \ > - $(BUILD_DIR)/$(FRAMEWORK_PACKAGE)/IconCut.class \ > - $(BUILD_DIR)/$(FRAMEWORK_PACKAGE)/PatternDefinitionsGenerator.class \ > $(BUILD_DIR)/$(TEST_PACKAGE)/AgentTest.class \ > $(BUILD_DIR)/$(TEST_PACKAGE)/CliClientSmokeTest.class \ > $(BUILD_DIR)/$(TEST_PACKAGE)/GuiClientSmokeTest.class \ > diff -r 5abf85c4d3ba patterns/1.1.0/AA/MainWindow/host_icon_with_arrow.png > Binary file patterns/1.1.0/AA/MainWindow/host_icon_with_arrow.png has changed > diff -r 5abf85c4d3ba patterns/1.1.0/AA/MainWindow/vm_icon_blue2.png > Binary file patterns/1.1.0/AA/MainWindow/vm_icon_blue2.png has changed > diff -r 5abf85c4d3ba patterns/1.1.0/AA/MainWindow/vm_icon_whiteblue.png > Binary file patterns/1.1.0/AA/MainWindow/vm_icon_whiteblue.png has changed > diff -r 5abf85c4d3ba scripts/mongoPortNumber.txt Well the handling of images by duplicating them is not hte best way:(. But fix of this is beyond scope of this patch. After agreed above minors, I think it will be ok to push. Ty for your first contribution! J:) From jvanek at redhat.com Thu Sep 11 10:03:52 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 11 Sep 2014 12:03:52 +0200 Subject: [rfc][icedtea-web] IcedTea-Web for Windows In-Reply-To: <5410FCF8.7040600@gmx.de> References: <5410FCF8.7040600@gmx.de> Message-ID: <54117388.3030601@redhat.com> On 09/11/2014 03:38 AM, Jacob Wisor wrote: > Hello there! > > I was thinking about bringing IcedTea-Web to Windows for quite some time now. So I have looked into > the current plug-in code for Un*x systems. Unfortunately, it has dependencies on pthreads and GTK+. > Although these could be compiled in statically, this would actually not solve all the problems to it. > Mainly, three things would not work. > First, error logging. Because Windows has slightly different pipe and IPC semantics to POSIX the > current code makes to many assumptions on their behavior while only applicable to POSIX. Although I > am pretty sure the GTK+ library tries to resemble POSIX semantics as close as possible, or abstract > them away with its concept of channels, I am also sure that we would run into some bogus and hard to > track down bugs later on. Error logging from Java applications has to be designed on Windows quite > differently. > > Second, sub-process shutdown. Windows has some quite different process semantics than POSIX. > Terminating the JVM in-process server in Windows properly requires really Windows specific code. > Ports of pthreads and GTK+ won't do much here. > > Third, plug-in registration, detection, and install/uninstall. These tasks involve the Windows > registry, which of course is highly Windows specific. GTK+ has nothing to offer here. And lastly (or > forth), getting the plug-in on the Internet Explorer is absolutely impossible without registering > and providing a scriptable COM component. While Mozilla compatible browsers can load plug-ins from > designated folders, the Internet Explorer relies entirely on the OLE server and COM infrastructure, > so registration is required. So, why bother about IE anyway? Well, it's like the No. 1 browser on > the Windows platform. Without support for IE, most people will have even less incentive to use > open-source IcedTea-Web. > > Long story short, I came to the conclusion that it is probably best to start implementing Windows > specific code now and to blend it with the existing Un*x code later. Do you think it is even possible? > > At this stage, the plug-in does not do much, except for registering the plug-in with Mozilla > compatible browsers and COM. However, you won't see it in the list of Add-ons in IE. Simply because > IE requires an implemented IOleObject interface, which I did not come to yet. ;-) But, the plug-in > does show up in Mozilla compatible browsers! I have been trying to test the Chrome browser too but > to no avail. So far, I have been building and testing the 64 bit version only. > > How to build > > True to IcedTea's motto, you will not need any proprietary or closed source tools to build. However, > you will need MinGW, mingw-make, XulRunner SDK (a Linux package works too), and OpenJDK with Windows > headers. Actually, I have been coding in F20 entirely, and the only thing I had to pull manually > were the JVM Windows headers, hence you should be good on almost every Linux distro. > Before building, look into the Makefile.mingw file to setup your paths or to find out about the make > variables to set on the command line. Then invoke > > mingw-make -C plugin/icedteanp/windows -f Makefile.mingw all > > or for the 64 bit version > > mingw-make -C plugin/icedteanp/windows -f Makefile.mingw \ > PROCESSOR_ARCHITECTURE=AMD64 all > > I have designed the make file to build on Un*x and Windows systems, although I have not tested > building on Windows yet. > > Have fun and thank you for reviewing! > Oh this is magnificent chnageset! I have absolutely nothing about windows specific part of this patch. I'm also compltly out of skill on this field. So the sources of this part are (from my side) always ok to go freely. Some comments to > > IcedTea-Web DLL properties.png > > > > IcedTea-Web in Mozilla Nigtly x64 for Windows.png > > > > Windows plug-in.patch > > > diff --git a/.hgignore b/.hgignore > --- a/.hgignore > +++ b/.hgignore > @@ -1,13 +1,23 @@ > -Makefile.in > -aclocal.m4 > -autom4te.cache > +Makefile\.in > +aclocal\.m4 > +autom4te\.cache > build > configure > install-sh > missing > -config.guess > -config.sub > -netx/net/sourceforge/jnlp/resources/AUTHORS.html > -netx/net/sourceforge/jnlp/resources/COPYING.html > -netx/net/sourceforge/jnlp/resources/ChangeLog.html > -netx/net/sourceforge/jnlp/resources/NEWS.html > +config\.guess > +config\.sub > +.+\.patch > +.+\.[Rr][Ee][Ss] > +.+\.(o|[Oo][Bb][Jj]) > +.+\.[Ee][Xx][Ee] > +.+\.(so|[Dd][Ll]{2}) > +.+\.(a|[Ll][Ii][Bb]) > +.+\.[Mm][Ss][Ii] > +.+\.rpm > +.+\.[Xx][Pp][Ii] > +(\.settings|\.project|\.cproject) > +netx/net/sourceforge/jnlp/resources/AUTHORS\.html > +netx/net/sourceforge/jnlp/resources/COPYING\.html > +netx/net/sourceforge/jnlp/resources/ChangeLog\.html > +netx/net/sourceforge/jnlp/resources/NEWS\.html Except the .project this part is ok to go as separate changeset. .project, is legacy habit to include classapth code style modules for eclipse in main trunk. Personally I'm for removing those, and uplaod them for download to http://icedtea.classpath.org/wiki/IcedTea-Web#Code_style Once uploaded and deleted, .project can be excluded. > diff --git a/javaws.ico b/javaws.ico > new file mode 100644 > index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..d8f848b89ffe5b7986e83e1d4d0a250c40ac6afb Why this? The ico is same as javaws.png. So I would inlicne to runtime generation from jaavws.png to javaws.ico. Also - why not to use png? Ifabove seems to be unacceptable, then I would move this icon to windows folder. > GIT binary patch > literal 77494 > zc%1EB2S5`^7vA&)2uVmn at 4a^r1gT<|rhrtj04f$#P!SPSR1`s^BX-4J(6cLwsMxWc > zo?Yx zJ3&{NHu;q)P3aebq6(`8!(@>R#C?BGW-Mv)BI&o8ekA=jr${9KG(UjCVzqbxk{_GD > zpd-iM^uPo at KgZid0E*9#;qw#P@>lTrYg&-k+F#o-zY3qf>2;bIkkC z)s7$2>@R8Y`fd0r&Hjo``fFOSqqV=b1$#IQNNC63>_r&Rj-TiC*(pq at Kd}XScnbG6 > z{1q);w?lpvUVlw%zay`|me1eNf*tG^WVJxc*Xe*C)6$>F=Px0&^jGlvDJ}hQN!Y^g > Q*wSCi?@ti!Z)o!W4+)&_H~;_u > > diff --git a/plugin/icedteanp/windows/GUIDs.c b/plugin/icedteanp/windows/GUIDs.c > new file mode 100644 > --- /dev/null > +++ b/plugin/icedteanp/windows/GUIDs.c ... > diff --git a/plugin/icedteanp/windows/IcedTea-Web.h b/plugin/icedteanp/windows/IcedTea-Web.h > new file mode 100644 > --- /dev/null > +++ b/plugin/icedteanp/windows/IcedTea-Web.h .... > diff --git a/plugin/icedteanp/windows/IcedTea-Web.rc b/plugin/icedteanp/windows/IcedTea-Web.rc > new file mode 100644 > --- /dev/null > +++ b/plugin/icedteanp/windows/IcedTea-Web.rc ...Well.. What to say.. Really magnificent. ... those? > +#endif /* HAVE_JAVA8 */ > + > +#ifndef ICEDTEA_WEB_MIME_TYPES > +#define ICEDTEA_WEB_MIME_TYPES \ > + "application/x-java-applet|" \ > + "application/x-java-applet|" \ > + "application/x-java-applet;version=1.1|" \ > + "application/x-java-applet;version=1.1|" \ > + "application/x-java-applet;version=1.1.1|" \ > + "application/x-java-applet;version=1.1.1|" \ > + "application/x-java-applet;version=1.1.2|" \ >... > + "application/x-java-bean;version=1.6|" \ > + "application/x-java-bean;version=1.6|" \ > + "application/x-java-bean;version=1.7|" \ > + "application/x-java-bean;version=1.7|" \ > + PLUGIN_BEAN_MIME_DESC \ > + PLUGIN_BEAN_MIME_DESC \ ...those... > +// "class|jar|" > +// "class|jar|" > +// "class|jar|" > +// "class|jar|" > +// "class|jar|" > +// "class|jar|" > +// "class|jar|" > +// "jnlp|" > +// "class|jar" > +// VALUE "FileOpenName", "Java-Klassendatei (*.class)|" > +// "Java-Archiv (*.jar)|" > +// "Java-Klassendatei (*.class)|" > +// "Java-Archiv (*.jar)|" > +// "Java-Klassendatei (*.class)|" > +// "Java-Archiv (*.jar)|" > +// "Java-Klassendatei (*.class)|" > +// "Java-Archiv (*.jar)|" ...those... > + "class|jar|" > + "class|jar|" > + "class|jar|" > + "class|jar|" > + "class|jar|" > + "jnlp|" > + "class|jar" > + VALUE "FileOpenName", "Java Class File (*.class)|" > + "Java Archive (*.jar)|" > + "Java Class File (*.class)|" > + "Java Archive (*.jar)|" > + "Java Class File (*.class)|" > + "Java Archive (*.jar)|" > + "Java Class File (*.class)|" > + "Java Archive (*.jar)|" > + "Java Class File (*.class)|" > + "Java Archive (*.jar)|" > + "Java Class File (*.class)|" ...those... > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)|" > +// "Aplikacja JNLP (*.jnlp)|" > +// "Plik Klassy Java (*.class)|" > +// "Archiwum Java (*.jar)" > +// VALUE "Language", "pl" > +// } > + } and those ^ seems to me like most easy to be belnded. Together with ITW But defintiely not as this changeset. > + > + BLOCK "VarFileInfo" { > + VALUE "Translation", LANG_CZECH, 1250, /* Czech */ > + LANG_GERMAN, 1252, /* German */ > + LANG_ENGLISH, 1252, /* English */ > + LANG_POLISH, 1250 /* Polish */ > + } > +} > + > +ID_ICON ICON "../../../javaws.ico" > + > +STRINGTABLE LANGUAGE LANG_CZECH, SUBLANG_DEFAULT { > + IDS_FRIENDLYTYPENAME "JNLP aplikace" > +} > + > +STRINGTABLE LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT { > + IDS_FRIENDLYTYPENAME "JNLP Application" > + IDS_OPEN "&Open" > +} > + > +STRINGTABLE LANGUAGE LANG_GERMAN, SUBLANG_DEFAULT { > + IDS_FRIENDLYTYPENAME "JNLP-Anwendung" > + IDS_OPEN "?&ffnen" > +} > + > +STRINGTABLE LANGUAGE LANG_POLISH, SUBLANG_DEFAULT { > + IDS_FRIENDLYTYPENAME "Aplikacja JNLP" > + IDS_OPEN "O&tw?rz" > +} > + > +#else /* OS2 */ > +#include > + > +NP_INFO_ProductVersion RC_DATA { > + PACKAGE_MAJOR_VERSION, > + PACKAGE_MINOR_VERSION, > + PACKAGE_PATCH_VERSION, > + PACKAGE_BUILD_VERSION > +} > +NP_INFO_MIMEType RC_DATA { > + ICEDTEA_WEB_MIME_TYPES "\0" > +} > +NP_INFO_FileOpenName RC_DATA { > + "Java Class File (*.class)|" > + "Java Archive (*.jar)|" > + "JNLP Application (*.jnlp)|\0" > +} > +NP_INFO_FileExtents RC_DATA { > + "class|jar|jnlp\0" > +} > +NP_INFO_FileDescription RC_DATA { > + PACKAGE_DESCRIPTION "\0" > +} > +NP_INFO_ProductName RC_DATA { > + PACKAGE_NAME "\0" > +} > +NP_INFO_CompanyName RC_DATA { > + PACKAGE_VENDOR "\0" > +} > +NP_INFO_FileVersion RC_DATA { > + PACKAGE_MAJOR_VERSION, > + PACKAGE_MINOR_VERSION, > + PACKAGE_PATCH_VERSION, > + PACKAGE_BUILD_VERSION > +} > +NP_INFO_InternalName RC_DATA { > + "NP" PACKAGE_NAME "\0" > +} > +NP_INFO_LegalCopyright RC_DATA { > + "GPLv2, see the file COPYING for details\0" > +} > +NP_INFO_OriginalFilename RC_DATA { > + "NP" PACKAGE_NAME ".DLL\0" > +} > +#endif /* OS2 */ > +#endif /* RC_INVOKED */ > +#endif /*_ICEDTEA_WEB_RC_ */ > diff --git a/plugin/icedteanp/windows/IcedTeaIEPlugin.c b/plugin/icedteanp/windows/IcedTeaIEPlugin.c > new file mode 100644 > --- /dev/null > +++ b/plugin/icedteanp/windows/IcedTeaIEPlugin.c > @@ -0,0 +1,2191 @@ > +#define INC_OLE2 > +#include > +#include ... http://en.wiktionary.org/wiki/to_je_pro_m%C4%9B_%C5%A1pan%C4%9Blsk%C3%A1_vesnice :)) > +} > diff --git a/plugin/icedteanp/windows/IcedTeaIEPlugin.h b/plugin/icedteanp/windows/IcedTeaIEPlugin.h > new file mode 100644 > --- /dev/null > +++ b/plugin/icedteanp/windows/IcedTeaIEPlugin.h > @@ -0,0 +1,3 @@ ....still the same. > \ No newline at end of file > Well one general hint - Maybe its the time to restructure plugin directory? I would go for something like plugin/windows/src (your "c a nd rest" files) plugin/windows/build (mingw make or whatever you may need for build (the ico if you will insists?-) ) )) plugin/linux/src (current icedteanp) plugin/linux/build? And so extract plugin parts from main makefile? plugin/share/java (current current java) plugin/share/docs plugin/share/tests This si just idea, not necessary for this changeset or at all. And can be complicated to do... J. From jvanek at redhat.com Thu Sep 11 10:07:41 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 11 Sep 2014 12:07:41 +0200 Subject: [rfc][icedtea-web] IcedTea-Web for Windows In-Reply-To: <54117388.3030601@redhat.com> References: <5410FCF8.7040600@gmx.de> <54117388.3030601@redhat.com> Message-ID: <5411746D.7070002@redhat.com> On 09/11/2014 12:03 PM, Jiri Vanek wrote: > On 09/11/2014 03:38 AM, Jacob Wisor wrote: >> Hello there! >> >> I was thinking about bringing IcedTea-Web to Windows for quite some time now. So I have looked into >> the current plug-in code for Un*x systems. Unfortunately, it has dependencies on pthreads and GTK+. >> Although these could be compiled in statically, this would actually not solve all the problems to it. >> Mainly, three things would not work. >> First, error logging. Because Windows has slightly different pipe and IPC semantics to POSIX the >> current code makes to many assumptions on their behavior while only applicable to POSIX. Although I >> am pretty sure the GTK+ library tries to resemble POSIX semantics as close as possible, or abstract >> them away with its concept of channels, I am also sure that we would run into some bogus and hard to >> track down bugs later on. Error logging from Java applications has to be designed on Windows quite >> differently. >> >> Second, sub-process shutdown. Windows has some quite different process semantics than POSIX. >> Terminating the JVM in-process server in Windows properly requires really Windows specific code. >> Ports of pthreads and GTK+ won't do much here. >> >> Third, plug-in registration, detection, and install/uninstall. These tasks involve the Windows >> registry, which of course is highly Windows specific. GTK+ has nothing to offer here. And lastly (or >> forth), getting the plug-in on the Internet Explorer is absolutely impossible without registering >> and providing a scriptable COM component. While Mozilla compatible browsers can load plug-ins from >> designated folders, the Internet Explorer relies entirely on the OLE server and COM infrastructure, >> so registration is required. So, why bother about IE anyway? Well, it's like the No. 1 browser on >> the Windows platform. Without support for IE, most people will have even less incentive to use >> open-source IcedTea-Web. >> >> Long story short, I came to the conclusion that it is probably best to start implementing Windows >> specific code now and to blend it with the existing Un*x code later. > > Do you think it is even possible? > >> >> At this stage, the plug-in does not do much, except for registering the plug-in with Mozilla >> compatible browsers and COM. However, you won't see it in the list of Add-ons in IE. Simply because >> IE requires an implemented IOleObject interface, which I did not come to yet. ;-) But, the plug-in >> does show up in Mozilla compatible browsers! I have been trying to test the Chrome browser too but >> to no avail. So far, I have been building and testing the 64 bit version only. >> >> How to build >> >> True to IcedTea's motto, you will not need any proprietary or closed source tools to build. However, >> you will need MinGW, mingw-make, XulRunner SDK (a Linux package works too), and OpenJDK with Windows >> headers. Actually, I have been coding in F20 entirely, and the only thing I had to pull manually >> were the JVM Windows headers, hence you should be good on almost every Linux distro. >> Before building, look into the Makefile.mingw file to setup your paths or to find out about the make >> variables to set on the command line. Then invoke >> >> mingw-make -C plugin/icedteanp/windows -f Makefile.mingw all >> >> or for the 64 bit version >> >> mingw-make -C plugin/icedteanp/windows -f Makefile.mingw \ >> PROCESSOR_ARCHITECTURE=AMD64 all >> >> I have designed the make file to build on Un*x and Windows systems, although I have not tested >> building on Windows yet. >> >> Have fun and thank you for reviewing! >> > > Oh this is magnificent chnageset! > > I have absolutely nothing about windows specific part of this patch. I'm also compltly out of skill > on this field. So the sources of this part are (from my side) always ok to go freely. > > Some comments to >> >> IcedTea-Web DLL properties.png >> >> >> >> IcedTea-Web in Mozilla Nigtly x64 for Windows.png >> >> >> >> Windows plug-in.patch >> >> >> diff --git a/.hgignore b/.hgignore >> --- a/.hgignore >> +++ b/.hgignore >> @@ -1,13 +1,23 @@ >> -Makefile.in >> -aclocal.m4 >> -autom4te.cache >> +Makefile\.in >> +aclocal\.m4 >> +autom4te\.cache >> build >> configure >> install-sh >> missing >> -config.guess >> -config.sub >> -netx/net/sourceforge/jnlp/resources/AUTHORS.html >> -netx/net/sourceforge/jnlp/resources/COPYING.html >> -netx/net/sourceforge/jnlp/resources/ChangeLog.html >> -netx/net/sourceforge/jnlp/resources/NEWS.html >> +config\.guess >> +config\.sub >> +.+\.patch >> +.+\.[Rr][Ee][Ss] >> +.+\.(o|[Oo][Bb][Jj]) >> +.+\.[Ee][Xx][Ee] >> +.+\.(so|[Dd][Ll]{2}) >> +.+\.(a|[Ll][Ii][Bb]) >> +.+\.[Mm][Ss][Ii] >> +.+\.rpm >> +.+\.[Xx][Pp][Ii] >> +(\.settings|\.project|\.cproject) >> +netx/net/sourceforge/jnlp/resources/AUTHORS\.html >> +netx/net/sourceforge/jnlp/resources/COPYING\.html >> +netx/net/sourceforge/jnlp/resources/ChangeLog\.html >> +netx/net/sourceforge/jnlp/resources/NEWS\.html > > Except the .project this part is ok to go as separate changeset. > > .project, is legacy habit to include classapth code style modules for eclipse in main trunk. > > Personally I'm for removing those, and uplaod them for download to > http://icedtea.classpath.org/wiki/IcedTea-Web#Code_style > > Once uploaded and deleted, .project can be excluded. > >> diff --git a/javaws.ico b/javaws.ico >> new file mode 100644 >> index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..d8f848b89ffe5b7986e83e1d4d0a250c40ac6afb > > Why this? The ico is same as javaws.png. So I would inlicne to runtime generation from jaavws.png to > javaws.ico. > Also - why not to use png? > > > Ifabove seems to be unacceptable, then I would move this icon to windows folder. >> GIT binary patch >> literal 77494 >> zc%1EB2S5`^7vA&)2uVmn at 4a^r1gT<|rhrtj04f$#P!SPSR1`s^BX-4J(6cLwsMxWc >> zo?Yx > ...snip... > >> zJ3&{NHu;q)P3aebq6(`8!(@>R#C?BGW-Mv)BI&o8ekA=jr${9KG(UjCVzqbxk{_GD >> zpd-iM^uPo at KgZid0E*9#;qw#P@>lTrYg&-k+F#o-zY3qf>2;bIkkC> z)s7$2>@R8Y`fd0r&Hjo``fFOSqqV=b1$#IQNNC63>_r&Rj-TiC*(pq at Kd}XScnbG6 >> z{1q);w?lpvUVlw%zay`|me1eNf*tG^WVJxc*Xe*C)6$>F=Px0&^jGlvDJ}hQN!Y^g >> Q*wSCi?@ti!Z)o!W4+)&_H~;_u >> >> diff --git a/plugin/icedteanp/windows/GUIDs.c b/plugin/icedteanp/windows/GUIDs.c >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/GUIDs.c > ... >> diff --git a/plugin/icedteanp/windows/IcedTea-Web.h b/plugin/icedteanp/windows/IcedTea-Web.h >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/IcedTea-Web.h > .... >> diff --git a/plugin/icedteanp/windows/IcedTea-Web.rc b/plugin/icedteanp/windows/IcedTea-Web.rc >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/IcedTea-Web.rc > > ...Well.. What to say.. Really magnificent. > ... > > those? >> +#endif /* HAVE_JAVA8 */ >> + >> +#ifndef ICEDTEA_WEB_MIME_TYPES >> +#define ICEDTEA_WEB_MIME_TYPES \ >> + "application/x-java-applet|" \ >> + "application/x-java-applet|" \ >> + "application/x-java-applet;version=1.1|" \ >> + "application/x-java-applet;version=1.1|" \ >> + "application/x-java-applet;version=1.1.1|" \ >> + "application/x-java-applet;version=1.1.1|" \ >> + "application/x-java-applet;version=1.1.2|" \ >> ... >> + "application/x-java-bean;version=1.6|" \ >> + "application/x-java-bean;version=1.6|" \ >> + "application/x-java-bean;version=1.7|" \ >> + "application/x-java-bean;version=1.7|" \ >> + PLUGIN_BEAN_MIME_DESC \ >> + PLUGIN_BEAN_MIME_DESC \ > > ...those... > >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "jnlp|" >> +// "class|jar" >> +// VALUE "FileOpenName", "Java-Klassendatei (*.class)|" >> +// "Java-Archiv (*.jar)|" >> +// "Java-Klassendatei (*.class)|" >> +// "Java-Archiv (*.jar)|" >> +// "Java-Klassendatei (*.class)|" >> +// "Java-Archiv (*.jar)|" >> +// "Java-Klassendatei (*.class)|" >> +// "Java-Archiv (*.jar)|" > ...those... >> + "class|jar|" >> + "class|jar|" >> + "class|jar|" >> + "class|jar|" >> + "class|jar|" >> + "jnlp|" >> + "class|jar" >> + VALUE "FileOpenName", "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" > > ...those... > >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Aplikacja JNLP (*.jnlp)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)" >> +// VALUE "Language", "pl" >> +// } >> + } > and those ^ seems to me like most easy to be belnded. Together with ITW > But defintiely not as this changeset. > >> + >> + BLOCK "VarFileInfo" { >> + VALUE "Translation", LANG_CZECH, 1250, /* Czech */ >> + LANG_GERMAN, 1252, /* German */ >> + LANG_ENGLISH, 1252, /* English */ >> + LANG_POLISH, 1250 /* Polish */ >> + } >> +} >> + >> +ID_ICON ICON "../../../javaws.ico" >> + >> +STRINGTABLE LANGUAGE LANG_CZECH, SUBLANG_DEFAULT { >> + IDS_FRIENDLYTYPENAME "JNLP aplikace" >> +} >> + >> +STRINGTABLE LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT { >> + IDS_FRIENDLYTYPENAME "JNLP Application" >> + IDS_OPEN "&Open" >> +} >> + >> +STRINGTABLE LANGUAGE LANG_GERMAN, SUBLANG_DEFAULT { >> + IDS_FRIENDLYTYPENAME "JNLP-Anwendung" >> + IDS_OPEN "?&ffnen" >> +} >> + >> +STRINGTABLE LANGUAGE LANG_POLISH, SUBLANG_DEFAULT { >> + IDS_FRIENDLYTYPENAME "Aplikacja JNLP" >> + IDS_OPEN "O&tw?rz" >> +} >> + >> +#else /* OS2 */ >> +#include >> + >> +NP_INFO_ProductVersion RC_DATA { >> + PACKAGE_MAJOR_VERSION, >> + PACKAGE_MINOR_VERSION, >> + PACKAGE_PATCH_VERSION, >> + PACKAGE_BUILD_VERSION >> +} >> +NP_INFO_MIMEType RC_DATA { >> + ICEDTEA_WEB_MIME_TYPES "\0" >> +} >> +NP_INFO_FileOpenName RC_DATA { >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "JNLP Application (*.jnlp)|\0" >> +} >> +NP_INFO_FileExtents RC_DATA { >> + "class|jar|jnlp\0" >> +} >> +NP_INFO_FileDescription RC_DATA { >> + PACKAGE_DESCRIPTION "\0" >> +} >> +NP_INFO_ProductName RC_DATA { >> + PACKAGE_NAME "\0" >> +} >> +NP_INFO_CompanyName RC_DATA { >> + PACKAGE_VENDOR "\0" >> +} >> +NP_INFO_FileVersion RC_DATA { >> + PACKAGE_MAJOR_VERSION, >> + PACKAGE_MINOR_VERSION, >> + PACKAGE_PATCH_VERSION, >> + PACKAGE_BUILD_VERSION >> +} >> +NP_INFO_InternalName RC_DATA { >> + "NP" PACKAGE_NAME "\0" >> +} >> +NP_INFO_LegalCopyright RC_DATA { >> + "GPLv2, see the file COPYING for details\0" >> +} >> +NP_INFO_OriginalFilename RC_DATA { >> + "NP" PACKAGE_NAME ".DLL\0" >> +} >> +#endif /* OS2 */ >> +#endif /* RC_INVOKED */ >> +#endif /*_ICEDTEA_WEB_RC_ */ >> diff --git a/plugin/icedteanp/windows/IcedTeaIEPlugin.c b/plugin/icedteanp/windows/IcedTeaIEPlugin.c >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/IcedTeaIEPlugin.c >> @@ -0,0 +1,2191 @@ >> +#define INC_OLE2 >> +#include >> +#include > > ... http://en.wiktionary.org/wiki/to_je_pro_m%C4%9B_%C5%A1pan%C4%9Blsk%C3%A1_vesnice :)) > >> +} >> diff --git a/plugin/icedteanp/windows/IcedTeaIEPlugin.h b/plugin/icedteanp/windows/IcedTeaIEPlugin.h >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/IcedTeaIEPlugin.h >> @@ -0,0 +1,3 @@ > > ....still the same. >> \ No newline at end of file >> > > > Well one general hint - Maybe its the time to restructure plugin directory? > > I would go for something like > plugin/windows/src (your "c a nd rest" files) > plugin/windows/build (mingw make or whatever you may need for build (the ico if you will insists?-) > ) )) > plugin/linux/src (current icedteanp) > plugin/linux/build? And so extract plugin parts from main makefile? > plugin/share/java (current current java) > plugin/share/docs > plugin/share/tests > > > This si just idea, not necessary for this changeset or at all. And can be complicated to do... > > J. One more thing to +config\.guess +config\.sub +.+\.patch +.+\.[Rr][Ee][Ss] +.+\.(o|[Oo][Bb][Jj]) +.+\.[Ee][Xx][Ee] +.+\.(so|[Dd][Ll]{2}) +.+\.(a|[Ll][Ii][Bb]) +.+\.[Mm][Ss][Ii] +.+\.rpm Although I agree those belongs to exclude list, by default those files should be built in some "output dir" Not sure how your mingw makefile is handling those. Best regards from CZ J. From jkang at redhat.com Thu Sep 11 14:01:28 2014 From: jkang at redhat.com (Jie Kang) Date: Thu, 11 Sep 2014 10:01:28 -0400 (EDT) Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <5410E9B6.2030808@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> <54107019.2030106@redhat.com> <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> <5410E9B6.2030808@redhat.com> Message-ID: <2058764014.3737904.1410444088683.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/10/2014 02:31 PM, Jie Kang wrote: > > > > Hello, > > > > > > Good points. I have made Translator an enum with a single instance where > > the public static String R still remains and added basic unit tests for > > Translator. > > > > > > Overall I definitely like the idea behind this patch. Just a few minor > implementation details I have some questions about. > > > public static String R(String message) { > > - return JNLPRuntime.getMessage(message); > > + return getInstance().getMessage(message); > > } > > Can this be defined in terms of Translator.R(String, Object...) instead? > Not a big deal but it seems natural to me. Hello, Thanks for the review! I am not sure if I understood correctly but for this R(String message) do you mean something like: return R(message, new Object[0]) I prefer the other way since it's more efficient and makes more sense to me hahah. Though I understand what you mean by being more natural. It's just on closer inspection it seems really weird to make this call when you can just use getInstance().getMessage(message); Is it okay if I keep it original? > > > + public static void loadResourceBundle(ResourceBundle bundle) { > > + getInstance().resources = bundle; > > + } > > Why is this still static? I think this makes sense as a method belonging > to the singleton instance, and I only see one call site (TranslatorTest) > that would need to be refactored. I would also rather see a > (package-private?) setter method rather than direct field assignment > here, but that's not a huge deal. I chose to make it static since I wanted the class to be accessed in a consistent manner. getInstance() was private and R() was public static so it made sense to me to make loadResourceBundle() also static in order to preserve the privacy of getInstance(). Also I preferred keeping it public in order to possibly allow for itweb-settings to have an option to set the preferred locale or something like that (in the future). Now that I think about it, this isn't necessary. > > > + } catch (Exception ex) { > > + throw new IllegalStateException("Missing resource bundle in > > netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); > > + } > > Is this path correct even for non-default (English) locales? Eg for > Czech shouldn't it be attempting (and failing) to load > net/sourceforge/jnlp/resource/Messages_cs.properties? I'm not sure how > easy it is to get the name of the ResourceBundle that the runtime would > attempt to load however, it may not be worth the effort - this is a > pretty close approximation anyway even for other locales I suppose. In terms of resource bundle failing to load, it attempts to load whatever the default locale is and failing that, attempts to load the base copy, only if the base does not exist will it fail and throw the exception. Getting the default locale is pretty easy so I've changed the message to be more appropriate. How does it look? Thanks, > > Thanks, > -- > Andrew Azores > -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-translator-2.patch Type: text/x-patch Size: 10660 bytes Desc: not available URL: From jvanek at redhat.com Thu Sep 11 14:15:49 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 11 Sep 2014 16:15:49 +0200 Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <2058764014.3737904.1410444088683.JavaMail.zimbra@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> <54107019.2030106@redhat.com> <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> <5410E9B6.2030808@redhat.com> <2058764014.3737904.1410444088683.JavaMail.zimbra@redhat.com> Message-ID: <5411AE95.90203@redhat.com> On 09/11/2014 04:01 PM, Jie Kang wrote: > > > ----- Original Message ----- >> On 09/10/2014 02:31 PM, Jie Kang wrote: >>> >>> Hello, >>> >>> >>> Good points. I have made Translator an enum with a single instance where >>> the public static String R still remains and added basic unit tests for >>> Translator. >>> >>> >> >> Overall I definitely like the idea behind this patch. Just a few minor >> implementation details I have some questions about. >> >>> public static String R(String message) { >>> - return JNLPRuntime.getMessage(message); >>> + return getInstance().getMessage(message); >>> } >> >> Can this be defined in terms of Translator.R(String, Object...) instead? >> Not a big deal but it seems natural to me. > > Hello, > > > Thanks for the review! > > I am not sure if I understood correctly but for this R(String message) do you mean something like: > return R(message, new Object[0]) > > I prefer the other way since it's more efficient and makes more sense to me hahah. Though I understand what you mean by being more natural. It's just on closer inspection it seems really weird to make this call when you can just use getInstance().getMessage(message); > > Is it okay if I keep it original? > >> >>> + public static void loadResourceBundle(ResourceBundle bundle) { >>> + getInstance().resources = bundle; >>> + } >> >> Why is this still static? I think this makes sense as a method belonging >> to the singleton instance, and I only see one call site (TranslatorTest) >> that would need to be refactored. I would also rather see a >> (package-private?) setter method rather than direct field assignment >> here, but that's not a huge deal. > > I chose to make it static since I wanted the class to be accessed in a consistent manner. getInstance() was private and R() was public static so it made sense to me to make loadResourceBundle() also static in order to preserve the privacy of getInstance(). > > Also I preferred keeping it public in order to possibly allow for itweb-settings to have an option to set the preferred locale or something like that (in the future). Now that I think about it, this isn't necessary. > > >> >>> + } catch (Exception ex) { >>> + throw new IllegalStateException("Missing resource bundle in >>> netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); >>> + } >> >> Is this path correct even for non-default (English) locales? Eg for >> Czech shouldn't it be attempting (and failing) to load >> net/sourceforge/jnlp/resource/Messages_cs.properties? I'm not sure how >> easy it is to get the name of the ResourceBundle that the runtime would >> attempt to load however, it may not be worth the effort - this is a >> pretty close approximation anyway even for other locales I suppose. > > In terms of resource bundle failing to load, it attempts to load whatever the default locale is and failing that, attempts to load the base copy, only if the base does not exist will it fail and throw the exception. Getting the default locale is pretty easy so I've changed the message to be more appropriate. > > How does it look? > > I'm happy with that. If Andrew have some objections, Follow his advises. Green from me :) J. From ldracz at redhat.com Thu Sep 11 14:35:11 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Thu, 11 Sep 2014 10:35:11 -0400 (EDT) Subject: [fyi] [icedtea-web]failing unittest testSetFileNull In-Reply-To: <54116917.5050001@redhat.com> References: <5410649D.2080506@redhat.com> <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> <586797042.3123592.1410371433512.JavaMail.zimbra@redhat.com> <1859742716.3125841.1410371711313.JavaMail.zimbra@redhat.com> <637091988.3144804.1410372675019.JavaMail.zimbra@redhat.com> <54116917.5050001@redhat.com> Message-ID: <98901378.3769699.1410446111222.JavaMail.zimbra@redhat.com> Hello, > No removal. > > > Ensure that it works correctly even with null parameter. > > > There is no similar test. > > J. > Okay, I made a check to see whether file was set to null. Also added two tests that test the methods that use file and check that they throw NullPointerExceptions when file is set to null. Regards, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: setFileNullTest.patch Type: text/x-patch Size: 1145 bytes Desc: not available URL: From jvanek at redhat.com Thu Sep 11 14:44:33 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 11 Sep 2014 16:44:33 +0200 Subject: [fyi] [icedtea-web]failing unittest testSetFileNull In-Reply-To: <98901378.3769699.1410446111222.JavaMail.zimbra@redhat.com> References: <5410649D.2080506@redhat.com> <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> <586797042.3123592.1410371433512.JavaMail.zimbra@redhat.com> <1859742716.3125841.1410371711313.JavaMail.zimbra@redhat.com> <637091988.3144804.1410372675019.JavaMail.zimbra@redhat.com> <54116917.5050001@redhat.com> <98901378.3769699.1410446111222.JavaMail.zimbra@redhat.com> Message-ID: <5411B551.1080204@redhat.com> On 09/11/2014 04:35 PM, Lukasz Dracz wrote: > Hello, > >> No removal. >> >> >> Ensure that it works correctly even with null parameter. >> >> >> There is no similar test. >> >> J. >> > > Okay, I made a check to see whether file was set to null. Also added two tests that test the methods that use file and check that they throw NullPointerExceptions when file is set to null. > > Regards, > Lukasz Dracz > Sounds ok to me. But ping also Jie if he is ok with that. Thanx! J. From jvanek at redhat.com Thu Sep 11 14:51:09 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 11 Sep 2014 16:51:09 +0200 Subject: [rfc] ]icedtea-web] localizable javaws + policieditor + minor fixes Message-ID: <5411B6DD.2020800@redhat.com> As before, SSIA :) Thank you! J. -------------- next part -------------- A non-text attachment was scrubbed... Name: localizableJavawsPe+Minors.patch Type: text/x-patch Size: 13831 bytes Desc: not available URL: From gitne at gmx.de Thu Sep 11 15:07:24 2014 From: gitne at gmx.de (Jacob Wisor) Date: Thu, 11 Sep 2014 17:07:24 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve IcedTea-Web cache disk space In-Reply-To: <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <54071A8A.9050202@gmx.de> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> Message-ID: <5411BAAC.9050204@gmx.de> On 09/08/2014 08:38 PM, Lukasz Dracz wrote: > > Hello, > >> Hello, >> >> When you check the 'limit cache size box' with a size of 0, the JAR >> compression option and cache location option are disabled. At the moment, >> limiting cache size to 0 means that once icedtea-web finishes, the cache is >> cleared of all files. >> >> I think the description for Caching should be reworded a little to make this >> known. E.g. >> >> "No files will be cached. Cached files will be deleted." can be reworded to >> something like: >> "Cached files will be deleted on icedtea-web close. > > Okay > >> As well, the ability to choose where icedtea-web downloads file should still >> be enabled even if cache has a limit of 0. > > Yes since it still downloads the files even if they are deleted after use. > This provides the user with more choice on where they want the files to be temporarily. > >> In terms of code, it functionally looks okay but I would strongly suggest >> adding logically placed line spaces throughout the code for easier reading. > > Yes, sorry about that, I added spaces in a bunch of places now to increase readability. > > Thank you, > Lukasz Dracz As this patch seems kind of the last version that actually got pushed, I am replying to this posting. Are my few nits. Regarding the discussion about cache size 0 and IcedTea-Web's behavior in this case, I suppose that displaying the TIFPCacheSizeSetToNoCaching message is an acceptable compromise (because it describes what will actually happen), but only as long as we can expect a followup patch that makes IcedTea-Web use a "memory only" cache. > diff -r af89bcaa02a2 -r e30d71ab91c6 netx/net/sourceforge/jnlp/resources > /Messages.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 10 > 09:45:10 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 10 > 10:22:46 2014 -0400 > @@ -801,6 +801,10 @@ > TIFPDeleteFiles=Delete files > TIFPViewFiles=View files... > TIFPFileChooserChooseButton=Choose > +TIFPLimitCacheSize=Limit cache size > +TIFPCacheSizeSpinnerValueTooLargeWarning=WARNING: Uses more > space than {0} MB available > +TIFPCacheSizeSpinnerLargeValueWarning= Available: {0} MB Drop the html tags. They are not required here. Besides, HTML trims all leading and trailing white spaces, as well as replaces multiple white spaces between words with one SPACE (\u0020) character. This probably leads to undesired behavior here, if not now then maybe in the future. > +TIFPCacheSizeSetToNoCaching=Cached files will be deleted on > icedtea-web close. Again, drop the html tags. They do not serve any purpose here. Also, please use the proper branding, which is "IcedTea-Web". We may have even a public static final constant for this. And finally, this sentence needs rewording to be proper English. I would suggest: Cached files will be deleted when IcedTea-Web terminates. I think the term "terminates" is appropriate here, because the user actually never gets to "close" IcedTea-Web directly since its shutdown or /termination/ is controlled indirectly via the JNLP application or the JVM. One last thing I have experienced is that a message for "TIFPCacheSizeSpinnerTooltip" is missing when hovering over the cache size spinner. Please fix this! Thank you for improving the cache size UI controls. ;-) Jacob From jkang at redhat.com Thu Sep 11 15:12:11 2014 From: jkang at redhat.com (Jie Kang) Date: Thu, 11 Sep 2014 11:12:11 -0400 (EDT) Subject: [rfc][icedtea-web] CacheLRUWrapper SortedEntries Fix In-Reply-To: <314425078.3783581.1410447169334.JavaMail.zimbra@redhat.com> Message-ID: <1729888749.3804276.1410448331980.JavaMail.zimbra@redhat.com> Hello, When messing around with CacheUtil::cleanCache related to [1] , I discovered an issue with the LRU entries having unnecessary duplicates. [1] http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-August/029280.html : in particular, Omair's comments asking why the keep HashSet and conditionals were needed. When removing 'keep', duplicates remained in the LRU (but the underlying problem is that there are duplicates at all, which is what this fix is for) After some tinkering I have confirmed that the code dealing with LRU entries is mostly correct except for the function clearLRUSortedEntries. This patch fixes the bug by making said function return a "deeper" copy of the entries. Updates to the map wearere being performed while iterating over the list returned by clearLRUSortedEntries. It seems that though 'new ArrayList(Set)' was used, inconsistencies still appeared when iterating and updating the map. This may or may not be related to [2] which was the impetus for my change. The change removes the occurrence of inconsistencies in the LRU. [2] http://maxrohde.com/2014/01/14/copy-entryset-of-a-hashmap-in-java/ Thoughts? Okay to push? Regards, -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-cachelru-duplicate-fix-1.patch Type: text/x-patch Size: 1087 bytes Desc: not available URL: From jkang at redhat.com Thu Sep 11 15:41:14 2014 From: jkang at redhat.com (Jie Kang) Date: Thu, 11 Sep 2014 11:41:14 -0400 (EDT) Subject: [rfc][icedtea-web] localizable files and icedtea-web about page In-Reply-To: <541063A3.8070201@redhat.com> References: <541063A3.8070201@redhat.com> Message-ID: <256207747.3820015.1410450074350.JavaMail.zimbra@redhat.com> Hello, Looks nice! A few nits: + for (int x=1 ; x<=7 ; x++){ + p1.append(getFormatter().getOption(Translator.R("ITWdescO"+x+"title"), Translator.R("ITWdescO"+x+"text"))); + } Can you comment here why it goes from 1 to 7? Something like : pulls from Message.properties [(ITWdesc01title, ITWdesc01text), ...] Just to make understanding faster :) @Override public String getIntroduction() { return super.getIntroduction() + getFormatter().wrapParagraph( Translator.R("ITWintroL1",getFormatter().getBold(getId() + " ")) + getFormatter().getNewLine() + getFormatter().getNewLine() + Translator.R("ITWintroL2") + getFormatter().getNewLine() + Translator.R("ITWintroL3", getId(), getFormatter().getUrl("http://www.java.com/en/download/testjava.jsp", Translator.R("ITWintroUrlCaption"))) minor + getFormatter().getNewLine() + getFormatter().getOption("",Translator.R("BFileInfoAuthors")) + getFormatter().getOption("",Translator.R("BFileInfoCopying")) + getFormatter().getOption("",Translator.R("BFileInfoNews")) + getFormatter().getNewLine() + getFormatter().getNewLine()); } for the multiple getFormatter().getNewLine() do you think it would be neat to have a function like: getNewLine(int num) : Returns 'num' new line characters. String header = getFormatter().getBold("Features of NetX: ") + getFormatter().getNewLine(); "Features of NetX: " This string should probably be localized +ITWintroL1={0}provides a Free Software web browser plugin running applets written in the Java programming language and an implementation of Java Web Start, originally based on the NetX project. Do you think the "Free Software" should be changed to "Free Open Source Software"? +ITWintroL3={0} also includes a plugin to {1} within web browsers. For this message I see in the english man page: icedtea-web also includes a plugin to http://www.java.com/en/download/testjava.jsp within web browsers. Is this replacement of {1} with http://... supposed to happen? It doesn't really make sense to me. In the english man page for Description I see: Features of NetX: Modular Easily add JNLP capabilities to an application. Saves Memory Launch programs in a shared JVM. Fast startup Runs applications from a cache for fast starting. Security Run any application in a sandbox or log its activities. Auto-Update Applications can auto-update without special code. Network Deployment Deploy to the internet, not with installers. Can you make the format consistent by making the text part always on a new line? E.g: Security Run any application in a sandbox or log its activities. becomes Security Run any application in a sandbox or log its activities. Also the text here (from english man page) has very weird spacing: Visit the http://icedtea.classpath.org/wiki/Main_Page or specifically the http://icedtea.class? path.org/wiki/IcedTea-Web pages for more information. Help with common issues with IcedTea-Web can be found http://icedtea.classpath.org/wiki/IcedTea-Web#Com? mon_Issues . I think this has to do with the formatting? I am not sure. Regards, ----- Original Message ----- > ssia > > First of patches moving the individual liens to properties. Fixes to > individual sentences welcomed. > > J. > -- Jie Kang From gitne at gmx.de Thu Sep 11 15:55:36 2014 From: gitne at gmx.de (Jacob Wisor) Date: Thu, 11 Sep 2014 17:55:36 +0200 Subject: [rfc][icedtea-web] localizable files and icedtea-web about page In-Reply-To: <256207747.3820015.1410450074350.JavaMail.zimbra@redhat.com> References: <541063A3.8070201@redhat.com> <256207747.3820015.1410450074350.JavaMail.zimbra@redhat.com> Message-ID: <5411C5F8.9040504@gmx.de> On 09/11/2014 05:41 PM, Jie Kang wrote: > String header = getFormatter().getBold("Features of NetX: ") + getFormatter().getNewLine(); > > "Features of NetX: " This string should probably be localized Yep, and it should also get reworded to: "NetX features". ;-) > +ITWintroL1={0}provides a Free Software web browser plugin running applets written in the Java programming language and an implementation of Java Web Start, originally based on the NetX project. > > Do you think the "Free Software" should be changed to "Free Open Source Software"? No, free software is a super set of open source software. There does exist open source software which is not free (in the sense of freedom, not free of charge) software. IcedTea-Web is free software. ;-) > +ITWintroL3={0} also includes a plugin to {1} within web browsers. > > For this message I see in the english man page: > icedtea-web also includes a plugin to http://www.java.com/en/download/testjava.jsp within web browsers. > > Is this replacement of {1} with http://... supposed to happen? It doesn't really make sense to me. Yep, looks broken. > In the english man page for Description I see: > Features of NetX: > > Modular Easily add JNLP capabilities to an application. > > Saves Memory > Launch programs in a shared JVM. > > Fast startup > Runs applications from a cache for fast starting. > > Security Run any application in a sandbox or log its activities. > > Auto-Update Applications can auto-update without special code. > > Network Deployment > Deploy to the internet, not with installers. > > Can you make the format consistent by making the text part always on a new line? E.g: > Security Run any application in a sandbox or log its activities. > becomes > Security > Run any application in a sandbox or log its activities. Oh, yes please. > Also the text here (from english man page) has very weird spacing: > > Visit the http://icedtea.classpath.org/wiki/Main_Page or specifically the http://icedtea.class? > path.org/wiki/IcedTea-Web pages for more information. > Help with common issues with IcedTea-Web can be found http://icedtea.classpath.org/wiki/IcedTea-Web#Com? > mon_Issues . > > I think this has to do with the formatting? I am not sure. I agree here too. :-) Reagrds, Jacob From jkang at redhat.com Thu Sep 11 16:08:54 2014 From: jkang at redhat.com (Jie Kang) Date: Thu, 11 Sep 2014 12:08:54 -0400 (EDT) Subject: [fyi] [icedtea-web]failing unittest testSetFileNull In-Reply-To: <5411B551.1080204@redhat.com> References: <5410649D.2080506@redhat.com> <817971068.3070919.1410366335169.JavaMail.zimbra@redhat.com> <586797042.3123592.1410371433512.JavaMail.zimbra@redhat.com> <1859742716.3125841.1410371711313.JavaMail.zimbra@redhat.com> <637091988.3144804.1410372675019.JavaMail.zimbra@redhat.com> <54116917.5050001@redhat.com> <98901378.3769699.1410446111222.JavaMail.zimbra@redhat.com> <5411B551.1080204@redhat.com> Message-ID: <74913878.3833930.1410451734507.JavaMail.zimbra@redhat.com> No objections from me. Can you check what the behaviour is if an NPE get's thrown? Does the program crash? or does it chain up somewhere and get dealt with safely? If necessary maybe a new patch should make sure it can't crash from this null file behaviour. I think it's been coded so null file should never reach those locations but safeguards should still be put in place. Regards, ----- Original Message ----- > On 09/11/2014 04:35 PM, Lukasz Dracz wrote: > > Hello, > > > >> No removal. > >> > >> > >> Ensure that it works correctly even with null parameter. > >> > >> > >> There is no similar test. > >> > >> J. > >> > > > > Okay, I made a check to see whether file was set to null. Also added two > > tests that test the methods that use file and check that they throw > > NullPointerExceptions when file is set to null. > > > > Regards, > > Lukasz Dracz > > > Sounds ok to me. But ping also Jie if he is ok with that. > > > Thanx! > > J. > -- Jie Kang From ldracz at redhat.com Thu Sep 11 19:38:25 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Thu, 11 Sep 2014 15:38:25 -0400 (EDT) Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <5410777C.6070506@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <20140904181831.GB3074@redhat.com> <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> <540F27F6.4050602@redhat.com> <1887532824.2369149.1410286878320.JavaMail.zimbra@redhat.com> <1467651074.2470228.1410293867916.JavaMail.zimbra@redhat.com> <5410777C.6070506@redhat.com> Message-ID: <854154890.3936468.1410464305025.JavaMail.zimbra@redhat.com> Hello, > As we agreed, drop basedri, and update NEWS > > Something like "dropped support for long unmaintained -basedir argument" > And also "maybe returned support for -jnlp argument " :) Yes > Much more nits later > > > > > > optionParser-13.patch > > /** > > * Contains settings to be used by the Parser while parsing JNLP files. > > * > > @@ -99,12 +96,8 @@ > > * at boot on the command line. These settings are also stored so > > they > > * can be retrieved at a later time. > > */ > > - public static ParserSettings setGlobalParserSettingsFromArgs(String[] > > cmdArgs) { > > - List argList = Arrays.asList(cmdArgs); > > - boolean strict = argList.contains("-strict"); > > - boolean malformedXmlAllowed = !argList.contains("-xml"); > > - > > - globalParserSettings = new ParserSettings(strict, true, > > malformedXmlAllowed); > > + public static ParserSettings setGlobalParserSettingsFromArgs(boolean > > strict, boolean xml) { > > + globalParserSettings = new ParserSettings(strict, true, !xml); > > return globalParserSettings; > > } > > Looking to the code, I really do not see an reason for this to do exists > anymore (even withyour > explanation). > This is just creating new object. You can create it and set is reguraly Yeah your right, I got rid of the method and just make a new ParserSettings and set the globalParserSettings after. > If you decide to have helepr method here, then the bestargument for it is > optionParser, and this > helping method will read it on its own. > > eeing this: > ParserSettings defaultSettings, noArgs; > defaultSettings = new ParserSettings(); > - noArgs = ParserSettings.setGlobalParserSettingsFromArgs(new > String[0]); > + noArgs = ParserSettings.setGlobalParserSettingsFromArgs(false, > true); > > > later, makes me think that combination of > setGlobalParserSettingsFromArgs(boolean strict, boolean xml) { > and > setGlobalParserSettingsFromArgs(OptionParser)) { > setGlobalParserSettingsFromArgs(getParsed1, getPArsed2...) { > } > > Is the pointer... I removed the second Test as I didn't see a point to it with the removal of that method. > > Dont forget to drop also those lines and thirs mutations Done. > ... > > */ > > private static String getJNLPFile() { > > + if (optionParser.getMainArgs().length > 1 || > > optionParser.mainArgExists() > > + && > > (optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP) > > + || > > optionParser.hasOption(OptionsDefinitions.OPTIONS.BASEDIR))) { > > + for (String s : optionParser.getMainArgs()) { > > + OutputController.getLogger().printOutLn("The argument '"+ s > > +"' is not a valid expected argument"); > > use getLogger.log() for all outputs. There is actually no exception... Okay, changed it to log and also added a new exception called InvalidArgumentException. > > + } > > + } else if > > (optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP)) { > > + return optionParser.getValue(OptionsDefinitions.OPTIONS.JNLP); > > I would encapsulate this in OptionParser > > something like optionParser.validateMainArg() or similar. > > > There is still question how to handle them. > > But right now, the best way is to die once some unrecognized arg is found. > Its not celar for me > where this happens in code. AFAIK it does not. Any invalid args are caught in the first if statement which does not return, so it logs the Not Valid Args and displays a help message and the JNLPRuntime exits after. > So validateMainArg should throw lunchError with invalid options found. I'm sorry but I don't quite understand what/how validateMainArg would do ? MainArgs are in the parser the arguments that weren't found in Options or as a value to an option. For ex. update only takes one value, therefore something like 'command update 5 File' would place File in the list as a main arg. The logic in boot, the first if checks that if you have more than one main arg, or you have a main arg and a jnlp has been specified that means more main args have been specified than expected in boot, hence throw InvalidArgumentException. The other two else if return the jnlp file. To me it seems like validating the main args would be handled differently based on each application, in this case Boot is looking for only one arg that is to be a file, itweb-settings is probably not expecting a main arg. I am probably overlooking something so if you could explain to me what you mean/want out of validateMainArg that would be helpful, thanks ! > This is actually still wrong. You shoudl remove only leading dashes. > So you may change your algorithm to some while (s.starts) or use repalceAll > with "^-*" regex > > > + s = s.replace("-","").split("=")[0]; > This is s surprising but not guaranted that if split argument mathces nothing > then whole original is > returens. But I guess we can live with that. > > Anyway this method needs test. > This method is private so I can't test it directly, I added a few tests to check that a dash in the middle such as 'a-rg' would not be read as arg or multiple dashes would not replace the second dash such as '-ar-g' and just check the 'ar-g' part against the arg option. Also tested that with a '=' and no initial dash it recognizes the option aswell. > You have list here, and it is correct. Do not vaste time converting it to > array. Rather fix the > users of those methods. > > and here - do not connvert to array. Wotking with list is much more > comfortable. Keep returning > list, and fix the users of those calls rather. Okay, I had to refactor Launcher. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: optionParser-17.patch Type: text/x-patch Size: 44383 bytes Desc: not available URL: From ldracz at redhat.com Thu Sep 11 20:25:55 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Thu, 11 Sep 2014 16:25:55 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve IcedTea-Web cache disk space In-Reply-To: <5411BAAC.9050204@gmx.de> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> <5411BAAC.9050204@gmx.de> Message-ID: <349509496.4004554.1410467155409.JavaMail.zimbra@redhat.com> Hello, > As this patch seems kind of the last version that actually got pushed, I am > replying to this posting. Are my few nits. > > Regarding the discussion about cache size 0 and IcedTea-Web's behavior in > this > case, I suppose that displaying the TIFPCacheSizeSetToNoCaching message is an > acceptable compromise (because it describes what will actually happen), but > only > as long as we can expect a followup patch that makes IcedTea-Web use a > "memory > only" cache. Yeah, I will try to get a "memory only" cache working sometime in the future. > > diff -r af89bcaa02a2 -r e30d71ab91c6 netx/net/sourceforge/jnlp/resources > > /Messages.properties > > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 10 > > 09:45:10 2014 -0400 > > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 10 > > 10:22:46 2014 -0400 > > @@ -801,6 +801,10 @@ > > TIFPDeleteFiles=Delete files > > TIFPViewFiles=View files... > > TIFPFileChooserChooseButton=Choose > > +TIFPLimitCacheSize=Limit cache size > > +TIFPCacheSizeSpinnerValueTooLargeWarning=WARNING: Uses more > > space than {0} MB available > > +TIFPCacheSizeSpinnerLargeValueWarning= Available: {0} MB > > Drop the html tags. They are not required here. Besides, HTML trims all > leading > and trailing white spaces, as well as replaces multiple white spaces between > words with one SPACE (\u0020) character. This probably leads to undesired > behavior here, if not now then maybe in the future. Okay. > > +TIFPCacheSizeSetToNoCaching=Cached files will be deleted on > > icedtea-web close. > > Again, drop the html tags. They do not serve any purpose here. > Also, please use the proper branding, which is "IcedTea-Web". We may have > even a > public static final constant for this. > And finally, this sentence needs rewording to be proper English. I would > suggest: > > Cached files will be deleted when IcedTea-Web terminates. > > I think the term "terminates" is appropriate here, because the user actually > never gets to "close" IcedTea-Web directly since its shutdown or > /termination/ > is controlled indirectly via the JNLP application or the JVM. Yeah, this is much better. > One last thing I have experienced is that a message for > "TIFPCacheSizeSpinnerTooltip" is missing when hovering over the cache size > spinner. Please fix this! Yeah, the tooltip was removed previously due to a weird bug appearing with the tooltip not disappearing when resized to with the tooltip reaching outside the window. I have checked and can't seem to reproduce this bug, I think it go fixed when I refactored the layout from a panel within a panel to just everything in one panel. Also I made it so the tooltip is disabled when the spinner is disabled which I assumed is the desired behaviour. > Thank you for improving the cache size UI controls. ;-) No problem, thanks for all the suggestions and reviews :) > Jacob Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: improveCacheDiskSpacePanel.patch Type: text/x-patch Size: 2626 bytes Desc: not available URL: From jvanek at redhat.com Fri Sep 12 07:17:13 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 12 Sep 2014 09:17:13 +0200 Subject: [rfc][icedtea-web] CacheLRUWrapper SortedEntries Fix In-Reply-To: <1729888749.3804276.1410448331980.JavaMail.zimbra@redhat.com> References: <1729888749.3804276.1410448331980.JavaMail.zimbra@redhat.com> Message-ID: <54129DF9.4010102@redhat.com> On 09/11/2014 05:12 PM, Jie Kang wrote: > Hello, > > When messing around with CacheUtil::cleanCache related to [1] , I discovered an issue with the LRU entries having unnecessary duplicates. > > [1] http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-August/029280.html : in particular, Omair's comments asking why the keep HashSet and conditionals were needed. When removing 'keep', duplicates remained in the LRU (but the underlying problem is that there are duplicates at all, which is what this fix is for) > > After some tinkering I have confirmed that the code dealing with LRU entries is mostly correct except for the function clearLRUSortedEntries. This patch fixes the bug by making said function return a "deeper" copy of the entries. Updates to the map wearere being performed while iterating over the list returned by clearLRUSortedEntries. It seems that though 'new ArrayList(Set)' was used, inconsistencies still appeared when iterating and updating the map. This may or may not be related to [2] which was the impetus for my change. The change removes the occurrence of inconsistencies in the LRU. > > [2] http://maxrohde.com/2014/01/14/copy-entryset-of-a-hashmap-in-java/ > > Thoughts? Okay to push? > Looks ok. From jvanek at redhat.com Fri Sep 12 09:53:33 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 12 Sep 2014 11:53:33 +0200 Subject: [rfc][icedtea-web] localizable files and icedtea-web about page In-Reply-To: <256207747.3820015.1410450074350.JavaMail.zimbra@redhat.com> References: <541063A3.8070201@redhat.com> <256207747.3820015.1410450074350.JavaMail.zimbra@redhat.com> Message-ID: <5412C29D.6070107@redhat.com> On 09/11/2014 05:41 PM, Jie Kang wrote: > Hello, > > Looks nice! A few nits: > > + for (int x=1 ; x<=7 ; x++){ > + p1.append(getFormatter().getOption(Translator.R("ITWdescO"+x+"title"), Translator.R("ITWdescO"+x+"text"))); > + } > > Can you comment here why it goes from 1 to 7? Something like : pulls from Message.properties [(ITWdesc01title, ITWdesc01text), ...] > Just to make understanding faster :) > done. > > @Override > public String getIntroduction() { > return super.getIntroduction() > + getFormatter().wrapParagraph( > Translator.R("ITWintroL1",getFormatter().getBold(getId() + " ")) > + getFormatter().getNewLine() + getFormatter().getNewLine() > + Translator.R("ITWintroL2") > + getFormatter().getNewLine() > + Translator.R("ITWintroL3", getId(), getFormatter().getUrl("http://www.java.com/en/download/testjava.jsp", Translator.R("ITWintroUrlCaption"))) > minor + getFormatter().getNewLine() > + getFormatter().getOption("",Translator.R("BFileInfoAuthors")) > + getFormatter().getOption("",Translator.R("BFileInfoCopying")) > + getFormatter().getOption("",Translator.R("BFileInfoNews")) > + getFormatter().getNewLine() + getFormatter().getNewLine()); > > } > > for the multiple getFormatter().getNewLine() do you think it would be neat to have a function like: > getNewLine(int num) : Returns 'num' new line characters. I was thinking about it since beginning. Fixed, and added some tests. Hurray - firs tunittests for this thing O:( > > > > String header = getFormatter().getBold("Features of NetX: ") + getFormatter().getNewLine(); > > "Features of NetX: " This string should probably be localized overlooked! Fixed, and reworded as Jacob suggested. > > > +ITWintroL1={0}provides a Free Software web browser plugin running applets written in the Java programming language and an implementation of Java Web Start, originally based on the NetX project. > > Do you think the "Free Software" should be changed to "Free Open Source Software"? Not fixed - as Jacob suggested. > > +ITWintroL3={0} also includes a plugin to {1} within web browsers. > > For this message I see in the english man page: > icedtea-web also includes a plugin to http://www.java.com/en/download/testjava.jsp within web browsers. > > Is this replacement of {1} with http://... supposed to happen? It doesn't really make sense to me. > Well. This is not easy task to fix. In HTML you have readable text-> hidden link. plaintext nor man support similar thing. So I Implemented the man/plain foramtters to simply ignore the human readable part, as the url is the real keeper of information. If this is going to be subject of change, I'm for. I have jsut lack of ideas. Anyway this will be different changeset, as it affects whole documentation Right now I have this foramting for plain texts urls in mind: human readable title (url) Thoughts? > > > > > In the english man page for Description I see: > Features of NetX: > > Modular Easily add JNLP capabilities to an application. > > Saves Memory > Launch programs in a shared JVM. > > Fast startup > Runs applications from a cache for fast starting. > > Security Run any application in a sandbox or log its activities. > > Auto-Update Applications can auto-update without special code. > > Network Deployment > Deploy to the internet, not with installers. > > Can you make the format consistent by making the text part always on a new line? E.g: I cant! This is how program man is formatting TP command. I got this TP thing from our original pages (actually my results were 1:1 copies of those on non added lines) So - We may change to different formatting for parameters then TP, currently I dont know of any more suitable:( The TP do what it is supposed to do. It do some kind of two columns table, where second column have fixed starting point (it is declared by the number, in our case 12 everywhere [12 everywhere was also in original man pages) So if you look at it, you will see, that the record is put to second line, only where the first column is longer then expected width (in our case 12) Anyway.. different changeset. Suggestions welcomed! > Security Run any application in a sandbox or log its activities. > becomes > Security > Run any application in a sandbox or log its activities. > > > > > > Also the text here (from english man page) has very weird spacing: > > Visit the http://icedtea.classpath.org/wiki/Main_Page or specifically the http://icedtea.class? > path.org/wiki/IcedTea-Web pages for more information. > Help with common issues with IcedTea-Web can be found http://icedtea.classpath.org/wiki/IcedTea-Web#Com? > mon_Issues . > > I think this has to do with the formatting? I am not sure. > This is nearly the same issue as TP. This is what program man is doing. It formats the paragraphs to fit your terminal width, and it is trying to align justifiably both left and righ, but enlarging spaces where suitable. so "hell ouu a friend" on 4 chars wide terminall will become similar to: "hell" " ouu" " a " "frie" "nd " Afaik absolutely no op here. > > > Regards, > > ----- Original Message ----- >> ssia >> >> First of patches moving the individual liens to properties. Fixes to >> individual sentences welcomed. >> >> J. >> > Thanx both of yo for check! J. -------------- next part -------------- A non-text attachment was scrubbed... Name: localizableFilesArgsItw2.patch Type: text/x-patch Size: 28299 bytes Desc: not available URL: From ptisnovs at icedtea.classpath.org Fri Sep 12 09:56:44 2014 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Fri, 12 Sep 2014 09:56:44 +0000 Subject: /hg/gfx-test: Ten new tests added into CAGOperationsOnTwoOverlap... Message-ID: changeset 35d7cdaf9c2e in /hg/gfx-test details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=35d7cdaf9c2e author: Pavel Tisnovsky date: Fri Sep 12 11:57:52 2014 +0200 Ten new tests added into CAGOperationsOnTwoOverlappingRectangles. diffstat: ChangeLog | 5 + src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java | 250 ++++++++++ 2 files changed, 255 insertions(+), 0 deletions(-) diffs (272 lines): diff -r dc04b210f52b -r 35d7cdaf9c2e ChangeLog --- a/ChangeLog Wed Sep 10 13:31:21 2014 +0200 +++ b/ChangeLog Fri Sep 12 11:57:52 2014 +0200 @@ -1,3 +1,8 @@ +2014-09-12 Pavel Tisnovsky + + * src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java: + Ten new tests added into CAGOperationsOnTwoOverlappingRectangles. + 2014-09-10 Pavel Tisnovsky * src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRoundRectangles.java: diff -r dc04b210f52b -r 35d7cdaf9c2e src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java --- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java Wed Sep 10 13:31:21 2014 +0200 +++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java Fri Sep 12 11:57:52 2014 +0200 @@ -2182,6 +2182,256 @@ } /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using union operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionTextureFillUsingDiagonalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingDiagonalStripesTexture(image, graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingUnionOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractTextureFillUsingDiagonalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingDiagonalStripesTexture(image, graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using inverse subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractTextureFillUsingDiagonalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingDiagonalStripesTexture(image, graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using Intersect operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testIntersectTextureFillUsingDiagonalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingDiagonalStripesTexture(image, graphics2d); + // create area using Intersect operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingIntersectOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using Xor operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorTextureFillUsingDiagonalStripesTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingDiagonalStripesTexture(image, graphics2d); + // create area using Xor operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingXorOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using union operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testUnionTextureFillUsingColorDotsTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingColorDotsTexture(image, graphics2d); + // create area using union operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingUnionOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testSubtractTextureFillUsingColorDotsTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingColorDotsTexture(image, graphics2d); + // create area using subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using inverse subtract operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testInverseSubtractTextureFillUsingColorDotsTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingColorDotsTexture(image, graphics2d); + // create area using inverse subtract operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingInverseSubtractOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using Intersect operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testIntersectTextureFillUsingColorDotsTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingColorDotsTexture(image, graphics2d); + // create area using Intersect operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingIntersectOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** + * Checks the process of creating and rendering new geometric shape + * constructed from two overlapping rectangles using Xor operator. The shape is rendered + * using texture paint (fill). + * + * @param image + * image to which area is to be drawn + * @param graphics2d + * graphics canvas + * @return test result status - PASSED, FAILED or ERROR + */ + public TestResult testXorTextureFillUsingColorDotsTexture(TestImage image, Graphics2D graphics2d) + { + // set stroke color + CommonRenderingStyles.setStrokeColor(graphics2d); + // set fill color + CommonRenderingStyles.setTextureFillUsingColorDotsTexture(image, graphics2d); + // create area using Xor operator + Area area = CommonCAGOperations.createAreaFromTwoOverlappingRectanglesUsingXorOperator(image); + // draw the area + graphics2d.fill(area); + // test result + return TestResult.PASSED; + } + + /** * Entry point to the test suite. * * @param args From jvanek at redhat.com Fri Sep 12 11:25:53 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 12 Sep 2014 13:25:53 +0200 Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <854154890.3936468.1410464305025.JavaMail.zimbra@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <20140904181831.GB3074@redhat.com> <206375438.642458.1409862146911.JavaMail.zimbra@redhat.com> <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> <540F27F6.4050602@redhat.com> <1887532824.2369149.1410286878320.JavaMail.zimbra@redhat.com> <1467651074.2470228.1410293867916.JavaMail.zimbra@redhat.com> <5410777C.6070506@redhat.com> <854154890.3936468.1410464305025.JavaMail.zimbra@redhat.com> Message-ID: <5412D841.4020104@redhat.com> > Yeah your right, I got rid of the method and just make a new ParserSettings and set the globalParserSettings after. > One more nit here inline later. >> >If you decide to have helepr method here, then the bestargument for it is >> >optionParser, and this ...snip... >> >where this happens in code. AFAIK it does not. > Any invalid args are caught in the first if statement which does not return, so it logs the Not Valid Args and displays a help message and the JNLPRuntime exits after. > >> >So validateMainArg should throw lunchError with invalid options found. > I'm sorry but I don't quite understand what/how validateMainArg would do ? > MainArgs are in the parser the arguments that weren't found in Options or as a value to an option. > For ex. update only takes one value, therefore something like 'command update 5 File' would place File in > the list as a main arg. And thats correct :) > > The logic in boot, the first if checks that if you have more than one main arg, or you have a main arg and a > jnlp has been specified that means more main args have been specified than expected in boot, hence throw InvalidArgumentException. The other two else if return the jnlp file. > agree > To me it seems like validating the main args would be handled differently based on each application, in this case Boot is looking for only one arg that is to be a file, itweb-settings is probably not expecting a main arg. I am probably overlooking something so if you could explain to me what you mean/want out of validateMainArg that would be helpful, thanks ! agree. This part now seems ok to me. > >> >This is actually still wrong. You shoudl remove only leading dashes. >> >So you may change your algorithm to some while (s.starts) or use repalceAll >> >with "^-*" regex >> > >>> > >+ s = s.replace("-","").split("=")[0]; >> >This is s surprising but not guaranted that if split argument mathces nothing >> >then whole original is >> >returens. But I guess we can live with that. >> > >> >Anyway this method needs test. >> > > This method is private so I can't test it directly, I added a few tests to check that a dash in the middle such as 'a-rg' would not be read as arg or multiple dashes would not replace the second dash such as '-ar-g' and just check the 'ar-g' part against the arg option. Also tested that with a '=' and no initial dash it recognizes the option aswell. > +- ok.... >> >You have list here, and it is correct. Do not vaste time converting it to >> >array. Rather fix the >> >users of those methods. >> > >> >and here - do not connvert to array. Wotking with list is much more >> >comfortable. Keep returning >> >list, and fix the users of those calls rather. > Okay, I had to refactor Launcher. Looks much better now, except one nit inline. > > Thank you, > Lukasz Dracz > > > optionParser-17.patch > > > diff -r e30d71ab91c6 NEWS ... > * extra information > */ > - private void addProperties(JNLPFile file, String[] props) throws LaunchException { > + private void addProperties(JNLPFile file, List props) throws LaunchException { > ResourcesDesc resources = file.getResources(); > > - for (int i = 0; i < props.length; i++) { > + for (String input : props) { > // allows empty property, not sure about validity of that. > - int equals = props[i].indexOf("="); > - if (equals == -1) { > - throw launchError(new LaunchException(R("BBadProp", props[i]))); > + if (!input.contains("=")) { > + throw launchError(new LaunchException(R("BBadProp", input))); > } > > - String key = props[i].substring(0, equals); > - String value = props[i].substring(equals + 1, props[i].length()); > + String key = input.split("=")[0]; > + String value = input.split("=")[1]; Unluckily the behaviour changed here. What if vale contains equals chat to? Please keep prevoius indexOf approach:( > > resources.addResource(new PropertyDesc(key, value)); > } > @@ -344,18 +343,17 @@ > * @throws LaunchException if an exception occurs while extracting > * extra information > */ > - private void addParameters(JNLPFile file, String[] params) throws LaunchException { > + private void addParameters(JNLPFile file, List params) throws LaunchException { > AppletDesc applet = file.getApplet(); > > - for (int i = 0; i < params.length; i++) { > + for (String input : params) { > // allows empty param, not sure about validity of that. > - int equals = params[i].indexOf("="); > - if (equals == -1) { > - throw launchError(new LaunchException(R("BBadParam", params[i]))); > + if (!input.contains("=")) { > + throw launchError(new LaunchException(R("BBadParam", input))); > } > > - String name = params[i].substring(0, equals); > - String value = params[i].substring(equals + 1, params[i].length()); > + String name = input.split("=")[0]; > + String value = input.split("=")[1]; > same here. Sorry. tbh - those two deserves test as you are refactoring them. > applet.addParameter(name, value); > } > @@ -365,11 +363,11 @@ > * Add the arguments to the JNLP file; only call if file is > * actually an application (not installer). > */ > - private void addArguments(JNLPFile file, String[] args) { > + private void addArguments(JNLPFile file, List args) { > ApplicationDesc app = file.getApplication(); > > - for (int i = 0; i < args.length; i++) { > - app.addArgument(args[i]); > + for (String input : args ) { > + app.addArgument(input); > } > } > > diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/OptionsDefinitions.java > --- a/netx/net/sourceforge/jnlp/OptionsDefinitions.java Wed Sep 10 10:22:46 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 11 15:30:54 2014 -0400 > @@ -71,6 +71,7 @@ > NOHEADERS("-Xignoreheaders", "BXignoreheaders"), > OFFLINE("-Xoffline", "BXoffline"), > TRUSTNONE("-Xtrustnone","BOTrustnone"), > + JNLP("-jnlp","BOJnlp", NumberOfArguments.ONE), > //itweb settings > NODASHHELP("help", "IBOHelp"), > LIST("list", "IBOList"), > @@ -200,7 +201,8 @@ > OPTIONS.NOFORK, > OPTIONS.NOHEADERS, > OPTIONS.OFFLINE, > - OPTIONS.TRUSTNONE}); > + OPTIONS.TRUSTNONE, > + OPTIONS.JNLP}); > } > > public static List getJavaWsOptions() { > diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/ParserSettings.java > --- a/netx/net/sourceforge/jnlp/ParserSettings.java Wed Sep 10 10:22:46 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/ParserSettings.java Thu Sep 11 15:30:54 2014 -0400 > @@ -37,9 +37,6 @@ > > package net.sourceforge.jnlp; > > -import java.util.Arrays; > -import java.util.List; > - > /** > * Contains settings to be used by the Parser while parsing JNLP files. > * > @@ -94,18 +91,4 @@ > globalParserSettings = parserSettings; > } > > - /** > - * Return the ParserSettings to be used according to arguments specified > - * at boot on the command line. These settings are also stored so they > - * can be retrieved at a later time. > - */ > - public static ParserSettings setGlobalParserSettingsFromArgs(String[] cmdArgs) { > - List argList = Arrays.asList(cmdArgs); > - boolean strict = argList.contains("-strict"); > - boolean malformedXmlAllowed = !argList.contains("-xml"); > - > - globalParserSettings = new ParserSettings(strict, true, malformedXmlAllowed); > - return globalParserSettings; > - } XXXX!!! :) > - > } > diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/runtime/Boot.java > --- a/netx/net/sourceforge/jnlp/runtime/Boot.java Wed Sep 10 10:22:46 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/runtime/Boot.java Thu Sep 11 15:30:54 2014 -0400 > @@ -22,7 +22,6 @@ > import java.net.URL; > import java.security.AccessController; > import java.security.PrivilegedAction; > -import java.util.ArrayList; > import java.util.Arrays; > import java.util.HashMap; > import java.util.List; > @@ -32,6 +31,7 @@ > ... > } > > - Map extra = new HashMap(); > - extra.put("arguments", getOptions("-arg")); > - extra.put("parameters", getOptions("-param")); > - extra.put("properties", getOptions("-property")); > + Map> extra = new HashMap>(); > + extra.put("arguments", optionParser.getValues(OptionsDefinitions.OPTIONS.ARG)); > + extra.put("parameters", optionParser.getValues(OptionsDefinitions.OPTIONS.PARAM)); > + extra.put("properties", optionParser.getValues(OptionsDefinitions.OPTIONS.PROPERTY)); > > - ParserSettings settings = ParserSettings.setGlobalParserSettingsFromArgs(args); > + ParserSettings settings = new ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT), true, !optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); > + ParserSettings.setGlobalParserSettings(settings); Please hide those two lines. add public whatever setGlobalParserSettingsFromOptionParser(Optionparser optionParser){ ParserSettings settings = new ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT), true, !optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); this.setGlobalParserSettings(settings); } in ParserSettings and here call setGlobalParserSettingsFromOptionParser(optionParser) only Consequentially return (modified) the rmeoved test. > > try { > Launcher launcher = new Launcher(false); > @@ -266,7 +271,13 @@ > */ > private static URL getFileLocation() { > > - String location = getJNLPFile(); > + String location = null; > + try { > + location = getJNLPFile(); > + } catch (InvalidArgumentException e) { > + OutputController.getLogger().log(e); > + fatalError("Invalid argument: "+e); > + } > > if (location == null) { > handleMessage(); > @@ -294,64 +305,19 @@ > /** > * Gets the JNLP file from the command line arguments, or exits upon error. > */ > - private static String getJNLPFile() { > + private static String getJNLPFile() throws InvalidArgumentException { > + if (optionParser.getMainArgs().size() > 1 || (optionParser.mainArgExists() > + && optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP))) { > + throw new InvalidArgumentException(optionParser.getMainArg()); > + } else if (optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP)) { > + return optionParser.getValue(OptionsDefinitions.OPTIONS.JNLP); > + } else if (optionParser.mainArgExists()) { > + return optionParser.getMainArg(); > + } As you explained, fair enough. > > - if (args.length == 0) { > - handleMessage(); > - JNLPRuntime.exit(0); > - } else if (args.length == 1) { > - return args[args.length - 1]; > - } else { > - String lastArg = args[args.length - 1]; > - String secondLastArg = args[args.length - 2]; > - > - if (doubleArgs.indexOf(secondLastArg) == -1) { > - return lastArg; > - } else { > - handleMessage(); > - JNLPRuntime.exit(0); > - } > - } > + handleMessage(); > + JNLPRuntime.exit(0); > return null; > } > > - /** > - * Return value of the first occurence of the specified > - * option, or null if the option is not present. If the > - * option is a flag (0-parameter) and is present then the > - * option name is returned. > - */ > - private static String getOption(String option) { > - String result[] = getOptions(option); > - > - if (result.length == 0) > - return null; > - else > - return result[0]; > - } > - > - /** > - * Return all the values of the specified option, or an empty > - * array if the option is not present. If the option is a > - * flag (0-parameter) and is present then the option name is > - * returned once for each occurrence. > - */ > - private static String[] getOptions(String option) { > - List result = new ArrayList(); > - > - for (int i = 0; i < args.length; i++) { > - if (option.equals(args[i])) { > - if (-1 == doubleArgs.indexOf(option)) > - result.add(option); > - else if (i + 1 < args.length) > - result.add(args[i + 1]); > - } > - > - if (args[i].startsWith("-") && -1 != doubleArgs.indexOf(args[i])) > - i++; > - } > - > - return result.toArray(new String[result.size()]); > - } > - > } > diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/util/optionparser/InvalidArgumentException.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/util/optionparser/InvalidArgumentException.java Thu Sep 11 15:30:54 2014 -0400 > @@ -0,0 +1,43 @@ > +/*Copyright (C) 2014 Red Hat, Inc. > + > +This file is part of IcedTea. > + > +IcedTea is free software; you can redistribute it and/or > +modify it under the terms of the GNU General Public License as published by > +the Free Software Foundation, version 2. > + > +IcedTea is distributed in the hope that it will be useful, > +but WITHOUT ANY WARRANTY; without even the implied warranty of > +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +General Public License for more details. > + > +You should have received a copy of the GNU General Public License > +along with IcedTea; see the file COPYING. If not, write to > +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA > +02110-1301 USA. > + > +Linking this library statically or dynamically with other modules is > +making a combined work based on this library. Thus, the terms and > +conditions of the GNU General Public License cover the whole > +combination. > + > +As a special exception, the copyright holders of this library give you > +permission to link this library with independent modules to produce an > +executable, regardless of the license terms of these independent > +modules, and to copy and distribute the resulting executable under > +terms of your choice, provided that you also meet, for each linked > +independent module, the terms and conditions of the license of that > +module. An independent module is a module which is not derived from > +or based on this library. If you modify this library, you may extend > +this exception to your version of the library, but you are not > +obligated to do so. If you do not wish to do so, delete this > +exception statement from your version. > + */ > + > +package net.sourceforge.jnlp.util.optionparser; > + > +public class InvalidArgumentException extends Exception { > + public InvalidArgumentException(String argument) { > + super(argument); > + } > +} ... If you fulfill all nits above, please add also chnagelog in next iteration. I believe it will be last one.. Otherwise we both grow old and turn gray before it is finish. Also remember, your next task is to port ITWsettings and polieditor to use this class. Looking forward to have this in! J. From jvanek at redhat.com Fri Sep 12 11:26:47 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 12 Sep 2014 13:26:47 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <54101CEB.1040104@redhat.com> References: <54071FE9.2000309@redhat.com> <54101CEB.1040104@redhat.com> Message-ID: <5412D877.8070300@redhat.com> :((( This patch is becoming blocker. Any volunteer? J. On 09/10/2014 11:42 AM, Jiri Vanek wrote: > ping? > > > -------- Original Message -------- > Subject: Re: [rfc][icedtea-web] https probing > Date: Wed, 03 Sep 2014 16:04:25 +0200 > From: Jiri Vanek > To: Jacob Wisor , distro-pkg-dev at openjdk.java.net > > On 08/26/2014 09:51 AM, Jacob Wisor wrote: >> On 08/26/2014 09:16 AM, Jiri Vanek wrote: >>> ping? >>> >>> On 08/20/2014 08:30 PM, Jiri Vanek wrote: >>>> On 08/19/2014 11:25 PM, Jacob Wisor wrote: >>>>> On 08/18/2014 08:46 PM, Omair Majid wrote: >>>>>> Hi, >>>>>> >>>>>> >>>>>> * Jacob Wisor [2014-08-11 12:12]: >>>>>>> On 08/08/2014 10:37 AM, Jiri Vanek wrote: >>>>>>>> Unluckily this fix patch is not helping obscure servers to do exists. >>>>>>>> It really fixes bugs. >>>>>>>> >>>>>>>> First part of fix is delivered to be able handle SSLv2 handshake, Those >>>>>>>> servers >>>>>>>> do exists, and have no reason nor need to update or patch or whatever. We are >>>>>>>> wrong by not allowing it right now. >>>>>>>> See System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); in code. >>>>>>> >>>>>>> Oh yes they do need fixing. SSLv2 is insecure and has been revoked by the >>>>>>> IETF, period. Nobody should be using it. Even SSL 3.0 is deemed by the IETF >>>>>>> as historic (https://datatracker.ietf.org/doc/rfc6101) although it is >>>>>>> largely identical to TLS 1.0. Nevertheless, nobody should be using it >>>>>>> either. Just one of many reasons is that it does not even support such a >>>>>>> common hash algorithm as SHA1 (which by the way has been deprecated by NIST >>>>>>> in favor of SHA256 too). Everybody should really upgrade to at least TLS >>>>>>> 1.0, even though possible security leaks have been discovered in TLS 1.0 on >>>>>>> specific configuration settings permutations. >>>>>>> >>>>>>> DO NOT use SSL anymore and DO NOT promote them in your software. Upgrade to >>>>>>> TLS. >>>>>> >>>>>> This isn't SSv2, though. It's a SSLv2 hello packet wrapping an SSLv3 >>>>>> packet: http://bugs.java.com/bugdatabase/view_bug.do?bug_id=4915862 >>>>>> >>>>>> It's actually part of the TLS 1.0 spec: >>>>>> https://www.ietf.org/rfc/rfc2246.txt, Appendix E. >>>>> >>>>> This part describes backward compatibility of TLS 1.0 clients to SSL 3.0 and >>>>> SSL 2.0 servers (and >>>>> vice versa). >>>>> >>>>> "TLS 1.0 clients that support SSL Version 2.0 servers must send SSL >>>>> Version 2.0 client hello messages [SSL2]. TLS servers should accept >>>>> either client hello format if they wish to support SSL 2.0 clients on >>>>> the same connection port. The only deviations from the Version 2.0 >>>>> specification are the ability to specify a version with a value of >>>>> three and the support for more ciphering types in the CipherSpec." >>>>> >>>>> Currently, IcedTea-Web is a TLS 1.0 or SSL 3.0 client. According to this >>>>> paragraph, TLS 1.0 clients >>>>> send SSL 2.0 client hello messages in order to connect to SSL 2.0 servers, >>>>> that is, to negotiate a >>>>> SSL 2.0 connection. So no, SSL 2.0 servers do not upgrade automagically to >>>>> TLS 1.0 when they receive >>>>> SSL 2.0 client hello messages from TLS 1.0 clients. Pure old SSL 2.0 servers >>>>> will never speak >>>>> anything later than SSL 2.0. >>>>> >>>>> One reason behind this paragraph was for TLS 1.0 clients to allow probing SSL >>>>> 2.0 servers with >>>>> cipher specifications in SSL 2.0 and those introduced in TLS 1.0. In >>>>> practice, SSL 2.0 servers will >>>>> _never_ negotiate to a cipher specification introduced since TLS 1.0 because >>>>> they were simply not >>>>> built for that. >>>>> >>>>> Another reason for this paragraph back in 1999 (!) was to allow implementors >>>>> of TLS 1.0 to ease >>>>> transition from SSL to TLS and to give them the option to merge TLS into >>>>> their existing SSL >>>>> libraries (or as much as possible build on top of them). Again, this has >>>>> nothing to do with >>>>> automagically upgrading SSL 2.0 servers to TLS. It is just a description of >>>>> how TLS 1.0 clients >>>>> could fallback to SSL 2.0, if they wish to. >>>>> And, I am most certain nobody should want this, unless one has no clue what >>>>> transport security is >>>>> all about or is a complete lunatic. >>>>> >>>>> The next paragraph says it all: >>>>> >>>>> " Warning: The ability to send Version 2.0 client hello messages will be >>>>> phased out with all due haste. Implementors should make every >>>>> effort to move forward as quickly as possible. Version 3.0 >>>>> provides better mechanisms for moving to newer versions." >>>>> >>>>> So, the Java API should have got rid of the option to fallback to SSL 2.0 >>>>> years before. It's a shame >>>>> that J2SE still supports SSL 2.0 connections in 2014. Why? Because this has >>>>> nothing to do with >>>>> compatibility but with *security*. >>>>> >>>> >>>> Ok. Thank you for patience with me. (really!) >>>> >>>> So there is another approach. >>>> >>>> Now the ssl2 is tested as last attempt, and if it is possible to connect like >>>> that, then the user is >>>> warned and error is thrown (which leads to skipping resource from that >>>> >>>> >>>> The not-checking certificate now can be allowed or forbidden by properties. By >>>> default it asks user >>>> by every such invalid certs its found. How to deal with human intraction is todo. >>>> >>>> >>>> The reason for this message is to get verbose logical error emsssage, not only >>>> "itw do not work again" >>>> >>>> >>>> What do you think now? >>>> >>>> J. >> > >> > + DeploymentConfiguration.KEY_HTTPS_PROBINGALOWED, >> > [...] >> > + public static final String KEY_HTTPS_PROBINGALOWED = >> > "deployment.security.https.probing.alowed"; >> > [...] >> > + public void disconect(URLConnection conn) { >> > [...] >> > + public synchronized void disconectHttps(HttpsURLConnection conn) { >> > [...] >> > + private final boolean unsecure; >> > + >> > + private HttpsSettings(boolean ssl2, boolean unsecure) { >> > [...] >> > + public static URLConnection openConnection(URL url, boolean ssl2, >> > boolean unsecure) throws IOException { >> >> I am not testing this unless you have fixed your typos. >> For god's sake, your are a programmer, right? You should know best that exact spelling is important. >> Obviously, I am just talking till I am blue in the face. > > Noooo. I moreover overlooked :( Sorry. > > Now it should be as good as I'm able to do so without third party attendance. >> >> Also, please replace all occurrences of "ssl2" in text strings with "SSL2" (or "SSL 2.0" as used in >> the specification). Acronyms of names are always upper case in English. >> > > ok! >> > > > Here is updated version. > > > Sorry for delay, I was hacking the documentation generator. Now its one (discussing with Lukas > concurrently edited code), ad I think you will like it :) > > > J. > > > > > From jvanek at redhat.com Fri Sep 12 11:30:31 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 12 Sep 2014 13:30:31 +0200 Subject: [rfc][icedtea-web] missing jnlpfile and securtydelegate for TemporaryPermissionsButton calls In-Reply-To: <5408CF97.3030305@redhat.com> References: <53FDA41B.4060801@redhat.com> <53FE5CD3.4060602@redhat.com> <54070D4D.70605@redhat.com> <5408CF97.3030305@redhat.com> Message-ID: <5412D957.8040803@redhat.com> On 09/04/2014 10:46 PM, Andrew Azores wrote: > On 03/09/14 08:45 AM, Jiri Vanek wrote: >> On 08/28/2014 12:33 AM, Andrew Azores wrote: >>> Hi, >>> >>> Still on PTO here and preparing to move back into my parents' place while I go back to finish >>> school, so I haven't really invested any real time into this bug. But... >>> >>> On 08/27/2014 05:25 AM, Jiri Vanek wrote: >>>> Hi! >>>> >>>> During testing of https probing, helpcrypto found and interesting issue >>>> in head. >>>> >>>> Under some circumstances calls to TemporaryPermissionsButton have >>>> jnlpfile and securitydelegate null. >>> >>> The SecurityDelegate can be instantiated much earlier in JNLPClassLoader if need be. It can even be >>> the first thing done after calling the super constructor AFAIK. Since the JNLPClassLoader is also >>> what eventually causes the security dialog to appear with the Temporary Permissions button on it, >>> this will probably resolve the null securityDelegate reference part. >>> >>>> >>>> Two things troubles me: >>>> - both those values are needed only when "tmeporarypermissions" are >>>> clicked, so they should not affect startup of ITW >>>> - how come that they are null? I blame >>>> http://icedtea.classpath.org/hg/icedtea-web/annotate/d87ee4e6e81a/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java#78 >>>> >>>> >>>> >>>> (looking into Looking to this, >>>> http://icedtea.classpath.org/hg/icedtea-web/file/b4363c984e1b/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java#l79 >>>> >>>> >>>> ) >>> >>> For the null jnlpFile - I can't think off the top of my head what is causing that. It could just be >>> again that the dialog is being shown before a field has been assigned a value, as it is with the >>> securityDelegate. If it's simply an ordering issue like this then that isn't *too* concerning. If we >>> truly just do not have a reference to any JNLPFile or PluginBridge for this applet then there's >>> something seriously wrong. >>> >>>> >>>> >>>> Atatched is the nasty workarorund and here is snippet of log >>>> >>>> Securitymanager=net.sourceforge.jnlp.runtime.JNLPSecurityManager at 19f17b1 >>>> Registering priority for string reference 2 >>>> Registering priority for reference 2 >>>> Returning value:0 >>>> Setting value:0 >>>> Setting value:null >>>> dummy string null, null, javax.swing.JButton[,0,0,0x0,inva...snip... >>>> plugin_in_pipe_callback return >>>> plugin_send_message_to_appletviewer return >>>> PIPE: plugin wrote(?): plugin PluginProxyInfo reference 1 DIRECT >>>> plugin_send_message_to_appletviewer >>>> Proxy info: plugin PluginProxyInfo reference 1 DIRECT >>>> >>>> >>>> >>>> Without the workarround itw dies: >>>> >>>> ITNP_SetWindow return >>>> ITNP_SetWindow: window already exists. >>>> ITNP_SetWindow >>>> at java.lang.Thread.run(Thread.java:745) >>>> at >>>> net.sourceforge.jnlp.security.SecurityDialogMessageHandler.run(SecurityDialogMessageHandler.java:81) >>>> >>>> >>>> at >>>> net.sourceforge.jnlp.security.SecurityDialogMessageHandler.handleMessage(SecurityDialogMessageHandler.java:102) >>>> >>>> >>>> >>>> at net.sourceforge.jnlp.security.SecurityDialog. >>>> (SecurityDialog.java:129) >>>> at >>>> net.sourceforge.jnlp.security.SecurityDialog.initDialog(SecurityDialog.java:255) >>>> >>>> at >>>> net.sourceforge.jnlp.security.SecurityDialog.installPanel(SecurityDialog.java:307) >>>> >>>> at net.sourceforge.jnlp.security.dialogs.CertWarningPane. >>>> (CertWarningPane.java:116) >>>> at >>>> net.sourceforge.jnlp.security.dialogs.CertWarningPane.addComponents(CertWarningPane.java:124) >>>> >>>> at >>>> net.sourceforge.jnlp.security.dialogs.CertWarningPane.addButtons(CertWarningPane.java:242) >>>> >>>> at >>>> net.sourceforge.jnlp.security.dialogs.TemporaryPermissionsButton. >>>> (TemporaryPermissionsButton.java:79) >>>> at java.util.Objects.requireNonNull(Objects.java:201) >>>> Exception in thread "NetxSecurityThread" java.lang.NullPointerException >>>> plugin_in_pipe_callback return >>>> plugin_send_message_to_appletviewer return >>>> PIPE: plugin wrote(?): plugin PluginProxyInfo reference 1 DIRECT >>>> plugin_send_message_to_appletviewer >>>> Proxy info: plugin PluginProxyInfo reference 1 DIRECT >>>> >>>> >>>> >>>> I think the AssertNotNUll are really really invasive here. But at least >>>> they cought probably more serious issue - to early call to the dialogue >>>> with tmppermissions button.... >>>> >>>> >>>> J. >>> >>> Yup. The PolicyEditor can't be sensibly launched if the jnlpFile is null (your nasty workaround >>> really is nasty - assigning the new permissions to all applets rather than only ones on the current >>> applet's codebase!), and the securityDelegate is needed if this button is to function at all. So >>> there's no sensible thing to do if either of those fields come up null. Perhaps rather than outright >>> failing to launch ITW we could have the button indicate a failure somehow and have the dialog simply >>> not install the button, however. Just another option for Lukasz or whomever to look into. If this >>> still hasn't been fixed by the time I come off PTO then I'll gladly take ownership of the bug. >>> >> >> Andrew have made some investigations, and this is moreover conclusion >> - its a bug - the tmp permissions dialogue is shared among javaws and applets, and in applets >> lifecycle can happen this NPE >> - however, the fix will take some time > > Eh, not necessarily :) see below. > >> >> Even after it may be some cases, when this NPE will rise. We agreed that disabling the button n >> this case is probably best solution. >> >> >> The attache dpatch do so, >> >> Two nits : >> - is really the SecurityDelegate suddenly useless? > > Yes - this NPE bug only occurs when the button is being installed by a CertWarningPane invoked by > the VariableX509TrustManager. In other words, it only occurs when the dialog is asking the user > whether they trust the certificate presented for the current HTTPS connection, not when the dialog > is asking the user if they trust a certificate used to sign an applet. IMO it doesn't make sense to > decide to apply sandboxing rules to an applet at this point, based on trusting the HTTPS > certificate, although maybe that is something to explore. If we do want this to be an option then > the VariableX509TrustManager will have to have some work done so it can carry the extra state of the > JNLPFile and SecurityDelegate corresponding to the current applet/application as well. This would > take some extra time, but if we don't want to add allowing sandboxing based on the HTTPS certificate > trust, then your patch or mine are basically sufficient. > >> - Why all apps reproducing this issue suddenly started to work? ( I mean without this patch) > > Do they? I haven't tried to verify this but that's surprising to me. The only validation currently > done by the CertWarningPane is checking if the JNLPFile is null (which is a pretty fragile check - > it's been changed to check the type of the CertVerifier instead), and if it is, then the button is > not installed into the button panel. This decision is made well after the TemporaryPermissionsButton > has been instantiated, which means that the Objects.requireNonNull checks have been performed. And > the VariableX509TrustManager is still hard-coded to specifically provide "null" for the "file" and > "securityDelegate" parameters... > >> >> >> Still I think it is good thing to get rid of assers and disable button. > > I think it's better to just not show the button (buttonS really, it's the Sandbox as well as > Temporary Permissions) in this context, but it's an easy change to make either way. > >> >> >> J. >> >> > > Attached is my take on the patch. I also corrected the buttons on the dialog so that their labels > and tooltips make more sense in the context of trusting an HTTPS certificate rather than an applet > certificate. This looks a little messy with all the if statements added, but maybe it's not worth > abstracting this class and making two subclasses just to change the labels on the buttons (and > ignore two buttons from the button panel). Up to you. I can refactor it into two classes no problem > but I know you expressed distaste for this approach on IRC ;) > > Thanks, > Ok for head, with only nit... Please log in debug mode: + if (file == null || securityDelegate == null || linkedButton == null) { + this.setEnabled(false); log here which are suddenly null. + } else { Go on and push hten. J. From jvanek at redhat.com Fri Sep 12 11:32:59 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 12 Sep 2014 13:32:59 +0200 Subject: [rfc][icedtea-web] javaws.1 man page update In-Reply-To: <540A4B81.4090306@gmx.de> References: <53F8D650.5090702@redhat.com> <5409EFFB.8030504@redhat.com> <540A4B81.4090306@gmx.de> Message-ID: <5412D9EB.9090204@redhat.com> On 09/06/2014 01:47 AM, Jacob Wisor wrote: > On 09/05/2014 at 07:16 PM, Andrew Azores wrote: >> On 08/23/2014 01:58 PM, Andrew Azores wrote: >>> Hi, >>> >>> I looked at `man javaws` for some reason yesterday - no idea what I was >>> looking for or why - and thought it could do with some minor >>> improvement. I've fixed a few minor typos, improved the phrasing in a >>> few areas, and made it more consistent with capitalizing acronyms such >>> as XML, HTML, and JNLP. >>> >>> Thanks, >> >> Since the generated man pages feature is finally shaping up and looks like it >> might actually be done soon(ish), I suppose this patch is obsoleted? > > Not really. Actually, you should probably check the generated documentation output against the > improvements you have made in your patch. AFAICT, most of the stuff in your patch is about > punctuation and formatting. So, since you seem to have a keen eye on this you could check the > generated documentation output. ;-) > Andrew, do you mind to watch the localization patch which I'm now sending? I think I have covered most of the issues you picked up, but I culd overlook anything. Also feel free to rework this patch for head once the localization patches are done. J. From jvanek at redhat.com Fri Sep 12 13:24:21 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 12 Sep 2014 15:24:21 +0200 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup Message-ID: <5412F405.7050807@redhat.com> Hi! Last of the set. yupii! Except localizing-able the plugin and settings man/plain/html it celans up duplicated strings in NetworkSettingsPanel (and adding soem 7'th featueres) Tehre is also one change in makefile. I found that i dont like versioned subdirs :( SoI created docs/version/normla dirs structure. Especially for man it is rmeoving one unnecessary level and do work with it afaikmore comfortable Ty! J. -------------- next part -------------- A non-text attachment was scrubbed... Name: localizabblePlugin+settings+fix+cleanup.patch Type: text/x-patch Size: 15631 bytes Desc: not available URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 12 14:51:34 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 12 Sep 2014 14:51:34 +0000 Subject: [Bug 1996] New: SIGSEGV (0xb) at pc=0x00007fe0f869e242, pid=18628, tid=140603051435776 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1996 Bug ID: 1996 Summary: SIGSEGV (0xb) at pc=0x00007fe0f869e242, pid=18628, tid=140603051435776 Product: IcedTea Version: 7-hg Hardware: x86_64 OS: Linux Status: NEW Severity: critical Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: christine at christine.nl CC: unassigned at icedtea.classpath.org Created attachment 1170 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1170&action=edit saved file # # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007fe0f869e242, pid=18628, tid=140603051435776 # # JRE version: OpenJDK Runtime Environment (7.0_65-b32) (build 1.7.0_65-b32) # Java VM: OpenJDK 64-Bit Server VM (24.65-b04 mixed mode linux-amd64 compressed oops) # Problematic frame: # C [sqlite-3.7.2-libsqlitejdbc.so+0xe242] # # Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again # # An error report file with more information is saved as: # /home/...../hs_err_pid18628.log # -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From gitne at gmx.de Fri Sep 12 14:53:08 2014 From: gitne at gmx.de (Jacob Wisor) Date: Fri, 12 Sep 2014 16:53:08 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <5412D877.8070300@redhat.com> References: <54071FE9.2000309@redhat.com> <54101CEB.1040104@redhat.com> <5412D877.8070300@redhat.com> Message-ID: <541308D4.8020802@gmx.de> On 09/12/2014 01:26 PM, Jiri Vanek wrote: > > :((( > > > This patch is becoming blocker. > > > Any volunteer? > > > J. > On 09/10/2014 11:42 AM, Jiri Vanek wrote: >> ping? I am on it since yesterday. I am sorry but I have been called multiple times to do something else. Jacob From bugzilla-daemon at icedtea.classpath.org Fri Sep 12 14:59:45 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 12 Sep 2014 14:59:45 +0000 Subject: [Bug 1996] SIGSEGV (0xb) at pc=0x00007fe0f869e242, pid=18628, tid=140603051435776 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1996 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |INVALID Severity|critical |normal --- Comment #1 from Andrew John Hughes --- This is a crash in the sqlite library, not OpenJDK. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Sat Sep 13 15:39:49 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:39:49 +0000 Subject: /hg/icedtea7: Update to icedtea-2.6pre08. Message-ID: changeset d93bc33e8bd5 in /hg/icedtea7 details: http://icedtea.classpath.org/hg/icedtea7?cmd=changeset;node=d93bc33e8bd5 author: Andrew John Hughes date: Sat Sep 13 16:37:31 2014 +0100 Update to icedtea-2.6pre08. PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 S8006935, RH1131221: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-12 Andrew John Hughes * Makefile.am, (CORBA_CHANGESET): Update to icedtea-2.6pre08. (JAXP_CHANGESET): Likewise. (JAXWS_CHANGESET): Likewise. (JDK_CHANGESET): Likewise. (LANGTOOLS_CHANGESET): Likewise. (OPENJDK_CHANGESET): Likewise. (CORBA_SHA256SUM): Likewise. (JAXP_SHA256SUM): Likewise. (JAXWS_SHA256SUM): Likewise. (JDK_SHA256SUM): Likewise. (LANGTOOLS_SHA256SUM): Likewise. (OPENJDK_SHA256SUM): Likewise. * NEWS: Updated. * configure.ac: Bump to 2.6pre08. * hotspot.map: Update to icedtea-2.6pre08. diffstat: ChangeLog | 19 +++++++++++++++++++ Makefile.am | 24 ++++++++++++------------ NEWS | 6 +++++- configure.ac | 2 +- hotspot.map | 2 +- 5 files changed, 38 insertions(+), 15 deletions(-) diffs (99 lines): diff -r 941db1268ae7 -r d93bc33e8bd5 ChangeLog --- a/ChangeLog Wed Sep 03 15:37:20 2014 +0100 +++ b/ChangeLog Sat Sep 13 16:37:31 2014 +0100 @@ -1,3 +1,22 @@ +2014-09-12 Andrew John Hughes + + * Makefile.am, + (CORBA_CHANGESET): Update to icedtea-2.6pre08. + (JAXP_CHANGESET): Likewise. + (JAXWS_CHANGESET): Likewise. + (JDK_CHANGESET): Likewise. + (LANGTOOLS_CHANGESET): Likewise. + (OPENJDK_CHANGESET): Likewise. + (CORBA_SHA256SUM): Likewise. + (JAXP_SHA256SUM): Likewise. + (JAXWS_SHA256SUM): Likewise. + (JDK_SHA256SUM): Likewise. + (LANGTOOLS_SHA256SUM): Likewise. + (OPENJDK_SHA256SUM): Likewise. + * NEWS: Updated. + * configure.ac: Bump to 2.6pre08. + * hotspot.map: Update to icedtea-2.6pre08. + 2014-09-03 Andrew John Hughes * NEWS: Add 2.5.2 release notes. diff -r 941db1268ae7 -r d93bc33e8bd5 Makefile.am --- a/Makefile.am Wed Sep 03 15:37:20 2014 +0100 +++ b/Makefile.am Sat Sep 13 16:37:31 2014 +0100 @@ -4,19 +4,19 @@ BUILD_VERSION = b02 COMBINED_VERSION = $(JDK_UPDATE_VERSION)-$(BUILD_VERSION) -CORBA_CHANGESET = 30f5a9254154 -JAXP_CHANGESET = 614b7c12f276 -JAXWS_CHANGESET = f21a65d1832c -JDK_CHANGESET = 0cc91db3a787 -LANGTOOLS_CHANGESET = 3eab691bd9ac -OPENJDK_CHANGESET = 390d699dae61 +CORBA_CHANGESET = a756dcabdae6 +JAXP_CHANGESET = fbc3c0ab4c1d +JAXWS_CHANGESET = 646981c9ac47 +JDK_CHANGESET = 9702c7936ed8 +LANGTOOLS_CHANGESET = cdf407c97754 +OPENJDK_CHANGESET = df23e3760506 -CORBA_SHA256SUM = 0e3d6de86d961eb78fb8772551736d2714a4243bfa2564e97cdccdab46744482 -JAXP_SHA256SUM = 1fd51eba3addba7fb23803dc31a1d4f4690a36e4813c9e3cb8280a063591cbe8 -JAXWS_SHA256SUM = 15131dfd51691567024e4217653bfdf30c4481aee1282f6c1b9ba097271d16cd -JDK_SHA256SUM = 2f7160feb741a0b953318ced15f6749e74e708a7ef7c2cf6f2ff0ca0cbc64202 -LANGTOOLS_SHA256SUM = c67866825e43a4ccde0c87fba0de9df2c41049d4d9ad8853e0997a40531ab04b -OPENJDK_SHA256SUM = 4870d912c1e09534ddfb453577708fb986b15dd8c514f2be9135082f4dd1c1a1 +CORBA_SHA256SUM = 4ff808d8a6a109cbcf5822aa0041579c2c770ad8a72d99270f1eb2f296a3539c +JAXP_SHA256SUM = 9f1f8370e696212a3d637b2166a04467dcde18d603a8422dba4d85a930d11416 +JAXWS_SHA256SUM = b3503db871796b64c3702793bb99c183c0fb2058f48175b304ae187d90ef377b +JDK_SHA256SUM = 1df589e5fbfb2d4d51e9864bf341cad2a9e6ac904691ac43ebe0da6c776c320d +LANGTOOLS_SHA256SUM = c39d278aab303e837f1cdecb3b284af4a7e5524e457e67ca9ccef906c9c6e6a7 +OPENJDK_SHA256SUM = 0621bd1a03618c289e6781e6348419d42af71d03dda6c589be15677928659cd0 DROP_URL = http://icedtea.classpath.org/download/drops diff -r 941db1268ae7 -r d93bc33e8bd5 NEWS --- a/NEWS Wed Sep 03 15:37:20 2014 +0100 +++ b/NEWS Sat Sep 13 16:37:31 2014 +0100 @@ -190,12 +190,16 @@ - S8052159: TEST_BUG: javax/swing/JTextField/8036819/bug8036819.java fails to compile - S8054841: (process) ProcessBuilder leaks native memory * Backports - - S4963723: Implement SHA-224 + - S4963723, RH1131221: Implement SHA-224 - S7044060, RH1131221: Need to support NSA Suite B Cryptography algorithms + - S8006935, RH1131221: Need to take care of long secret keys in HMAC/PRF compuation * Bug fixes - PR1786: Allow x86 build to occur on x86_64 using a previously built x86_64 build - PR1846: Build fails when using IcedTea7 as bootstrap JDK with native ecj - PR1847: Synchronise javac.in with IcedTea6 + - PR1988: C++ Interpreter should no longer be used on ppc64 + - PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose + - PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 New in release 2.5.2 (2014-08-29): diff -r 941db1268ae7 -r d93bc33e8bd5 configure.ac --- a/configure.ac Wed Sep 03 15:37:20 2014 +0100 +++ b/configure.ac Sat Sep 13 16:37:31 2014 +0100 @@ -1,4 +1,4 @@ -AC_INIT([icedtea], [2.6pre07], [distro-pkg-dev at openjdk.java.net]) +AC_INIT([icedtea], [2.6pre08], [distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AM_MAINTAINER_MODE([enable]) AC_CONFIG_FILES([Makefile]) diff -r 941db1268ae7 -r d93bc33e8bd5 hotspot.map --- a/hotspot.map Wed Sep 03 15:37:20 2014 +0100 +++ b/hotspot.map Sat Sep 13 16:37:31 2014 +0100 @@ -1,3 +1,3 @@ # version type(drop/hg) url changeset sha256sum -default drop http://icedtea.classpath.org/download/drops/icedtea7 8ffb87775f56 4ebe884633a09388f1801303e77307ceb1987d2228963c6f517939ac5f26cd0c +default drop http://icedtea.classpath.org/download/drops/icedtea7 6d5ec408f4ca 569f1529b900fc52435da4aa2f06f5697fe61459ed2962fc39a21e392d431206 aarch64 hg http://hg.openjdk.java.net/aarch64-port/jdk7u/hotspot f50993b6c38d 64c2d0bfa71d6eecf18ab28fd64d5bd79af096f77548d80de7953c306fd9c22c From bugzilla-daemon at icedtea.classpath.org Sat Sep 13 15:40:00 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:40:00 +0000 Subject: [Bug 1992] [IcedTea7] Support retrieving proxy settings on GNOME 3 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1992 --- Comment #2 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7?cmd=changeset;node=d93bc33e8bd5 author: Andrew John Hughes date: Sat Sep 13 16:37:31 2014 +0100 Update to icedtea-2.6pre08. PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 S8006935, RH1131221: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-12 Andrew John Hughes * Makefile.am, (CORBA_CHANGESET): Update to icedtea-2.6pre08. (JAXP_CHANGESET): Likewise. (JAXWS_CHANGESET): Likewise. (JDK_CHANGESET): Likewise. (LANGTOOLS_CHANGESET): Likewise. (OPENJDK_CHANGESET): Likewise. (CORBA_SHA256SUM): Likewise. (JAXP_SHA256SUM): Likewise. (JAXWS_SHA256SUM): Likewise. (JDK_SHA256SUM): Likewise. (LANGTOOLS_SHA256SUM): Likewise. (OPENJDK_SHA256SUM): Likewise. * NEWS: Updated. * configure.ac: Bump to 2.6pre08. * hotspot.map: Update to icedtea-2.6pre08. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Sat Sep 13 15:40:06 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:40:06 +0000 Subject: [Bug 1988] [IcedTea7] C++ Interpreter should no longer be used on ppc64 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1988 --- Comment #2 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7?cmd=changeset;node=d93bc33e8bd5 author: Andrew John Hughes date: Sat Sep 13 16:37:31 2014 +0100 Update to icedtea-2.6pre08. PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 S8006935, RH1131221: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-12 Andrew John Hughes * Makefile.am, (CORBA_CHANGESET): Update to icedtea-2.6pre08. (JAXP_CHANGESET): Likewise. (JAXWS_CHANGESET): Likewise. (JDK_CHANGESET): Likewise. (LANGTOOLS_CHANGESET): Likewise. (OPENJDK_CHANGESET): Likewise. (CORBA_SHA256SUM): Likewise. (JAXP_SHA256SUM): Likewise. (JAXWS_SHA256SUM): Likewise. (JDK_SHA256SUM): Likewise. (LANGTOOLS_SHA256SUM): Likewise. (OPENJDK_SHA256SUM): Likewise. * NEWS: Updated. * configure.ac: Bump to 2.6pre08. * hotspot.map: Update to icedtea-2.6pre08. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Sat Sep 13 15:40:09 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:40:09 +0000 Subject: [Bug 1989] [IcedTea7] Make jdk_generic_profile.sh handle missing programs better and be more verbose In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1989 --- Comment #2 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7?cmd=changeset;node=d93bc33e8bd5 author: Andrew John Hughes date: Sat Sep 13 16:37:31 2014 +0100 Update to icedtea-2.6pre08. PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 S8006935, RH1131221: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-12 Andrew John Hughes * Makefile.am, (CORBA_CHANGESET): Update to icedtea-2.6pre08. (JAXP_CHANGESET): Likewise. (JAXWS_CHANGESET): Likewise. (JDK_CHANGESET): Likewise. (LANGTOOLS_CHANGESET): Likewise. (OPENJDK_CHANGESET): Likewise. (CORBA_SHA256SUM): Likewise. (JAXP_SHA256SUM): Likewise. (JAXWS_SHA256SUM): Likewise. (JDK_SHA256SUM): Likewise. (LANGTOOLS_SHA256SUM): Likewise. (OPENJDK_SHA256SUM): Likewise. * NEWS: Updated. * configure.ac: Bump to 2.6pre08. * hotspot.map: Update to icedtea-2.6pre08. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Sat Sep 13 15:42:16 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:42:16 +0000 Subject: /hg/icedtea7-forest/corba: Added tag icedtea-2.6pre08 for change... Message-ID: changeset 1f4f51eef6d7 in /hg/icedtea7-forest/corba details: http://icedtea.classpath.org/hg/icedtea7-forest/corba?cmd=changeset;node=1f4f51eef6d7 author: andrew date: Sat Sep 13 16:38:47 2014 +0100 Added tag icedtea-2.6pre08 for changeset a756dcabdae6 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r a756dcabdae6 -r 1f4f51eef6d7 .hgtags --- a/.hgtags Wed Aug 27 23:07:41 2014 +0100 +++ b/.hgtags Sat Sep 13 16:38:47 2014 +0100 @@ -489,3 +489,4 @@ df1decc820934ad8bf91c853e81c88d4f7590e25 jdk7u80-b01 30f5a9254154b68dd16e2d93579d7606c79bd54b icedtea-2.6pre07 250d1a2def5b39f99b2f2793821cac1d63b9629f icedtea-2.6pre06 +a756dcabdae6fcdff57a2d321088c42604b248a6 icedtea-2.6pre08 From andrew at icedtea.classpath.org Sat Sep 13 15:42:22 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:42:22 +0000 Subject: /hg/icedtea7-forest/jaxp: Added tag icedtea-2.6pre08 for changes... Message-ID: changeset d700606ea729 in /hg/icedtea7-forest/jaxp details: http://icedtea.classpath.org/hg/icedtea7-forest/jaxp?cmd=changeset;node=d700606ea729 author: andrew date: Sat Sep 13 16:38:48 2014 +0100 Added tag icedtea-2.6pre08 for changeset fbc3c0ab4c1d diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r fbc3c0ab4c1d -r d700606ea729 .hgtags --- a/.hgtags Wed Aug 27 23:07:42 2014 +0100 +++ b/.hgtags Sat Sep 13 16:38:48 2014 +0100 @@ -490,3 +490,4 @@ 4c959b6a32057ec18c9c722ada3d0d0c716a51c4 jdk7u80-b01 614b7c12f276c52ebef06fb17c79cf0eadbcc774 icedtea-2.6pre07 75513ef5e265955b432550ec73770b8404a4d36b icedtea-2.6pre06 +fbc3c0ab4c1d53059c32d330ca36cb33a3c04299 icedtea-2.6pre08 From andrew at icedtea.classpath.org Sat Sep 13 15:42:27 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:42:27 +0000 Subject: /hg/icedtea7-forest/jaxws: Added tag icedtea-2.6pre08 for change... Message-ID: changeset 4e25a5278078 in /hg/icedtea7-forest/jaxws details: http://icedtea.classpath.org/hg/icedtea7-forest/jaxws?cmd=changeset;node=4e25a5278078 author: andrew date: Sat Sep 13 16:38:49 2014 +0100 Added tag icedtea-2.6pre08 for changeset 646981c9ac47 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r 646981c9ac47 -r 4e25a5278078 .hgtags --- a/.hgtags Wed Aug 27 23:07:42 2014 +0100 +++ b/.hgtags Sat Sep 13 16:38:49 2014 +0100 @@ -489,3 +489,4 @@ 0eb2482c3d0663c39794ec4c268acc41c4cd387b jdk7u80-b01 f21a65d1832ce426c02a7d87b9d83b1a4a64018c icedtea-2.6pre07 37d1831108b5ced7f1e63e1cd58b46dba7b76cc9 icedtea-2.6pre06 +646981c9ac471feb9c600504585a4f2c59aa2f61 icedtea-2.6pre08 From andrew at icedtea.classpath.org Sat Sep 13 15:42:33 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:42:33 +0000 Subject: /hg/icedtea7-forest/langtools: Added tag icedtea-2.6pre08 for ch... Message-ID: changeset 7567648c553a in /hg/icedtea7-forest/langtools details: http://icedtea.classpath.org/hg/icedtea7-forest/langtools?cmd=changeset;node=7567648c553a author: andrew date: Sat Sep 13 16:38:55 2014 +0100 Added tag icedtea-2.6pre08 for changeset cdf407c97754 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r cdf407c97754 -r 7567648c553a .hgtags --- a/.hgtags Wed Aug 27 23:07:43 2014 +0100 +++ b/.hgtags Sat Sep 13 16:38:55 2014 +0100 @@ -489,3 +489,4 @@ 6c307a0b7a94e002d8a2532ffd8146d6c53f42d3 jdk7u80-b01 3eab691bd9ac5222c11dbabb7b5fbc8463c62df6 icedtea-2.6pre07 f43a81252f827395020fe71099bfa62f2ca0de50 icedtea-2.6pre06 +cdf407c97754412b02ebfdda111319dbd3cb9ca9 icedtea-2.6pre08 From andrew at icedtea.classpath.org Sat Sep 13 15:42:39 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:42:39 +0000 Subject: /hg/icedtea7-forest/hotspot: Added tag icedtea-2.6pre08 for chan... Message-ID: changeset 9e540ae27ead in /hg/icedtea7-forest/hotspot details: http://icedtea.classpath.org/hg/icedtea7-forest/hotspot?cmd=changeset;node=9e540ae27ead author: andrew date: Sat Sep 13 16:38:57 2014 +0100 Added tag icedtea-2.6pre08 for changeset 6d5ec408f4ca diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r 6d5ec408f4ca -r 9e540ae27ead .hgtags --- a/.hgtags Mon Sep 08 17:44:42 2014 +0100 +++ b/.hgtags Sat Sep 13 16:38:57 2014 +0100 @@ -717,3 +717,4 @@ e2533d62ca887078e4b952a75a75680cfb7894b9 jdk7u80-b01 8ffb87775f56ed5c602f320d2513351298ee4778 icedtea-2.6pre07 b517477362d1b0d4f9b567c82db85136fd14bc6e icedtea-2.6pre06 +6d5ec408f4cac2c2004bf6120403df1b18051a21 icedtea-2.6pre08 From andrew at icedtea.classpath.org Sat Sep 13 15:42:46 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 13 Sep 2014 15:42:46 +0000 Subject: /hg/icedtea7-forest/jdk: Added tag icedtea-2.6pre08 for changese... Message-ID: changeset 6923000c68ee in /hg/icedtea7-forest/jdk details: http://icedtea.classpath.org/hg/icedtea7-forest/jdk?cmd=changeset;node=6923000c68ee author: andrew date: Sat Sep 13 16:38:53 2014 +0100 Added tag icedtea-2.6pre08 for changeset 9702c7936ed8 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r 9702c7936ed8 -r 6923000c68ee .hgtags --- a/.hgtags Wed Sep 10 17:12:24 2014 +0100 +++ b/.hgtags Sat Sep 13 16:38:53 2014 +0100 @@ -473,3 +473,4 @@ bc7f9d966c1df3748ef9c148eab25976cd065963 jdk7u80-b01 0cc91db3a787da44e3775bdde4c3c222d3cd529f icedtea-2.6pre07 21eee0ed9be97d4e283cdf626971281481e711f1 icedtea-2.6pre06 +9702c7936ed8da9befdc27d30b2cbf51718d810a icedtea-2.6pre08 From aazores at redhat.com Sat Sep 13 16:53:01 2014 From: aazores at redhat.com (Andrew Azores) Date: Sat, 13 Sep 2014 12:53:01 -0400 Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <2058764014.3737904.1410444088683.JavaMail.zimbra@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> <54107019.2030106@redhat.com> <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> <5410E9B6.2030808@redhat.com> <2058764014.3737904.1410444088683.JavaMail.zimbra@redhat.com> Message-ID: <5414766D.6000901@redhat.com> On 09/11/2014 10:01 AM, Jie Kang wrote: > > > ----- Original Message ----- >> On 09/10/2014 02:31 PM, Jie Kang wrote: >>> >>> Hello, >>> >>> >>> Good points. I have made Translator an enum with a single instance where >>> the public static String R still remains and added basic unit tests for >>> Translator. >>> >>> >> >> Overall I definitely like the idea behind this patch. Just a few minor >> implementation details I have some questions about. >> >>> public static String R(String message) { >>> - return JNLPRuntime.getMessage(message); >>> + return getInstance().getMessage(message); >>> } >> >> Can this be defined in terms of Translator.R(String, Object...) instead? >> Not a big deal but it seems natural to me. > > Hello, > > > Thanks for the review! > > I am not sure if I understood correctly but for this R(String message) do you mean something like: > return R(message, new Object[0]) > > I prefer the other way since it's more efficient and makes more sense to me hahah. Though I understand what you mean by being more natural. It's just on closer inspection it seems really weird to make this call when you can just use getInstance().getMessage(message); > > Is it okay if I keep it original? Sure, this definitely is not a blocker on push. I think "efficiency" here is a pretty weak reason though ;) it's just one extra method call, not very heavy. The other benefit is that if down the line somebody wants to add some extra validation or something, for example, then it only needs to be added in one of the methods, rather than both overloads. It's also a little bit confusing looking because since R(String, Object...) is varargs, it's actually valid to call it simply as, for example, R("TEST"). In this case, your varargs array just ends up being the empty array. So what you've done by defining both methods is essentially add a constraint for the varargs that it has to be of at least size 1, then branching into different calls to getMessage, one of which is actually defined in terms of the other in failure cases anyway... the call web is just a bit tangled is what I'm trying to say. But it's fine as-is regardless. > >> >>> + public static void loadResourceBundle(ResourceBundle bundle) { >>> + getInstance().resources = bundle; >>> + } >> >> Why is this still static? I think this makes sense as a method belonging >> to the singleton instance, and I only see one call site (TranslatorTest) >> that would need to be refactored. I would also rather see a >> (package-private?) setter method rather than direct field assignment >> here, but that's not a huge deal. > > I chose to make it static since I wanted the class to be accessed in a consistent manner. getInstance() was private and R() was public static so it made sense to me to make loadResourceBundle() also static in order to preserve the privacy of getInstance(). > Well, getInstance() may have been private, but INSTANCE is not anyway ;) > Also I preferred keeping it public in order to possibly allow for itweb-settings to have an option to set the preferred locale or something like that (in the future). Now that I think about it, this isn't necessary. > > >> >>> + } catch (Exception ex) { >>> + throw new IllegalStateException("Missing resource bundle in >>> netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); >>> + } >> >> Is this path correct even for non-default (English) locales? Eg for >> Czech shouldn't it be attempting (and failing) to load >> net/sourceforge/jnlp/resource/Messages_cs.properties? I'm not sure how >> easy it is to get the name of the ResourceBundle that the runtime would >> attempt to load however, it may not be worth the effort - this is a >> pretty close approximation anyway even for other locales I suppose. > > In terms of resource bundle failing to load, it attempts to load whatever the default locale is and failing that, attempts to load the base copy, only if the base does not exist will it fail and throw the exception. Getting the default locale is pretty easy so I've changed the message to be more appropriate. > > How does it look? Ah okay, this makes perfect sense. I do like the new message better. > > > Thanks, > >> >> Thanks, >> -- >> Andrew Azores >> > +1 okay to push from me. Thanks, -- Andrew Azores From aazores at redhat.com Sat Sep 13 17:01:19 2014 From: aazores at redhat.com (Andrew Azores) Date: Sat, 13 Sep 2014 13:01:19 -0400 Subject: [rfc] ]icedtea-web] localizable javaws + policieditor + minor fixes In-Reply-To: <5411B6DD.2020800@redhat.com> References: <5411B6DD.2020800@redhat.com> Message-ID: <5414785F.6040402@redhat.com> On 09/11/2014 10:51 AM, Jiri Vanek wrote: > +PEdescL2=If executed without any arguments, no file is opened, and saving the file will result in a prompt on where to save it. Otherwise, if a file path is given as \ > +a command line argument, then that file path will be opened and parsed as policy file. > parsed as policy My eagle-eyes spy two spaces before 'policy' O:) +1 for push with that tiny fix Thanks, -- Andrew Azores From aazores at icedtea.classpath.org Sat Sep 13 17:23:40 2014 From: aazores at icedtea.classpath.org (aazores at icedtea.classpath.org) Date: Sat, 13 Sep 2014 17:23:40 +0000 Subject: /hg/icedtea-web: Fix for TemporaryPermissionsButton NPE on HTTPS... Message-ID: changeset 90faf53bb981 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=90faf53bb981 author: Andrew Azores date: Sat Sep 13 13:23:26 2014 -0400 Fix for TemporaryPermissionsButton NPE on HTTPS Cert warnings 2014-09-13 Andrew Azores * netx/net/sourceforge/jnlp/resources/Messages.properties (CertWarnHTTPSAcceptTip, CertWarnHTTPSRejectTip): new messages more applicable for HTTPS cert warning dialogs * netx/net/sourceforge/jnlp/security/dialogs/CertWarningPane.java: distinguish between HTTPS cert warnings and signed applet cert warnings. Display appropriate text labels and buttons corresponding to either case. * netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java: remove assertions for non-null file, securityDelegate, and linkedButton. Instead, if any are null, simply disable this component and do not add component listeners dependent upon these fields. diffstat: ChangeLog | 13 +++ netx/net/sourceforge/jnlp/resources/Messages.properties | 2 + netx/net/sourceforge/jnlp/security/dialogs/CertWarningPane.java | 41 +++++++-- netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java | 32 +++++-- 4 files changed, 67 insertions(+), 21 deletions(-) diffs (164 lines): diff -r e30d71ab91c6 -r 90faf53bb981 ChangeLog --- a/ChangeLog Wed Sep 10 10:22:46 2014 -0400 +++ b/ChangeLog Sat Sep 13 13:23:26 2014 -0400 @@ -1,3 +1,16 @@ +2014-09-13 Andrew Azores + + * netx/net/sourceforge/jnlp/resources/Messages.properties + (CertWarnHTTPSAcceptTip, CertWarnHTTPSRejectTip): new messages more + applicable for HTTPS cert warning dialogs + * netx/net/sourceforge/jnlp/security/dialogs/CertWarningPane.java: + distinguish between HTTPS cert warnings and signed applet cert warnings. + Display appropriate text labels and buttons corresponding to either case. + * netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java: + remove assertions for non-null file, securityDelegate, and linkedButton. + Instead, if any are null, simply disable this component and do not add + component listeners dependent upon these fields. + 2014-09-10 Lukasz Dracz Refactor of the cache panel GUI in itweb-settings diff -r e30d71ab91c6 -r 90faf53bb981 netx/net/sourceforge/jnlp/resources/Messages.properties --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 10 10:22:46 2014 -0400 +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Sat Sep 13 13:23:26 2014 -0400 @@ -25,6 +25,8 @@ CertWarnCancelTip=Do not run this applet CertWarnPolicyTip=Advanced sandbox settings CertWarnPolicyEditorItem=Launch PolicyEditor +CertWarnHTTPSAcceptTip=Accept this certificate and trust the HTTPS connection +CertWarnHTTPSRejectTip=Do not accept this certificate and do not establish the HTTPS connection AFileOnTheMachine=a file on the machine AlwaysAllowAction=Always allow this action diff -r e30d71ab91c6 -r 90faf53bb981 netx/net/sourceforge/jnlp/security/dialogs/CertWarningPane.java --- a/netx/net/sourceforge/jnlp/security/dialogs/CertWarningPane.java Wed Sep 10 10:22:46 2014 -0400 +++ b/netx/net/sourceforge/jnlp/security/dialogs/CertWarningPane.java Sat Sep 13 13:23:26 2014 -0400 @@ -224,7 +224,8 @@ infoPanel.add(nameLabel); infoPanel.add(publisherLabel); - if (!(certVerifier instanceof HttpsCertVerifier)) { + final boolean isHttpsCertTrustDialog = certVerifier instanceof HttpsCertVerifier; + if (!isHttpsCertTrustDialog) { infoPanel.add(fromLabel); } @@ -233,15 +234,34 @@ //run and cancel buttons buttonPanel = new JPanel(new FlowLayout(FlowLayout.RIGHT)); - run = new JButton(R("ButRun")); + run = new JButton(); + if (isHttpsCertTrustDialog) { + run.setText(R("ButYes")); + } else { + run.setText(R("ButRun")); + } sandbox = new JButton(R("ButSandbox")); advancedOptions = new TemporaryPermissionsButton(file, securityDelegate, sandbox); - cancel = new JButton(R("ButCancel")); - run.setToolTipText(R("CertWarnRunTip")); + cancel = new JButton(); + if (isHttpsCertTrustDialog) { + cancel.setText(R("ButNo")); + } else { + cancel.setText(R("ButCancel")); + } + + if (isHttpsCertTrustDialog) { + run.setToolTipText(R("CertWarnHTTPSAcceptTip")); + } else { + run.setToolTipText(R("CertWarnRunTip")); + } sandbox.setToolTipText(R("CertWarnSandboxTip")); advancedOptions.setToolTipText(R("CertWarnPolicyTip")); - cancel.setToolTipText(R("CertWarnCancelTip")); + if (isHttpsCertTrustDialog) { + cancel.setToolTipText(R("CertWarnHTTPSRejectTip")); + } else { + cancel.setToolTipText(R("CertWarnCancelTip")); + } alwaysTrust.addActionListener(new ButtonDisableListener(sandbox)); int buttonWidth = Math.max(run.getMinimumSize().width, @@ -266,11 +286,12 @@ initialFocusComponent = cancel; buttonPanel.add(run); - // file will be null iff this dialog is being called from VariableX509TrustManager. - // In this case, the "sandbox" button does not make any sense, as we are asking - // the user if they trust some certificate that is not being used to sign an app. - // Since there is no app, there is nothing to run sandboxed. - if (file != null) { + // Only iff this dialog is being invoked by VariableX509TrustManager. + // In this case, the "sandbox" button and temporary permissions do not make any sense, + // as we are asking the user if they trust some certificate that is not being used to sign an app + // (eg "do you trust this certificate presented for the HTTPS connection to the applet's host site") + // Since this dialog isn't talking about an applet/application, there is nothing to run sandboxed. + if (!isHttpsCertTrustDialog) { buttonPanel.add(sandbox); buttonPanel.add(advancedOptions); } diff -r e30d71ab91c6 -r 90faf53bb981 netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java --- a/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java Wed Sep 10 10:22:46 2014 -0400 +++ b/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java Sat Sep 13 13:23:26 2014 -0400 @@ -49,7 +49,6 @@ import java.security.Permission; import java.util.Collection; import java.util.HashSet; -import java.util.Objects; import javax.swing.AbstractButton; import javax.swing.JButton; @@ -64,6 +63,7 @@ import net.sourceforge.jnlp.security.policyeditor.PolicyEditor; import net.sourceforge.jnlp.security.policyeditor.PolicyEditor.PolicyEditorWindow; import net.sourceforge.jnlp.security.policyeditor.PolicyEditorPermissions; +import net.sourceforge.jnlp.util.logging.OutputController; public class TemporaryPermissionsButton extends JButton { @@ -75,22 +75,32 @@ private final Collection temporaryPermissions = new HashSet<>(); public TemporaryPermissionsButton(final JNLPFile file, final SecurityDelegate securityDelegate, final JButton linkedButton) { + /* If any of the above parameters are null, then the button cannot function - in particular, a null SecurityDelegate + * would prevent temporary permissions from being able to be added; a null JNLPFile would prevent PolicyEditor from + * being launched with a sensible codebase for the current applet; and a null JButton would prevent the Sandbox button + * from being automatically invoked when a set of temporary permissions are selected by the user. + */ super("\u2630"); - Objects.requireNonNull(file); - Objects.requireNonNull(securityDelegate); - Objects.requireNonNull(linkedButton); this.menu = createPolicyPermissionsMenu(); this.linkedButton = linkedButton; this.file = file; this.securityDelegate = securityDelegate; - linkedButton.addActionListener(new ActionListener() { - @Override - public void actionPerformed(ActionEvent e) { - securityDelegate.addPermissions(temporaryPermissions); - } - }); - addMouseListener(new PolicyEditorPopupListener(this)); + if (file == null || securityDelegate == null || linkedButton == null) { + this.setEnabled(false); + OutputController.getLogger().log(OutputController.Level.MESSAGE_DEBUG, "Temporary Permissions Button disabled due to null fields." + + " file: " + file + + ", securityDelegate: " + securityDelegate + + ", linkedButton: " + linkedButton); + } else { + linkedButton.addActionListener(new ActionListener() { + @Override + public void actionPerformed(ActionEvent e) { + securityDelegate.addPermissions(temporaryPermissions); + } + }); + addMouseListener(new PolicyEditorPopupListener(this)); + } } private JPopupMenu createPolicyPermissionsMenu() { From aazores at redhat.com Sat Sep 13 17:24:46 2014 From: aazores at redhat.com (Andrew Azores) Date: Sat, 13 Sep 2014 13:24:46 -0400 Subject: [rfc][icedtea-web] missing jnlpfile and securtydelegate for TemporaryPermissionsButton calls In-Reply-To: <5412D957.8040803@redhat.com> References: <53FDA41B.4060801@redhat.com> <53FE5CD3.4060602@redhat.com> <54070D4D.70605@redhat.com> <5408CF97.3030305@redhat.com> <5412D957.8040803@redhat.com> Message-ID: <54147DDE.6040708@redhat.com> On 09/12/2014 07:30 AM, Jiri Vanek wrote: > On 09/04/2014 10:46 PM, Andrew Azores wrote: >> On 03/09/14 08:45 AM, Jiri Vanek wrote: >>> On 08/28/2014 12:33 AM, Andrew Azores wrote: >>>> Hi, >>>> >>>> Still on PTO here and preparing to move back into my parents' place >>>> while I go back to finish >>>> school, so I haven't really invested any real time into this bug. >>>> But... >>>> >>>> On 08/27/2014 05:25 AM, Jiri Vanek wrote: >>>>> Hi! >>>>> >>>>> During testing of https probing, helpcrypto found and interesting >>>>> issue >>>>> in head. >>>>> >>>>> Under some circumstances calls to TemporaryPermissionsButton have >>>>> jnlpfile and securitydelegate null. >>>> >>>> The SecurityDelegate can be instantiated much earlier in >>>> JNLPClassLoader if need be. It can even be >>>> the first thing done after calling the super constructor AFAIK. >>>> Since the JNLPClassLoader is also >>>> what eventually causes the security dialog to appear with the >>>> Temporary Permissions button on it, >>>> this will probably resolve the null securityDelegate reference part. >>>> >>>>> >>>>> Two things troubles me: >>>>> - both those values are needed only when "tmeporarypermissions" are >>>>> clicked, so they should not affect startup of ITW >>>>> - how come that they are null? I blame >>>>> http://icedtea.classpath.org/hg/icedtea-web/annotate/d87ee4e6e81a/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java#78 >>>>> >>>>> >>>>> >>>>> >>>>> (looking into Looking to this, >>>>> http://icedtea.classpath.org/hg/icedtea-web/file/b4363c984e1b/netx/net/sourceforge/jnlp/security/dialogs/TemporaryPermissionsButton.java#l79 >>>>> >>>>> >>>>> >>>>> ) >>>> >>>> For the null jnlpFile - I can't think off the top of my head what is >>>> causing that. It could just be >>>> again that the dialog is being shown before a field has been >>>> assigned a value, as it is with the >>>> securityDelegate. If it's simply an ordering issue like this then >>>> that isn't *too* concerning. If we >>>> truly just do not have a reference to any JNLPFile or PluginBridge >>>> for this applet then there's >>>> something seriously wrong. >>>> >>>>> >>>>> >>>>> Atatched is the nasty workarorund and here is snippet of log >>>>> >>>>> Securitymanager=net.sourceforge.jnlp.runtime.JNLPSecurityManager at 19f17b1 >>>>> >>>>> Registering priority for string reference 2 >>>>> Registering priority for reference 2 >>>>> Returning value:0 >>>>> Setting value:0 >>>>> Setting value:null >>>>> dummy string null, null, javax.swing.JButton[,0,0,0x0,inva...snip... >>>>> plugin_in_pipe_callback return >>>>> plugin_send_message_to_appletviewer return >>>>> PIPE: plugin wrote(?): plugin PluginProxyInfo reference 1 DIRECT >>>>> plugin_send_message_to_appletviewer >>>>> Proxy info: plugin PluginProxyInfo reference 1 DIRECT >>>>> >>>>> >>>>> >>>>> Without the workarround itw dies: >>>>> >>>>> ITNP_SetWindow return >>>>> ITNP_SetWindow: window already exists. >>>>> ITNP_SetWindow >>>>> at java.lang.Thread.run(Thread.java:745) >>>>> at >>>>> net.sourceforge.jnlp.security.SecurityDialogMessageHandler.run(SecurityDialogMessageHandler.java:81) >>>>> >>>>> >>>>> >>>>> at >>>>> net.sourceforge.jnlp.security.SecurityDialogMessageHandler.handleMessage(SecurityDialogMessageHandler.java:102) >>>>> >>>>> >>>>> >>>>> >>>>> at net.sourceforge.jnlp.security.SecurityDialog. >>>>> (SecurityDialog.java:129) >>>>> at >>>>> net.sourceforge.jnlp.security.SecurityDialog.initDialog(SecurityDialog.java:255) >>>>> >>>>> >>>>> at >>>>> net.sourceforge.jnlp.security.SecurityDialog.installPanel(SecurityDialog.java:307) >>>>> >>>>> >>>>> at net.sourceforge.jnlp.security.dialogs.CertWarningPane. >>>>> (CertWarningPane.java:116) >>>>> at >>>>> net.sourceforge.jnlp.security.dialogs.CertWarningPane.addComponents(CertWarningPane.java:124) >>>>> >>>>> >>>>> at >>>>> net.sourceforge.jnlp.security.dialogs.CertWarningPane.addButtons(CertWarningPane.java:242) >>>>> >>>>> >>>>> at >>>>> net.sourceforge.jnlp.security.dialogs.TemporaryPermissionsButton. >>>>> (TemporaryPermissionsButton.java:79) >>>>> at java.util.Objects.requireNonNull(Objects.java:201) >>>>> Exception in thread "NetxSecurityThread" >>>>> java.lang.NullPointerException >>>>> plugin_in_pipe_callback return >>>>> plugin_send_message_to_appletviewer return >>>>> PIPE: plugin wrote(?): plugin PluginProxyInfo reference 1 DIRECT >>>>> plugin_send_message_to_appletviewer >>>>> Proxy info: plugin PluginProxyInfo reference 1 DIRECT >>>>> >>>>> >>>>> >>>>> I think the AssertNotNUll are really really invasive here. But at >>>>> least >>>>> they cought probably more serious issue - to early call to the >>>>> dialogue >>>>> with tmppermissions button.... >>>>> >>>>> >>>>> J. >>>> >>>> Yup. The PolicyEditor can't be sensibly launched if the jnlpFile is >>>> null (your nasty workaround >>>> really is nasty - assigning the new permissions to all applets >>>> rather than only ones on the current >>>> applet's codebase!), and the securityDelegate is needed if this >>>> button is to function at all. So >>>> there's no sensible thing to do if either of those fields come up >>>> null. Perhaps rather than outright >>>> failing to launch ITW we could have the button indicate a failure >>>> somehow and have the dialog simply >>>> not install the button, however. Just another option for Lukasz or >>>> whomever to look into. If this >>>> still hasn't been fixed by the time I come off PTO then I'll gladly >>>> take ownership of the bug. >>>> >>> >>> Andrew have made some investigations, and this is moreover conclusion >>> - its a bug - the tmp permissions dialogue is shared among javaws >>> and applets, and in applets >>> lifecycle can happen this NPE >>> - however, the fix will take some time >> >> Eh, not necessarily :) see below. >> >>> >>> Even after it may be some cases, when this NPE will rise. We agreed >>> that disabling the button n >>> this case is probably best solution. >>> >>> >>> The attache dpatch do so, >>> >>> Two nits : >>> - is really the SecurityDelegate suddenly useless? >> >> Yes - this NPE bug only occurs when the button is being installed by a >> CertWarningPane invoked by >> the VariableX509TrustManager. In other words, it only occurs when the >> dialog is asking the user >> whether they trust the certificate presented for the current HTTPS >> connection, not when the dialog >> is asking the user if they trust a certificate used to sign an applet. >> IMO it doesn't make sense to >> decide to apply sandboxing rules to an applet at this point, based on >> trusting the HTTPS >> certificate, although maybe that is something to explore. If we do >> want this to be an option then >> the VariableX509TrustManager will have to have some work done so it >> can carry the extra state of the >> JNLPFile and SecurityDelegate corresponding to the current >> applet/application as well. This would >> take some extra time, but if we don't want to add allowing sandboxing >> based on the HTTPS certificate >> trust, then your patch or mine are basically sufficient. >> >>> - Why all apps reproducing this issue suddenly started to work? ( >>> I mean without this patch) >> >> Do they? I haven't tried to verify this but that's surprising to me. >> The only validation currently >> done by the CertWarningPane is checking if the JNLPFile is null (which >> is a pretty fragile check - >> it's been changed to check the type of the CertVerifier instead), and >> if it is, then the button is >> not installed into the button panel. This decision is made well after >> the TemporaryPermissionsButton >> has been instantiated, which means that the Objects.requireNonNull >> checks have been performed. And >> the VariableX509TrustManager is still hard-coded to specifically >> provide "null" for the "file" and >> "securityDelegate" parameters... >> >>> >>> >>> Still I think it is good thing to get rid of assers and disable button. >> >> I think it's better to just not show the button (buttonS really, it's >> the Sandbox as well as >> Temporary Permissions) in this context, but it's an easy change to >> make either way. >> >>> >>> >>> J. >>> >>> >> >> Attached is my take on the patch. I also corrected the buttons on the >> dialog so that their labels >> and tooltips make more sense in the context of trusting an HTTPS >> certificate rather than an applet >> certificate. This looks a little messy with all the if statements >> added, but maybe it's not worth >> abstracting this class and making two subclasses just to change the >> labels on the buttons (and >> ignore two buttons from the button panel). Up to you. I can refactor >> it into two classes no problem >> but I know you expressed distaste for this approach on IRC ;) >> >> Thanks, >> > > > Ok for head, with only nit... > > > Please log in debug mode: > > + if (file == null || securityDelegate == null || linkedButton == > null) { > + this.setEnabled(false); > log here which are suddenly null. > + } else { > > > > Go on and push hten. > > J. Done. Wasn't there a bugzilla for this? I didn't find it to put the bug ID in the commit message or at least go comment on the report. Thanks, -- Andrew Azores From aazores at redhat.com Sat Sep 13 17:27:43 2014 From: aazores at redhat.com (Andrew Azores) Date: Sat, 13 Sep 2014 13:27:43 -0400 Subject: [rfc][icedtea-web] javaws.1 man page update In-Reply-To: <5412D9EB.9090204@redhat.com> References: <53F8D650.5090702@redhat.com> <5409EFFB.8030504@redhat.com> <540A4B81.4090306@gmx.de> <5412D9EB.9090204@redhat.com> Message-ID: <54147E8F.1090806@redhat.com> On 09/12/2014 07:32 AM, Jiri Vanek wrote: > On 09/06/2014 01:47 AM, Jacob Wisor wrote: >> On 09/05/2014 at 07:16 PM, Andrew Azores wrote: >>> On 08/23/2014 01:58 PM, Andrew Azores wrote: >>>> Hi, >>>> >>>> I looked at `man javaws` for some reason yesterday - no idea what I was >>>> looking for or why - and thought it could do with some minor >>>> improvement. I've fixed a few minor typos, improved the phrasing in a >>>> few areas, and made it more consistent with capitalizing acronyms such >>>> as XML, HTML, and JNLP. >>>> >>>> Thanks, >>> >>> Since the generated man pages feature is finally shaping up and looks >>> like it >>> might actually be done soon(ish), I suppose this patch is obsoleted? >> >> Not really. Actually, you should probably check the generated >> documentation output against the >> improvements you have made in your patch. AFAICT, most of the stuff in >> your patch is about >> punctuation and formatting. So, since you seem to have a keen eye on >> this you could check the >> generated documentation output. ;-) >> > Andrew, do you mind to watch the localization patch which I'm now sending? > > I think I have covered most of the issues you picked up, but I culd > overlook anything. > > > Also feel free to rework this patch for head once the localization > patches are done. > > > J. I have been watching the localization and generated documentation stuff... just not saying much about it all because I haven't had a lot of time to really give things proper review :) especially the actual generation code. Maybe for now while I'm getting settled in with school and figuring out when I can find time to keep contributing, I'll just stick with this documentation duty... Anyway I do think this has been taken care of now. It may still be worth backporting at least. Thanks, -- Andrew Azores From gitne at gmx.de Sat Sep 13 22:00:02 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sun, 14 Sep 2014 00:00:02 +0200 Subject: [rfc][icedtea-web][itweb-settings] Improve IcedTea-Web cache disk space In-Reply-To: <349509496.4004554.1410467155409.JavaMail.zimbra@redhat.com> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <52819644.29735325.1409767204437.JavaMail.zimbra@redhat.com> <540851A2.2080807@gmx.de> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> <5411BAAC.9050204@gmx.de> <349509496.4004554.1410467155409.JavaMail.zimbra@redhat.com> Message-ID: <5414BE62.5040804@gmx.de> On 09/11/2014 at 10:25 PM, Lukasz Dracz wrote: >>> diff -r af89bcaa02a2 -r e30d71ab91c6 netx/net/sourceforge/jnlp/resources >>> /Messages.properties >>> --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 10 >>> 09:45:10 2014 -0400 >>> +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 10 >>> 10:22:46 2014 -0400 >>> @@ -801,6 +801,10 @@ >>> TIFPDeleteFiles=Delete files >>> TIFPViewFiles=View files... >>> TIFPFileChooserChooseButton=Choose >>> +TIFPLimitCacheSize=Limit cache size >>> +TIFPCacheSizeSpinnerValueTooLargeWarning=WARNING: Uses more >>> space than {0} MB available Keep html tags here because they serve a reasonable purpose. >>> +TIFPCacheSizeSpinnerLargeValueWarning= Available: {0} MB >> >> Drop the html tags. They are not required here. Besides, HTML trims all >> leading >> and trailing white spaces, as well as replaces multiple white spaces between >> words with one SPACE (\u0020) character. This probably leads to undesired >> behavior here, if not now then maybe in the future. > > Okay. I am sorry, but we have run into a misunderstanding here. :-\ My comment was not meant to remove /all/ html tags. What I meant was that the html tags should be only removed from those messages which do not actually require HTML features. So, to be specific this time: TIFPCacheSizeSpinnerLargeValueWarning, TIFPCacheSizeSetToNoCaching, and TIFPCacheSizeSpinnerTooltip only. diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Wed Sep 10 10:22:46 2014 -0400 +++ b/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Thu Sep 11 16:15:11 2014 -0400 [...] @@ -402,10 +401,11 @@ cacheSizeWarningLabel.setEnabled(bool); if(bool == false) { + cacheSizeSpinner.setToolTipText(null); cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSpinnerLargeValueWarning", usableDiskSpace)); } else { - final long cacheSizeSpinnerValue = (long) cacheSizeSpinner.getValue(); + cacheSizeSpinner.setToolTipText(Translator.R("TIFPCacheSizeSpinnerTooltip", CACHE_MIN_SIZE, CACHE_MAX_SIZE)); final long cacheSizeSpinnerValue = (long) cacheSizeSpinner.getValue(); Please check formatting here. I assume that the declaration and initialization statement of "cacheSizeSpinnerValue" was intended to be on a line of its own, after the "cacheSizeSpinner.setToolTipText()" statement. After fixing this stuff, I think it is okay to push. :-) Jacob From gitne at gmx.de Sun Sep 14 00:10:39 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sun, 14 Sep 2014 02:10:39 +0200 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <5412F405.7050807@redhat.com> References: <5412F405.7050807@redhat.com> Message-ID: <5414DCFF.4000200@gmx.de> On 09/12/2014 at 03:24 PM, Jiri Vanek wrote: > Hi! > > Last of the set. yupii! > > Except localizing-able the plugin and settings man/plain/html it celans up > duplicated strings in NetworkSettingsPanel (and adding soem 7'th featueres) > > Tehre is also one change in makefile. I found that i dont like versioned subdirs > :( SoI created docs/version/normla dirs structure. Especially for man it is > rmeoving one unnecessary level and do work with it afaikmore comfortable > diff -r e30d71ab91c6 Makefile.am > --- a/Makefile.am Wed Sep 10 10:22:46 2014 -0400 > +++ b/Makefile.am Fri Sep 12 15:21:39 2014 +0200 > [...] > @@ -474,13 +474,13 @@ > endif > > stamps/generate-docs.stamp: stamps/netx.stamp > - mkdir $(DOCS_DIR) ; \ > - HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html-$(FULL_VERSION) ; \ > - PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain-$(FULL_VERSION) ; \ > - MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man-$(FULL_VERSION)/man ; \ > + mkdir -p $(DOCS_DIR) ; \ > + HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html ; \ > + PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain ; \ > + MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man/ ; \ Drop the trailing slash. > mkdir $$HTML_DOCS_TARGET_DIR ; \ > mkdir $$PLAIN_DOCS_TARGET_DIR ; \ > - mkdir -p $$MAN_DOCS_TARGET_DIR ; \ > + mkdir $$MAN_DOCS_TARGET_DIR ; \ Why did you remove the "-p" switch? It is probably best to have this switch almost always on in scripts to avoid running into errors just because of non-existing parent directories. > [...] > diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java > --- a/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java Wed Sep 10 10:22:46 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java Fri Sep 12 15:21:39 2014 +0200 > @@ -58,17 +58,17 @@ > @SuppressWarnings("serial") > public class NetworkSettingsPanel extends JPanel implements ActionListener { > > - private DeploymentConfiguration config; > + private final DeploymentConfiguration config; > > private JPanel description; > - private ArrayList proxyPanels = new ArrayList(); // The stuff with editable fields > + private final ArrayList proxyPanels = new ArrayList<>(); // The stuff with editable fields > > /** List of properties used by this panel */ > - public static String[] properties = { "deployment.proxy.type", > - "deployment.proxy.http.host", > - "deployment.proxy.http.port", > - "deployment.proxy.bypass.local", > - "deployment.proxy.auto.config.url", }; > + public static String[] properties = { DeploymentConfiguration.KEY_PROXY_TYPE, > + DeploymentConfiguration.KEY_PROXY_HTTP_HOST, > + DeploymentConfiguration.KEY_PROXY_HTTP_PORT, > + DeploymentConfiguration.KEY_PROXY_BYPASS_LOCAL, > + DeploymentConfiguration.KEY_PROXY_AUTO_CONFIG_URL, }; The formatting here should probably go here like this: public static String[] properties = { DeploymentConfiguration.KEY_PROXY_TYPE, DeploymentConfiguration.KEY_PROXY_HTTP_HOST, DeploymentConfiguration.KEY_PROXY_HTTP_PORT, DeploymentConfiguration.KEY_PROXY_BYPASS_LOCAL, DeploymentConfiguration.KEY_PROXY_AUTO_CONFIG_URL }; Please also mind the comma after the last element. > /** > * Creates a new instance of the network settings panel. > @@ -259,18 +259,23 @@ > */ > private void setState() { > ((CardLayout) this.description.getLayout()).show(this.description, config.getProperty(properties[0])); > - if (config.getProperty(properties[0]).equals("0")) { > - for (JPanel panel : proxyPanels) > - enablePanel(panel, false); > - } else if (config.getProperty(properties[0]).equals("1")) { > - enablePanel(proxyPanels.get(1), false); > - enablePanel(proxyPanels.get(0), true); > - } else if (config.getProperty(properties[0]).equals("2")) { > - enablePanel(proxyPanels.get(0), false); > - enablePanel(proxyPanels.get(1), true); > - } else if (config.getProperty(properties[0]).equals("3")) { > - for (JPanel panel : proxyPanels) > - enablePanel(panel, false); > + switch (config.getProperty(properties[0])) { > + case "0": > + for (JPanel panel : proxyPanels) > + enablePanel(panel, false); > + break; > + case "1": > + enablePanel(proxyPanels.get(1), false); > + enablePanel(proxyPanels.get(0), true); > + break; > + case "2": > + enablePanel(proxyPanels.get(0), false); > + enablePanel(proxyPanels.get(1), true); > + break; > + case "3": > + for (JPanel panel : proxyPanels) > + enablePanel(panel, false); > + break; > } > } Hmm, although I personally do not like the new switch control structure with regards to strings, it is much more readable this way. ;-) > [...] > diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/resources/Messages.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 10 10:22:46 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Fri Sep 12 15:21:39 2014 +0200 > @@ -876,6 +876,27 @@ > CBCheckSignedAppletDontMatchException = Signed applets are not allowed to run when their actual Codebase does not match the Codebase specified in their manifest. Expected: {0}. Actual: {1}. See: http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/no_redeploy.html for details. > CBCheckSignedFail = Application Codebase does NOT match the Codebase specified in the application's manifest, and this application is signed. You are strongly discouraged from running this application. See: http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/no_redeploy.html for details. > > +#itweb-settings man (note, spaces (especially the one around @@ markup)are important due to man pages markup > +ITWSintro= - view and modify settings for @BOLD_OPEN at javaws @BOLD_CLOSE at and the @BOLD_OPEN at browser plugin at BOLD_CLOSE@ What are those "@BOLD_OPEN@" and "@BOLD_CLOSE@" tags? Are they some sort of project specific markup language? If so, I am very unhappy with this. Where is the documentation for this? Does it handle @ escapes correctly? Is "... @BOLD_OPEN at javaws @BOLD_CLOSE at and ..." actually correct? > +ITWSsynops=command arguments > +IWSdescL1=is a command line and a GUI program to modify and edit settings used by the icedtea-web implementation \ > +of at BOLD_OPEN@ javaws @BOLD_CLOSE at and the @BOLD_OPEN at browser plugin at BOLD_CLOSE@. Why did you suddenly introduce broken lines or line continuing characters to Message.properties, since you have always been strictly against them? Is "... of at BOLD_OPEN@ javaws @BOLD_CLOSE at and ..." actually correct? > +IWSdescL2=If executed without any arguments, it starts up a GUI. Otherwise, it tries to do what is specified in the argument. > +IWSdescL3=The command-line allows quickly searching, making a copy of and modifying specific settings without having to hunt through a UI. > +IWSexampleL1=Show the GUI editor > +IWSexampleL2=Resets the value of `{0}` setting. Are the "`" characters literals in the man page or markups? > +ITWSdefault=default > +IWSexampleL3=Known properties > +IWSexampleL31=(key, value and default value (if different)): > +IWSexampleL32=(key and default value): > + > +#itweb-plugin man (note, spaces (especially the one around @@ markup)are important due to man pages markup > +ITWPintro=- allow to run @BOLD_OPEN at java applets @BOLD_CLOSE at in your favourite @BOLD_OPEN at browser@BOLD_CLOSE@ Check double spaces. Is "... run @BOLD_OPEN at java applets @BOLD_CLOSE at in ..." actually correct? > +ITWPsynopsL1=is working in your browser, once your browser knows about this files. > +ITWPsynopsL2=The {0} must be placed, or linked iniside specific direcotries. See {1} Spelling! > +ITWPsynopsL3=@BOLD_OPEN@ Mozzila compliant browsers @BOLD_CLOSE at like Firefox, Midori, Epiphany, Chrome or Chromium use: Spelling! The foundation's name is Mozilla! > +ITWPsynopsL4=@BOLD_OPEN@ Opera family browsers @BOLD_CLOSE at like Opera use: Please be careful when mentioning registered trademark and product names. If you mention them, you will probably need to include a statement on their legal status somewhere in the documentation for certain jurisdictions. Hence, it is best to avoid them. However, I am also aware that avoiding them completely is not always possible. Therefore, I strongly suggest to use the term "Mozilla compatible" only, wherever required. "NPAPI compatible" is also acceptable but far more technical and probably unknown to most users. "Mozilla compatible" covers all browsers currently supported by IcedTea-Web and avoids entanglements with too many entities. Because Mozilla is also the original author of the NPAPI, it describes the technical aspect sufficiently enough. And, although Mozilla is trademarked as well, the term would nevertheless reduce any legal risks to a minimum, especially given the Mozilla foundation's nature and history in free software. Of course, this does not relieve us of placing a legal notice in the documentation about Mozilla either, but reduces any efforts to just one entity. > [...] > diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java > --- a/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java Wed Sep 10 10:22:46 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java Fri Sep 12 15:21:39 2014 +0200 > @@ -38,6 +38,7 @@ > > import java.io.IOException; > import net.sourceforge.jnlp.config.PathsAndFiles; > +import net.sourceforge.jnlp.runtime.Translator; > import net.sourceforge.jnlp.util.docprovider.formatters.formatters.Formatter; Generally speaking, I am really having trouble accepting this kind of custom formatter to IcedTea-Web. Actually, this goes for any project which is not specifically concerned with parsing a well specified language. Unfortunately, most developers greatly underestimate the prerequisites for a properly working formatter. The probability of not getting it right is far greater than one would initially assume. This starts with checking inputs and outputs, goes over properly handling encoded strings, and ends on handling escapes properly. The amount of testing required to get /and/ keep a formatter correct is just enormous. Then, it has to be documented and everybody who wants to add documentation on a new feature that he/she has just implemented is required to (a) know how the documentation generator works and (b) understand its formatting. So ultimately, we should get rid of this formatter and any @TAG@ tags. If you really need formatting tags for man pages then the documentation generator should be able to include them itself automatically. Otherwise, adding documentation becomes unnecessarily difficult and overly complex. It's a pity that you rushed to push the documentation generator... Jacob From gitne at gmx.de Sun Sep 14 04:17:57 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sun, 14 Sep 2014 06:17:57 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <54101CEB.1040104@redhat.com> References: <54071FE9.2000309@redhat.com> <54101CEB.1040104@redhat.com> Message-ID: <541516F5.3020504@gmx.de> On 09/10/2014 at 11:42 AM, Jiri Vanek wrote: > ping? Unfortunately, because tip has change in the meantime in regards to this patch I could not actually do runtime tests. However, I have commented on the code. Please, can you post a patch based on the current tip? > -------- Original Message -------- > Subject: Re: [rfc][icedtea-web] https probing > Date: Wed, 03 Sep 2014 16:04:25 +0200 > From: Jiri Vanek > To: Jacob Wisor , distro-pkg-dev at openjdk.java.net > > On 08/26/2014 09:51 AM, Jacob Wisor wrote: >> On 08/26/2014 09:16 AM, Jiri Vanek wrote: >>> ping? >>> >>> On 08/20/2014 08:30 PM, Jiri Vanek wrote: >>>> On 08/19/2014 11:25 PM, Jacob Wisor wrote: >>>>> On 08/18/2014 08:46 PM, Omair Majid wrote: >>>>>> Hi, >>>>>> >>>>>> >>>>>> * Jacob Wisor [2014-08-11 12:12]: >>>>>>> On 08/08/2014 10:37 AM, Jiri Vanek wrote: >>>>>>>> Unluckily this fix patch is not helping obscure servers to do exists. >>>>>>>> It really fixes bugs. >>>>>>>> >>>>>>>> First part of fix is delivered to be able handle SSLv2 handshake, Those >>>>>>>> servers >>>>>>>> do exists, and have no reason nor need to update or patch or whatever. >>>>>>>> We are >>>>>>>> wrong by not allowing it right now. >>>>>>>> See System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); in code. >>>>>>> >>>>>>> Oh yes they do need fixing. SSLv2 is insecure and has been revoked by the >>>>>>> IETF, period. Nobody should be using it. Even SSL 3.0 is deemed by the IETF >>>>>>> as historic (https://datatracker.ietf.org/doc/rfc6101) although it is >>>>>>> largely identical to TLS 1.0. Nevertheless, nobody should be using it >>>>>>> either. Just one of many reasons is that it does not even support such a >>>>>>> common hash algorithm as SHA1 (which by the way has been deprecated by NIST >>>>>>> in favor of SHA256 too). Everybody should really upgrade to at least TLS >>>>>>> 1.0, even though possible security leaks have been discovered in TLS 1.0 on >>>>>>> specific configuration settings permutations. >>>>>>> >>>>>>> DO NOT use SSL anymore and DO NOT promote them in your software. Upgrade to >>>>>>> TLS. >>>>>> >>>>>> This isn't SSv2, though. It's a SSLv2 hello packet wrapping an SSLv3 >>>>>> packet: http://bugs.java.com/bugdatabase/view_bug.do?bug_id=4915862 >>>>>> >>>>>> It's actually part of the TLS 1.0 spec: >>>>>> https://www.ietf.org/rfc/rfc2246.txt, Appendix E. >>>>> >>>>> This part describes backward compatibility of TLS 1.0 clients to SSL 3.0 and >>>>> SSL 2.0 servers (and >>>>> vice versa). >>>>> >>>>> "TLS 1.0 clients that support SSL Version 2.0 servers must send SSL >>>>> Version 2.0 client hello messages [SSL2]. TLS servers should accept >>>>> either client hello format if they wish to support SSL 2.0 clients on >>>>> the same connection port. The only deviations from the Version 2.0 >>>>> specification are the ability to specify a version with a value of >>>>> three and the support for more ciphering types in the CipherSpec." >>>>> >>>>> Currently, IcedTea-Web is a TLS 1.0 or SSL 3.0 client. According to this >>>>> paragraph, TLS 1.0 clients >>>>> send SSL 2.0 client hello messages in order to connect to SSL 2.0 servers, >>>>> that is, to negotiate a >>>>> SSL 2.0 connection. So no, SSL 2.0 servers do not upgrade automagically to >>>>> TLS 1.0 when they receive >>>>> SSL 2.0 client hello messages from TLS 1.0 clients. Pure old SSL 2.0 servers >>>>> will never speak >>>>> anything later than SSL 2.0. >>>>> >>>>> One reason behind this paragraph was for TLS 1.0 clients to allow probing SSL >>>>> 2.0 servers with >>>>> cipher specifications in SSL 2.0 and those introduced in TLS 1.0. In >>>>> practice, SSL 2.0 servers will >>>>> _never_ negotiate to a cipher specification introduced since TLS 1.0 because >>>>> they were simply not >>>>> built for that. >>>>> >>>>> Another reason for this paragraph back in 1999 (!) was to allow implementors >>>>> of TLS 1.0 to ease >>>>> transition from SSL to TLS and to give them the option to merge TLS into >>>>> their existing SSL >>>>> libraries (or as much as possible build on top of them). Again, this has >>>>> nothing to do with >>>>> automagically upgrading SSL 2.0 servers to TLS. It is just a description of >>>>> how TLS 1.0 clients >>>>> could fallback to SSL 2.0, if they wish to. >>>>> And, I am most certain nobody should want this, unless one has no clue what >>>>> transport security is >>>>> all about or is a complete lunatic. >>>>> >>>>> The next paragraph says it all: >>>>> >>>>> " Warning: The ability to send Version 2.0 client hello messages will be >>>>> phased out with all due haste. Implementors should make every >>>>> effort to move forward as quickly as possible. Version 3.0 >>>>> provides better mechanisms for moving to newer versions." >>>>> >>>>> So, the Java API should have got rid of the option to fallback to SSL 2.0 >>>>> years before. It's a shame >>>>> that J2SE still supports SSL 2.0 connections in 2014. Why? Because this has >>>>> nothing to do with >>>>> compatibility but with *security*. >>>>> >>>> >>>> Ok. Thank you for patience with me. (really!) >>>> >>>> So there is another approach. >>>> >>>> Now the ssl2 is tested as last attempt, and if it is possible to connect like >>>> that, then the user is >>>> warned and error is thrown (which leads to skipping resource from that >>>> >>>> >>>> The not-checking certificate now can be allowed or forbidden by properties. By >>>> default it asks user >>>> by every such invalid certs its found. How to deal with human intraction is >>>> todo. This property needs to bo documented, especially for administrators. Does IcedTea-Web ask for /every/ invalid or unverifiable certificate in the certificate chain or just the first highest one in the chain? I am asking because the verification process can actually stop and assume the users answer or the property setting for all certificates beneath the first highest invalid or unverifiable certificate in the chain. >>>> The reason for this message is to get verbose logical error emsssage, not only >>>> "itw do not work again" I understand. It's always nice to have sane and useful error messages. :-) > diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/cache/CacheUtil.java > --- a/netx/net/sourceforge/jnlp/cache/CacheUtil.java Wed Sep 03 14:45:40 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/cache/CacheUtil.java Wed Sep 03 16:02:36 2014 +0200 > [...] > @@ -99,11 +99,9 @@ > } else { > try { > // this is what URLClassLoader does > - URLConnection conn = location.openConnection(); > + URLConnection conn = ConnectionFactory.getConnectionFactory().openConnection(location); Please make "conn" final. > result = conn.getPermission(); > - if (conn instanceof HttpURLConnection) { > - ((HttpURLConnection) conn).disconnect(); > - } > + ConnectionFactory.getConnectionFactory().disconnect(conn); Formatting. > [...] > diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/cache/ResourceTracker.java > --- a/netx/net/sourceforge/jnlp/cache/ResourceTracker.java Wed Sep 03 14:45:40 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/cache/ResourceTracker.java Wed Sep 03 16:02:36 2014 +0200 > @@ -56,6 +56,7 @@ > import net.sourceforge.jnlp.event.DownloadEvent; > import net.sourceforge.jnlp.event.DownloadListener; > import net.sourceforge.jnlp.runtime.JNLPRuntime; > +import net.sourceforge.jnlp.security.ConnectionFactory; > import net.sourceforge.jnlp.util.HttpUtils; > import net.sourceforge.jnlp.util.UrlUtils; > import net.sourceforge.jnlp.util.WeakList; > @@ -641,7 +642,7 @@ > try { > // create out second in case in does not exist > URL realLocation = resource.getDownloadLocation(); "realLocation" can be final here too. > - con = realLocation.openConnection(); > + con = ConnectionFactory.getConnectionFactory().openConnection(realLocation); > con.addRequestProperty("Accept-Encoding", "pack200-gzip, gzip"); > > con.connect(); > @@ -698,8 +699,7 @@ > out.close(); > > // explicitly close the URLConnection. > - if (con instanceof HttpURLConnection) > - ((HttpURLConnection) con).disconnect(); > + ConnectionFactory.getConnectionFactory().disconnect(con); Is it safe to assume that "con" will never be null or ConnectionFactory.disconnect() will accept null? > if (packgz || gzip) { > // TODO why not set this otherwise? > @@ -811,7 +811,7 @@ > } > > resource.setDownloadLocation(finalLocation); > - connection = finalLocation.openConnection(); // this won't change so should be okay unsynchronized > + connection = ConnectionFactory.getConnectionFactory().openConnection(finalLocation); // this won't change so should be okay not-synchronized > connection.addRequestProperty("Accept-Encoding", "pack200-gzip, gzip"); > > size = connection.getContentLength(); > @@ -855,9 +855,7 @@ > resource.fireDownloadEvent(); // fire CONNECTED > > // explicitly close the URLConnection. > - if (connection instanceof HttpURLConnection) { > - ((HttpURLConnection) connection).disconnect(); > - } > + ConnectionFactory.getConnectionFactory().disconnect(connection); > } catch (Exception ex) { > OutputController.getLogger().log(ex); > resource.changeStatus(EnumSet.noneOf(Resource.Status.class), EnumSet.of(ERROR)); > @@ -915,7 +913,7 @@ > */ > static CodeWithRedirect getUrlResponseCodeWithRedirectonResult(URL url, Map requestProperties, RequestMethods requestMethod) throws IOException { > CodeWithRedirect result = new CodeWithRedirect(); > - URLConnection connection = url.openConnection(); > + URLConnection connection = ConnectionFactory.getConnectionFactory().openConnection(url); "connection" should probably be final here too. > for (Map.Entry property : requestProperties.entrySet()) { > connection.addRequestProperty(property.getKey(), property.getValue()); > @@ -946,9 +944,7 @@ > if (possibleRedirect != null && possibleRedirect.trim().length() > 0) { > result.URL = new URL(possibleRedirect); > } > - if (connection instanceof HttpURLConnection) { > - ((HttpURLConnection) connection).disconnect(); > - } > + ConnectionFactory.getConnectionFactory().disconnect(connection); > > return result; > > diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/config/Defaults.java > --- a/netx/net/sourceforge/jnlp/config/Defaults.java Wed Sep 03 14:45:40 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/config/Defaults.java Wed Sep 03 16:02:36 2014 +0200 > @@ -46,6 +46,7 @@ > > import net.sourceforge.jnlp.ShortcutDesc; > import net.sourceforge.jnlp.runtime.JNLPProxySelector; > +import net.sourceforge.jnlp.security.ConnectionFactory; > > /** > * This class stores the default configuration > @@ -434,6 +435,27 @@ > DeploymentConfiguration.KEY_ENABLE_MANIFEST_ATTRIBUTES_CHECK, > BasicValueValidators.getBooleanValidator(), > String.valueOf(true) > + }, > + //https > + { > + DeploymentConfiguration.KEY_HTTPS_PROBINGALLOWED, > + BasicValueValidators.getBooleanValidator(), > + String.valueOf(true) > + }, > + { > + DeploymentConfiguration.KEY_HTTPS_SYNCFORCED, > + BasicValueValidators.getBooleanValidator(), > + String.valueOf(false) > + }, > + { > + DeploymentConfiguration.KEY_HTTPS_PROBEALWAYS, > + BasicValueValidators.getBooleanValidator(), > + String.valueOf(false) > + }, > + { > + DeploymentConfiguration.KEY_HTTPS_ALLOWINSECURE, > + ConnectionFactory.InsecureStates.validator, > + ConnectionFactory.InsecureStates.ASK.toString() > } > }; > > diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java > --- a/netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java Wed Sep 03 14:45:40 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java Wed Sep 03 16:02:36 2014 +0200 > @@ -13,7 +13,6 @@ > // You should have received a copy of the GNU Lesser General Public > // License along with this library; if not, write to the Free Software > // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. > - > package net.sourceforge.jnlp.config; > > import static net.sourceforge.jnlp.runtime.Translator.R; > @@ -66,28 +65,32 @@ > public static final int JNLP_ASSOCIATION_REPLACE_ASK = 3; > > /** > - * when set to as value of KEY_CONSOLE_STARTUP_MODE = "deployment.console.startup.mode", > - * then console is not visible by default, but may be shown > + * when set to as value of KEY_CONSOLE_STARTUP_MODE = > + * "deployment.console.startup.mode", then console is not visible by > + * default, but may be shown > */ > public static final String CONSOLE_HIDE = "HIDE"; > /** > - * when set to as value of KEY_CONSOLE_STARTUP_MODE = "deployment.console.startup.mode", > - * then console show for both javaws and plugin > + * when set to as value of KEY_CONSOLE_STARTUP_MODE = > + * "deployment.console.startup.mode", then console show for both javaws and > + * plugin > */ > public static final String CONSOLE_SHOW = "SHOW"; > /** > - * when set to as value of KEY_CONSOLE_STARTUP_MODE = "deployment.console.startup.mode", > - * then console is not visible by default, nop data are passed to it (save memory and cpu) but can not be shown > + * when set to as value of KEY_CONSOLE_STARTUP_MODE = > + * "deployment.console.startup.mode", then console is not visible by > + * default, no data are passed to it (save memory and cpu) but can not be > + * shown > */ > public static final String CONSOLE_DISABLE = "DISABLE"; > /** > - * when set to as value of KEY_CONSOLE_STARTUP_MODE = "deployment.console.startup.mode", > - * then console show for plugin > + * when set to as value of KEY_CONSOLE_STARTUP_MODE = > + * "deployment.console.startup.mode", then console show for plugin > */ > public static final String CONSOLE_SHOW_PLUGIN = "SHOW_PLUGIN_ONLY"; > /** > - * when set to as value of KEY_CONSOLE_STARTUP_MODE = "deployment.console.startup.mode", > - * then console show for javaws > + * when set to as value of KEY_CONSOLE_STARTUP_MODE = > + * "deployment.console.startup.mode", then console show for javaws > */ > public static final String CONSOLE_SHOW_JAVAWS = "SHOW_JAVAWS_ONLY"; > > @@ -96,7 +99,9 @@ > public static final String KEY_SYSTEM_CACHE_DIR = "deployment.system.cachedir"; > public static final String KEY_USER_LOG_DIR = "deployment.user.logdir"; > public static final String KEY_USER_TMP_DIR = "deployment.user.tmp"; > - /** the directory containing locks for single instance applications */ > + /** > + * the directory containing locks for single instance applications > + */ It is good of you to fix javadoc comments, but then please do it thoroughly. Please turn this comment into a complete sentence. ;-) > public static final String KEY_USER_LOCKS_DIR = "deployment.user.locksdir"; > /** > * The netx_running file is used to indicate if any instances of netx are > @@ -124,8 +129,9 @@ > /* > * Security and access control > */ > - > - /** Boolean. Only show security prompts to user if true */ > + /** > + * Boolean. Only show security prompts to user if true > + */ Same goes here about javadoc. "Boolean." is certainly not a good brief description of "KEY_SECURITY_PROMPT_USER". Please keep in mind that javadoc assumes all text up to the first dot to be a brief description. > public static final String KEY_SECURITY_PROMPT_USER = "deployment.security.askgrantdialog.show"; > > //enum of AppletSecurityLevel in result > @@ -133,23 +139,35 @@ > > public static final String KEY_SECURITY_TRUSTED_POLICY = "deployment.security.trusted.policy"; > > - /** Boolean. Only give AWTPermission("showWindowWithoutWarningBanner") if true */ > + /** > + * Boolean. Only give AWTPermission("showWindowWithoutWarningBanner") if > + * true > + */ Javadoc, see above. > public static final String KEY_SECURITY_ALLOW_HIDE_WINDOW_WARNING = "deployment.security.sandbox.awtwarningwindow"; > > - /** Boolean. Only prompt user for granting any JNLP permissions if true */ > + /** > + * Boolean. Only prompt user for granting any JNLP permissions if true > + */ Javadoc, see above. > public static final String KEY_SECURITY_PROMPT_USER_FOR_JNLP = "deployment.security.sandbox.jnlp.enhanced"; > > - /** Boolean. Only install the custom authenticator if true */ > + /** > + * Boolean. Only install the custom authenticator if true > + */ Javadoc, see above. > public static final String KEY_SECURITY_INSTALL_AUTHENTICATOR = "deployment.security.authenticator"; > > /* > * Networking > */ > - > - /** the proxy type. possible values are {@code JNLPProxySelector.PROXY_TYPE_*} */ > + /** > + * the proxy type. possible values are > + * {@code JNLPProxySelector.PROXY_TYPE_*} > + */ > public static final String KEY_PROXY_TYPE = "deployment.proxy.type"; > > - /** Boolean. If true, the http host/port should be used for https and ftp as well */ > + /** > + * Boolean. If true, the http host/port should be used for https and ftp as > + * well > + */ Javadoc, see above. > public static final String KEY_PROXY_SAME = "deployment.proxy.same"; > > public static final String KEY_PROXY_AUTO_CONFIG_URL = "deployment.proxy.auto.config.url"; > @@ -173,30 +191,23 @@ > public static final String KEY_ENABLE_LOGGING_TOFILE = "deployment.log.file"; > public static final String KEY_ENABLE_LOGGING_TOSTREAMS = "deployment.log.stdstreams"; > public static final String KEY_ENABLE_LOGGING_TOSYSTEMLOG = "deployment.log.system"; > - > + > /* > * manifest check > */ > public static final String KEY_ENABLE_MANIFEST_ATTRIBUTES_CHECK = "deployment.manifest.attributes.check"; > > /** > - * Console initial status. > - * One of CONSOLE_* values > - * See declaration above: > - * CONSOLE_HIDE = "HIDE"; > - * CONSOLE_SHOW = "SHOW"; > - * CONSOLE_DISABLE = "DISABLE"; > - * CONSOLE_SHOW_PLUGIN = "SHOW_PLUGIN_ONLY"; > - * CONSOLE_SHOW_JAVAWS = "SHOW_JAVAWS_ONLY"; > + * Console initial status. One of CONSOLE_* values See declaration above: > + * CONSOLE_HIDE = "HIDE"; CONSOLE_SHOW = "SHOW"; CONSOLE_DISABLE = > + * "DISABLE"; CONSOLE_SHOW_PLUGIN = "SHOW_PLUGIN_ONLY"; CONSOLE_SHOW_JAVAWS > + * = "SHOW_JAVAWS_ONLY"; > */ You should be probably using {@link} doc tags here. > public static final String KEY_CONSOLE_STARTUP_MODE = "deployment.console.startup.mode"; > - > - > > /* > * Desktop Integration > */ > - > public static final String KEY_JNLP_ASSOCIATIONS = "deployment.javaws.associations"; > public static final String KEY_CREATE_DESKTOP_SHORTCUT = "deployment.javaws.shortcut"; > > @@ -209,8 +220,17 @@ > /* > * JVM arguments for plugin > */ > - public static final String KEY_PLUGIN_JVM_ARGUMENTS= "deployment.plugin.jvm.arguments"; > - public static final String KEY_JRE_DIR= "deployment.jre.dir"; > + public static final String KEY_PLUGIN_JVM_ARGUMENTS = "deployment.plugin.jvm.arguments"; > + public static final String KEY_JRE_DIR = "deployment.jre.dir"; > + > + /* > + * https settings > + */ > + public static final String KEY_HTTPS_PROBINGALLOWED = "deployment.security.https.probing.allowed"; > + public static final String KEY_HTTPS_SYNCFORCED = "deployment.security.https.syncforced"; > + public static final String KEY_HTTPS_PROBEALWAYS = "deployment.security.https.probing.always"; > + public static final String KEY_HTTPS_ALLOWINSECURE = "deployment.security.https.allowinsecure"; > + > private ConfigurationException loadingException = null; > > public void setLoadingException(ConfigurationException ex) { > @@ -224,27 +244,37 @@ > public void resetToDefaults() { > currentConfiguration = Defaults.getDefaults(); > } > - > > public enum ConfigType { > + > System, User > } > > - /** is it mandatory to load the system properties? */ > + /** > + * is it mandatory to load the system properties? > + */ > private boolean systemPropertiesMandatory = false; > > - /** The system's subdirResult deployment.config file */ > + /** > + * The system's subdirResult deployment.config file > + */ "deployment.config" should probably be put into a {@code} doc tag to prevent terminating the brief description on "deployment.". > private File systemPropertiesFile = null; > - /** The user's subdirResult deployment.config file */ > + /** > + * The user's subdirResult deployment.config file > + */ Same goes here for "deployment.config". > private File userPropertiesFile = null; > - > + > /*default user file*/ > public static final File USER_DEPLOYMENT_PROPERTIES_FILE = new File(Defaults.USER_CONFIG_HOME + File.separator + DEPLOYMENT_PROPERTIES); > > - /** the current deployment properties */ > + /** > + * the current deployment properties > + */ > private Map> currentConfiguration; > > - /** the deployment properties that cannot be changed */ > + /** > + * the deployment properties that cannot be changed > + */ > private Map> unchangeableConfiguration; > > public DeploymentConfiguration() { > @@ -254,7 +284,8 @@ > > /** > * Initialize this deployment configuration by reading configuration files. > - * Generally, it will try to continue and ignore errors it finds (such as file not found). > + * Generally, it will try to continue and ignore errors it finds (such as > + * file not found). > * > * @throws ConfigurationException if it encounters a fatal error. > */ > @@ -266,18 +297,19 @@ > return new File(Defaults.USER_CONFIG_HOME + File.separator + APPLET_TRUST_SETTINGS); > } > > - public static File getAppletTrustGlobalSettingsPath() { > - return new File(File.separator + "etc" + File.separator + ".java" + File.separator > + public static File getAppletTrustGlobalSettingsPath() { > + return new File(File.separator + "etc" + File.separator + ".java" + File.separator > + "deployment" + File.separator + APPLET_TRUST_SETTINGS); This is definitely not okay on Windows and probably not okay on Mac OS either but it seems acceptable for now. > - > + > } > > /** > * Initialize this deployment configuration by reading configuration files. > - * Generally, it will try to continue and ignore errors it finds (such as file not found). > + * Generally, it will try to continue and ignore errors it finds (such as > + * file not found). > * > - * @param fixIssues If true, fix issues that are discovered when reading configuration by > - * resorting to the default values > + * @param fixIssues If true, fix issues that are discovered when reading > + * configuration by resorting to the default values > * @throws ConfigurationException if it encounters a fatal error. > */ > public void load(boolean fixIssues) throws ConfigurationException { > @@ -303,7 +335,6 @@ > * First, try to read the system's subdirResult deployment.config file to find if > * there is a system-level deployment.poperties file > */ > - > if (systemConfigFile != null) { > if (loadSystemConfiguration(systemConfigFile)) { > OutputController.getLogger().log("System level " + DEPLOYMENT_CONFIG_FILE + " is mandatory: " + systemPropertiesMandatory); > @@ -431,9 +462,9 @@ > > /** > * Check that the configuration is valid. If there are invalid values,set > - * those values to the default values. This is done by using check() > - * method of the ValueCheker for each setting on the actual value. Fixes > - * are made in-place. > + * those values to the default values. This is done by using check() method > + * of the ValueCheker for each setting on the actual value. Fixes are made > + * in-place. > * > * @param initial a map representing the initial configuration > */ > @@ -465,7 +496,8 @@ > } > > /** > - * @return the location of system-level deployment.config file, or null if none can be found > + * @return the location of system-level deployment.config file, or null if > + * none can be found > */ > private File findSystemConfigFile() { > File etcFile = new File(File.separator + "etc" + File.separator + ".java" + File.separator > @@ -525,7 +557,7 @@ > try { > Setting urlSettings = systemConfiguration.get("deployment.system.config"); > if (urlSettings == null || urlSettings.getValue() == null) { > - OutputController.getLogger().log("No System level " + DEPLOYMENT_PROPERTIES + " found in "+configFile.getAbsolutePath()); > + OutputController.getLogger().log("No System level " + DEPLOYMENT_PROPERTIES + " found in " + configFile.getAbsolutePath()); > return false; > } > urlString = urlSettings.getValue(); > @@ -542,9 +574,9 @@ > return false; > } > } catch (MalformedURLException e) { > - OutputController.getLogger().log("Invalid url for " + DEPLOYMENT_PROPERTIES+ ": " + urlString + "in " + configFile.getAbsolutePath()); > + OutputController.getLogger().log("Invalid url for " + DEPLOYMENT_PROPERTIES + ": " + urlString + "in " + configFile.getAbsolutePath()); > OutputController.getLogger().log(e); > - if (systemPropertiesMandatory){ > + if (systemPropertiesMandatory) { > ConfigurationException ce = new ConfigurationException("Invalid url to system properties, which are mandatory"); > ce.initCause(e); > throw ce; > @@ -561,7 +593,8 @@ > * @param file the File to load Properties from > * @param mandatory indicates if reading this file is mandatory > * > - * @throws ConfigurationException if the file is mandatory but cannot be read > + * @throws ConfigurationException if the file is mandatory but cannot be > + * read > */ > private Map> loadProperties(ConfigType type, File file, boolean mandatory) > throws ConfigurationException { > @@ -578,7 +611,7 @@ > try { > return parsePropertiesFile(file); > } catch (IOException e) { > - if (mandatory){ > + if (mandatory) { > ConfigurationException ce = new ConfigurationException("Exception during loading of " + file + " which is mandatory to read"); > ce.initCause(e); > throw ce; > @@ -793,7 +826,6 @@ > String currentPropertiesOld = Defaults.USER_CONFIG_HOME + File.separator + DEPLOYMENT_PROPERTIES + ".old"; > errors += moveLegacyToCurrent(legacyPropertiesOld, currentPropertiesOld); > > - > String legacyAppletTrust = LEGACY_USER_HOME + File.separator + APPLET_TRUST_SETTINGS; > String currentAppletTrust = getAppletTrustUserSettingsPath().getAbsolutePath(); > errors += moveLegacyToCurrent(legacyAppletTrust, currentAppletTrust); > diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/runtime/CachedJarFileCallback.java > --- a/netx/net/sourceforge/jnlp/runtime/CachedJarFileCallback.java Wed Sep 03 14:45:40 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/runtime/CachedJarFileCallback.java Wed Sep 03 16:02:36 2014 +0200 > @@ -43,7 +43,6 @@ > import java.io.IOException; > import java.io.InputStream; > import java.io.OutputStream; > -import java.net.HttpURLConnection; > import java.net.URL; > import java.net.URLConnection; > import java.security.AccessController; > @@ -51,6 +50,7 @@ > import java.security.PrivilegedExceptionAction; > import java.util.Map; > import java.util.concurrent.ConcurrentHashMap; > +import net.sourceforge.jnlp.security.ConnectionFactory; > import net.sourceforge.jnlp.util.logging.OutputController; > import net.sourceforge.jnlp.util.JarFile; > > @@ -128,7 +128,7 @@ > java.util.jar.JarFile result = null; > > final int BUF_SIZE = 2048; > - URLConnection conn = url.openConnection(); > + URLConnection conn = ConnectionFactory.getConnectionFactory().openConnection(url); > /* get the stream before asserting privileges */ > final InputStream in = conn.getInputStream(); > > @@ -169,9 +169,7 @@ > } catch (PrivilegedActionException pae) { > throw (IOException) pae.getException(); > } finally{ > - if (conn instanceof HttpURLConnection) { > - ((HttpURLConnection) conn).disconnect(); > - } > + ConnectionFactory.getConnectionFactory().disconnect(conn); > } > > return result; > diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/security/ConnectionFactory.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/security/ConnectionFactory.java Wed Sep 03 16:02:36 2014 +0200 > @@ -0,0 +1,334 @@ > +/* > + * Copyright (C) 2014 Red Hat, Inc. > + * This file is part of IcedTea. > + * cedTea is free software; you can redistribute it and/or... > + */ > +package net.sourceforge.jnlp.security; > + > +import java.io.IOException; > +import java.net.HttpURLConnection; > +import java.net.URL; > +import java.net.URLConnection; > +import java.security.KeyManagementException; > +import java.security.NoSuchAlgorithmException; > +import java.security.SecureRandom; > +import java.security.cert.CertificateException; > +import java.security.cert.X509Certificate; > +import java.util.ArrayList; > +import java.util.List; > +import javax.net.ssl.HostnameVerifier; > +import javax.net.ssl.HttpsURLConnection; > +import javax.net.ssl.KeyManager; > +import javax.net.ssl.SSLContext; > +import javax.net.ssl.SSLSession; > +import javax.net.ssl.TrustManager; > +import javax.net.ssl.X509TrustManager; > +import net.sourceforge.jnlp.config.DeploymentConfiguration; > +import net.sourceforge.jnlp.config.ValueValidator; > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > +import net.sourceforge.jnlp.util.logging.OutputController; > + > +/** > + * > + * @author jvanek Please replace with full name and e-mail address. > + */ > +public class ConnectionFactory { Do we really want to allow sub-classes? > + > + public static enum InsecureStates { Naming: What are insecure states? ... axis of evil ...? :-D > + > + TRUE, FALSE, ASK; Are "TRUE", "FALSE", and "ASK" really insecure? What makes them insecure? > + > + public static final ValueValidator validator = new ValueValidator() { Shouldn't this custom validator extend BasicValidator? > + > + @Override > + public void validate(Object value) throws IllegalArgumentException { Please make "value" final. > + if (value instanceof InsecureStates) { It's a pity ValueValidator cannot be parametrized. :-( This is a perfect example for making use of generics. But, lets keep it as it is for now. > + return; > + } > + if (value instanceof String) { > + try { > + fromString((String) value); > + } catch (RuntimeException ex) { > + throw new IllegalArgumentException(ex); > + } > + } > + throw new IllegalArgumentException("Expected InsecureStates type or string of one of " + getPossibleValues()); Get this InsecureStates' name via reflection for the exception message instead of hard coding it into the string: InsecureStates.class.getName(). This will lead to a compile time error whenever the enum's name changes (for what ever reason), so the enum won't escape renaming in the string. Besides, this exception message should probably be localized. > + } > + > + @Override > + public String getPossibleValues() { > + return TRUE.toString() + " " + FALSE.toString() + " " + ASK.toString(); > + } > + }; Besides, the validator's definition should not be located at ConnectionFactory.InsecureStates.validator's initialization. Put its implementation into a named nested class instead of an anonymous one. > + > + public static InsecureStates fromString(String s) { Please make "s" final. And what about NPE? Should a NPE just break the program while incorrectly formatted strings just throw a RuntimeException? Seems to me like an arbitrary decision. > + if (s.trim().equalsIgnoreCase("true")) { > + return TRUE; > + } > + if (s.trim().equalsIgnoreCase("false")) { > + return FALSE; > + } > + if (s.trim().equalsIgnoreCase("ask")) { > + return ASK; > + } You know, you could use the new switch control statement here. ;-) > + throw new RuntimeException("unknown value of " + s + " for " + DeploymentConfiguration.KEY_HTTPS_ALLOWINSECURE); This exception message should probably be localized too. > + } > + > + } > + private final List httpsConnections = new ArrayList<>(); > + > + private static class ConnectionFactoryHolder { > + > + //https://en.wikipedia.org/wiki/Double-checked_locking#Usage_in_Java > + //https://en.wikipedia.org/wiki/Initialization_on_demand_holder_idiom > + private static volatile ConnectionFactory INSTANCE = new ConnectionFactory(); > + } > + > + public static boolean isProbingAllowed() { > + return getBooleanProperty(DeploymentConfiguration.KEY_HTTPS_PROBINGALLOWED); > + } > + > + public static boolean isSyncForced() { > + return !getBooleanProperty(DeploymentConfiguration.KEY_HTTPS_SYNCFORCED); Why negate the result here? > + } > + > + public static boolean isProbeAlways() { > + return getBooleanProperty(DeploymentConfiguration.KEY_HTTPS_PROBEALWAYS); > + } > + > + public static InsecureStates getInsecureStatus() { > + return InsecureStates.fromString(JNLPRuntime.getConfiguration().getProperty(DeploymentConfiguration.KEY_HTTPS_ALLOWINSECURE)); > + } > + > + public static boolean isInsecurePossible() { Do you see now why I insist on meaingful naming? What does it mean when "insecure is possible" (isInsecurePossible() == true)? Insecure certificates, insecure connections? Does this method detect whether insecure connections are possible to hosts? What does it mean? > + InsecureStates i = getInsecureStatus(); > + if (i.equals(InsecureStates.TRUE) || i.equals(InsecureStates.ASK)) { > + return true; > + } > + return false; > + } > + > + public static boolean getBooleanProperty(String s) { > + String s3 = JNLPRuntime.getConfiguration().getProperty(s); What does "s3" mean? Anyway, please make it final. > + if (s3 == null || s3.trim().isEmpty()) { > + return false; > + } else { No need for "else:. ;-) > + return Boolean.valueOf(s3); > + } > + > + } > + > + public static ConnectionFactory getConnectionFactory() { > + return ConnectionFactoryHolder.INSTANCE; > + } > + > + public URLConnection openConnection(URL url) throws IOException { > + OutputController.getLogger().log("Connecting " + url.toExternalForm()); "Connecting *to* ..." > + if (url.getProtocol().equalsIgnoreCase("https") && isProbingAllowed()) { > + if (isSyncForced()) { > + while (!httpsConnections.isEmpty()) { > + try { > + Thread.sleep(100); > + } catch (InterruptedException ex) { > + throw new IOException(ex); > + } > + } Polling? Really? Is this really the proper way to do it? And, do we really need to offer synchronious connections? Besides, what about infinite looping? > + } > + return openHttpsConnection(url); > + } else { > + OutputController.getLogger().log("done " + url.toExternalForm()); > + return url.openConnection(); > + } > + } > + > + private synchronized URLConnection openHttpsConnection(URL url) throws IOException { > + URLConnection conn = null; > + //yes,by default we assume that once initialized https settings are valid for all resources > + //note the combination of async and try every time have no sense (it *may* change the opened connections => error > + OutputController.getLogger().log("Probing " + url.toExternalForm()); > + if (HttpsSettings.getHttpsSettings() == null || isProbeAlways()) { > + HttpsProbeResult pr = HttpsSettings.initHttpsSettings(url); > + if (pr.settings != null && pr.conn != null) { > + conn = pr.conn; > + } > + } else { > + conn = HttpsSettings.getHttpsSettings().openConnection(url); > + } > + httpsConnections.add(conn); "conn" can still be null and be added to "httpsConnections". This is probably not intended. > + OutputController.getLogger().log("done " + url.toExternalForm()); > + return conn; Same here, because "conn" can be null, null may be returned. > + } > + > + public void disconnect(URLConnection conn) { > + if (conn instanceof HttpsURLConnection) { > + disconnectHttps((HttpsURLConnection) conn); > + } else { > + if (conn instanceof HttpURLConnection) { > + ((HttpURLConnection) conn).disconnect(); > + } > + } > + } > + > + public synchronized void disconnectHttps(HttpsURLConnection conn) { > + conn.disconnect(); Possible NPE. > + //this s intentional search by object value. equals do not work > + for (int i = 0; i < httpsConnections.size(); i++) { Start from the end, decrement to 0, and compare to 0. Comparing to 0 gives almost always far better performance on modern processors because they are heavily optimized for branch predicion on 0. > + URLConnection uRLConnection = httpsConnections.get(i); > + if (uRLConnection == conn) { > + httpsConnections.remove(i); > + i--; Besides, why not use ArrayList.removeAll(Collection) here? It is probably much faster, even though you have to create a Collection instance. > + } > + > + } > + } > + > + private static class HttpsProbeResult { > + > + URLConnection conn; > + HttpsSettings settings; > + } > + > + private static class HttpsSettings { > + > + private static HttpsSettings INSTANCE; > + private static SSLContext ctxOrig; > + > + @Override > + public String toString() { > + return "SSL 2.0: " + ssl2 + ", insecure " + insecure; > + } > + > + public static HttpsSettings getHttpsSettings() { > + return INSTANCE; > + } > + > + private static HttpsProbeResult initHttpsSettings(URL initUrl) throws IOException { > + try { > + if (ctxOrig == null) { > + ctxOrig = SSLContext.getDefault(); > + } > + HttpsProbeResult pr = new HttpsProbeResult(); > + try { > + pr.settings = new HttpsSettings(false, false); > + pr.conn = pr.settings.openConnection(initUrl); > + INSTANCE = pr.settings; > + return pr; > + } catch (IOException e) { > + OutputController.getLogger().log(e); > + } > + if (isInsecurePossible()) { > + try { > + OutputController.getLogger().log("Probing " + initUrl.toExternalForm() + " without certificate check."); > + pr.settings = new HttpsSettings(false, true); > + pr.conn = pr.settings.openConnection(initUrl); > + if (getInsecureStatus().equals(InsecureStates.ASK)) { > + //TODO dialog for not trusted cert dialog > + } > + INSTANCE = pr.settings; > + return pr; > + } catch (IOException e) { > + OutputController.getLogger().log(e); > + } > + } > + HttpURLConnection conn = null; > + try { > + OutputController.getLogger().log("Probing " + initUrl.toExternalForm() + " with SSL 2.0 handshake."); > + conn = (HttpURLConnection) HttpsSettings.openConnection(initUrl, true, false); > + String s = "The " + initUrl.toExternalForm() + " was accessible only by insecure SSL 2.0 handshake. This is forbidden. Contact its administrator."; > + OutputController.getLogger().log(OutputController.Level.WARNING_ALL, s); > + throw new RuntimeException(s); > + } catch (IOException e) { > + OutputController.getLogger().log(e); > + } finally { > + if (conn != null) { > + conn.disconnect(); > + } > + } > + conn = null; > + if (isInsecurePossible()) { > + try { > + OutputController.getLogger().log("Probing " + initUrl.toExternalForm() + " with SSL 2.0 and without certificate check."); > + conn = (HttpURLConnection) HttpsSettings.openConnection(initUrl, true, true); > + String s = "The " + initUrl.toExternalForm() + " was accessible only by insecure SSL 2.0 handshake and with unchecked certificate. The SSL 2.0 handshake is forbidden. Contact its administrator."; > + OutputController.getLogger().log(OutputController.Level.WARNING_ALL, s); > + throw new RuntimeException(s); > + } catch (IOException e) { > + OutputController.getLogger().log(e); > + } finally { > + if (conn != null) { > + conn.disconnect(); > + } > + } > + } > + throw new IOException("All probing methods on " + initUrl.toExternalForm() + "failed."); > + } catch (NoSuchAlgorithmException ex) { > + throw new IOException(ex); > + } > + } > + > + private final boolean ssl2; > + private final boolean insecure; > + > + private HttpsSettings(boolean ssl2, boolean insecure) { > + this.ssl2 = ssl2; > + this.insecure = insecure; > + } > + > + private URLConnection openConnection(URL url) throws IOException { > + return openConnection(url, ssl2, insecure); > + } > + > + public static URLConnection openConnection(URL url, boolean ssl2, boolean insecure) throws IOException { > + try { > + if (ssl2) { > + System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); > + } else { > + System.clearProperty("https.protocols"); > + > + } I am absolutely sure we do not want to modify *system* properties for *all* future connections here. What about other existing and other future connections, especially connections created by a JNLP application? And then there SecurityManager implications. What if these or all system properties are read-only? So no, we do not want to modify system properties at runtime. > + if (insecure) { > + // configure the SSLContext without a TrustManager > + SSLContext ctx = SSLContext.getInstance("TLS"); > + ctx.init(new KeyManager[0], new TrustManager[]{new DummyTrustManager()}, new SecureRandom()); > + SSLContext.setDefault(ctx); > + } else { > + SSLContext.setDefault(ctxOrig); > + } > + HttpsURLConnection conn = (HttpsURLConnection) url.openConnection(); > + if (insecure) { > + conn.setHostnameVerifier(new HostnameVerifier() { > + @Override > + public boolean verify(String arg0, SSLSession arg1) { > + return true; > + } > + }); > + } > + > + return conn; > + } catch (KeyManagementException | NoSuchAlgorithmException ex) { > + throw new IOException(ex); > + } > + } > + > + private static class DummyTrustManager implements X509TrustManager { > + > + public DummyTrustManager() { > + } > + > + @Override > + public void checkClientTrusted(X509Certificate[] arg0, String arg1) throws CertificateException { > + } > + > + @Override > + public void checkServerTrusted(X509Certificate[] arg0, String arg1) throws CertificateException { > + } > + > + @Override > + public X509Certificate[] getAcceptedIssuers() { > + return null; > + } > + } > + } > + > +} So much reviewing for now. I'll get back to it when you have a patch based on the current tip ready. Jacob From gitne at gmx.de Mon Sep 15 02:06:10 2014 From: gitne at gmx.de (Jacob Wisor) Date: Mon, 15 Sep 2014 04:06:10 +0200 Subject: [rfc][icedtea-web] IcedTea-Web for Windows In-Reply-To: <54117388.3030601@redhat.com> References: <5410FCF8.7040600@gmx.de> <54117388.3030601@redhat.com> Message-ID: <54164992.2080607@gmx.de> On 09/11/2014 12:03 AM, Jiri Vanek wrote: > On 09/11/2014 03:38 AM, Jacob Wisor wrote: >> Hello there! >> [...] >> Long story short, I came to the conclusion that it is probably best to start >> implementing Windows >> specific code now and to blend it with the existing Un*x code later. > > Do you think it is even possible? Yes it is. Many projects do this. ;-) However, it is best to identify code portions which are platform specific first and then keep and maintain them cleanly apart than vigorously trying to stuff everything into one set of source files littered with preprocessor directives for different platforms. Most people have failed terribly on the latter approach (although it sounds most intuitive at the first glance). >> [...] >> diff --git a/.hgignore b/.hgignore >> --- a/.hgignore >> +++ b/.hgignore >> @@ -1,13 +1,23 @@ >> -Makefile.in >> -aclocal.m4 >> -autom4te.cache >> +Makefile\.in >> +aclocal\.m4 >> +autom4te\.cache >> build >> configure >> install-sh >> missing >> -config.guess >> -config.sub >> -netx/net/sourceforge/jnlp/resources/AUTHORS.html >> -netx/net/sourceforge/jnlp/resources/COPYING.html >> -netx/net/sourceforge/jnlp/resources/ChangeLog.html >> -netx/net/sourceforge/jnlp/resources/NEWS.html >> +config\.guess >> +config\.sub >> +.+\.patch >> +.+\.[Rr][Ee][Ss] >> +.+\.(o|[Oo][Bb][Jj]) >> +.+\.[Ee][Xx][Ee] >> +.+\.(so|[Dd][Ll]{2}) >> +.+\.(a|[Ll][Ii][Bb]) >> +.+\.[Mm][Ss][Ii] >> +.+\.rpm >> +.+\.[Xx][Pp][Ii] >> +(\.settings|\.project|\.cproject) >> +netx/net/sourceforge/jnlp/resources/AUTHORS\.html >> +netx/net/sourceforge/jnlp/resources/COPYING\.html >> +netx/net/sourceforge/jnlp/resources/ChangeLog\.html >> +netx/net/sourceforge/jnlp/resources/NEWS\.html > > Except the .project this part is ok to go as separate changeset. > > .project, is legacy habit to include classapth code style modules for eclipse > in main trunk. > > Personally I'm for removing those, and uplaod them for download to > http://icedtea.classpath.org/wiki/IcedTea-Web#Code_style > > Once uploaded and deleted, .project can be excluded. Sounds good to me. I have included modifications to .hgignore mainly because the format of the file is actually a list of lines with regular expressions than simple file names with shell globbing. So, especially the dots (.) in the file names were actually intended as "\.". And then, I have added patterns for files that may get generated and written to source code directories when building IcedTea-Web. This should prevent committing intermediate or binary files. Although usually files have to be added to the commit list first, some users may enable the "--addremove" switch when committing, so they may run into problems there. Anyway, I have always found it soothing and reassuring to have the versioning tool to automatically ignore the non-source stuff. So, this brings us to the point where we could turn the concept upside down. Instead of Mercurial having ignore specific files it could instead ignore all files by default and only track those which have actually been added. Okay, I am going to prepare a separate patch which deals with .hgignore and .project only. >> diff --git a/javaws.ico b/javaws.ico >> new file mode 100644 >> index >> e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..d8f848b89ffe5b7986e83e1d4d0a250c40ac6afb >> > > Why this? The ico is same as javaws.png. So I would inlicne to runtime > generation from jaavws.png to javaws.ico. > Also - why not to use png? I would agree to this if there was a readily available tool that would produce acceptable quality ico equivalents of png icon files. Unfortunately, there is none. Well, maybe there does exist a free GIMP script which handles this job perfectly. But then, it would be an awful gigantic dependency to have, like GIMP plus some possibly obscure plug-in script just for the build process to generate an ico file from a png file. You see, in order to produce modern Windows ico files you cannot just do a simple conversion of one png image. Modern Windows ico files are a set layers of different sizes, color spaces, and palettes. So, unless you can come up with a good command-line tool which is available on Linux *and* Windows that does the job, it is best to have two icon files and try to keep them in sync manually, as good as possible. > Ifabove seems to be unacceptable, then I would move this icon to windows folder. Okay, accepted. >> GIT binary patch >> literal 77494 >> zc%1EB2S5`^7vA&)2uVmn at 4a^r1gT<|rhrtj04f$#P!SPSR1`s^BX-4J(6cLwsMxWc >> zo?Yx > ...snip... > >> zJ3&{NHu;q)P3aebq6(`8!(@>R#C?BGW-Mv)BI&o8ekA=jr${9KG(UjCVzqbxk{_GD >> zpd-iM^uPo at KgZid0E*9#;qw#P@>lTrYg&-k+F#o-zY3qf>2;bIkkC> z)s7$2>@R8Y`fd0r&Hjo``fFOSqqV=b1$#IQNNC63>_r&Rj-TiC*(pq at Kd}XScnbG6 >> z{1q);w?lpvUVlw%zay`|me1eNf*tG^WVJxc*Xe*C)6$>F=Px0&^jGlvDJ}hQN!Y^g >> Q*wSCi?@ti!Z)o!W4+)&_H~;_u >> >> diff --git a/plugin/icedteanp/windows/GUIDs.c b/plugin/icedteanp/windows/GUIDs.c >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/GUIDs.c > ... >> diff --git a/plugin/icedteanp/windows/IcedTea-Web.h >> b/plugin/icedteanp/windows/IcedTea-Web.h >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/IcedTea-Web.h > .... >> diff --git a/plugin/icedteanp/windows/IcedTea-Web.rc >> b/plugin/icedteanp/windows/IcedTea-Web.rc >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/IcedTea-Web.rc > > ...Well.. What to say.. Really magnificent. > ... > > those? >> +#endif /* HAVE_JAVA8 */ >> + >> +#ifndef ICEDTEA_WEB_MIME_TYPES >> +#define ICEDTEA_WEB_MIME_TYPES \ >> + "application/x-java-applet|" \ >> + "application/x-java-applet|" \ >> + "application/x-java-applet;version=1.1|" \ >> + "application/x-java-applet;version=1.1|" \ >> + "application/x-java-applet;version=1.1.1|" \ >> + "application/x-java-applet;version=1.1.1|" \ >> + "application/x-java-applet;version=1.1.2|" \ >> ... >> + "application/x-java-bean;version=1.6|" \ >> + "application/x-java-bean;version=1.6|" \ >> + "application/x-java-bean;version=1.7|" \ >> + "application/x-java-bean;version=1.7|" \ >> + PLUGIN_BEAN_MIME_DESC \ >> + PLUGIN_BEAN_MIME_DESC \ > > ...those... > >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "class|jar|" >> +// "jnlp|" >> +// "class|jar" >> +// VALUE "FileOpenName", "Java-Klassendatei (*.class)|" >> +// "Java-Archiv (*.jar)|" >> +// "Java-Klassendatei (*.class)|" >> +// "Java-Archiv (*.jar)|" >> +// "Java-Klassendatei (*.class)|" >> +// "Java-Archiv (*.jar)|" >> +// "Java-Klassendatei (*.class)|" >> +// "Java-Archiv (*.jar)|" > ...those... >> + "class|jar|" >> + "class|jar|" >> + "class|jar|" >> + "class|jar|" >> + "class|jar|" >> + "jnlp|" >> + "class|jar" >> + VALUE "FileOpenName", "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "Java Class File (*.class)|" > > ...those... > >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)|" >> +// "Aplikacja JNLP (*.jnlp)|" >> +// "Plik Klassy Java (*.class)|" >> +// "Archiwum Java (*.jar)" >> +// VALUE "Language", "pl" >> +// } >> + } > and those ^ seems to me like most easy to be belnded. Together with ITW Yes and no. Unfortunately, the MIME type description format Mozilla uses is quite different for Windows or OS/2 and Un*x plug-ins. I am sure one could come up with a set of preprocessor directives to blend them together, but I fear that the only person who will have had written such set of preprocessor directives is also going to be the only one who will understand it and be able to maintain it. :-D Nevertheless, I will think about it, but this is probably a task for later when we have the first IcedTea-Web for Windows prototype running. > But defintiely not as this changeset. Right. >> + >> + BLOCK "VarFileInfo" { >> + VALUE "Translation", LANG_CZECH, 1250, /* Czech */ >> + LANG_GERMAN, 1252, /* German */ >> + LANG_ENGLISH, 1252, /* English */ >> + LANG_POLISH, 1250 /* Polish */ >> + } >> +} >> + >> +ID_ICON ICON "../../../javaws.ico" >> + >> +STRINGTABLE LANGUAGE LANG_CZECH, SUBLANG_DEFAULT { >> + IDS_FRIENDLYTYPENAME "JNLP aplikace" >> +} >> + >> +STRINGTABLE LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT { >> + IDS_FRIENDLYTYPENAME "JNLP Application" >> + IDS_OPEN "&Open" >> +} >> + >> +STRINGTABLE LANGUAGE LANG_GERMAN, SUBLANG_DEFAULT { >> + IDS_FRIENDLYTYPENAME "JNLP-Anwendung" >> + IDS_OPEN "?&ffnen" >> +} >> + >> +STRINGTABLE LANGUAGE LANG_POLISH, SUBLANG_DEFAULT { >> + IDS_FRIENDLYTYPENAME "Aplikacja JNLP" >> + IDS_OPEN "O&tw?rz" >> +} >> + >> +#else /* OS2 */ >> +#include >> + >> +NP_INFO_ProductVersion RC_DATA { >> + PACKAGE_MAJOR_VERSION, >> + PACKAGE_MINOR_VERSION, >> + PACKAGE_PATCH_VERSION, >> + PACKAGE_BUILD_VERSION >> +} >> +NP_INFO_MIMEType RC_DATA { >> + ICEDTEA_WEB_MIME_TYPES "\0" >> +} >> +NP_INFO_FileOpenName RC_DATA { >> + "Java Class File (*.class)|" >> + "Java Archive (*.jar)|" >> + "JNLP Application (*.jnlp)|\0" >> +} >> +NP_INFO_FileExtents RC_DATA { >> + "class|jar|jnlp\0" >> +} >> +NP_INFO_FileDescription RC_DATA { >> + PACKAGE_DESCRIPTION "\0" >> +} >> +NP_INFO_ProductName RC_DATA { >> + PACKAGE_NAME "\0" >> +} >> +NP_INFO_CompanyName RC_DATA { >> + PACKAGE_VENDOR "\0" >> +} >> +NP_INFO_FileVersion RC_DATA { >> + PACKAGE_MAJOR_VERSION, >> + PACKAGE_MINOR_VERSION, >> + PACKAGE_PATCH_VERSION, >> + PACKAGE_BUILD_VERSION >> +} >> +NP_INFO_InternalName RC_DATA { >> + "NP" PACKAGE_NAME "\0" >> +} >> +NP_INFO_LegalCopyright RC_DATA { >> + "GPLv2, see the file COPYING for details\0" >> +} >> +NP_INFO_OriginalFilename RC_DATA { >> + "NP" PACKAGE_NAME ".DLL\0" >> +} >> +#endif /* OS2 */ >> +#endif /* RC_INVOKED */ >> +#endif /*_ICEDTEA_WEB_RC_ */ >> diff --git a/plugin/icedteanp/windows/IcedTeaIEPlugin.c >> b/plugin/icedteanp/windows/IcedTeaIEPlugin.c >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/IcedTeaIEPlugin.c >> @@ -0,0 +1,2191 @@ >> +#define INC_OLE2 >> +#include >> +#include > > ... > http://en.wiktionary.org/wiki/to_je_pro_m%C4%9B_%C5%A1pan%C4%9Blsk%C3%A1_vesnice > :)) Don't worry! :-) Well then, get a friend who has got the expertise. Btw, the phrase above transliterates to "B?hmische D?rfer" (Bohemian villages) in German. You see, there is the connotation to the Czech again. It's a small world! ;-) >> +} >> diff --git a/plugin/icedteanp/windows/IcedTeaIEPlugin.h >> b/plugin/icedteanp/windows/IcedTeaIEPlugin.h >> new file mode 100644 >> --- /dev/null >> +++ b/plugin/icedteanp/windows/IcedTeaIEPlugin.h >> @@ -0,0 +1,3 @@ > > ....still the same. >> \ No newline at end of file >> > > > Well one general hint - Maybe its the time to restructure plugin directory? > > I would go for something like > plugin/windows/src (your "c a nd rest" files) > plugin/windows/build (mingw make or whatever you may need for build (the ico if > you will insists?-) ) )) > plugin/linux/src (current icedteanp) > plugin/linux/build? And so extract plugin parts from main makefile? > plugin/share/java (current current java) > plugin/share/docs > plugin/share/tests Yes, this reads reasonable. However, I am going to do this for Windows now only. Moving the Un*x/Linux sources will require adapting the build scripts to the new file structure or things will break. So, I do not want to touch the Un*x/Linux sources now because it is going to take a changeset of its own. Jacob From jvanek at redhat.com Mon Sep 15 11:16:51 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 15 Sep 2014 13:16:51 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <541308D4.8020802@gmx.de> References: <54071FE9.2000309@redhat.com> <54101CEB.1040104@redhat.com> <5412D877.8070300@redhat.com> <541308D4.8020802@gmx.de> Message-ID: <5416CAA3.8090803@redhat.com> On 09/12/2014 04:53 PM, Jacob Wisor wrote: > On 09/12/2014 01:26 PM, Jiri Vanek wrote: >> >> :((( >> >> >> This patch is becoming blocker. >> >> >> Any volunteer? >> >> >> J. >> On 09/10/2014 11:42 AM, Jiri Vanek wrote: >>> ping? > > I am on it since yesterday. I am sorry but I have been called multiple times to do something else. > > Jacob Hi! Thank you very much for the swarm of reviews! I have read them all and I need to think about them. Again, thank you very much. Few things which cough my eye: *localizable Plugin+settings+fix+cleanup:* the @bold@ whatever@ stuff: - It is placeholder for in html or \n.B \n in man. Tbh Right now I dont know workaround - I would like to get rid of of all this @@ markups. And I'm successfully doing so:) - I Get rid of all except the @bold@, Which I found as necessary evil. But if workaround will be found. I will be most happy to get rid of it. >> +IWSexampleL2=Resets the value of `{0}` setting. > Are the "`" characters literals in the man page or markups? Originally there were the ' (" ' ") char, however, I noted, then If I put {n} into '' like '{0}' the properties fiel do not evaluate it correctly. Same for " char and no escaping helped.. So I put here ` char:( Anyway - no markup mentioned. In original text it was just quoting - making it readable or similar. So it have nothing to do with any markup, and AFAIK all plain, html and man output is ok with it.I will be happy to change it if you dont like it ad know replacement. https probing - > I am absolutely sure we do not want to modify *system* properties for *all* > future connections here. What about other existing and other future connections, > especially connections created by a JNLP application? > And then there SecurityManager implications. What if these or all system > properties are read-only? So no, we do not want to modify system properties at > runtime. Ok. This sounds like serious flaw. My intention was to modify *all* https settings. Actually are you sure that in this case I'm modifying jnlpapplications one? Reading it now.. you are probably right:-/. - but - ITW is creating copy of the properties, and to jnlp app it is forwarding the copy of original one. However, thank you for catching this. This needs verification/investigations on my side. If I leave aside the affect on future running jnlp app, and cosidering only impact of itw, then this what this patch should do. - got requested https connection creation - stop the world - try to set working https configuration - create connection and use this setting sinc on for ever (no stop the world anymore) or (if probing always and/or synchronized connections on) - got requested https connection creation - stop the world - try to set working https configuration for this single run - create connection. In next request do the same The motivation to do this was: - 99% of applications need same https settings for whole app (I mean jnlpruntime, not the application itself) - the 1% which needs to connection to different not-standard servers wil need to use the second approach. IcedTea-Web for Windows ico: commandline "convert" tool from imagemagic package do nit suit you? >> I would go for something like >> plugin/windows/src (your "c a nd rest" files) >> plugin/windows/build (mingw make or whatever you may need for build (the ico if >> you will insists?-) ) )) >> plugin/linux/src (current icedteanp) >> plugin/linux/build? And so extract plugin parts from main makefile? >> plugin/share/java (current current java) >> plugin/share/docs >> plugin/share/tests > Yes, this reads reasonable. However, I am going to do this for Windows now only. > Moving the Un*x/Linux sources will require adapting the build scripts to the new > file structure or things will break. So, I do not want to touch the Un*x/Linux > sources now because it is going to take a changeset of its own. I think that the adaptation of current makefile will not be so dramatic. And I think it is better to do it earlier or later All those are more over thoughts, I will probably copypaste them to next rounds of review, but all seemed to interesting to dont reply:) Again, TYVM for reviews! J. From jvanek at redhat.com Mon Sep 15 11:27:14 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 15 Sep 2014 13:27:14 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <5416CAA3.8090803@redhat.com> References: <54071FE9.2000309@redhat.com> <54101CEB.1040104@redhat.com> <5412D877.8070300@redhat.com> <541308D4.8020802@gmx.de> <5416CAA3.8090803@redhat.com> Message-ID: <5416CD12.40800@redhat.com> On 09/15/2014 01:16 PM, Jiri Vanek wrote: > On 09/12/2014 04:53 PM, Jacob Wisor wrote: >> On 09/12/2014 01:26 PM, Jiri Vanek wrote: >>> >>> :((( >>> >>> >>> This patch is becoming blocker. >>> >>> >>> Any volunteer? >>> >>> >>> J. >>> On 09/10/2014 11:42 AM, Jiri Vanek wrote: >>>> ping? >> >> I am on it since yesterday. I am sorry but I have been called multiple times to do something else. >> >> Jacob > > Hi! > > Thank you very much for the swarm of reviews! > > I have read them all and I need to think about them. Again, thank you very much. > > > Few things which cough my eye: > > > *localizable Plugin+settings+fix+cleanup:* > > the @bold@ whatever@ stuff: > - It is placeholder for in html or \n.B \n in man. Tbh Right now I dont know workaround > - I would like to get rid of of all this @@ markups. And I'm successfully doing so:) > - I Get rid of all except the @bold@, Which I found as necessary evil. But if workaround will be > found. I will be most happy to get rid of it. > > > >> +IWSexampleL2=Resets the value of `{0}` setting. > > Are the "`" characters literals in the man page or markups? > > Originally there were the ' (" ' ") char, however, I noted, then If I put {n} into '' like '{0}' the > properties fiel do not evaluate it correctly. Same for " char and no escaping helped.. So I put > here ` char:( > Anyway - no markup mentioned. In original text it was just quoting - making it readable or similar. > So it have nothing to do with any markup, and AFAIK all plain, html and man output is ok with it.I > will be happy to change it if you dont like it ad know replacement. > > > https probing > - > > I am absolutely sure we do not want to modify *system* properties for *all* > > future connections here. What about other existing and other future connections, > > especially connections created by a JNLP application? > > And then there SecurityManager implications. What if these or all system > > properties are read-only? So no, we do not want to modify system properties at > > runtime. > > Ok. This sounds like serious flaw. My intention was to modify *all* https settings. Actually are > you sure that in this case I'm modifying jnlpapplications one? Reading it now.. you are probably > right:-/. - but - ITW is creating copy of the properties, and to jnlp app it is forwarding the copy > of original one. However, thank you for catching this. This needs verification/investigations on my > side. > > If I leave aside the affect on future running jnlp app, and cosidering only impact of itw, then this > what this patch should do. > - got requested https connection creation > - stop the world > - try to set working https configuration > - create connection and use this setting sinc on for ever (no stop the world anymore) > or (if probing always and/or synchronized connections on) > - got requested https connection creation > - stop the world > - try to set working https configuration for this single run > - create connection. In next request do the same > > The motivation to do this was: > - 99% of applications need same https settings for whole app (I mean jnlpruntime, not the > application itself) > - the 1% which needs to connection to different not-standard servers wil need to use the second > approach. > > > IcedTea-Web for Windows > ico: > commandline "convert" tool from imagemagic package do nit suit you? > > > >> I would go for something like > >> plugin/windows/src (your "c a nd rest" files) > >> plugin/windows/build (mingw make or whatever you may need for build (the ico if > >> you will insists?-) ) )) > >> plugin/linux/src (current icedteanp) > >> plugin/linux/build? And so extract plugin parts from main makefile? > >> plugin/share/java (current current java) > >> plugin/share/docs > >> plugin/share/tests > > > Yes, this reads reasonable. However, I am going to do this for Windows now only. > > Moving the Un*x/Linux sources will require adapting the build scripts to the new > > file structure or things will break. So, I do not want to touch the Un*x/Linux > > sources now because it is going to take a changeset of its own. > > > I think that the adaptation of current makefile will not be so dramatic. And I think it is better to > do it earlier or later I accidentally press send:( I think that the adaptation of current makefile will not be so dramatic. And I think it is better to do it earlier then later. Especially if we agree on similar structure, the windows port may be already using it since first commit. Also - should this be target for 1.6 ? If so it shoudl be done :) If not then there si pelnty of time. But this depends completely on you. There may be even different reelase cycle of windows port. And well you do not need to do unix maklefiel refactoring. Anybody can And I volunteer (with wish to other volunteers :D ) > > > > All those are more over thoughts, I will probably copypaste them to next rounds of review, but all > seemed to interesting to dont reply:) > > Again, TYVM for reviews! > > J. From jkang at icedtea.classpath.org Mon Sep 15 14:11:22 2014 From: jkang at icedtea.classpath.org (jkang at icedtea.classpath.org) Date: Mon, 15 Sep 2014 14:11:22 +0000 Subject: /hg/icedtea-web: Fix for duplicate entries in CacheLRUWrapper Message-ID: changeset 11ebb7204bdc in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=11ebb7204bdc author: Jie Kang date: Mon Sep 15 10:10:44 2014 -0400 Fix for duplicate entries in CacheLRUWrapper 2014-09-15 Jie Kang * netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java (getLRUSortedEntries): now creates a deeper copy of cacheOrder list diffstat: ChangeLog | 5 +++++ netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java | 8 +++++++- 2 files changed, 12 insertions(+), 1 deletions(-) diffs (37 lines): diff -r 90faf53bb981 -r 11ebb7204bdc ChangeLog --- a/ChangeLog Sat Sep 13 13:23:26 2014 -0400 +++ b/ChangeLog Mon Sep 15 10:10:44 2014 -0400 @@ -1,3 +1,8 @@ +2014-09-15 Jie Kang + + * netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java + (getLRUSortedEntries): now creates a deeper copy of cacheOrder list + 2014-09-13 Andrew Azores * netx/net/sourceforge/jnlp/resources/Messages.properties diff -r 90faf53bb981 -r 11ebb7204bdc netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java --- a/netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java Sat Sep 13 13:23:26 2014 -0400 +++ b/netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java Mon Sep 15 10:10:44 2014 -0400 @@ -40,6 +40,7 @@ import java.io.File; import java.io.IOException; +import java.util.AbstractMap; import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; @@ -227,7 +228,12 @@ //although Properties are pretending to be they are always //bug in jdk? public synchronized List> getLRUSortedEntries() { - List> entries = new ArrayList(cacheOrder.entrySet()); + List> entries = new ArrayList<>(); + + for (Entry e : cacheOrder.entrySet()) { + entries.add(new AbstractMap.SimpleImmutableEntry(e)); + } + // sort by keys in descending order. Collections.sort(entries, new Comparator>() { @Override From jkang at redhat.com Mon Sep 15 14:27:00 2014 From: jkang at redhat.com (Jie Kang) Date: Mon, 15 Sep 2014 10:27:00 -0400 (EDT) Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <5414766D.6000901@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> <54107019.2030106@redhat.com> <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> <5410E9B6.2030808@redhat.com> <2058764014.3737904.1410444088683.JavaMail.zimbra@redhat.com> <5414766D.6000901@redhat.com> Message-ID: <931268835.5056488.1410791220835.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/11/2014 10:01 AM, Jie Kang wrote: > > > > > > ----- Original Message ----- > >> On 09/10/2014 02:31 PM, Jie Kang wrote: > >>> > >>> Hello, > >>> > >>> > >>> Good points. I have made Translator an enum with a single instance where > >>> the public static String R still remains and added basic unit tests for > >>> Translator. > >>> > >>> > >> > >> Overall I definitely like the idea behind this patch. Just a few minor > >> implementation details I have some questions about. > >> > >>> public static String R(String message) { > >>> - return JNLPRuntime.getMessage(message); > >>> + return getInstance().getMessage(message); > >>> } > >> > >> Can this be defined in terms of Translator.R(String, Object...) instead? > >> Not a big deal but it seems natural to me. > > > > Hello, > > > > > > Thanks for the review! > > > > I am not sure if I understood correctly but for this R(String message) do > > you mean something like: > > return R(message, new Object[0]) > > > > I prefer the other way since it's more efficient and makes more sense to me > > hahah. Though I understand what you mean by being more natural. It's just > > on closer inspection it seems really weird to make this call when you can > > just use getInstance().getMessage(message); > > > > Is it okay if I keep it original? > > Sure, this definitely is not a blocker on push. I think "efficiency" > here is a pretty weak reason though ;) it's just one extra method call, > not very heavy. The other benefit is that if down the line somebody > wants to add some extra validation or something, for example, then it > only needs to be added in one of the methods, rather than both overloads. > > It's also a little bit confusing looking because since R(String, > Object...) is varargs, it's actually valid to call it simply as, for > example, R("TEST"). In this case, your varargs array just ends up being > the empty array. So what you've done by defining both methods is > essentially add a constraint for the varargs that it has to be of at > least size 1, then branching into different calls to getMessage, one of > which is actually defined in terms of the other in failure cases > anyway... the call web is just a bit tangled is what I'm trying to say. > But it's fine as-is regardless. Hello, Just wanted to say thanks for this explanation! I decided to go with what you suggested instead. Since the varargs case accepts 0 args, we can technically remove the function R(String message) and just have R(String message, Object ... params), no? Do you think it'd be good to remove R(String message) in this patch? Regards, > > > > >> > >>> + public static void loadResourceBundle(ResourceBundle bundle) { > >>> + getInstance().resources = bundle; > >>> + } > >> > >> Why is this still static? I think this makes sense as a method belonging > >> to the singleton instance, and I only see one call site (TranslatorTest) > >> that would need to be refactored. I would also rather see a > >> (package-private?) setter method rather than direct field assignment > >> here, but that's not a huge deal. > > > > I chose to make it static since I wanted the class to be accessed in a > > consistent manner. getInstance() was private and R() was public static so > > it made sense to me to make loadResourceBundle() also static in order to > > preserve the privacy of getInstance(). > > > > Well, getInstance() may have been private, but INSTANCE is not anyway ;) > > > Also I preferred keeping it public in order to possibly allow for > > itweb-settings to have an option to set the preferred locale or something > > like that (in the future). Now that I think about it, this isn't > > necessary. > > > > > >> > >>> + } catch (Exception ex) { > >>> + throw new IllegalStateException("Missing resource bundle in > >>> netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); > >>> + } > >> > >> Is this path correct even for non-default (English) locales? Eg for > >> Czech shouldn't it be attempting (and failing) to load > >> net/sourceforge/jnlp/resource/Messages_cs.properties? I'm not sure how > >> easy it is to get the name of the ResourceBundle that the runtime would > >> attempt to load however, it may not be worth the effort - this is a > >> pretty close approximation anyway even for other locales I suppose. > > > > In terms of resource bundle failing to load, it attempts to load whatever > > the default locale is and failing that, attempts to load the base copy, > > only if the base does not exist will it fail and throw the exception. > > Getting the default locale is pretty easy so I've changed the message to > > be more appropriate. > > > > How does it look? > > Ah okay, this makes perfect sense. I do like the new message better. > > > > > > > Thanks, > > > >> > >> Thanks, > >> -- > >> Andrew Azores > >> > > > > +1 okay to push from me. > > Thanks, > -- > Andrew Azores > -- Jie Kang From bugzilla-daemon at icedtea.classpath.org Mon Sep 15 15:01:07 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 15 Sep 2014 15:01:07 +0000 Subject: [Bug 1998] New: icedtea crash in atlassian-confluence-5.4.2 (wiki) Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1998 Bug ID: 1998 Summary: icedtea crash in atlassian-confluence-5.4.2 (wiki) Product: IcedTea Version: 6-hg Hardware: 64-bit OS: Linux Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: hari_ganesh at intuit.com CC: unassigned at icedtea.classpath.org Created attachment 1171 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1171&action=edit Error report created when atlassian-confluence-5.4.2 crashed. more hs_err_pid13428.log # # A fatal error has been detected by the Java Runtime Environment: # # Internal Error (verifier.cpp:1518), pid=13428, tid=1316403520 # guarantee(cp->cache() == NULL) failed: not rewritten yet # # JRE version: 6.0_22-b22 # Java VM: OpenJDK 64-Bit Server VM (20.0-b11 mixed mode linux-amd64 compressed oops) # Derivative: IcedTea6 1.10.9 # Distribution: CentOS release 5.8 (Final), package rhel-1.28.1.10.9.el5_8-x86_64 # If you would like to submit a bug report, please include # instructions how to reproduce the bug and visit: # http://icedtea.classpath.org/bugzilla -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Mon Sep 15 15:12:33 2014 From: jkang at redhat.com (Jie Kang) Date: Mon, 15 Sep 2014 11:12:33 -0400 (EDT) Subject: [rfc][icedtea-web] localizable files and icedtea-web about page In-Reply-To: <5412C29D.6070107@redhat.com> References: <541063A3.8070201@redhat.com> <256207747.3820015.1410450074350.JavaMail.zimbra@redhat.com> <5412C29D.6070107@redhat.com> Message-ID: <1430519373.5097105.1410793953430.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/11/2014 05:41 PM, Jie Kang wrote: > > Hello, > > > > Looks nice! A few nits: > > > > + for (int x=1 ; x<=7 ; x++){ > > + > > p1.append(getFormatter().getOption(Translator.R("ITWdescO"+x+"title"), > > Translator.R("ITWdescO"+x+"text"))); > > + } > > > > Can you comment here why it goes from 1 to 7? Something like : pulls from > > Message.properties [(ITWdesc01title, ITWdesc01text), ...] > > Just to make understanding faster :) > > > > done. > > > > > @Override > > public String getIntroduction() { > > return super.getIntroduction() > > + getFormatter().wrapParagraph( > > Translator.R("ITWintroL1",getFormatter().getBold(getId() > > + " ")) > > + getFormatter().getNewLine() + > > getFormatter().getNewLine() > > + Translator.R("ITWintroL2") > > + getFormatter().getNewLine() > > + Translator.R("ITWintroL3", getId(), > > getFormatter().getUrl("http://www.java.com/en/download/testjava.jsp", > > Translator.R("ITWintroUrlCaption"))) > > minor + getFormatter().getNewLine() > > + > > getFormatter().getOption("",Translator.R("BFileInfoAuthors")) > > + > > getFormatter().getOption("",Translator.R("BFileInfoCopying")) > > + > > getFormatter().getOption("",Translator.R("BFileInfoNews")) > > + getFormatter().getNewLine() + > > getFormatter().getNewLine()); > > > > } > > > > for the multiple getFormatter().getNewLine() do you think it would be neat > > to have a function like: > > getNewLine(int num) : Returns 'num' new line characters. > > I was thinking about it since beginning. Fixed, and added some tests. Hurray > - firs tunittests for > this thing O:( > > > > > > > > String header = getFormatter().getBold("Features of NetX: ") + > > getFormatter().getNewLine(); > > > > "Features of NetX: " This string should probably be localized > > overlooked! Fixed, and reworded as Jacob suggested. > > > > > > > +ITWintroL1={0}provides a Free Software web browser plugin running applets > > written in the Java programming language and an implementation of Java Web > > Start, originally based on the NetX project. > > > > Do you think the "Free Software" should be changed to "Free Open Source > > Software"? > > Not fixed - as Jacob suggested. > > > > +ITWintroL3={0} also includes a plugin to {1} within web browsers. > > > > For this message I see in the english man page: > > icedtea-web also includes a plugin to > > http://www.java.com/en/download/testjava.jsp within web browsers. > > > > Is this replacement of {1} with http://... supposed to happen? It doesn't > > really make sense to me. > > > > Well. This is not easy task to fix. > > In HTML you have readable text-> hidden link. plaintext nor man support > similar thing. > > So I Implemented the man/plain foramtters to simply ignore the human readable > part, as the url is > the real keeper of information. > > If this is going to be subject of change, I'm for. I have jsut lack of ideas. > Anyway this will be different changeset, as it affects whole documentation > > Right now I have this foramting for plain texts urls in mind: > human readable title (url) > > Thoughts? Hello, I think the format of 'human readable title : (url)' works fine! As for the other things, yeah different changeset. After your patches are reviewed + applied, I will look into the formatting issues with man and see if I can come up with something; Also, can you double-check the text file for icedtea-web (plain.../en/icedteaweb.txt) I see on the very first line: *** icedtea-web P_TAIL *** I'm not sure what this is for;; Apart from that looks good to me :) Regards, > > > > > > > > > > > In the english man page for Description I see: > > Features of NetX: > > > > Modular Easily add JNLP capabilities to an application. > > > > Saves Memory > > Launch programs in a shared JVM. > > > > Fast startup > > Runs applications from a cache for fast starting. > > > > Security Run any application in a sandbox or log its activities. > > > > Auto-Update Applications can auto-update without special code. > > > > Network Deployment > > Deploy to the internet, not with installers. > > > > Can you make the format consistent by making the text part always on a new > > line? E.g: > > I cant! This is how program man is formatting TP command. I got this TP thing > from our original > pages (actually my results were 1:1 copies of those on non added lines) > > So - We may change to different formatting for parameters then TP, currently > I dont know of any more > suitable:( > > The TP do what it is supposed to do. It do some kind of two columns table, > where second column have > fixed starting point (it is declared by the number, in our case 12 everywhere > [12 everywhere was > also in original man pages) > So if you look at it, you will see, that the record is put to second line, > only where the first > column is longer then expected width (in our case 12) > > Anyway.. different changeset. Suggestions welcomed! > > Security Run any application in a sandbox or log its activities. > > becomes > > Security > > Run any application in a sandbox or log its activities. > > > > > > > > > > > > Also the text here (from english man page) has very weird spacing: > > > > Visit the http://icedtea.classpath.org/wiki/Main_Page or > > specifically the http://icedtea.class? > > path.org/wiki/IcedTea-Web pages for more information. > > Help with common issues with IcedTea-Web can be found > > http://icedtea.classpath.org/wiki/IcedTea-Web#Com? > > mon_Issues . > > > > I think this has to do with the formatting? I am not sure. > > > > This is nearly the same issue as TP. This is what program man is doing. It > formats the paragraphs > to fit your terminal width, and it is trying to align justifiably both left > and righ, but enlarging > spaces where suitable. > > so "hell ouu a friend" on 4 chars wide terminall will become similar to: > "hell" > " ouu" > " a " > "frie" > "nd " > > Afaik absolutely no op here. > > > > > > Regards, > > > > ----- Original Message ----- > >> ssia > >> > >> First of patches moving the individual liens to properties. Fixes to > >> individual sentences welcomed. > >> > >> J. > >> > > > > > Thanx both of yo for check! > > > J. > -- Jie Kang From jvanek at redhat.com Mon Sep 15 15:16:29 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 15 Sep 2014 17:16:29 +0200 Subject: [rfc][icedtea-web] localizable files and icedtea-web about page In-Reply-To: <1430519373.5097105.1410793953430.JavaMail.zimbra@redhat.com> References: <541063A3.8070201@redhat.com> <256207747.3820015.1410450074350.JavaMail.zimbra@redhat.com> <5412C29D.6070107@redhat.com> <1430519373.5097105.1410793953430.JavaMail.zimbra@redhat.com> Message-ID: <541702CD.8000006@redhat.com> On 09/15/2014 05:12 PM, Jie Kang wrote: > > > ----- Original Message ----- >> On 09/11/2014 05:41 PM, Jie Kang wrote: >>> Hello, >>> >>> Looks nice! A few nits: >>> >>> + for (int x=1 ; x<=7 ; x++){ >>> + >>> p1.append(getFormatter().getOption(Translator.R("ITWdescO"+x+"title"), >>> Translator.R("ITWdescO"+x+"text"))); >>> + } >>> >>> Can you comment here why it goes from 1 to 7? Something like : pulls from >>> Message.properties [(ITWdesc01title, ITWdesc01text), ...] >>> Just to make understanding faster :) >>> >> >> done. >> >>> >>> @Override >>> public String getIntroduction() { >>> return super.getIntroduction() >>> + getFormatter().wrapParagraph( >>> Translator.R("ITWintroL1",getFormatter().getBold(getId() >>> + " ")) >>> + getFormatter().getNewLine() + >>> getFormatter().getNewLine() >>> + Translator.R("ITWintroL2") >>> + getFormatter().getNewLine() >>> + Translator.R("ITWintroL3", getId(), >>> getFormatter().getUrl("http://www.java.com/en/download/testjava.jsp", >>> Translator.R("ITWintroUrlCaption"))) >>> minor + getFormatter().getNewLine() >>> + >>> getFormatter().getOption("",Translator.R("BFileInfoAuthors")) >>> + >>> getFormatter().getOption("",Translator.R("BFileInfoCopying")) >>> + >>> getFormatter().getOption("",Translator.R("BFileInfoNews")) >>> + getFormatter().getNewLine() + >>> getFormatter().getNewLine()); >>> >>> } >>> >>> for the multiple getFormatter().getNewLine() do you think it would be neat >>> to have a function like: >>> getNewLine(int num) : Returns 'num' new line characters. >> >> I was thinking about it since beginning. Fixed, and added some tests. Hurray >> - firs tunittests for >> this thing O:( >>> >>> >>> >>> String header = getFormatter().getBold("Features of NetX: ") + >>> getFormatter().getNewLine(); >>> >>> "Features of NetX: " This string should probably be localized >> >> overlooked! Fixed, and reworded as Jacob suggested. >> >>> >>> >>> +ITWintroL1={0}provides a Free Software web browser plugin running applets >>> written in the Java programming language and an implementation of Java Web >>> Start, originally based on the NetX project. >>> >>> Do you think the "Free Software" should be changed to "Free Open Source >>> Software"? >> >> Not fixed - as Jacob suggested. >>> >>> +ITWintroL3={0} also includes a plugin to {1} within web browsers. >>> >>> For this message I see in the english man page: >>> icedtea-web also includes a plugin to >>> http://www.java.com/en/download/testjava.jsp within web browsers. >>> >>> Is this replacement of {1} with http://... supposed to happen? It doesn't >>> really make sense to me. >>> >> >> Well. This is not easy task to fix. >> >> In HTML you have readable text-> hidden link. plaintext nor man support >> similar thing. >> >> So I Implemented the man/plain foramtters to simply ignore the human readable >> part, as the url is >> the real keeper of information. >> >> If this is going to be subject of change, I'm for. I have jsut lack of ideas. >> Anyway this will be different changeset, as it affects whole documentation >> >> Right now I have this foramting for plain texts urls in mind: >> human readable title (url) >> >> Thoughts? > > Hello, > > I think the format of 'human readable title : (url)' works fine! > > As for the other things, yeah different changeset. After your patches are reviewed + applied, I will look into the formatting issues with man and see if I can come up with something; > > Also, can you double-check the text file for icedtea-web (plain.../en/icedteaweb.txt) > I see on the very first line: > *** icedtea-web P_TAIL *** > If you look to previous changeset, you can see that it was fixxed here (missing double ddoalr in shell variable instead $$TP_TAIL was there only $TP_TAIL > I'm not sure what this is for;; > > Apart from that looks good to me :) > Ok. I will push once Jacob approves. TY! > > Regards, > > >> >>> >>> >>> >>> >>> In the english man page for Description I see: >>> Features of NetX: >>> >>> Modular Easily add JNLP capabilities to an application. >>> >>> Saves Memory >>> Launch programs in a shared JVM. >>> >>> Fast startup >>> Runs applications from a cache for fast starting. >>> >>> Security Run any application in a sandbox or log its activities. >>> >>> Auto-Update Applications can auto-update without special code. >>> >>> Network Deployment >>> Deploy to the internet, not with installers. >>> >>> Can you make the format consistent by making the text part always on a new >>> line? E.g: >> >> I cant! This is how program man is formatting TP command. I got this TP thing >> from our original >> pages (actually my results were 1:1 copies of those on non added lines) >> >> So - We may change to different formatting for parameters then TP, currently >> I dont know of any more >> suitable:( >> >> The TP do what it is supposed to do. It do some kind of two columns table, >> where second column have >> fixed starting point (it is declared by the number, in our case 12 everywhere >> [12 everywhere was >> also in original man pages) >> So if you look at it, you will see, that the record is put to second line, >> only where the first >> column is longer then expected width (in our case 12) >> >> Anyway.. different changeset. Suggestions welcomed! >>> Security Run any application in a sandbox or log its activities. >>> becomes >>> Security >>> Run any application in a sandbox or log its activities. >>> >>> >>> >>> >>> >>> Also the text here (from english man page) has very weird spacing: >>> >>> Visit the http://icedtea.classpath.org/wiki/Main_Page or >>> specifically the http://icedtea.class? >>> path.org/wiki/IcedTea-Web pages for more information. >>> Help with common issues with IcedTea-Web can be found >>> http://icedtea.classpath.org/wiki/IcedTea-Web#Com? >>> mon_Issues . >>> >>> I think this has to do with the formatting? I am not sure. >>> >> >> This is nearly the same issue as TP. This is what program man is doing. It >> formats the paragraphs >> to fit your terminal width, and it is trying to align justifiably both left >> and righ, but enlarging >> spaces where suitable. >> >> so "hell ouu a friend" on 4 chars wide terminall will become similar to: >> "hell" >> " ouu" >> " a" >> "frie" >> "nd" >> >> Afaik absolutely no op here. >>> >>> >>> Regards, >>> >>> ----- Original Message ----- >>>> ssia >>>> >>>> First of patches moving the individual liens to properties. Fixes to >>>> individual sentences welcomed. >>>> >>>> J. >>>> >>> >> >> >> Thanx both of yo for check! >> >> >> J. >> > From aazores at redhat.com Mon Sep 15 15:40:33 2014 From: aazores at redhat.com (Andrew Azores) Date: Mon, 15 Sep 2014 11:40:33 -0400 Subject: [rfc][icedtea-web] Move Translation Responsibility from JNLPRuntime to Translator In-Reply-To: <931268835.5056488.1410791220835.JavaMail.zimbra@redhat.com> References: <283287773.3011684.1410360674214.JavaMail.zimbra@redhat.com> <54107019.2030106@redhat.com> <1797240014.3195542.1410373862891.JavaMail.zimbra@redhat.com> <5410E9B6.2030808@redhat.com> <2058764014.3737904.1410444088683.JavaMail.zimbra@redhat.com> <5414766D.6000901@redhat.com> <931268835.5056488.1410791220835.JavaMail.zimbra@redhat.com> Message-ID: <54170871.7080905@redhat.com> On 09/15/2014 10:27 AM, Jie Kang wrote: >>> >>> I am not sure if I understood correctly but for this R(String message) do >>> you mean something like: >>> return R(message, new Object[0]) >>> >>> I prefer the other way since it's more efficient and makes more sense to me >>> hahah. Though I understand what you mean by being more natural. It's just >>> on closer inspection it seems really weird to make this call when you can >>> just use getInstance().getMessage(message); >>> >>> Is it okay if I keep it original? >> >> Sure, this definitely is not a blocker on push. I think "efficiency" >> here is a pretty weak reason though ;) it's just one extra method call, >> not very heavy. The other benefit is that if down the line somebody >> wants to add some extra validation or something, for example, then it >> only needs to be added in one of the methods, rather than both overloads. >> >> It's also a little bit confusing looking because since R(String, >> Object...) is varargs, it's actually valid to call it simply as, for >> example, R("TEST"). In this case, your varargs array just ends up being >> the empty array. So what you've done by defining both methods is >> essentially add a constraint for the varargs that it has to be of at >> least size 1, then branching into different calls to getMessage, one of >> which is actually defined in terms of the other in failure cases >> anyway... the call web is just a bit tangled is what I'm trying to say. >> But it's fine as-is regardless. > > Hello, > > Just wanted to say thanks for this explanation! I decided to go with what you suggested instead. Since the varargs case accepts 0 args, we can technically remove the function R(String message) and just have R(String message, Object ... params), no? Do you think it'd be good to remove R(String message) in this patch? > > > Regards, > Sure, post the patch at will :) Thanks, -- Andrew Azores From aazores at redhat.com Mon Sep 15 15:43:54 2014 From: aazores at redhat.com (Andrew Azores) Date: Mon, 15 Sep 2014 11:43:54 -0400 Subject: [rfc][icedtea-web] javaws.1 man page update In-Reply-To: <54147E8F.1090806@redhat.com> References: <53F8D650.5090702@redhat.com> <5409EFFB.8030504@redhat.com> <540A4B81.4090306@gmx.de> <5412D9EB.9090204@redhat.com> <54147E8F.1090806@redhat.com> Message-ID: <5417093A.2000109@redhat.com> On 09/13/2014 01:27 PM, Andrew Azores wrote: > Anyway I do think this has been taken care of now. It may still be worth > backporting at least. > Well, it turns out that that man page hasn't been updated in long enough that there's no backporting work to be done, it just cleanly applies. So, do we want to make this change in 1.5? Thanks, -- Andrew Azores From jkang at icedtea.classpath.org Mon Sep 15 15:48:02 2014 From: jkang at icedtea.classpath.org (jkang at icedtea.classpath.org) Date: Mon, 15 Sep 2014 15:48:02 +0000 Subject: /hg/icedtea-web: Moved translator responsibility from JNLPRuntim... Message-ID: changeset 1e274216ee4c in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=1e274216ee4c author: Jie Kang date: Mon Sep 15 11:42:08 2014 -0400 Moved translator responsibility from JNLPRuntime to Translator 2014-09-15 Jie Kang * netx/net/sourceforge/jnlp/runtime/Translator.java: * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java: (getMessage): moved from JNLPRuntime to Translator * netx/net/sourceforge/jnlp/runtime/TranslatorTest.java: added tests for translating using a ResourceBundle diffstat: ChangeLog | 10 + netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java | 61 +------- netx/net/sourceforge/jnlp/runtime/Translator.java | 72 +++++++++- tests/netx/unit/net/sourceforge/jnlp/runtime/TranslatorTest.java | 60 ++++++++ 4 files changed, 142 insertions(+), 61 deletions(-) diffs (316 lines): diff -r 11ebb7204bdc -r 1e274216ee4c ChangeLog --- a/ChangeLog Mon Sep 15 10:10:44 2014 -0400 +++ b/ChangeLog Mon Sep 15 11:42:08 2014 -0400 @@ -1,3 +1,13 @@ +2014-09-15 Jie Kang + + Moved translator responsibility from JNLPRuntime to Translator + * netx/net/sourceforge/jnlp/runtime/Translator.java: + * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java: + (getMessage): moved from JNLPRuntime to Translator + * netx/net/sourceforge/jnlp/runtime/TranslatorTest.java: + added tests for translating using a ResourceBundle + + 2014-09-15 Jie Kang * netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java diff -r 11ebb7204bdc -r 1e274216ee4c netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java Mon Sep 15 10:10:44 2014 -0400 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java Mon Sep 15 11:42:08 2014 -0400 @@ -16,6 +16,8 @@ package net.sourceforge.jnlp.runtime; +import static net.sourceforge.jnlp.runtime.Translator.R; + import java.awt.EventQueue; import java.io.File; import java.io.FileInputStream; @@ -35,10 +37,8 @@ import java.security.Policy; import java.security.Security; import java.text.DateFormat; -import java.text.MessageFormat; import java.util.Date; import java.util.List; -import java.util.ResourceBundle; import javax.jnlp.ServiceManager; import javax.naming.ConfigurationException; @@ -67,8 +67,8 @@ import net.sourceforge.jnlp.services.XServiceManagerStub; import net.sourceforge.jnlp.util.FileUtils; import net.sourceforge.jnlp.util.logging.JavaConsole; +import net.sourceforge.jnlp.util.logging.LogConfig; import net.sourceforge.jnlp.util.logging.OutputController; -import net.sourceforge.jnlp.util.logging.LogConfig; import sun.net.www.protocol.jar.URLJarFile; /** @@ -92,10 +92,6 @@ */ public class JNLPRuntime { - static { - loadResources(); - } - /** * java-abrt-connector can print out specific application String method, it is good to save visited urls for reproduce purposes. * For javaws we can read the destination jnlp from commandline @@ -104,9 +100,6 @@ */ private static String history = ""; - /** the localized resource strings */ - private static ResourceBundle resources; - /** the security manager */ private static JNLPSecurityManager security; @@ -231,7 +224,7 @@ //where deployment.system.config points is not readable throw new RuntimeException(getConfiguration().getLoadingException()); } - OutputController.getLogger().log(OutputController.Level.WARNING_ALL, getMessage("RConfigurationError")+": "+getConfiguration().getLoadingException().getMessage()); + OutputController.getLogger().log(OutputController.Level.WARNING_ALL, R("RConfigurationError")+": "+getConfiguration().getLoadingException().getMessage()); } KeyStores.setConfiguration(getConfiguration()); @@ -453,16 +446,16 @@ config.load(); config.copyTo(System.getProperties()); } catch (ConfigurationException ex) { - OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, Translator.R("RConfigurationError")); + OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("RConfigurationError")); //mark this exceptionas we can die on it later config.setLoadingException(ex); //to be sure - we MUST die - http://docs.oracle.com/javase/6/docs/technotes/guides/deployment/deployment-guide/properties.html }catch(Exception t){ //all exceptions are causing InstantiatizationError so this do it much more readble OutputController.getLogger().log(OutputController.Level.ERROR_ALL, t); - OutputController.getLogger().log(OutputController.Level.WARNING_ALL, Translator.R("RFailingToDefault")); + OutputController.getLogger().log(OutputController.Level.WARNING_ALL, R("RFailingToDefault")); if (!JNLPRuntime.isHeadless()){ - JOptionPane.showMessageDialog(null, getMessage("RFailingToDefault")+"\n"+t.toString()); + JOptionPane.showMessageDialog(null, R("RFailingToDefault")+"\n"+t.toString()); } //try to survive this unlikely exception config.resetToDefaults(); @@ -678,40 +671,11 @@ return indicator; } - /** - * Returns the localized resource string identified by the - * specified key. If the message is empty, a null is - * returned. - */ - public static String getMessage(String key) { - try { - String result = resources.getString(key); - if (result.length() == 0) - return null; - else - return result; - } catch (Exception ex) { - if (!key.equals("RNoResource")) - return getMessage("RNoResource", new Object[] { key }); - else - return "Missing resource: " + key; - } - } - public static String getLocalisedTimeStamp(Date timestamp) { return DateFormat.getInstance().format(timestamp); } /** - * Returns the localized resource string using the specified arguments. - * - * @param args the formatting arguments to the resource string - */ - public static String getMessage(String key, Object... args) { - return MessageFormat.format(getMessage(key), args); - } - - /** * Returns {@code true} if the current runtime will fork */ public static boolean getForksAllowed() { @@ -755,17 +719,6 @@ } /** - * Load the resources. - */ - private static void loadResources() { - try { - resources = ResourceBundle.getBundle("net.sourceforge.jnlp.resources.Messages"); - } catch (Exception ex) { - throw new IllegalStateException("Missing resource bundle in netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); - } - } - - /** * @return {@code true} if running on Windows */ public static boolean isWindows() { diff -r 11ebb7204bdc -r 1e274216ee4c netx/net/sourceforge/jnlp/runtime/Translator.java --- a/netx/net/sourceforge/jnlp/runtime/Translator.java Mon Sep 15 10:10:44 2014 -0400 +++ b/netx/net/sourceforge/jnlp/runtime/Translator.java Mon Sep 15 11:42:08 2014 -0400 @@ -16,16 +16,32 @@ package net.sourceforge.jnlp.runtime; +import java.text.MessageFormat; +import java.util.Locale; +import java.util.MissingResourceException; +import java.util.ResourceBundle; + /** * Utility class to provide simple methods to help localize messages */ -public class Translator { +public enum Translator { - /** - * @return the localized string for the message - */ - public static String R(String message, Object... params) { - return JNLPRuntime.getMessage(message, params); + INSTANCE; + + /** the localized resource strings */ + private ResourceBundle resources; + + private Translator() { + try { + resources = ResourceBundle.getBundle("net.sourceforge.jnlp.resources.Messages"); + } catch (Exception ex) { + throw new IllegalStateException("No bundles found for Locale: " + Locale.getDefault().toString() + + "and missing base resource bundle in netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); + } + } + + public static Translator getInstance() { + return Translator.INSTANCE; } /** @@ -34,7 +50,49 @@ * @return a string representing the localized message */ public static String R(String message) { - return JNLPRuntime.getMessage(message); + return R(message, new Object[0]); } + /** + * @return the localized string for the message + */ + public static String R(String message, Object... params) { + return getInstance().getMessage(message, params); + } + + protected void loadResourceBundle(ResourceBundle bundle) { + this.resources = bundle; + } + + /** + * Returns the localized resource string using the specified arguments. + * + * @param args the formatting arguments to the resource string + */ + private String getMessage(String key, Object... args) { + return MessageFormat.format(getMessage(key), args); + } + + /** + * Returns the localized resource string identified by the + * specified key. If the message is empty, a null is + * returned. + */ + private String getMessage(String key) { + try { + String result = resources.getString(key); + if (result.length() == 0) + return ""; + else + return result; + } catch (NullPointerException e) { + return getMessage("RNoResource", new Object[]{key}); + } catch (MissingResourceException | ClassCastException e) { + if (key == "RNoResource") { + return "No localized text found"; + } else { + return getMessage("RNoResource", new Object[]{key}); + } + } + } } diff -r 11ebb7204bdc -r 1e274216ee4c tests/netx/unit/net/sourceforge/jnlp/runtime/TranslatorTest.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/netx/unit/net/sourceforge/jnlp/runtime/TranslatorTest.java Mon Sep 15 11:42:08 2014 -0400 @@ -0,0 +1,60 @@ +package net.sourceforge.jnlp.runtime; + +import static org.junit.Assert.assertEquals; + +import java.io.File; +import java.io.FileOutputStream; +import java.io.IOException; +import java.net.URL; +import java.net.URLClassLoader; +import java.util.Locale; +import java.util.ResourceBundle; + +import org.junit.Before; +import org.junit.Test; + +public class TranslatorTest { + + @Before + public void setup() throws IOException { + File f = new File(System.getProperty("java.io.tmpdir"), "test.properties"); + f.createNewFile(); + f.deleteOnExit(); + + FileOutputStream fos = new FileOutputStream(f); + String message = "key=value\n" + + "argkey=value {0}\n" + + "RNoResource=no-resource\n"; + fos.write(message.getBytes()); + + URL u = f.getParentFile().toURI().toURL(); + ClassLoader loader = new URLClassLoader(new URL[] {u}); + + ResourceBundle bundle = ResourceBundle.getBundle("test", Locale.getDefault(), loader); + Translator.getInstance().loadResourceBundle(bundle); + } + + @Test + public void testTranslateNonExistingMessage() { + String message = Translator.R("doesn't-exist"); + assertEquals("no-resource", message); + } + + @Test + public void testTranslateNullMessage() { + String message = Translator.R(null); + assertEquals("no-resource", message); + } + + @Test + public void testTranslateMessage() { + String message = Translator.R("key"); + assertEquals("value", message); + } + + @Test + public void testTranslateMessageWithArgs() { + String message = Translator.R("argkey", new Object[] {"Hello"}); + assertEquals("value Hello", message); + } +} From ldracz at redhat.com Mon Sep 15 16:39:15 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Mon, 15 Sep 2014 12:39:15 -0400 (EDT) Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <5412D841.4020104@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> <540F27F6.4050602@redhat.com> <1887532824.2369149.1410286878320.JavaMail.zimbra@redhat.com> <1467651074.2470228.1410293867916.JavaMail.zimbra@redhat.com> <5410777C.6070506@redhat.com> <854154890.3936468.1410464305025.JavaMail.zimbra@redhat.com> <5412D841.4020104@redhat.com> Message-ID: <1128387955.5149807.1410799155448.JavaMail.zimbra@redhat.com> Hello, > > > > - String key = props[i].substring(0, equals); > > - String value = props[i].substring(equals + 1, > > props[i].length()); > > + String key = input.split("=")[0]; > > + String value = input.split("=")[1]; > > > Unluckily the behaviour changed here. What if vale contains equals chat to? > > Please keep prevoius indexOf approach:( Okay, changed back to indexOf approach > > - ParserSettings settings = > > ParserSettings.setGlobalParserSettingsFromArgs(args); > > + ParserSettings settings = new > > ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT), > > true, !optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); > > + ParserSettings.setGlobalParserSettings(settings); > > Please hide those two lines. Okay > add > public whatever setGlobalParserSettingsFromOptionParser(Optionparser > optionParser){ > ParserSettings settings = new > ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT), > true, > !optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); > this.setGlobalParserSettings(settings); > > } > > in ParserSettings > > and here call setGlobalParserSettingsFromOptionParser(optionParser) > only > > Consequentially return (modified) the rmeoved test. Test is back and added one more test as well. > > If you fulfill all nits above, please add also chnagelog in next iteration. I > believe it will be > last one.. Otherwise we both grow old and turn gray before it is finish. Okay added the ChangeLog. Also I reworked findMainArg method, before it would choose the first value without a dash from the last args, which does not make sense now that we accept arguments with/without dashes. Now it checks for the last value that is not an option or does not have an option right before it that takes OneArgument / OneOrMoreArguments. My reasoning for this is if you have for ex. 'command -arg green blue File.jnlp -update 25' we know update only takes one argument so we know 25 is not the user's main argument but File.jnlp is since blue is not an option. Also for ex. 'command -arg green blue File.jnlp -arg yellow' I figured we know arg takes one or more arguments but if it has exactly one argument then it is intentional by the user so in this case File.jnlp is found as the main arg instead of yellow. However if the user does 'command -arg green blue File.jnlp -arg yellow red' then the parser will use red as the main argument which I think is okay and the user should specify in this case either by putting File.jnlp after red or -jnlp infront of File.jnlp. Also added four unit tests to OptionParserTest to make sure this is working as intended. > Also remember, your next task is to port ITWsettings and polieditor to use > this class. Yes, I have been looking at how ITWsettings does its parsing and will probably tackle this one next and PolicyEditor after. > Looking forward to have this in! > J. > Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: optionParser-20.patch Type: text/x-patch Size: 52598 bytes Desc: not available URL: From ldracz at redhat.com Mon Sep 15 18:13:28 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Mon, 15 Sep 2014 14:13:28 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] Improve IcedTea-Web cache disk space In-Reply-To: <5414BE62.5040804@gmx.de> References: <319590383.4051363.1404829211485.JavaMail.zimbra@redhat.com> <809710797.550417.1409855988786.JavaMail.zimbra@redhat.com> <750048683.1852863.1410198359663.JavaMail.zimbra@redhat.com> <1288205202.1878651.1410201515944.JavaMail.zimbra@redhat.com> <5411BAAC.9050204@gmx.de> <349509496.4004554.1410467155409.JavaMail.zimbra@redhat.com> <5414BE62.5040804@gmx.de> Message-ID: <1354468912.5195808.1410804808968.JavaMail.zimbra@redhat.com> Hello, > I am sorry, but we have run into a misunderstanding here. :-\ My comment was > not > meant to remove /all/ html tags. What I meant was that the html tags should > be > only removed from those messages which do not actually require HTML features. > So, to be specific this time: TIFPCacheSizeSpinnerLargeValueWarning, > TIFPCacheSizeSetToNoCaching, and TIFPCacheSizeSpinnerTooltip only. Ah okay, sorry for misunderstanding. > diff -r e30d71ab91c6 > netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java > --- a/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java > Wed Sep 10 10:22:46 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java > Thu Sep 11 16:15:11 2014 -0400 > [...] > @@ -402,10 +401,11 @@ > cacheSizeWarningLabel.setEnabled(bool); > > if(bool == false) { > + cacheSizeSpinner.setToolTipText(null); > > cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSpinnerLargeValueWarning", > usableDiskSpace)); > } else { > > - final long cacheSizeSpinnerValue = (long) > cacheSizeSpinner.getValue(); > + > cacheSizeSpinner.setToolTipText(Translator.R("TIFPCacheSizeSpinnerTooltip", > CACHE_MIN_SIZE, CACHE_MAX_SIZE)); final long cacheSizeSpinnerValue > = > (long) cacheSizeSpinner.getValue(); > > Please check formatting here. I assume that the declaration and > initialization > statement of "cacheSizeSpinnerValue" was intended to be on a line of its own, > after the "cacheSizeSpinner.setToolTipText()" statement. Good catch ! > After fixing this stuff, I think it is okay to push. :-) > > Jacob > I pushed with the changes you suggested. Thanks for the review and the catch :) ! Regards, Lukasz Dracz From rjdkolb at gmail.com Mon Sep 15 19:15:48 2014 From: rjdkolb at gmail.com (Richard Kolb) Date: Mon, 15 Sep 2014 21:15:48 +0200 Subject: Icedtea Zero Arm modifications Message-ID: Hello, I am doing a presentation using Icedtea on an Arm processor (Pcduino 3) at Software freedom day. Can anyone tell me what modifications Icedtea has to the Zero JVM in the OpenJDK. I heard a rumor that it outputs Thumb 2 instructions. Thanks, Richard. -------------- next part -------------- An HTML attachment was scrubbed... URL: From aph at redhat.com Mon Sep 15 19:21:12 2014 From: aph at redhat.com (Andrew Haley) Date: Mon, 15 Sep 2014 20:21:12 +0100 Subject: Icedtea Zero Arm modifications In-Reply-To: References: Message-ID: <54173C28.6090609@redhat.com> On 09/15/2014 08:15 PM, Richard Kolb wrote: > I am doing a presentation using Icedtea on an Arm processor (Pcduino 3) at > Software freedom day. > > Can anyone tell me what modifications Icedtea has to the Zero JVM in the > OpenJDK. > I heard a rumor that it outputs Thumb 2 instructions. It does, yes. We have a little JIT in there which generates reasonable code. We also have an interpreter written in ARM assembly language. Andrew. From rjdkolb at gmail.com Mon Sep 15 19:32:03 2014 From: rjdkolb at gmail.com (Richard Kolb) Date: Mon, 15 Sep 2014 21:32:03 +0200 Subject: Icedtea Zero Arm modifications In-Reply-To: <54173C28.6090609@redhat.com> References: <54173C28.6090609@redhat.com> Message-ID: Hi Andrew, On 15 September 2014 21:21, Andrew Haley wrote: > On 09/15/2014 08:15 PM, Richard Kolb wrote: > > I am doing a presentation using Icedtea on an Arm processor (Pcduino 3) > at > > Software freedom day. > > > > Can anyone tell me what modifications Icedtea has to the Zero JVM in the > > OpenJDK. > > I heard a rumor that it outputs Thumb 2 instructions. > > It does, yes. We have a little JIT in there which generates reasonable > code. > > We also have an interpreter written in ARM assembly language. > Thanks very much. I see it easily out performs JamVM using JMH. Do you have any kind of docs about the JIT ? thanks, Richard. > > Andrew. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 15 19:42:14 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 15 Sep 2014 19:42:14 +0000 Subject: [Bug 1998] icedtea crash in atlassian-confluence-5.4.2 (wiki) In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1998 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Hardware|64-bit |x86_64 Version|6-hg |unspecified Resolution|--- |WONTFIX --- Comment #1 from Andrew John Hughes --- This version (1.10.9) is very outdated and no longer supported. Please re-open if this bug can be replicated with the latest 1.13.4 release. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From aph at redhat.com Tue Sep 16 07:51:43 2014 From: aph at redhat.com (Andrew Haley) Date: Tue, 16 Sep 2014 08:51:43 +0100 Subject: Icedtea Zero Arm modifications In-Reply-To: References: <54173C28.6090609@redhat.com> Message-ID: <5417EC0F.6050905@redhat.com> On 15/09/14 20:32, Richard Kolb wrote: > Do you have any kind of docs about the JIT ? Not much https://archive.fosdem.org/2010/schedule/speakers/edward+nevill.html From rjdkolb at gmail.com Tue Sep 16 07:57:50 2014 From: rjdkolb at gmail.com (Richard Kolb) Date: Tue, 16 Sep 2014 09:57:50 +0200 Subject: Icedtea Zero Arm modifications In-Reply-To: <5417EC0F.6050905@redhat.com> References: <54173C28.6090609@redhat.com> <5417EC0F.6050905@redhat.com> Message-ID: On 16 Sep 2014 09:51, "Andrew Haley" wrote: > > On 15/09/14 20:32, Richard Kolb wrote: > > Do you have any kind of docs about the JIT ? > > Not much > > https://archive.fosdem.org/2010/schedule/speakers/edward+nevill.html This is perfect. Thanks Andrew. -------------- next part -------------- An HTML attachment was scrubbed... URL: From xerxes at zafena.se Tue Sep 16 08:47:15 2014 From: xerxes at zafena.se (=?UTF-8?B?WGVyeGVzIFLDpW5ieQ==?=) Date: Tue, 16 Sep 2014 10:47:15 +0200 Subject: Icedtea Zero Arm modifications In-Reply-To: References: <54173C28.6090609@redhat.com> <5417EC0F.6050905@redhat.com> Message-ID: <5417F913.4000602@zafena.se> Den 2014-09-16 09:57, Richard Kolb skrev: > > On 16 Sep 2014 09:51, "Andrew Haley" > wrote: > > > > On 15/09/14 20:32, Richard Kolb wrote: > > > Do you have any kind of docs about the JIT ? > > > > Not much > > > > https://archive.fosdem.org/2010/schedule/speakers/edward+nevill.html > > This is perfect. Thanks Andrew. > Documentation for the Zero ARM assembler interpreter was documented on Edwards Cambridge Software Labs OpenJDK page, www.camswl.com/openjdk , that is now defunct. A copy of the introduction text from Edwards page is still available: http://www.linux-arm.org/LinuxReference/OpenJDKPage The documentation of mkbc the Bytecode Interpreter Generator is archived by the Internet archive wayback machine: https://web.archive.org/web/20110125193830/http://www.camswl.com/openjdk/mkbc.htm Rod Crawford of ARM documented in 2010 the reasoning why the port got funded, part 2 covers the Thumb2 JIT. http://community.arm.com/groups/smart-and-connected/blog/2010/04/15/how-do-you-make-java-fast-answer-go-down-the-pub http://community.arm.com/groups/smart-and-connected/blog/2010/05/06/how-do-you-make-java-fast-answer-go-down-the-pub-part-2 Cheers Xerxes -------------- next part -------------- An HTML attachment was scrubbed... URL: From rjdkolb at gmail.com Tue Sep 16 09:03:35 2014 From: rjdkolb at gmail.com (Richard Kolb) Date: Tue, 16 Sep 2014 11:03:35 +0200 Subject: Icedtea Zero Arm modifications In-Reply-To: <5417F913.4000602@zafena.se> References: <54173C28.6090609@redhat.com> <5417EC0F.6050905@redhat.com> <5417F913.4000602@zafena.se> Message-ID: Nice, will go though the material. Thanks Xerxes. On 16 Sep 2014 10:47, "Xerxes R?nby" wrote: > Den 2014-09-16 09:57, Richard Kolb skrev: > > On 16 Sep 2014 09:51, "Andrew Haley" wrote: > > > > On 15/09/14 20:32, Richard Kolb wrote: > > > Do you have any kind of docs about the JIT ? > > > > Not much > > > > https://archive.fosdem.org/2010/schedule/speakers/edward+nevill.html > > This is perfect. Thanks Andrew. > > > Documentation for the Zero ARM assembler interpreter was documented on > Edwards Cambridge Software Labs OpenJDK page, www.camswl.com/openjdk , > that is now defunct. > A copy of the introduction text from Edwards page is still available: > http://www.linux-arm.org/LinuxReference/OpenJDKPage > The documentation of mkbc the Bytecode Interpreter Generator is archived > by the Internet archive wayback machine: > > https://web.archive.org/web/20110125193830/http://www.camswl.com/openjdk/mkbc.htm > > Rod Crawford of ARM documented in 2010 the reasoning why the port got > funded, part 2 covers the Thumb2 JIT. > > http://community.arm.com/groups/smart-and-connected/blog/2010/04/15/how-do-you-make-java-fast-answer-go-down-the-pub > > http://community.arm.com/groups/smart-and-connected/blog/2010/05/06/how-do-you-make-java-fast-answer-go-down-the-pub-part-2 > > Cheers > Xerxes > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Tue Sep 16 13:32:19 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 16 Sep 2014 15:32:19 +0200 Subject: [rfc][icedtea-web] fix the empty string in codebase Message-ID: <54183BE3.40801@redhat.com> I have recently encountered an app, which failed to run, because of malformed jnlp. They had codebase="" and apparently wonted to have ".". Afaik ITW should work around this (oracle plugin does :( ) This patch is handling the "" for codebase as it was "." The app failed for me in alaca dialogue on NPE, teh patch contains small workaround around possible NPE here too + unittest to affected method ok for head? 1.5? Accordingly with investigating this failure, I have enhanced http://icedtea.classpath.org/wiki/IcedTea-Web#Filing_bugs for offline debugging. Volunteer for reproducer?-) Thanx, J. -------------- next part -------------- A non-text attachment was scrubbed... Name: emptyCodebaseFixAndalacaNPEworkarround.patch Type: text/x-patch Size: 4440 bytes Desc: not available URL: From jvanek at redhat.com Tue Sep 16 14:43:58 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 16 Sep 2014 16:43:58 +0200 Subject: [rfc][icedtea-web] javaws.1 man page update In-Reply-To: <5417093A.2000109@redhat.com> References: <53F8D650.5090702@redhat.com> <5409EFFB.8030504@redhat.com> <540A4B81.4090306@gmx.de> <5412D9EB.9090204@redhat.com> <54147E8F.1090806@redhat.com> <5417093A.2000109@redhat.com> Message-ID: <54184CAE.5090002@redhat.com> On 09/15/2014 05:43 PM, Andrew Azores wrote: > On 09/13/2014 01:27 PM, Andrew Azores wrote: >> Anyway I do think this has been taken care of now. It may still be worth >> backporting at least. >> > > Well, it turns out that that man page hasn't been updated in long enough that there's no backporting > work to be done, it just cleanly applies. So, do we want to make this change in 1.5? > > Thanks, Well yes, feel free to push. When you are in it, please add -Xoffline param. Its was forgotten:( From gitne at gmx.de Tue Sep 16 18:25:54 2014 From: gitne at gmx.de (Jacob Wisor) Date: Tue, 16 Sep 2014 20:25:54 +0200 Subject: [rfc][icedtea-web] fix the empty string in codebase In-Reply-To: <54183BE3.40801@redhat.com> References: <54183BE3.40801@redhat.com> Message-ID: <541880B2.205@gmx.de> On 09/16/2014 at 03:32 PM, Jiri Vanek wrote: > I have recently encountered an app, which failed to run, because of malformed > jnlp. They had codebase="" and apparently wonted to have ".". Afaik ITW should > work around this (oracle plugin does :( ) This patch is handling the "" for > codebase as it was "." Yeah, too bad Oracle's plug-in accepts this sort of "URL" because it is actually invalid. :-( An empty string URL is actually not equal nor equivalent to a missing attribute (null string). I suppose Oracle's plug-in turns those URLs into File objects internally... > The app failed for me in alaca dialogue on NPE, teh patch contains small > workaround around possible NPE here too + unittest to affected method > > ok for head? 1.5? > > > Accordingly with investigating this failure, I have enhanced > http://icedtea.classpath.org/wiki/IcedTea-Web#Filing_bugs for offline debugging. > > Volunteer for reproducer?-) > > Thanx, > J. > diff -r d8e057783109 netx/net/sourceforge/jnlp/Parser.java > --- a/netx/net/sourceforge/jnlp/Parser.java Mon Sep 15 14:09:30 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/Parser.java Tue Sep 16 15:25:44 2014 +0200 > @@ -1065,10 +1065,21 @@ > * @throws ParseException if the JNLP file is invalid > */ > public URL getURL(Node node, String name, URL base) throws ParseException { > - String href = getAttribute(node, name, null); > - if (href == null) > + String href = null; > + if ("codebase".equals(name)) { Hmm, strange that the JNLP parser does not have an enum of or a /list/ of valid JNLP element and attribute name constants. > + href = getCleanAttribute(node, name); > + if (href != null) {// so that code can throw an exceptionlater > + //some bogus jnlps have codebase as "" and expect it behaving as "." > + if (href.trim().isEmpty()) { Try "href != null && href.trim().isEmpty()". ;-) It can be even further optimized into one statement. > + href = "."; > + } > + } > + } else { > + href = getAttribute(node, name, null); > + } > + if (href == null) { > return null; // so that code can throw an exception if attribute was required > - > + } > try { > if (base == null) > return new URL(href); > @@ -1254,11 +1265,17 @@ > public String getAttribute(Node node, String name, String defaultValue) { > // SAX > // String result = ((Element) node).getAttribute(name); > + String result = getCleanAttribute(node, name); > + > + if (result == null || result.length() == 0) { > + return defaultValue; I am not sure this is correct at all. What if an attribute was intended to accept an empty string? The default value actually depends on the particular attribute's semantics. As I said before, a missing attribute equates to null and thus always to a default value. An empty string value equates either to a default value or /the/ empty string value, depending on the attribute's semantics. > + } > + > + return result; > + } > + > + public String getCleanAttribute(Node node, String name) { Err, what is a clean attribute? Did it wash before? :-D So, please check your naming. Besides, documentation is missing on a public method. And, judging by what it seems to be doing maybe it should be even private. > String result = node.getAttribute(name); > - > - if (result == null || result.length() == 0) > - return defaultValue; > - > return result; > } > > diff -r d8e057783109 netx/net/sourceforge/jnlp/security/SecurityDialogs.java > --- a/netx/net/sourceforge/jnlp/security/SecurityDialogs.java Mon Sep 15 14:09:30 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/security/SecurityDialogs.java Tue Sep 16 15:25:44 2014 +0200 > @@ -44,6 +44,8 @@ > import java.net.URL; > import java.security.AccessController; > import java.security.PrivilegedAction; > +import java.util.Arrays; > +import java.util.Comparator; > import java.util.Set; > import java.util.concurrent.Semaphore; > > @@ -285,7 +287,13 @@ > > SecurityDialogMessage message = new SecurityDialogMessage(); > message.dialogType = DialogType.MISSING_ALACA; > - message.extras = new Object[]{title, codeBase.toString(), UrlUtils.setOfUrlsToHtmlList(remoteUrls)}; > + String urlToShow = "unknown url"; > + if (codeBase != null) { > + urlToShow = codeBase.toString(); > + } else { > + OutputController.getLogger().log("Warning, null codebase wants to show in ALACA!"); > + } Formatting. > + message.extras = new Object[]{title, urlToShow, UrlUtils.setOfUrlsToHtmlList(remoteUrls)}; > Object selectedValue = getUserResponse(message); > return getIntegerResponseAsBoolean(selectedValue); > } > diff -r d8e057783109 tests/netx/unit/net/sourceforge/jnlp/ParserTest.java > --- a/tests/netx/unit/net/sourceforge/jnlp/ParserTest.java Mon Sep 15 14:09:30 2014 -0400 > +++ b/tests/netx/unit/net/sourceforge/jnlp/ParserTest.java Tue Sep 16 15:25:44 2014 +0200 > @@ -1413,4 +1413,30 @@ > > Assert.assertEquals(overwrittenCodebase.toExternalForm(), parser.getCodeBase().toExternalForm()); > } > + > + > + @Test > + public void testEmptyCodebase() throws Exception { > + String data = "\n" > + + " + + "codebase=\"\" aaa=\"\" " > + + ">\n" > + + ""; Although this is technically not wrong, it could probably go into a .jnlp file, just for clarity and maintainability. > + > + Node root = Parser.getRootNode(new ByteArrayInputStream(data.getBytes()), defaultParser); > + Assert.assertEquals("Root name is not jnlp", "jnlp", root.getNodeName()); > + MockJNLPFile file = new MockJNLPFile(LANG_LOCALE); > + Parser parser = new Parser(file, null, root, defaultParser, null); > + ParseException eex = null; > + //non codebase element is unaffected > + URL u = parser.getURL(root, "aaa", null); > + Assert.assertEquals(null, u); > + try { > + parser.getURL(root, "codebase", null); > + } catch (ParseException ex) { > + eex = ex; > + } > + Assert.assertEquals(true, eex != null); > + Assert.assertEquals(true, eex instanceof ParseException); > + } > } From jkang at redhat.com Tue Sep 16 20:36:12 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 16 Sep 2014 16:36:12 -0400 (EDT) Subject: [rfc][icedtea-web] Makefile Reproducer Tests Patch In-Reply-To: <1037617511.6139579.1410899535560.JavaMail.zimbra@redhat.com> Message-ID: <2099979744.6142171.1410899772899.JavaMail.zimbra@redhat.com> Hello, This patch modifies the makefile and causes it to only process (compile, copy, etc.) tests in the whitelist. This feature is greatly beneficial when running say 'make run-netx-dist-tests' which uses the whitelist to only run tests in the whitelist. Prior to this patch, though the tests ran were filtered by the whitelist, all tests were processed (compiled, resources moved, etc.). This wastes a large amount of time processing tests that aren't run. Thoughts? Regards. -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-makefile-reproducer.patch Type: text/x-patch Size: 1972 bytes Desc: not available URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 22:21:08 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 22:21:08 +0000 Subject: [Bug 2000] New: [IcedTea7] Synchronise HEAD tarball paths with release branch paths Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2000 Bug ID: 2000 Summary: [IcedTea7] Synchronise HEAD tarball paths with release branch paths Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org Pre-release versions should look for their tarballs in the same location as the final release. This includes HEAD, so if 2.6.0 is being developed on HEAD prior to branching, it should obtain drops from: http://icedtea.classpath.org/download/drops/icedtea7/2.6.0 This keeps the HEAD and branch Makefiles in sync and simplifies logic in distribution packages. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 22:28:32 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 22:28:32 +0000 Subject: [Bug 2000] [IcedTea7] Synchronise HEAD tarball paths with release branch paths In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2000 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 22:29:39 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 22:29:39 +0000 Subject: [Bug 2001] New: [IcedTea8] Synchronise HEAD tarball paths with release branch paths Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2001 Bug ID: 2001 Summary: [IcedTea8] Synchronise HEAD tarball paths with release branch paths Product: IcedTea Version: 8-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org Pre-release versions should look for their tarballs in the same location as the final release. This includes HEAD, so if 3.0.0 is being developed on HEAD prior to branching, it should obtain drops from: http://icedtea.classpath.org/download/drops/icedtea8/3.0.0 This keeps the HEAD and branch Makefiles in sync and simplifies logic in distribution packages. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 22:29:53 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 22:29:53 +0000 Subject: [Bug 2001] [IcedTea8] Synchronise HEAD tarball paths with release branch paths In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2001 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Blocks| |1282 Target Milestone|--- |3.0.0 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 22:29:53 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 22:29:53 +0000 Subject: [Bug 1282] [TRACKER] IcedTea 3.0.0 Release In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1282 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |2001 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Tue Sep 16 22:39:53 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 16 Sep 2014 22:39:53 +0000 Subject: /hg/icedtea7: PR2000: Synchronise HEAD tarball paths with releas... Message-ID: changeset 45cfef3d9a3a in /hg/icedtea7 details: http://icedtea.classpath.org/hg/icedtea7?cmd=changeset;node=45cfef3d9a3a author: Andrew John Hughes date: Tue Sep 16 23:38:31 2014 +0100 PR2000: Synchronise HEAD tarball paths with release branch paths 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Include release in path to match release branches. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. Add a trailing zero to the first release (2.6.0 instead of 2.6). * hotspot.map.in: ... here so the URL can be generated using the release version. diffstat: ChangeLog | 16 ++++++++++++++++ Makefile.am | 2 +- NEWS | 1 + acinclude.m4 | 11 +++++++++++ configure.ac | 5 ++++- hotspot.map | 3 --- hotspot.map.in | 3 +++ 7 files changed, 36 insertions(+), 5 deletions(-) diffs (97 lines): diff -r d93bc33e8bd5 -r 45cfef3d9a3a ChangeLog --- a/ChangeLog Sat Sep 13 16:37:31 2014 +0100 +++ b/ChangeLog Tue Sep 16 23:38:31 2014 +0100 @@ -1,3 +1,19 @@ +2014-09-16 Andrew John Hughes + + * hotspot.map: Moved to... + * Makefile.am: + (ICEDTEA_URL): Include release in path to match + release branches. + * NEWS: Updated. + * acinclude.m4: + (IT_DETERMINE_VERSION): Obtain branch and release + version automatically from package version. + * configure.ac: Call IT_DETERMINE_VERSION and + generate hotspot.map. Add a trailing zero to the + first release (2.6.0 instead of 2.6). + * hotspot.map.in: ... here so the URL can be + generated using the release version. + 2014-09-12 Andrew John Hughes * Makefile.am, diff -r d93bc33e8bd5 -r 45cfef3d9a3a Makefile.am --- a/Makefile.am Sat Sep 13 16:37:31 2014 +0100 +++ b/Makefile.am Tue Sep 16 23:38:31 2014 +0100 @@ -35,7 +35,7 @@ ICEDTEA_MAJOR = icedtea7 ICEDTEA_PREFIX = $(ICEDTEA_MAJOR)-forest ICEDTEA_HG_URL = http://icedtea.classpath.org/hg/$(ICEDTEA_PREFIX) -ICEDTEA_URL = $(DROP_URL)/$(ICEDTEA_MAJOR) +ICEDTEA_URL = $(DROP_URL)/$(ICEDTEA_MAJOR)/$(ICEDTEA_RELEASE) HS_TYPE = "`$(AWK) 'version==$$1 {print $$2}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" HS_URL = "`$(AWK) 'version==$$1 {print $$3}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" diff -r d93bc33e8bd5 -r 45cfef3d9a3a NEWS --- a/NEWS Sat Sep 13 16:37:31 2014 +0100 +++ b/NEWS Tue Sep 16 23:38:31 2014 +0100 @@ -200,6 +200,7 @@ - PR1988: C++ Interpreter should no longer be used on ppc64 - PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose - PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 + - PR2000: Synchronise HEAD tarball paths with release branch paths New in release 2.5.2 (2014-08-29): diff -r d93bc33e8bd5 -r 45cfef3d9a3a acinclude.m4 --- a/acinclude.m4 Sat Sep 13 16:37:31 2014 +0100 +++ b/acinclude.m4 Tue Sep 16 23:38:31 2014 +0100 @@ -2835,3 +2835,14 @@ esac AC_MSG_RESULT([$has_native_hotspot_port]) ]) + +AC_DEFUN_ONCE([IT_DETERMINE_VERSION], +[ + AC_MSG_CHECKING([which branch and release of IcedTea is being built]) + ICEDTEA_RELEASE=$(echo ${PACKAGE_VERSION} | sed 's#pre.*##') + ICEDTEA_BRANCH=$(echo ${ICEDTEA_RELEASE}|sed 's|\.[[0-9]]$||') + AC_MSG_RESULT([branch ${ICEDTEA_BRANCH}, release ${ICEDTEA_RELEASE}]) + AC_SUBST([ICEDTEA_RELEASE]) + AC_SUBST([ICEDTEA_BRANCH]) +]) + diff -r d93bc33e8bd5 -r 45cfef3d9a3a configure.ac --- a/configure.ac Sat Sep 13 16:37:31 2014 +0100 +++ b/configure.ac Tue Sep 16 23:38:31 2014 +0100 @@ -1,4 +1,4 @@ -AC_INIT([icedtea], [2.6pre08], [distro-pkg-dev at openjdk.java.net]) +AC_INIT([icedtea], [2.6.0pre08], [distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AM_MAINTAINER_MODE([enable]) AC_CONFIG_FILES([Makefile]) @@ -12,6 +12,9 @@ cd $abs_top_builddir AC_SUBST(abs_top_srcdir) +IT_DETERMINE_VERSION +AC_CONFIG_FILES([hotspot.map]) + AC_CANONICAL_HOST AC_PREFIX_DEFAULT([bootstrap]) diff -r d93bc33e8bd5 -r 45cfef3d9a3a hotspot.map --- a/hotspot.map Sat Sep 13 16:37:31 2014 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -# version type(drop/hg) url changeset sha256sum -default drop http://icedtea.classpath.org/download/drops/icedtea7 6d5ec408f4ca 569f1529b900fc52435da4aa2f06f5697fe61459ed2962fc39a21e392d431206 -aarch64 hg http://hg.openjdk.java.net/aarch64-port/jdk7u/hotspot f50993b6c38d 64c2d0bfa71d6eecf18ab28fd64d5bd79af096f77548d80de7953c306fd9c22c diff -r d93bc33e8bd5 -r 45cfef3d9a3a hotspot.map.in --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/hotspot.map.in Tue Sep 16 23:38:31 2014 +0100 @@ -0,0 +1,3 @@ +# version type(drop/hg) url changeset sha256sum +default drop http://icedtea.classpath.org/download/drops/icedtea7/@ICEDTEA_RELEASE@ 6d5ec408f4ca 569f1529b900fc52435da4aa2f06f5697fe61459ed2962fc39a21e392d431206 +aarch64 hg http://hg.openjdk.java.net/aarch64-port/jdk7u/hotspot f50993b6c38d 64c2d0bfa71d6eecf18ab28fd64d5bd79af096f77548d80de7953c306fd9c22c From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 22:40:04 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 22:40:04 +0000 Subject: [Bug 2000] [IcedTea7] Synchronise HEAD tarball paths with release branch paths In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2000 --- Comment #1 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7?cmd=changeset;node=45cfef3d9a3a author: Andrew John Hughes date: Tue Sep 16 23:38:31 2014 +0100 PR2000: Synchronise HEAD tarball paths with release branch paths 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Include release in path to match release branches. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. Add a trailing zero to the first release (2.6.0 instead of 2.6). * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 23:15:06 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 23:15:06 +0000 Subject: [Bug 2002] New: [IcedTea7] Fix references to hotspot.map following PR2000 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2002 Bug ID: 2002 Summary: [IcedTea7] Fix references to hotspot.map following PR2000 Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org gawk: fatal: cannot open file `/usr/local/build/buildslave/icedtea/icedtea7-quick/build/../src/hotspot.map' for reading (No such file or directory) /usr/bin/sha256sum: standard input: no properly formatted SHA256 checksum lines found gawk: fatal: cannot open file `/usr/local/build/buildslave/icedtea/icedtea7-quick/build/../src/hotspot.map' for reading (No such file or directory) gawk: fatal: cannot open file `/usr/local/build/buildslave/icedtea/icedtea7-quick/build/../src/hotspot.map' for reading (No such file or directory) /hotspot.tar.bz2: Scheme missing. gawk: fatal: cannot open file `/usr/local/build/buildslave/icedtea/icedtea7-quick/build/../src/hotspot.map' for reading (No such file or directory) /usr/bin/sha256sum: standard input: no properly formatted SHA256 checksum lines found ERROR: Bad download of HotSpot zip http://builder.classpath.org/icedtea/buildbot/builders/icedtea7-wheezy-x86_64-quick/builds/204/steps/compile/logs/stdio -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 23:15:34 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 23:15:34 +0000 Subject: [Bug 2002] [IcedTea7] Fix references to hotspot.map following PR2000 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2002 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Target Milestone|--- |2.5.3 --- Comment #1 from Andrew John Hughes --- hotspot.map is now generated and so lives in the build directory. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Tue Sep 16 23:20:28 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 16 Sep 2014 23:20:28 +0000 Subject: /hg/icedtea7: PR2002: Fix references to hotspot.map following PR... Message-ID: changeset 17d957f63b11 in /hg/icedtea7 details: http://icedtea.classpath.org/hg/icedtea7?cmd=changeset;node=17d957f63b11 author: Andrew John Hughes date: Wed Sep 17 00:18:09 2014 +0100 PR2002: Fix references to hotspot.map following PR2000 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. diffstat: ChangeLog | 12 ++++++++++++ Makefile.am | 11 +++++------ NEWS | 1 + 3 files changed, 18 insertions(+), 6 deletions(-) diffs (58 lines): diff -r 45cfef3d9a3a -r 17d957f63b11 ChangeLog --- a/ChangeLog Tue Sep 16 23:38:31 2014 +0100 +++ b/ChangeLog Wed Sep 17 00:18:09 2014 +0100 @@ -1,3 +1,15 @@ +2014-09-16 Andrew John Hughes + + * Makefile.am: + (HS_TYPE): Fix hotspot.map path. + (HS_URL): Likewise. + (HS_CHANGESET): Likewise. + (HS_SHA256SUM): Likewise. + (EXTRA_DIST): Remove hotspot.map. + hotspot.map.in is automatically added + by autoconf. + * NEWS: Updated. + 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... diff -r 45cfef3d9a3a -r 17d957f63b11 Makefile.am --- a/Makefile.am Tue Sep 16 23:38:31 2014 +0100 +++ b/Makefile.am Wed Sep 17 00:18:09 2014 +0100 @@ -37,10 +37,10 @@ ICEDTEA_HG_URL = http://icedtea.classpath.org/hg/$(ICEDTEA_PREFIX) ICEDTEA_URL = $(DROP_URL)/$(ICEDTEA_MAJOR)/$(ICEDTEA_RELEASE) -HS_TYPE = "`$(AWK) 'version==$$1 {print $$2}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" -HS_URL = "`$(AWK) 'version==$$1 {print $$3}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" -HS_CHANGESET = "`$(AWK) 'version==$$1 {print $$4}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" -HS_SHA256SUM = "`$(AWK) 'version==$$1 {print $$5}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" +HS_TYPE = "`$(AWK) 'version==$$1 {print $$2}' version=$(HSBUILD) $(abs_top_builddir)/hotspot.map`" +HS_URL = "`$(AWK) 'version==$$1 {print $$3}' version=$(HSBUILD) $(abs_top_builddir)/hotspot.map`" +HS_CHANGESET = "`$(AWK) 'version==$$1 {print $$4}' version=$(HSBUILD) $(abs_top_builddir)/hotspot.map`" +HS_SHA256SUM = "`$(AWK) 'version==$$1 {print $$5}' version=$(HSBUILD) $(abs_top_builddir)/hotspot.map`" # Build directories @@ -741,8 +741,7 @@ $(top_srcdir)/patches/hotspot/*/*.patch \ tools-copy contrib overlays \ jconsole.desktop policytool.desktop \ - $(JTREG_SRCS) HACKING fsg.sh \ - hotspot.map autogen.sh \ + $(JTREG_SRCS) HACKING fsg.sh autogen.sh \ tapset/hotspot.stp.in \ tapset/hotspot_jni.stp.in \ tapset/jstack.stp.in \ diff -r 45cfef3d9a3a -r 17d957f63b11 NEWS --- a/NEWS Tue Sep 16 23:38:31 2014 +0100 +++ b/NEWS Wed Sep 17 00:18:09 2014 +0100 @@ -201,6 +201,7 @@ - PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose - PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 - PR2000: Synchronise HEAD tarball paths with release branch paths + - PR2002: Fix references to hotspot.map following PR2000 New in release 2.5.2 (2014-08-29): From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 23:20:39 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 23:20:39 +0000 Subject: [Bug 2000] [IcedTea7] Synchronise HEAD tarball paths with release branch paths In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2000 --- Comment #2 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7?cmd=changeset;node=17d957f63b11 author: Andrew John Hughes date: Wed Sep 17 00:18:09 2014 +0100 PR2002: Fix references to hotspot.map following PR2000 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 16 23:20:42 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 16 Sep 2014 23:20:42 +0000 Subject: [Bug 2002] [IcedTea7] Fix references to hotspot.map following PR2000 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2002 --- Comment #2 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7?cmd=changeset;node=17d957f63b11 author: Andrew John Hughes date: Wed Sep 17 00:18:09 2014 +0100 PR2002: Fix references to hotspot.map following PR2000 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Wed Sep 17 09:50:36 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 17 Sep 2014 11:50:36 +0200 Subject: [rfc][icedtea-web] possible class cast exception in splashcontroler Message-ID: <5419596C.7060101@redhat.com> Some applets, may not be using the original apllet-viewer-pane, but rather *detach*, and are in separate window. If such an applet fails, the error screen can not be drawn, because the applications frame is not SpalshController. As splash logic can live happily with null splashcontoloere (==not work, and silently exit) , the class cast exception is unnecessary. There is nothing to be done to save the application as it already died, but the error is imho really unnecessary. J -------------- next part -------------- A non-text attachment was scrubbed... Name: splashCastFix.patch Type: text/x-patch Size: 574 bytes Desc: not available URL: From jvanek at redhat.com Wed Sep 17 10:58:53 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 17 Sep 2014 12:58:53 +0200 Subject: [rfc][icedtea-web] immutbale transaltor Message-ID: <5419696D.9000400@redhat.com> Hi! Attached patch is changing our new Transaltor to be immutable. The only desired change was to - private ResourceBundle resources; + private final ResourceBundle resources; and so .. get rid of loadResourceBundle, and so allow constructor chain of Translator() { this("net.sourceforge.jnlp.resources.Messages"); } Translator(String s) { this(ResourceBundle.getBundle(s)); } } Translator(ResourceBundle resources) { this.resources = resources; } And so make it instantiatable and consequentially adapt the test.... And so get rid of enum in favor of class, and so use handler idiom for creation.... Personally, why people use enums for singletons?!?!?! Well very simple singletons .. yes, but once there is some logic... Ouch they are so so *clumsy* ... So clamsy taht they can not be even properly tested ( no instance!, no overrload!). And once singleton is not immutbale.... Is it still singleton? Afaik the state after the patch is better: - singleton is still singleton - newly: - initialized on demand - immutable - the tets are done on separate copy, not on the changed singleton itself (aaargh) Any comment why to keep enum welcomed.... J. -------------- next part -------------- A non-text attachment was scrubbed... Name: immutableTransaltor.patch Type: text/x-patch Size: 5273 bytes Desc: not available URL: From jvanek at icedtea.classpath.org Wed Sep 17 12:20:46 2014 From: jvanek at icedtea.classpath.org (jvanek at icedtea.classpath.org) Date: Wed, 17 Sep 2014 12:20:46 +0000 Subject: /hg/icedtea-web: Javaws and PolicyEditor made localizable Message-ID: changeset e7f5499a75d3 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=e7f5499a75d3 author: Jiri Vanek date: Wed Sep 17 14:20:31 2014 +0200 Javaws and PolicyEditor made localizable diffstat: ChangeLog | 10 ++ Makefile.am | 4 +- netx/net/sourceforge/jnlp/resources/Messages.properties | 27 +++++++ netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java | 35 ++++++---- netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java | 26 ++---- netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/HtmlFormatter.java | 2 +- 6 files changed, 71 insertions(+), 33 deletions(-) diffs (222 lines): diff -r d8e057783109 -r e7f5499a75d3 ChangeLog --- a/ChangeLog Mon Sep 15 14:09:30 2014 -0400 +++ b/ChangeLog Wed Sep 17 14:20:31 2014 +0200 @@ -1,3 +1,13 @@ +2014-09-17 Jiri Vanek + + Javaws and PolicyEditor made localizable + * Makefile.am: usage of $TP_TAIL fixed to be correctly $$TP_TAIL + * netx/net/sourceforge/jnlp/resources/Messages.properties: added PE and JWS + families + * netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java: and + * netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java: + all strings moved to properties. Minor reformatting. + 2014-09-15 Lukasz Dracz Fix itweb-settings Cache Panel Tooltip diff -r d8e057783109 -r e7f5499a75d3 Makefile.am --- a/Makefile.am Mon Sep 15 14:09:30 2014 -0400 +++ b/Makefile.am Wed Sep 17 14:20:31 2014 +0200 @@ -493,9 +493,9 @@ export LANG=$$LANG_ID; \ mkdir $$HTML_DOCS_TARGET_DIR/$$ID ; \ echo "
  • $$LANG_ID
  • " >> $$HTML_DOCS_INDEX ; \ - $$TP_COMMAND html $$HTML_DOCS_TARGET_DIR/$$ID false $TP_TAIL ; \ + $$TP_COMMAND html $$HTML_DOCS_TARGET_DIR/$$ID false $$TP_TAIL ; \ mkdir $$PLAIN_DOCS_TARGET_DIR/$$ID ; \ - $$TP_COMMAND plain $$PLAIN_DOCS_TARGET_DIR/$$ID 160 false $TP_TAIL; \ + $$TP_COMMAND plain $$PLAIN_DOCS_TARGET_DIR/$$ID 160 false $$TP_TAIL; \ if [ $$ID == "en" ] ; then \ MAN_DESC=$$MAN_DOCS_TARGET_DIR/man1 ; \ else \ diff -r d8e057783109 -r e7f5499a75d3 netx/net/sourceforge/jnlp/resources/Messages.properties --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Sep 15 14:09:30 2014 -0400 +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Wed Sep 17 14:20:31 2014 +0200 @@ -236,6 +236,33 @@ BFileInfoCopying=The full GPLv2 license of this project can be found in the file COPYING in the IcedTea-Web root directory. BFileInfoNews=News about releases of this project can be found in the file NEWS in the IcedTea-Web root directory. +#policyeditor man (note, spaces (especially the one around @@ markup)are important due to man pages markup +PEintro= - view and modify security policy settings for @BOLD_OPEN at javaws @BOLD_CLOSE at and the @BOLD_OPEN at browser plugin at BOLD_CLOSE@ +PEsynopseP1=policy_file +PEsynopseP2=url +PEdescL1=is a GUI application with small command line support to view and edit applet security policy settings used by the icedtea-web implementation \ +of at BOLD_OPEN@ javaws @BOLD_CLOSE at and the @BOLD_OPEN@ browser plugin. @BOLD_CLOSE at It is intended as a simpler, easier to use, and more accessible alternative \ +to the standard @BOLD_OPEN@ JDK Policy Tool. @BOLD_CLOSE at Administrators and power users who need fine grained control over policy files should probably use \ +Policy Tool instead of PolicyEditor. +PEdescL2=If executed without any arguments, no file is opened, and saving the file will result in a prompt on where to save it. Otherwise, if a file path is given as \ +a command line argument, then that file path will be opened and parsed as policy file. +PEexampleL1=Show GUI and opens the default policy file. +PEexampleL2=Show the GUI editor with no file opened. + + +#javaws man (note, spaces (especially the one around @@ markup)are important due to man pages markup +JWSintro= - a Java Web Start client +JWSdescL1=is an implementation of a JNLP client. It uses a JNLP (Java Network Launch Protocol) file to securely run a remote Java application or a Java applet. \ +This implementation of {0}is from the IcedTea project and is based on the NetX project. +JWSdescL2=A JNLP file is an xml file that describes how to securely run a remote Java application or a Java applet. +JWSoptionsL1=When specifying options, the name of the jnlp file must be the last argument to javaws - all the options must preceede it. +JWSoptionsL2=The jnlp-file can either be a url or a local path. +JWSoptionsTitle1=Run options: +JWSoptionsTitle2=Control options: +JWSexampleL1=Shows basic help and about informations. +JWSexampleL2=Shows basic help and about informations in terminal only. +JWSexampleL3=Will start {0} application, originally from {1}, without downloading it, without headers check and in forced single VM. + # Boot options, message should be shorter than this ----------------> BOUsage=[-run-options] jnlp file BOUsage2=[-control-options] diff -r d8e057783109 -r e7f5499a75d3 netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java --- a/netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java Mon Sep 15 14:09:30 2014 -0400 +++ b/netx/net/sourceforge/jnlp/util/docprovider/JavaWsTextsProvider.java Wed Sep 17 14:20:31 2014 +0200 @@ -41,6 +41,7 @@ import java.io.IOException; import net.sourceforge.jnlp.OptionsDefinitions; import net.sourceforge.jnlp.config.PathsAndFiles; +import net.sourceforge.jnlp.runtime.Translator; import static net.sourceforge.jnlp.runtime.Translator.R; import net.sourceforge.jnlp.util.docprovider.formatters.formatters.Formatter; @@ -58,35 +59,34 @@ @Override public String getIntroduction() { return super.getIntroduction() - + getFormatter().wrapParagraph(getFormatter().process(getId() + " - a Java Web Start client")); + + getFormatter().wrapParagraph(getFormatter().process(getId() + " " + Translator.R("JWSintro"))); } @Override public String getSynopsis() { return super.getSynopsis() - + getFormatter().wrapParagraph(getFormatter().process("@BOLD_OPEN@ " + getId() + " @BOLD_CLOSE@" + R("BOUsage") + "@NWLINE_BOLD_OPEN at javaws @BOLD_CLOSE@" + R("BOUsage2"))); + + getFormatter().wrapParagraph(getFormatter().process(getFormatter().getBold(" " + getId() + " ") + R("BOUsage") + getFormatter().getBreakAndBold() + getId() + " " + getFormatter().getBoldClosing() + R("BOUsage2"))); } @Override public String getDescription() { return super.getDescription() + getFormatter().wrapParagraph(getFormatter().process( - "@BOLD_OPEN@ " + getId() + " @BOLD_CLOSE@" - + "is an implementation of a JNLP client. It uses a JNLP (Java Network Launch Protocol) file to securely run a remote Java application or a Java applet. This implementation of" - + "@BOLD_OPEN@ " + getId() + " @BOLD_CLOSE@" + "is from the IcedTea project and is based on the NetX project." - + "@NWLINE@@NWLINE@" - + "A JNLP file is an xml file that describes how to securely run a remote Java application or a Java applet.")); + getFormatter().getBold(getId() + " ") + + Translator.R("JWSdescL1", getFormatter().getBold(getId()+" ")) + + getFormatter().getNewLine()+ getFormatter().getNewLine() + + Translator.R("JWSdescL2"))); } @Override public String getOptions() { String title = super.getOptions(); - String add1 = "When specifying options, the name of the jnlp file must be the last argument to javaws - all the options must preceede it."; - String add2 = "The jnlp-file can either be a url or a local path."; + String add1 = Translator.R("JWSoptionsL1"); + String add2 = Translator.R("JWSoptionsL2"); String adds = getFormatter().wrapParagraph(add1 + getFormatter().getNewLine() + add2); - String runtime = getFormatter().getBold("run-options:") + getFormatter().getNewLine() + String runtime = getFormatter().getBold(Translator.R("JWSoptionsTitle1")) + getFormatter().getNewLine() + optionsToString(OptionsDefinitions.getJavaWsRuntimeOptions()); - String control = getFormatter().getBold("control-options:") + getFormatter().getNewLine() + String control = getFormatter().getBold(Translator.R("JWSoptionsTitle2")) + getFormatter().getNewLine() + optionsToString(OptionsDefinitions.getJavaWsControlOptions()); return title + adds + getFormatter().wrapParagraph(control) + getFormatter().wrapParagraph(runtime); } @@ -95,9 +95,16 @@ public String getExamples() { return super.getExamples() + getFormatter().wrapParagraph( - getFormatter().getOption(getId() + " -about", " Shows basic help and about informations") - + getFormatter().getOption(getId() + " -about -headless", " Shows basic help and about informations in commandline") - + getFormatter().getOption(getId() + " -Xnofork -Xignoreheaders -allowredirect -Xoffline http://mypage.web/dangerous.jnlp", " Will start dangerous.jnlp application, originally form mypage.web, without downloading it, without headers check and in forced single VM")); + getFormatter().getOption(getId() + " " + + OptionsDefinitions.OPTIONS.ABOUT.option, Translator.R("JWSexampleL1")) + + getFormatter().getOption(getId() + " " + + OptionsDefinitions.OPTIONS.ABOUT.option + " " + + OptionsDefinitions.OPTIONS.HEADLESS.option, Translator.R("JWSexampleL2")) + + getFormatter().getOption(getId() + " " + + OptionsDefinitions.OPTIONS.NOFORK.option + " " + + OptionsDefinitions.OPTIONS.NOHEADERS.option + " " + + OptionsDefinitions.OPTIONS.REDIRECT.option + " " + + OptionsDefinitions.OPTIONS.OFFLINE.option + " http://mypage.web/dangerous.jnlp", Translator.R("JWSexampleL3", "dangerous.jnlp", "mypage.web"))); } @Override diff -r d8e057783109 -r e7f5499a75d3 netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java --- a/netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java Mon Sep 15 14:09:30 2014 -0400 +++ b/netx/net/sourceforge/jnlp/util/docprovider/PolicyEditorTextsProvider.java Wed Sep 17 14:20:31 2014 +0200 @@ -39,6 +39,7 @@ import java.io.IOException; import net.sourceforge.jnlp.OptionsDefinitions; import net.sourceforge.jnlp.config.PathsAndFiles; +import net.sourceforge.jnlp.runtime.Translator; import net.sourceforge.jnlp.util.docprovider.formatters.formatters.Formatter; /** @@ -60,29 +61,22 @@ public String getIntroduction() { return super.getIntroduction() + getFormatter().wrapParagraph( - getFormatter().process(getId() + " - view and modify security policy settings for @BOLD_OPEN at javaws @BOLD_CLOSE at and the @BOLD_OPEN at browser plugin at BOLD_CLOSE@")); + getFormatter().process(getId() + " "+Translator.R("PEintro"))); } @Override public String getSynopsis() { return super.getSynopsis() - + getFormatter().wrapParagraph(getFormatter().process("@BOLD_OPEN@ " + getId() + " @BOLD_CLOSE_NWLINE_BOLD_OPEN@" + getId() + " [-file] @BOLD_CLOSE at policy_file @BOLD_OPEN@[-codebase] @BOLD_CLOSE at url")); + + getFormatter().wrapParagraph(getFormatter().process("@BOLD_OPEN@ " + getId() + " @BOLD_CLOSE_NWLINE_BOLD_OPEN@" + getId() + " [-file] @BOLD_CLOSE@"+Translator.R("PEsynopseP1")+" @BOLD_OPEN@[-codebase] @BOLD_CLOSE@"+Translator.R("PEsynopseP2"))); } @Override public String getDescription() { return super.getDescription() - + getFormatter().wrapParagraph(getFormatter().process("@BOLD_OPEN@ " + getId() + " @BOLD_CLOSE@" - + "is a GUI application with small command line support to view and edit applet security policy" - + " settings used by the icedtea-web implementation of" - + "@BOLD_OPEN@ javaws @BOLD_CLOSE at and the @BOLD_OPEN@ browser plugin. @BOLD_CLOSE at It is intended" - + " as a simpler, easier to use, and more accessible alternative to the standard" - + " @BOLD_OPEN@ JDK Policy Tool. @BOLD_CLOSE at Administrators and power users who need fine grained control over" - + " policy files should probably use Policy Tool instead of PolicyEditor." - + "@NWLINE@@NWLINE@" - + "If executed without any arguments, no file is opened, and saving the file will" - + " result in a prompt on where to save it. Otherwise, if a file path is given as" - + " a command line argument, then that file path will be opened and parsed as policy file.")); + + getFormatter().wrapParagraph(getFormatter().process(getFormatter().getBold(getId() + " ") + + Translator.R("PEdescL1") + + getFormatter().getNewLine() + getFormatter().getNewLine() + + Translator.R("PEdescL2"))); } @Override @@ -96,13 +90,13 @@ String title = super.getExamples(); String s = ""; if (expandVariables) { - s = s + getFormatter().getOption(getId() + " -file " + PathsAndFiles.JAVA_POLICY.getFullPath(), "Show GUI and opens the default policy file."); + s = s + getFormatter().getOption(getId() + " -file " + PathsAndFiles.JAVA_POLICY.getFullPath(), Translator.R("PEexampleL1")); } else { - s = s + getFormatter().getOption(getId() + " -file " + PathsAndFiles.JAVA_POLICY.toString(), "Show GUI and opens the default policy file."); + s = s + getFormatter().getOption(getId() + " -file " + PathsAndFiles.JAVA_POLICY.toString(), Translator.R("PEexampleL1")); } return title + getFormatter().wrapParagraph( - getFormatter().getOption(getId(), "Show the GUI editor with no file opened") + s); + getFormatter().getOption(getId(), Translator.R("PEexampleL2")) + s); } @Override diff -r d8e057783109 -r e7f5499a75d3 netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/HtmlFormatter.java --- a/netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/HtmlFormatter.java Mon Sep 15 14:09:30 2014 -0400 +++ b/netx/net/sourceforge/jnlp/util/docprovider/formatters/formatters/HtmlFormatter.java Wed Sep 17 14:20:31 2014 +0200 @@ -143,7 +143,7 @@ @Override public String getOption(String key, String value) { - return "
  • " + key + " - " + process(value) + ".
  • "; + return "
  • " + key + " - " + process(value) + "
  • "; } } From jvanek at redhat.com Wed Sep 17 12:33:32 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 17 Sep 2014 14:33:32 +0200 Subject: [rfc][icedtea-web] localizable files and icedtea-web about page In-Reply-To: <5411C5F8.9040504@gmx.de> References: <541063A3.8070201@redhat.com> <256207747.3820015.1410450074350.JavaMail.zimbra@redhat.com> <5411C5F8.9040504@gmx.de> Message-ID: <54197F9C.2060908@redhat.com> On 09/11/2014 05:55 PM, Jacob Wisor wrote: > On 09/11/2014 05:41 PM, Jie Kang wrote: >> String header = getFormatter().getBold("Features of NetX: ") + getFormatter().getNewLine(); >> >> "Features of NetX: " This string should probably be localized > > Yep, and it should also get reworded to: "NetX features". ;-) > >> +ITWintroL1={0}provides a Free Software web browser plugin running applets written in the Java >> programming language and an implementation of Java Web Start, originally based on the NetX project. >> >> Do you think the "Free Software" should be changed to "Free Open Source Software"? > > No, free software is a super set of open source software. There does exist open source software > which is not free (in the sense of freedom, not free of charge) software. IcedTea-Web is free > software. ;-) > >> +ITWintroL3={0} also includes a plugin to {1} within web browsers. >> >> For this message I see in the english man page: >> icedtea-web also includes a plugin to http://www.java.com/en/download/testjava.jsp within web >> browsers. >> >> Is this replacement of {1} with http://... supposed to happen? It doesn't really make sense to me. > > Yep, looks broken. > >> In the english man page for Description I see: >> Features of NetX: >> >> Modular Easily add JNLP capabilities to an application. >> >> Saves Memory >> Launch programs in a shared JVM. >> >> Fast startup >> Runs applications from a cache for fast starting. >> >> Security Run any application in a sandbox or log its activities. >> >> Auto-Update Applications can auto-update without special code. >> >> Network Deployment >> Deploy to the internet, not with installers. >> >> Can you make the format consistent by making the text part always on a new line? E.g: >> Security Run any application in a sandbox or log its activities. >> becomes >> Security >> Run any application in a sandbox or log its activities. > > Oh, yes please. > >> Also the text here (from english man page) has very weird spacing: >> >> Visit the http://icedtea.classpath.org/wiki/Main_Page or specifically the >> http://icedtea.class? >> path.org/wiki/IcedTea-Web pages for more information. >> Help with common issues with IcedTea-Web can be found >> http://icedtea.classpath.org/wiki/IcedTea-Web#Com? >> mon_Issues . >> >> I think this has to do with the formatting? I am not sure. > > I agree here too. :-) > > Reagrds, > Jacob Hi Jacob! As most fo the nits were agreed by Jie taht they are out of scope or should be addressed as separate changeset, I will push. ok? J From jvanek at redhat.com Wed Sep 17 12:48:38 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 17 Sep 2014 14:48:38 +0200 Subject: [rfc][icedtea-web] Makefile Reproducer Tests Patch In-Reply-To: <2099979744.6142171.1410899772899.JavaMail.zimbra@redhat.com> References: <2099979744.6142171.1410899772899.JavaMail.zimbra@redhat.com> Message-ID: <54198326.1010305@redhat.com> On 09/16/2014 10:36 PM, Jie Kang wrote: > Hello, > > > This patch modifies the makefile and causes it to only process (compile, copy, etc.) tests in the whitelist. > > This feature is greatly beneficial when running say > > 'make run-netx-dist-tests' > > which uses the whitelist to only run tests in the whitelist. Prior to this patch, though the tests ran were filtered by the whitelist, all tests were processed (compiled, resources moved, etc.). This wastes a large amount of time processing tests that aren't run. > > Thoughts? > > > Regards. > By doing so, the dependences of reproducer may not be compiled and installed. Is it what you wont? J. From jkang at redhat.com Wed Sep 17 12:54:24 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 17 Sep 2014 08:54:24 -0400 (EDT) Subject: [rfc][icedtea-web] Makefile Reproducer Tests Patch In-Reply-To: <54198326.1010305@redhat.com> References: <2099979744.6142171.1410899772899.JavaMail.zimbra@redhat.com> <54198326.1010305@redhat.com> Message-ID: <458293683.6459001.1410958464590.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/16/2014 10:36 PM, Jie Kang wrote: > > Hello, > > > > > > This patch modifies the makefile and causes it to only process (compile, > > copy, etc.) tests in the whitelist. > > > > This feature is greatly beneficial when running say > > > > 'make run-netx-dist-tests' > > > > which uses the whitelist to only run tests in the whitelist. Prior to this > > patch, though the tests ran were filtered by the whitelist, all tests were > > processed (compiled, resources moved, etc.). This wastes a large amount of > > time processing tests that aren't run. > > > > Thoughts? > > > > > > Regards. > > > > By doing so, the dependences of reproducer may not be compiled and installed. > Is it what you wont? Hello, If a reproducer depends on another reproducer than I think it should be up to the dev to deal with that appropriately through documentation, etc. In the best-case scenario, no test, including reproducers, should have any dependency on another test. Maybe we can add this functionality as a separate option? Then test-runner can choose to compile+install all tests, or compile+install only tests in the whitelist. This might be a good compromise. Regards? > > J. > -- Jie Kang From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 13:40:58 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 13:40:58 +0000 Subject: [Bug 1420] Bring command line to feature-parity with the swing gui In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1420 Jie Kang changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jkang at redhat.com Assignee|unassigned at icedtea.classpat |jkang at redhat.com |h.org | -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 14:34:15 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 14:34:15 +0000 Subject: [Bug 2003] New: [IcedTea7] --disable-system-gtk option broken by refactoring in PR1736 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2003 Bug ID: 2003 Summary: [IcedTea7] --disable-system-gtk option broken by refactoring in PR1736 Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org In file included from ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:25:0: ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.h:28:1: error: unknown type name 'gboolean' gboolean gtk2_check_dlversion(); ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:27:8: error: unknown type name 'gboolean' static gboolean gtk2_present = FALSE; ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:27:32: error: 'FALSE' undeclared here (not in a function) static gboolean gtk2_present = FALSE; ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:29:1: error: unknown type name 'gboolean' gboolean gtk2_check_dlversion() ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c: In function 'gtk2_check_dlversion': ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:31:25: error: 'TRUE' undeclared (first use in this function) if (gtk2_present == TRUE) { ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:31:25: note: each undeclared identifier is reported only once for each function it appears in ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:35:17: error: 'NULL' undeclared (first use in this function) void *lib = NULL; ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:37:5: warning: implicit declaration of function 'dlopen' [-Wimplicit-function-declaration] lib = dlopen(GTK2_LIB_VERSIONED, RTLD_LAZY | RTLD_LOCAL); ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:37:18: error: 'GTK2_LIB_VERSIONED' undeclared (first use in this function) lib = dlopen(GTK2_LIB_VERSIONED, RTLD_LAZY | RTLD_LOCAL); ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:37:38: error: 'RTLD_LAZY' undeclared (first use in this function) lib = dlopen(GTK2_LIB_VERSIONED, RTLD_LAZY | RTLD_LOCAL); ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:37:50: error: 'RTLD_LOCAL' undeclared (first use in this function) lib = dlopen(GTK2_LIB_VERSIONED, RTLD_LAZY | RTLD_LOCAL); ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:39:20: error: 'GTK2_LIB' undeclared (first use in this function) lib = dlopen(GTK2_LIB, RTLD_LAZY | RTLD_LOCAL); ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:45:5: error: 'fp_gtk_check_version' undeclared (first use in this function) fp_gtk_check_version = dlsym(lib, "gtk_check_version"); ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:45:5: warning: implicit declaration of function 'dlsym' [-Wimplicit-function-declaration] ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:47:5: warning: implicit declaration of function 'fp_gtk_check_version' [-Wimplicit-function-declaration] if (!fp_gtk_check_version(2, 2, 0)) { ^ ../../../src/solaris/native/common/deps/gtk2/gtk_fp_check.c:51:5: warning: implicit declaration of function 'dlclose' [-Wimplicit-function-declaration] dlclose(lib); -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 14:34:45 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 14:34:45 +0000 Subject: [Bug 2003] [IcedTea7] --disable-system-gtk option broken by refactoring in PR1736 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2003 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Wed Sep 17 14:44:24 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Wed, 17 Sep 2014 14:44:24 +0000 Subject: /hg/icedtea7-forest/jdk: PR2003: --disable-system-gtk option bro... Message-ID: changeset 930f4626048e in /hg/icedtea7-forest/jdk details: http://icedtea.classpath.org/hg/icedtea7-forest/jdk?cmd=changeset;node=930f4626048e author: andrew date: Wed Sep 17 15:43:58 2014 +0100 PR2003: --disable-system-gtk option broken by refactoring in PR1736 diffstat: make/sun/gtk/Makefile | 2 ++ src/solaris/native/common/deps/gtk2/gtk_fp.c | 3 --- src/solaris/native/common/deps/gtk2/gtk_fp.h | 10 +--------- src/solaris/native/common/deps/gtk2/gtk_fp_check.c | 2 ++ src/solaris/native/common/deps/gtk2/gtk_fp_check.h | 17 +++++++++++++++++ 5 files changed, 22 insertions(+), 12 deletions(-) diffs (93 lines): diff -r 6923000c68ee -r 930f4626048e make/sun/gtk/Makefile --- a/make/sun/gtk/Makefile Sat Sep 13 16:38:53 2014 +0100 +++ b/make/sun/gtk/Makefile Wed Sep 17 15:43:58 2014 +0100 @@ -58,6 +58,8 @@ ifeq ($(SYSTEM_GTK), true) OTHER_LDLIBS += $(GTK_LIBS) +else + OTHER_LDLIBS += $(LIBDL) endif ifeq ($(PLATFORM), solaris) diff -r 6923000c68ee -r 930f4626048e src/solaris/native/common/deps/gtk2/gtk_fp.c --- a/src/solaris/native/common/deps/gtk2/gtk_fp.c Sat Sep 13 16:38:53 2014 +0100 +++ b/src/solaris/native/common/deps/gtk2/gtk_fp.c Wed Sep 17 15:43:58 2014 +0100 @@ -25,11 +25,8 @@ #include #include #include -#include "jvm_md.h" #include "gtk_fp.h" -#define GTK2_LIB_VERSIONED VERSIONED_JNI_LIB_NAME("gtk-x11-2.0", "0") -#define GTK2_LIB JNI_LIB_NAME("gtk-x11-2.0") #define GTHREAD_LIB_VERSIONED VERSIONED_JNI_LIB_NAME("gthread-2.0", "0") #define GTHREAD_LIB JNI_LIB_NAME("gthread-2.0") #define NO_SYMBOL_EXCEPTION 1 diff -r 6923000c68ee -r 930f4626048e src/solaris/native/common/deps/gtk2/gtk_fp.h --- a/src/solaris/native/common/deps/gtk2/gtk_fp.h Sat Sep 13 16:38:53 2014 +0100 +++ b/src/solaris/native/common/deps/gtk2/gtk_fp.h Wed Sep 17 15:43:58 2014 +0100 @@ -25,7 +25,7 @@ #ifndef __GTK_FP_H__ #define __GTK_FP_H__ -#include +#include "gtk_fp_check.h" gboolean gtk2_dlload(); int gtk2_dlunload(); @@ -287,14 +287,6 @@ void (*fp_gtk_main)(void); guint (*fp_gtk_main_level)(void); -/** - * Returns : - * NULL if the GTK+ library is compatible with the given version, or a string - * describing the version mismatch. - */ -gchar* (*fp_gtk_check_version)(guint required_major, guint required_minor, - guint required_micro); - void (*fp_g_thread_init)(GThreadFunctions *vtable); void (*fp_gdk_threads_init)(void); void (*fp_gdk_threads_enter)(void); diff -r 6923000c68ee -r 930f4626048e src/solaris/native/common/deps/gtk2/gtk_fp_check.c --- a/src/solaris/native/common/deps/gtk2/gtk_fp_check.c Sat Sep 13 16:38:53 2014 +0100 +++ b/src/solaris/native/common/deps/gtk2/gtk_fp_check.c Wed Sep 17 15:43:58 2014 +0100 @@ -24,6 +24,8 @@ */ #include "gtk_fp_check.h" +#include + static gboolean gtk2_present = FALSE; gboolean gtk2_check_dlversion() diff -r 6923000c68ee -r 930f4626048e src/solaris/native/common/deps/gtk2/gtk_fp_check.h --- a/src/solaris/native/common/deps/gtk2/gtk_fp_check.h Sat Sep 13 16:38:53 2014 +0100 +++ b/src/solaris/native/common/deps/gtk2/gtk_fp_check.h Wed Sep 17 15:43:58 2014 +0100 @@ -25,6 +25,23 @@ #ifndef __GTK_FP_CHECK_H__ #define __GTK_FP_CHECK_H__ +#include +#include "jvm_md.h" + +#define GTK2_LIB_VERSIONED VERSIONED_JNI_LIB_NAME("gtk-x11-2.0", "0") +#define GTK2_LIB JNI_LIB_NAME("gtk-x11-2.0") + gboolean gtk2_check_dlversion(); +/************************ + * Gtk function pointers + ************************/ +/** + * Returns : + * NULL if the GTK+ library is compatible with the given version, or a string + * describing the version mismatch. + */ +gchar* (*fp_gtk_check_version)(guint required_major, guint required_minor, + guint required_micro); + #endif From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 14:44:33 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 14:44:33 +0000 Subject: [Bug 1736] Awt loads gtk3 in all the look and feel configurations In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1736 --- Comment #7 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7-forest/jdk?cmd=changeset;node=930f4626048e author: andrew date: Wed Sep 17 15:43:58 2014 +0100 PR2003: --disable-system-gtk option broken by refactoring in PR1736 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 14:44:40 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 14:44:40 +0000 Subject: [Bug 2003] [IcedTea7] --disable-system-gtk option broken by refactoring in PR1736 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2003 --- Comment #1 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7-forest/jdk?cmd=changeset;node=930f4626048e author: andrew date: Wed Sep 17 15:43:58 2014 +0100 PR2003: --disable-system-gtk option broken by refactoring in PR1736 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Wed Sep 17 14:46:42 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 17 Sep 2014 16:46:42 +0200 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <5414DCFF.4000200@gmx.de> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> Message-ID: <54199ED2.7000707@redhat.com> ... >> + mkdir -p $(DOCS_DIR) ; \ >> + HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html ; \ >> + PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain ; \ >> + MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man/ ; \ > > Drop the trailing slash. fixed > >> mkdir $$HTML_DOCS_TARGET_DIR ; \ >> mkdir $$PLAIN_DOCS_TARGET_DIR ; \ >> - mkdir -p $$MAN_DOCS_TARGET_DIR ; \ >> + mkdir $$MAN_DOCS_TARGET_DIR ; \ > > Why did you remove the "-p" switch? It is probably best to have this switch almost always on in > scripts to avoid running into errors just because of non-existing parent directories. I prefer opposite. To not use -p. If some typo seek in, then it can create whole branch in some really strange lcoation... Before this dline created two levels of diretories. So there was -p.Now it does not. however, the -export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs +export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs/$(FULL_VERSION) ... - mkdir $(DOCS_DIR) ; \ + mkdir -p $(DOCS_DIR) ; \ does. so not "fixed" > >> [...] >> diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java >> --- a/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java Wed Sep 10 10:22:46 2014 >> -0400 >> +++ b/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java Fri Sep 12 15:21:39 2014 >> +0200 >> @@ -58,17 +58,17 @@ >> @SuppressWarnings("serial") >> public class NetworkSettingsPanel extends JPanel implements ActionListener { >> >> - private DeploymentConfiguration config; >> + private final DeploymentConfiguration config; >> >> private JPanel description; >> - private ArrayList proxyPanels = new ArrayList(); // The stuff with editable >> fields >> + private final ArrayList proxyPanels = new ArrayList<>(); // The stuff with editable >> fields >> >> /** List of properties used by this panel */ >> - public static String[] properties = { "deployment.proxy.type", >> - "deployment.proxy.http.host", >> - "deployment.proxy.http.port", >> - "deployment.proxy.bypass.local", >> - "deployment.proxy.auto.config.url", }; >> + public static String[] properties = { DeploymentConfiguration.KEY_PROXY_TYPE, >> + DeploymentConfiguration.KEY_PROXY_HTTP_HOST, >> + DeploymentConfiguration.KEY_PROXY_HTTP_PORT, >> + DeploymentConfiguration.KEY_PROXY_BYPASS_LOCAL, >> + DeploymentConfiguration.KEY_PROXY_AUTO_CONFIG_URL, }; > > The formatting here should probably go here like this: > public static String[] properties = { > DeploymentConfiguration.KEY_PROXY_TYPE, > DeploymentConfiguration.KEY_PROXY_HTTP_HOST, > DeploymentConfiguration.KEY_PROXY_HTTP_PORT, > DeploymentConfiguration.KEY_PROXY_BYPASS_LOCAL, > DeploymentConfiguration.KEY_PROXY_AUTO_CONFIG_URL > }; > > Please also mind the comma after the last element. Thank you! Fixed and reformatted. > >> /** >> * Creates a new instance of the network settings panel. >> @@ -259,18 +259,23 @@ >> */ ... >> CBCheckSignedAppletDontMatchException = Signed applets are not allowed to run when their actual >> Codebase does not match the Codebase specified in their manifest. Expected: {0}. Actual: {1}. See: >> http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/no_redeploy.html for details. >> CBCheckSignedFail = Application Codebase does NOT match the Codebase specified in the >> application's manifest, and this application is signed. You are strongly discouraged from running >> this application. See: >> http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/no_redeploy.html for details. >> >> +#itweb-settings man (note, spaces (especially the one around @@ markup)are important due to man >> pages markup >> +ITWSintro= - view and modify settings for @BOLD_OPEN at javaws @BOLD_CLOSE at and the >> @BOLD_OPEN at browser plugin at BOLD_CLOSE@ > > What are those "@BOLD_OPEN@" and "@BOLD_CLOSE@" tags? Are they some sort of project specific markup > language? If so, I am very unhappy with this. Where is the documentation for this? Does it handle @ > escapes correctly? > > Is "... @BOLD_OPEN at javaws @BOLD_CLOSE at and ..." actually correct? Yes all those are correct. See the @@ explanation lower. > >> +ITWSsynops=command arguments >> +IWSdescL1=is a command line and a GUI program to modify and edit settings used by the icedtea-web >> implementation \ >> +of at BOLD_OPEN@ javaws @BOLD_CLOSE at and the @BOLD_OPEN at browser plugin at BOLD_CLOSE@. > > Why did you suddenly introduce broken lines or line continuing characters to Message.properties, > since you have always been strictly against them? You remember, do you? :)) Well its not that I'm 100% against, I like the i18ns and original file keeping same style. Also I don't like cutting on 80chars. Then maybe wee all can throw away our wide monitors... So easily spoken - here i broke, because it seemed to me more readable. so not "fixed" > > Is "... of at BOLD_OPEN@ javaws @BOLD_CLOSE at and ..." actually correct? > >> +IWSdescL2=If executed without any arguments, it starts up a GUI. Otherwise, it tries to do what >> is specified in the argument. >> +IWSdescL3=The command-line allows quickly searching, making a copy of and modifying specific >> settings without having to hunt through a UI. >> +IWSexampleL1=Show the GUI editor >> +IWSexampleL2=Resets the value of `{0}` setting. > > Are the "`" characters literals in the man page or markups? copypaste from my summary email:) Originally there were the ' (" ' ") char, however, I noted, then If I put {n} into '' like '{0}' the properties fiel do not evaluate it correctly. Same for " char and no escaping helped.. So I put here ` char:( Anyway - no markup mentioned. In original text it was just quoting - making it readable or similar. So it have nothing to do with any markup, and AFAIK all plain, html and man output is ok with it.I will be happy to change it if you dont like it ad know replacement. > >> +ITWSdefault=default >> +IWSexampleL3=Known properties >> +IWSexampleL31=(key, value and default value (if different)): >> +IWSexampleL32=(key and default value): >> + >> +#itweb-plugin man (note, spaces (especially the one around @@ markup)are important due to man >> pages markup >> +ITWPintro=- allow to run @BOLD_OPEN at java applets @BOLD_CLOSE at in your favourite >> @BOLD_OPEN at browser@BOLD_CLOSE@ > > Check double spaces. fixed. Thanx! > Is "... run @BOLD_OPEN at java applets @BOLD_CLOSE at in ..." actually correct? > >> +ITWPsynopsL1=is working in your browser, once your browser knows about this files. >> +ITWPsynopsL2=The {0} must be placed, or linked iniside specific direcotries. See {1} > > Spelling! Fixed:( > >> +ITWPsynopsL3=@BOLD_OPEN@ Mozzila compliant browsers @BOLD_CLOSE at like Firefox, Midori, Epiphany, >> Chrome or Chromium use: > > Spelling! The foundation's name is Mozilla! fixed:( > >> +ITWPsynopsL4=@BOLD_OPEN@ Opera family browsers @BOLD_CLOSE at like Opera use: > > Please be careful when mentioning registered trademark and product names. If you mention them, you > will probably need to include a statement on their legal status somewhere in the documentation for > certain jurisdictions. Hence, it is best to avoid them. However, I am also aware that avoiding them > completely is not always possible. Therefore, I strongly suggest to use the term "Mozilla > compatible" only, wherever required. "NPAPI compatible" is also acceptable but far more technical > and probably unknown to most users. "Mozilla compatible" covers all browsers currently supported by > IcedTea-Web and avoids entanglements with too many entities. Because Mozilla is also the original > author of the NPAPI, it describes the technical aspect sufficiently enough. And, although Mozilla is > trademarked as well, the term would nevertheless reduce any legal risks to a minimum, especially > given the Mozilla foundation's nature and history in free software. Of course, this does not relieve > us of placing a legal notice in the documentation about Mozilla either, but reduces any efforts to > just one entity. Ouch that is the long one. What is conclusion? It really was not celar :( I added the" +ITWPtrademarks=All browsers or company names in this section may be subjects of trademarks and/or copyrights. line to end of paragraph. > >> [...] >> diff -r e30d71ab91c6 netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java >> --- a/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java Wed Sep 10 >> 10:22:46 2014 -0400 >> +++ b/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java Fri Sep 12 >> 15:21:39 2014 +0200 >> @@ -38,6 +38,7 @@ >> >> import java.io.IOException; >> import net.sourceforge.jnlp.config.PathsAndFiles; >> +import net.sourceforge.jnlp.runtime.Translator; >> import net.sourceforge.jnlp.util.docprovider.formatters.formatters.Formatter; > > Generally speaking, I am really having trouble accepting this kind of custom formatter to > IcedTea-Web. Actually, this goes for any project which is not specifically concerned with parsing a > well specified language. Unfortunately, most developers greatly underestimate the prerequisites for > a properly working formatter. The probability of not getting it right is far greater than one would > initially assume. This starts with checking inputs and outputs, goes over properly handling encoded > strings, and ends on handling escapes properly. The amount of testing required to get /and/ keep a > formatter correct is just enormous. Then, it has to be documented and everybody who wants to add > documentation on a new feature that he/she has just implemented is required to (a) know how the > documentation generator works and (b) understand its formatting. > So ultimately, we should get rid of this formatter and any @TAG@ tags. If you really need formatting > tags for man pages then the documentation generator should be able to include them itself > automatically. Otherwise, adding documentation becomes unnecessarily difficult and overly complex. > It's a pity that you rushed to push the documentation generator... > Fixing all this paragraph is definitely for another changesets. Copypasted from summary:: the @bold@ whatever@ stuff: - It is placeholder for and in html or \n.B \n and /n in man. Tbh Right now I dont know solid workaround - I would like to get rid of of all this @@ markups. And I'm successfully doing so:) - I Get rid of all except the @bold@, Which I found as necessary evil. But if workaround will be found. I will be most happy to get rid of it. ..end of coopypaste: Well yes, Actually exactly this was reason why I rushed with this. Yes this can be improved, but also that can be improved! or that? But I do not wont to update so big patch until eternity. So I now will be focusing on such a parts which are not considered nice on some ends. The @bold@ substitution, I dont know the perfect cure. Maybe repalce by and which can be repalced to plain or man as is now @bold@ @bold close@ ? Yes I agree, "project specific markup" is not nice. And I'm(will) be working on removal of it. No escaping is now done. And I'm not sure if it is wonted/needed in current state of things. If it will become needed, it will be added. Yes, testing is needed. I wont to add unittests, and also automatic tests by xmllint on resulting html. I don't know how to validate man :( And not sure If I wont validate plain :) One general answer to this. I will be much more happy to hunt minor bugs in this generator, then check till madness three similar - but based on different sources - types of documentation. Maybe the current formatters are not perfect (without maybe,... thy are not even pretending to be complex. They are single-purposed ones) but do they job. And I doubt some more text will be added in close or more remote future. The context of static texts have changed in years only few times, and really only a bit. It was the properties, files and switches which were changed significantly and *always* forgotten to be documented and,. more horribly left also completely outdated. I really do not wont to check those errors anymore. Rather this. J. -------------- next part -------------- A non-text attachment was scrubbed... Name: localizabblePlugin+settings+fix+cleanup2.patch Type: text/x-patch Size: 16988 bytes Desc: not available URL: From jvanek at redhat.com Wed Sep 17 14:59:12 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 17 Sep 2014 16:59:12 +0200 Subject: [rfc][icedtea-web] Makefile Reproducer Tests Patch In-Reply-To: <458293683.6459001.1410958464590.JavaMail.zimbra@redhat.com> References: <2099979744.6142171.1410899772899.JavaMail.zimbra@redhat.com> <54198326.1010305@redhat.com> <458293683.6459001.1410958464590.JavaMail.zimbra@redhat.com> Message-ID: <5419A1C0.8010204@redhat.com> On 09/17/2014 02:54 PM, Jie Kang wrote: > > > ----- Original Message ----- >> On 09/16/2014 10:36 PM, Jie Kang wrote: >>> Hello, >>> >>> >>> This patch modifies the makefile and causes it to only process (compile, >>> copy, etc.) tests in the whitelist. >>> >>> This feature is greatly beneficial when running say >>> >>> 'make run-netx-dist-tests' >>> >>> which uses the whitelist to only run tests in the whitelist. Prior to this >>> patch, though the tests ran were filtered by the whitelist, all tests were >>> processed (compiled, resources moved, etc.). This wastes a large amount of >>> time processing tests that aren't run. >>> >>> Thoughts? >>> >>> >>> Regards. >>> >> >> By doing so, the dependences of reproducer may not be compiled and installed. >> Is it what you wont? > > Hello, > > > If a reproducer depends on another reproducer than I think it should be up to the dev to deal with that appropriately through documentation, etc. In the best-case scenario, no test, including reproducers, should have any dependency on another test. > > Maybe we can add this functionality as a separate option? Then test-runner can choose to compile+install all tests, or compile+install only tests in the whitelist. This might be a good compromise. > > I would say no. The author of whitelist modifications should be aware of his depnedencies. They are moreover easily grep-able from jnlp. So on one side I would be happy for this change. On second side I'm hesitating. Imagine test testing class not found, loading some remote depndence. Then it will not clear if it failed because of whitelist, or becasue of bug. And imagine you are fresh to itw and encounter this. The configure option seems to be good compromise. BY default all will be compiled+isntalled. On demand, only whitelist. if you wont you may (read must in this case) add this configure option as another changeset. The only request for now is that "*" must keep working :) J. From jvanek at redhat.com Wed Sep 17 15:39:13 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 17 Sep 2014 17:39:13 +0200 Subject: [rfc][icedtea-web] fix the empty string in codebase In-Reply-To: <541880B2.205@gmx.de> References: <54183BE3.40801@redhat.com> <541880B2.205@gmx.de> Message-ID: <5419AB21.1060203@redhat.com> On 09/16/2014 08:25 PM, Jacob Wisor wrote: > On 09/16/2014 at 03:32 PM, Jiri Vanek wrote: >> I have recently encountered an app, which failed to run, because of malformed >> jnlp. They had codebase="" and apparently wonted to have ".". Afaik ITW should >> work around this (oracle plugin does :( ) This patch is handling the "" for >> codebase as it was "." > > Yeah, too bad Oracle's plug-in accepts this sort of "URL" because it is actually invalid. :-( An > empty string URL is actually not equal nor equivalent to a missing attribute (null string). I > suppose Oracle's plug-in turns those URLs into File objects internally... > >> The app failed for me in alaca dialogue on NPE, teh patch contains small >> workaround around possible NPE here too + unittest to affected method >> >> ok for head? 1.5? >> >> >> Accordingly with investigating this failure, I have enhanced >> http://icedtea.classpath.org/wiki/IcedTea-Web#Filing_bugs for offline debugging. >> >> Volunteer for reproducer?-) >> >> Thanx, >> J. > >> diff -r d8e057783109 netx/net/sourceforge/jnlp/Parser.java >> --- a/netx/net/sourceforge/jnlp/Parser.java Mon Sep 15 14:09:30 2014 -0400 >> +++ b/netx/net/sourceforge/jnlp/Parser.java Tue Sep 16 15:25:44 2014 +0200 >> @@ -1065,10 +1065,21 @@ >> * @throws ParseException if the JNLP file is invalid >> */ >> public URL getURL(Node node, String name, URL base) throws ParseException { >> - String href = getAttribute(node, name, null); >> - if (href == null) >> + String href = null; >> + if ("codebase".equals(name)) { > > Hmm, strange that the JNLP parser does not have an enum of or a /list/ of valid JNLP element and > attribute name constants. I have intorduced nconstant for codebase String. Abd yes.. The parser is one fo the oldest untouched parts of original netx:( Terrible terribly old code :) > >> + href = getCleanAttribute(node, name); >> + if (href != null) {// so that code can throw an exceptionlater >> + //some bogus jnlps have codebase as "" and expect it behaving as "." >> + if (href.trim().isEmpty()) { > > Try "href != null && href.trim().isEmpty()". ;-) It can be even further optimized into one statement. Ouch. yup. Fixed > >> + href = "."; >> + } >> + } >> + } else { >> + href = getAttribute(node, name, null); >> + } >> + if (href == null) { >> return null; // so that code can throw an exception if attribute was required >> - >> + } >> try { >> if (base == null) >> return new URL(href); >> @@ -1254,11 +1265,17 @@ >> public String getAttribute(Node node, String name, String defaultValue) { >> // SAX >> // String result = ((Element) node).getAttribute(name); >> + String result = getCleanAttribute(node, name); >> + >> + if (result == null || result.length() == 0) { >> + return defaultValue; > > I am not sure this is correct at all. What if an attribute was intended to accept an empty string? > The default value actually depends on the particular attribute's semantics. As I said before, a > missing attribute equates to null and thus always to a default value. An empty string value equates > either to a default value or /the/ empty string value, depending on the attribute's semantics. > Unluckily it is correct.It is keeping "before patch" behaviour. It is not clear from patch, but is is only refactoring - extracting of method to avoid duplication before: ublic String getAttribute(Node node, String name, String defaultValue) { // SAX // String result = ((Element) node).getAttribute(name); String result = getCleanAttribute(node, name); if (result == null || result.length() == 0) { return defaultValue; } return result; } now: public String getAttribute(Node node, String name, String defaultValue) { // SAX // String result = ((Element) node).getAttribute(name); String result = getCleanAttribute(node, name); if (result == null || result.length() == 0) { return defaultValue; } return result; } private String getCleanAttribute(Node node, String name) { String result = node.getAttribute(name); return result; } So although your concerns below are valid, they are not valid in scope of this patch. And I'm afraid I do not dare to change the handling of attribute. Many parts depends on null return from here, and NPE later (tried :( ) >> + } >> + >> + return result; >> + } >> + >> + public String getCleanAttribute(Node node, String name) { > > Err, what is a clean attribute? Did it wash before? :-D So, please check your naming. Besides, > documentation is missing on a public method. And, judging by what it seems to be doing maybe it > should be even private. deffinitely! Made private. > >> String result = node.getAttribute(name); >> - >> - if (result == null || result.length() == 0) >> - return defaultValue; >> - >> return result; >> } >> >> diff -r d8e057783109 netx/net/sourceforge/jnlp/security/SecurityDialogs.java >> --- a/netx/net/sourceforge/jnlp/security/SecurityDialogs.java Mon Sep 15 14:09:30 2014 -0400 >> +++ b/netx/net/sourceforge/jnlp/security/SecurityDialogs.java Tue Sep 16 15:25:44 2014 +0200 >> @@ -44,6 +44,8 @@ >> import java.net.URL; >> import java.security.AccessController; >> import java.security.PrivilegedAction; >> +import java.util.Arrays; >> +import java.util.Comparator; >> import java.util.Set; >> import java.util.concurrent.Semaphore; >> >> @@ -285,7 +287,13 @@ >> >> SecurityDialogMessage message = new SecurityDialogMessage(); >> message.dialogType = DialogType.MISSING_ALACA; >> - message.extras = new Object[]{title, codeBase.toString(), >> UrlUtils.setOfUrlsToHtmlList(remoteUrls)}; >> + String urlToShow = "unknown url"; >> + if (codeBase != null) { >> + urlToShow = codeBase.toString(); >> + } else { >> + OutputController.getLogger().log("Warning, null codebase wants to show in ALACA!"); >> + } > > Formatting. should be fixed > >> + message.extras = new Object[]{title, urlToShow, UrlUtils.setOfUrlsToHtmlList(remoteUrls)}; >> Object selectedValue = getUserResponse(message); >> return getIntegerResponseAsBoolean(selectedValue); >> } >> diff -r d8e057783109 tests/netx/unit/net/sourceforge/jnlp/ParserTest.java >> --- a/tests/netx/unit/net/sourceforge/jnlp/ParserTest.java Mon Sep 15 14:09:30 2014 -0400 >> +++ b/tests/netx/unit/net/sourceforge/jnlp/ParserTest.java Tue Sep 16 15:25:44 2014 +0200 >> @@ -1413,4 +1413,30 @@ >> >> Assert.assertEquals(overwrittenCodebase.toExternalForm(), >> parser.getCodeBase().toExternalForm()); >> } >> + >> + >> + @Test >> + public void testEmptyCodebase() throws Exception { >> + String data = "\n" >> + + "> + + "codebase=\"\" aaa=\"\" " >> + + ">\n" >> + + ""; > > Although this is technically not wrong, it could probably go into a .jnlp file, just for clarity and > maintainability. > Uf sorry. I do not understand what you would like me to do So this remained same. >> + >> + Node root = Parser.getRootNode(new ByteArrayInputStream(data.getBytes()), defaultParser); >> + Assert.assertEquals("Root name is not jnlp", "jnlp", root.getNodeName()); >> + MockJNLPFile file = new MockJNLPFile(LANG_LOCALE); >> + Parser parser = new Parser(file, null, root, defaultParser, null); >> + ParseException eex = null; >> + //non codebase element is unaffected >> + URL u = parser.getURL(root, "aaa", null); >> + Assert.assertEquals(null, u); >> + try { >> + parser.getURL(root, "codebase", null); >> + } catch (ParseException ex) { >> + eex = ex; >> + } >> + Assert.assertEquals(true, eex != null); >> + Assert.assertEquals(true, eex instanceof ParseException); >> + } >> } TRhank you fr review! J. -------------- next part -------------- A non-text attachment was scrubbed... Name: emptyCodebaseFixAndalacaNPEworkarround2.patch Type: text/x-patch Size: 4742 bytes Desc: not available URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 15:59:44 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 15:59:44 +0000 Subject: [Bug 2004] New: When accessing applet it will crash Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 Bug ID: 2004 Summary: When accessing applet it will crash Product: IcedTea-Web Version: 1.4 Hardware: x86_64 OS: Linux Status: NEW Severity: critical Priority: P5 Component: Plugin Assignee: dbhole at redhat.com Reporter: da.ares at gmail.com CC: unassigned at icedtea.classpath.org IcedTea-Web Plugin version: 1.4 (1.4-3ubuntu2.1) Exception was: java.lang.NullPointerException at net.sourceforge.jnlp.NetxPanel.runLoader(NetxPanel.java:116) at sun.applet.AppletPanel.run(AppletPanel.java:380) at java.lang.Thread.run(Thread.java:744) -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 16:02:22 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 16:02:22 +0000 Subject: [Bug 2004] When accessing applet it will crash In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 --- Comment #1 from Deepak Bhole --- Hi, Can you please provide some more details about what site you were visiting and if there was anything you did that triggered it? -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Wed Sep 17 18:57:46 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 17 Sep 2014 14:57:46 -0400 (EDT) Subject: [rfc][icedtea-web] DeploymentConfiguration Key Additions In-Reply-To: <490204897.6723595.1410980049252.JavaMail.zimbra@redhat.com> Message-ID: <1727399995.6725538.1410980266113.JavaMail.zimbra@redhat.com> Hello, For consistency purposes, this patch adds three new keys to DeploymentConfiguration used by other parts of ITW. + public static final String KEY_CACHE_MAX_SIZE = "deployment.cache.max.size"; + + public static final String KEY_CACHE_ENABLED = "deployment.javapi.cache.enabled"; + public static final String KEY_CACHE_COMPRESSION_ENABLED = "deployment.cache.jarcompression"; The parts of ITW that use these keys have been refactored to make use of these instead of private enums or strings. Thoughts? Okay to push? Regards, -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-deployconfig-use.patch Type: text/x-patch Size: 9291 bytes Desc: not available URL: From omajid at redhat.com Wed Sep 17 19:57:41 2014 From: omajid at redhat.com (Omair Majid) Date: Wed, 17 Sep 2014 15:57:41 -0400 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <5419696D.9000400@redhat.com> References: <5419696D.9000400@redhat.com> Message-ID: <20140917195740.GD2198@redhat.com> * Jiri Vanek [2014-09-17 07:00]: > Attached patch is changing our new Transaltor to be immutable. That's great! I love immutable classes! > And so get rid of enum in favor of class, and so use handler idiom for creation.... Wait, what. How does this follow from the above? > Personally, why people use enums for singletons?!?!?! Please see Effective Java for an explanation. There's a summary on StackOverflow [0] too. > Well very simple > singletons .. yes, but once there is some logic... Ouch they are so so > *clumsy* ... So clamsy taht they can not be even properly tested ( no > instance!, no overrload!). > And once singleton is not immutbale.... Is it still singleton? A singleton is a class designed to be instantiated (at max) once. It should not be instantiated again. If you class is, by design, acceptable to instantiate more than once, then it's not a singleton. I am not sure how immutability affects singleton. I mean, most singletons are mutable, but it might be possible that you have a global shared resources that can be initialized only once and is basically immutable (or a constant) after. > + Translator() { > + Translator(String s) { > + Translator(ResourceBundle resources) { Is it intentional that these constructs are now visible package-wide? Because this kind of violates the singleton instance requirement. I mean, it's fine if you want to lean more heavily towards having a testable class rather than hell-will-break-loose-if-another-instance-of-this-class-is-created class. Thanks, Omair [0] http://stackoverflow.com/a/71399/3561275 -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 21:14:41 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 21:14:41 +0000 Subject: [Bug 2004] When accessing applet it will crash In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 --- Comment #2 from Diego --- Hi I was visiting the Web page www.wd2go.com and it simply did not start the Applet. Sorry I can't provide more details but that is all. Thanks Diego -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From gitne at gmx.de Wed Sep 17 21:17:45 2014 From: gitne at gmx.de (Jacob Wisor) Date: Wed, 17 Sep 2014 23:17:45 +0200 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <54199ED2.7000707@redhat.com> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> <54199ED2.7000707@redhat.com> Message-ID: <5419FA79.7050606@gmx.de> On 17.09.2014 at 04:46 PM, Jiri Vanek wrote: >>> mkdir $$HTML_DOCS_TARGET_DIR ; \ >>> mkdir $$PLAIN_DOCS_TARGET_DIR ; \ >>> - mkdir -p $$MAN_DOCS_TARGET_DIR ; \ >>> + mkdir $$MAN_DOCS_TARGET_DIR ; \ >> >> Why did you remove the "-p" switch? It is probably best to have this switch >> almost always on in >> scripts to avoid running into errors just because of non-existing parent >> directories. > > I prefer opposite. To not use -p. If some typo seek in, then it can create whole > branch in some really strange lcoation... > > Before this dline created two levels of diretories. So there was -p.Now it does > not. > > however, the > -export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs > +export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs/$(FULL_VERSION) > ... > - mkdir $(DOCS_DIR) ; \ > + mkdir -p $(DOCS_DIR) ; \ > > does. > > so not "fixed" Let me set this straight for you: Because my chain of thought is inconsistent, it is actually okay to violate the initial premise any time I like to. What kind of thinking is this? :-\ I am not against or in favor of any switch (or style). They do not really matter as long as they do their job. But, what does matter is *consistency*. Inconsistency is no style. So choose either one of the styles and stick with them. Stop trying to be philosophical. >>> +ITWSsynops=command arguments >>> +IWSdescL1=is a command line and a GUI program to modify and edit settings >>> used by the icedtea-web >>> implementation \ >>> +of at BOLD_OPEN@ javaws @BOLD_CLOSE at and the @BOLD_OPEN at browser plugin at BOLD_CLOSE@. >> >> Why did you suddenly introduce broken lines or line continuing characters to >> Message.properties, >> since you have always been strictly against them? > > You remember, do you? :)) Well its not that I'm 100% against, I like the i18ns > and original file keeping same style. > > Also I don't like cutting on 80chars. Then maybe wee all can throw away our wide > monitors... So easily spoken - here i broke, because it seemed to me more > readable. Again, your deeds and words are inconsistent. By this reasoning there are a lot more messages that would benefit from breaking for better readability. You are making a mess. Stick to a style. >> Is "... of at BOLD_OPEN@ javaws @BOLD_CLOSE at and ..." actually correct? >> >>> +IWSdescL2=If executed without any arguments, it starts up a GUI. Otherwise, >>> it tries to do what >>> is specified in the argument. >>> +IWSdescL3=The command-line allows quickly searching, making a copy of and >>> modifying specific >>> settings without having to hunt through a UI. >>> +IWSexampleL1=Show the GUI editor >>> +IWSexampleL2=Resets the value of `{0}` setting. >> >> Are the "`" characters literals in the man page or markups? > > copypaste from my summary email:) > Originally there were the ' (" ' ") char, however, I noted, then If I put {n} > into '' like '{0}' the > properties fiel do not evaluate it correctly. Same for " char and no escaping > helped.. So I put > here ` char:( Well then, this is obviously a serious flaw in the implementation of your "Grand Master Plan to Generate Documentation from Source Code". :-( There is really *no* *reason* to suddenly and arbitrarily forbid certain characters in messages with {n} argument placeholders. This is something that should have been fixed before pushing. Really, I am speechless about so much ignorance. Again, stop making a mess! > Anyway - no markup mentioned. In original text it was just quoting - making it > readable or similar. > So it have nothing to do with any markup, and AFAIK all plain, html and man > output is ok with it.I > will be happy to change it if you dont like it ad know replacement. >>> +ITWPsynopsL3=@BOLD_OPEN@ Mozzila compliant browsers @BOLD_CLOSE at like >>> Firefox, Midori, Epiphany, >>> Chrome or Chromium use: >> >> Spelling! The foundation's name is Mozilla! > fixed:( > >> >>> +ITWPsynopsL4=@BOLD_OPEN@ Opera family browsers @BOLD_CLOSE at like Opera use: >> >> Please be careful when mentioning registered trademark and product names. If >> you mention them, you >> will probably need to include a statement on their legal status somewhere in >> the documentation for >> certain jurisdictions. Hence, it is best to avoid them. However, I am also >> aware that avoiding them >> completely is not always possible. Therefore, I strongly suggest to use the >> term "Mozilla >> compatible" only, wherever required. "NPAPI compatible" is also acceptable but >> far more technical >> and probably unknown to most users. "Mozilla compatible" covers all browsers >> currently supported by >> IcedTea-Web and avoids entanglements with too many entities. Because Mozilla >> is also the original >> author of the NPAPI, it describes the technical aspect sufficiently enough. >> And, although Mozilla is >> trademarked as well, the term would nevertheless reduce any legal risks to a >> minimum, especially >> given the Mozilla foundation's nature and history in free software. Of course, >> this does not relieve >> us of placing a legal notice in the documentation about Mozilla either, but >> reduces any efforts to >> just one entity. > > Ouch that is the long one. What is conclusion? It really was not celar :( I > added the" As is it says. Just stick to a term referring to only one registered trademark or product name. This way, it is usually going to be easy to get the proper wording for this trademark or product name by looking into the help or about section of the product itself. > +ITWPtrademarks=All browsers or company names in this section may be subjects of > trademarks and/or copyrights. I am no lawyer but I am sure this sentence will not hold under legal scrutiny. Stop neglecting the severity of problems. Start paying attention to actually solving them. And, if you do not know how to solve a problem then get advice from somebody who has got the capability. >>> [...] >>> diff -r e30d71ab91c6 >>> netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java >>> --- >>> a/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java >>> Wed Sep 10 >>> 10:22:46 2014 -0400 >>> +++ >>> b/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java >>> Fri Sep 12 >>> 15:21:39 2014 +0200 >>> @@ -38,6 +38,7 @@ >>> >>> import java.io.IOException; >>> import net.sourceforge.jnlp.config.PathsAndFiles; >>> +import net.sourceforge.jnlp.runtime.Translator; >>> import net.sourceforge.jnlp.util.docprovider.formatters.formatters.Formatter; >> >> Generally speaking, I am really having trouble accepting this kind of custom >> formatter to >> IcedTea-Web. Actually, this goes for any project which is not specifically >> concerned with parsing a >> well specified language. Unfortunately, most developers greatly underestimate >> the prerequisites for >> a properly working formatter. The probability of not getting it right is far >> greater than one would >> initially assume. This starts with checking inputs and outputs, goes over >> properly handling encoded >> strings, and ends on handling escapes properly. The amount of testing required >> to get /and/ keep a >> formatter correct is just enormous. Then, it has to be documented and >> everybody who wants to add >> documentation on a new feature that he/she has just implemented is required to >> (a) know how the >> documentation generator works and (b) understand its formatting. >> So ultimately, we should get rid of this formatter and any @TAG@ tags. If you >> really need formatting >> tags for man pages then the documentation generator should be able to include >> them itself >> automatically. Otherwise, adding documentation becomes unnecessarily difficult >> and overly complex. >> It's a pity that you rushed to push the documentation generator... >> > > Fixing all this paragraph is definitely for another changesets. > > Copypasted from summary:: > > the @bold@ whatever@ stuff: > - It is placeholder for and in html or \n.B \n and /n in man. Tbh > Right now I dont know solid workaround > - I would like to get rid of of all this @@ markups. And I'm successfully > doing so:) > - I Get rid of all except the @bold@, Which I found as necessary evil. But if > workaround will be > found. I will be most happy to get rid of it. > > > ..end of coopypaste: So, where is the documentation for all the crap you have introduced again? I can't find it. How is anybody supposed to add documentation on a new or altered feature now? > Well yes, Actually exactly this was reason why I rushed with this. Yes this can > be improved, but also that can be improved! or that? But I do not wont to > update so big patch until eternity. Well, obviously you do not seem to have a sense for the *quality* of a problem and the implications it may cause. I am not mentioning stuff that just needs some polishing to shine. I am mentioning problems that have implications on other existing code and data, like Messages.properties. > So I now will be focusing on such a parts which are not considered nice on some > ends. This is totally inefficient. Do this *before* you push! And as already mentioned, it is not about polishing stuff to make it shine but about making it work *properly* in the first place. > The @bold@ substitution, I dont know the perfect cure. Maybe repalce by and > which can be repalced to plain or man as is now @bold@ @bold close@ ? > > Yes I agree, "project specific markup" is not nice. And I'm(will) be working on > removal of it. > > No escaping is now done. And I'm not sure if it is wonted/needed in current > state of things. > If it will become needed, it will be added. This is definitely the worst possible approach in software engineering that anyone can think of. Have not you learned anything, like trying to avoiding future problems now? Usually, you will have a really hard time fixing existing problems later, when some code or data relies on your crappy base. Anyway, why the sudden rush to push the "Grand Master Plan to Generate Documentation from Source Code"? > Yes, testing is needed. I wont to add unittests, and also automatic tests by > xmllint on resulting html. I don't know how to validate man :( And not sure If I > wont validate plain :) Well, if you do not know how to validate man pages then maybe you should have thought about it before pushing? > One general answer to this. > I will be much more happy to hunt minor bugs in this generator, then check till > madness three similar - but based on different sources - types of > documentation. Maybe the current formatters are not perfect (without maybe,... > thy are not even pretending to be complex. They are single-purposed ones) but do > they job. And I doubt some more text will be added in close or more remote > future. Oh, I am pretty sure we are going to add documentation. Just because of the simple fact that it is currently very rudimentary and /explaining/ very little. > The context of static texts have changed in years only few times, and > really only a bit. It was the properties, files and switches which were changed > significantly and *always* forgotten to be documented and,. more horribly left > also completely outdated. I really do not wont to check those errors anymore. > Rather this. This may sound like a reasonable or maybe even /noble/ cause but it is no excuse for not thinking a proposed solution through before applying it. As I have told you before, it is going to be quite difficult to get a documentation generator right but you have carelessly swept away all of my warnings. The code is definitely in a much worse shape now than it has been before the document generator changeset. IMHO you should pull back the document generator changeset, work it to an acceptable shape, and then test it. So what if it could take like a few months and may become quite big? Who cares! Just give it a few rfc iterations. But, what is most important is that we get clean changesets instead of fixes of fixes to half-baked changesets. Jacob From bugzilla-daemon at icedtea.classpath.org Wed Sep 17 21:47:12 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 17 Sep 2014 21:47:12 +0000 Subject: [Bug 2005] New: --help option should be included in documentation Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2005 Bug ID: 2005 Summary: --help option should be included in documentation Product: Thermostat Version: hg Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: shell Assignee: unassigned at icedtea.classpath.org Reporter: omajid at redhat.com CC: thermostat at icedtea.classpath.org As reported on IRC: < jerboaa> one thing I've noticed today is: thermostat --help is an alias for "thermostat help command". perhaps it should show up in usage? < jerboaa> common option perhaps -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Thu Sep 18 08:49:30 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 18 Sep 2014 08:49:30 +0000 Subject: [Bug 1990] iced tea plugin problem with remote login to wdmycloud In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1990 --- Comment #3 from JiriVanek --- (In reply to Martin Rooyakkers from comment #2) > Iced Tea Web Bug 1990 & 1991 > > Western Digital is working on the problem. > http://wdc.custhelp.com/app/answers/detail/search/1/a_id/11387/c/130/p/85,392 > > > This is an Iced Tea Web window that pops up after giving the password for > the network drive. > > Note ??? I have followed the links and added them where appropriate. > > Window start > The application com.wd.nas4g.mapdrive.MapDrive from > https://wdmycloud-device1190496.wd2go.com/mapDrive.php?ma > resources from the following remote locations: > -- https://wdmycloud-device1190496.wd2go.com/mapdrive > -- http://wdmycloud-device1190496.wd2go.com/mapdrive > > Are you sure you want to run this application? > > > **-**-**.**.**** > > For more information see: > JAR File Manifest Attributes - the link is; > http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/ > manifest.html#app_library > > and > Preventing the Repurposing of an Application ??? the link is; > http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/ > no_redeploy.html > > window end Yes the windows. Is correct. When you press run, does it work? The http://wdc.custhelp.com/app/answers/detail/search/1/a_id/11387/c/130/p/85,392 seems to be reporting only to workaround on oracle java - to lower the security settings so low, that manifest check on library allowable codebase is not performed. You may do the same in itw - itweb-settings application, then extended applet security, then medium level low. Or you may (since 1.5.1) mark "rember decission" in this dialogue. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Thu Sep 18 10:14:44 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 18 Sep 2014 12:14:44 +0200 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <5419FA79.7050606@gmx.de> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> <54199ED2.7000707@redhat.com> <5419FA79.7050606@gmx.de> Message-ID: <541AB094.60301@redhat.com> On 09/17/2014 11:17 PM, Jacob Wisor wrote: > On 17.09.2014 at 04:46 PM, Jiri Vanek wrote: >>>> mkdir $$HTML_DOCS_TARGET_DIR ; \ >>>> mkdir $$PLAIN_DOCS_TARGET_DIR ; \ >>>> - mkdir -p $$MAN_DOCS_TARGET_DIR ; \ >>>> + mkdir $$MAN_DOCS_TARGET_DIR ; \ >>> >>> Why did you remove the "-p" switch? It is probably best to have this switch >>> almost always on in >>> scripts to avoid running into errors just because of non-existing parent >>> directories. >> >> I prefer opposite. To not use -p. If some typo seek in, then it can create whole >> branch in some really strange lcoation... >> >> Before this dline created two levels of diretories. So there was -p.Now it does >> not. >> >> however, the >> -export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs >> +export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs/$(FULL_VERSION) >> ... >> - mkdir $(DOCS_DIR) ; \ >> + mkdir -p $(DOCS_DIR) ; \ >> >> does. >> >> so not "fixed" > > Let me set this straight for you: Because my chain of thought is inconsistent, it is actually okay > to violate the initial premise any time I like to. What kind of thinking is this? :-\ > I am not against or in favor of any switch (or style). They do not really matter as long as they do > their job. But, what does matter is *consistency*. Inconsistency is no style. So choose either one > of the styles and stick with them. Stop trying to be philosophical. What do you see as inconsistency? I have one sub directory to create, no -p. Is there a chain of them, so there appear -p. There is no rule for that. If you want rule, set up rule. and adapt Makefile. > >>>> +ITWSsynops=command arguments >>>> +IWSdescL1=is a command line and a GUI program to modify and edit settings >>>> used by the icedtea-web >>>> implementation \ >>>> +of at BOLD_OPEN@ javaws @BOLD_CLOSE at and the @BOLD_OPEN at browser plugin at BOLD_CLOSE@. >>> >>> Why did you suddenly introduce broken lines or line continuing characters to >>> Message.properties, >>> since you have always been strictly against them? >> >> You remember, do you? :)) Well its not that I'm 100% against, I like the i18ns >> and original file keeping same style. >> >> Also I don't like cutting on 80chars. Then maybe wee all can throw away our wide >> monitors... So easily spoken - here i broke, because it seemed to me more >> readable. > > Again, your deeds and words are inconsistent. By this reasoning there are a lot more messages that > would benefit from breaking for better readability. > You are making a mess. Stick to a style. The only thing I wonted that time IIRC was to keep lines in same state in translations and in original properties. and also if I recall, I was not forcing you to do so, but suggesting it. I'm really not sure what you are trying to suggest. The people in this project changes. AFAIK at least three generations of developers already changed here. If there were some style, it was lost, because each generation made its own. Again - if you wont rule here, set it, write it and refactor code to actually follow it I will be happy to follow it. > >>> Is "... of at BOLD_OPEN@ javaws @BOLD_CLOSE at and ..." actually correct? >>> >>>> +IWSdescL2=If executed without any arguments, it starts up a GUI. Otherwise, >>>> it tries to do what >>>> is specified in the argument. >>>> +IWSdescL3=The command-line allows quickly searching, making a copy of and >>>> modifying specific >>>> settings without having to hunt through a UI. >>>> +IWSexampleL1=Show the GUI editor >>>> +IWSexampleL2=Resets the value of `{0}` setting. >>> >>> Are the "`" characters literals in the man page or markups? >> >> copypaste from my summary email:) >> Originally there were the ' (" ' ") char, however, I noted, then If I put {n} >> into '' like '{0}' the >> properties fiel do not evaluate it correctly. Same for " char and no escaping >> helped.. So I put >> here ` char:( > > Well then, this is obviously a serious flaw in the implementation of your "Grand Master Plan to Thats not. Its feature of properties substitution - it handles characters ' or " in this way. So it was not introduced by my changeset. If you won to keep the ' char here. The solution is to get rid of the (in this changeset intorduced) {0} parameter and keep stick with hard coded value. Anyway, I just found that the change from '{0}' to ''{0}'' should do the trick. You, as the reviewer should point me to this trick, or force me to find the solution, or suggest different approach. Not to scold/mock about possible flaw in something a bit unrelated (I guess you will catch this word) but i see it like it. > Generate Documentation from Source Code". :-( There is really *no* *reason* to suddenly and > arbitrarily forbid certain characters in messages with {n} argument placeholders. :DD you must be joking in this sentence, are you? > This is something that should have been fixed before pushing. Really, I am speechless about so much > ignorance. Again, stop making a mess! No. It is something what can be tuned on the fly. > >> Anyway - no markup mentioned. In original text it was just quoting - making it >> readable or similar. >> So it have nothing to do with any markup, and AFAIK all plain, html and man >> output is ok with it.I >> will be happy to change it if you dont like it ad know replacement. > >>>> +ITWPsynopsL3=@BOLD_OPEN@ Mozzila compliant browsers @BOLD_CLOSE at like >>>> Firefox, Midori, Epiphany, >>>> Chrome or Chromium use: >>> >>> Spelling! The foundation's name is Mozilla! >> fixed:( >> >>> >>>> +ITWPsynopsL4=@BOLD_OPEN@ Opera family browsers @BOLD_CLOSE at like Opera use: >>> >>> Please be careful when mentioning registered trademark and product names. If >>> you mention them, you >>> will probably need to include a statement on their legal status somewhere in >>> the documentation for >>> certain jurisdictions. Hence, it is best to avoid them. However, I am also >>> aware that avoiding them >>> completely is not always possible. Therefore, I strongly suggest to use the >>> term "Mozilla >>> compatible" only, wherever required. "NPAPI compatible" is also acceptable but >>> far more technical >>> and probably unknown to most users. "Mozilla compatible" covers all browsers >>> currently supported by >>> IcedTea-Web and avoids entanglements with too many entities. Because Mozilla >>> is also the original >>> author of the NPAPI, it describes the technical aspect sufficiently enough. >>> And, although Mozilla is >>> trademarked as well, the term would nevertheless reduce any legal risks to a >>> minimum, especially >>> given the Mozilla foundation's nature and history in free software. Of course, >>> this does not relieve >>> us of placing a legal notice in the documentation about Mozilla either, but >>> reduces any efforts to >>> just one entity. >> >> Ouch that is the long one. What is conclusion? It really was not celar :( I >> added the" > > As is it says. Just stick to a term referring to only one registered trademark or product name. This > way, it is usually going to be easy to get the proper wording for this trademark or product name by > looking into the help or about section of the product itself. > I'm really not understanding what you wont me to do. I will remove the new sentence and wait for lawyer reply. >> +ITWPtrademarks=All browsers or company names in this section may be subjects of >> trademarks and/or copyrights. > > I am no lawyer but I am sure this sentence will not hold under legal scrutiny. Stop neglecting the > severity of problems. Start paying attention to actually solving them. And, if you do not know how > to solve a problem then get advice from somebody who has got the capability. Ok. Writing to lawyer:) (really) > >>>> [...] >>>> diff -r e30d71ab91c6 >>>> netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java >>>> --- >>>> a/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java ... >> - I would like to get rid of of all this @@ markups. And I'm successfully >> doing so:) >> - I Get rid of all except the @bold@, Which I found as necessary evil. But if >> workaround will be >> found. I will be most happy to get rid of it. >> >> >> ..end of coopypaste: > > So, where is the documentation for all the crap you have introduced again? I can't find it. How is > anybody supposed to add documentation on a new or altered feature now? Obviously it snot yet documented, because (obviously) it is not yet finished. > >> Well yes, Actually exactly this was reason why I rushed with this. Yes this can >> be improved, but also that can be improved! or that? But I do not wont to >> update so big patch until eternity. > > Well, obviously you do not seem to have a sense for the *quality* of a problem and the implications > it may cause. I am not mentioning stuff that just needs some polishing to shine. I am mentioning > problems that have implications on other existing code and data, like Messages.properties. > >> So I now will be focusing on such a parts which are not considered nice on some >> ends. > > This is totally inefficient. Do this *before* you push! And as already mentioned, it is not about sorry, but disagree completely. > polishing stuff to make it shine but about making it work *properly* in the first place. > >> The @bold@ substitution, I dont know the perfect cure. Maybe repalce by and >> which can be repalced to plain or man as is now @bold@ @bold close@ ? >> >> Yes I agree, "project specific markup" is not nice. And I'm(will) be working on >> removal of it. >> >> No escaping is now done. And I'm not sure if it is wonted/needed in current >> state of things. >> If it will become needed, it will be added. > > This is definitely the worst possible approach in software engineering that anyone can think of. I dont think so. The escaping is not needed now. Why it hsould be needed later? I'mnot going to solve possible future bugs (considering that those ar enot introduced by this) I'm going to fix documentation flaw which is here for *years* > Have not you learned anything, like trying to avoiding future problems now? Usually, you will have a > really hard time fixing existing problems later, when some code or data relies on your crappy base. Only time will prove this. > > Anyway, why the sudden rush to push the "Grand Master Plan to Generate Documentation from Source Code"? I don't understand that you don't understand. It was big changeset, not affecting any mayor parts, but spread across whole ITW. It was well tested to work with current state of things. Any further adaptations if the tunning will take to long will just destabilize it. According to nature of the patch, all hints you have - are fixable in runtime. In meantime, it will soak well. > >> Yes, testing is needed. I wont to add unittests, and also automatic tests by >> xmllint on resulting html. I don't know how to validate man :( And not sure If I >> wont validate plain :) > > Well, if you do not know how to validate man pages then maybe you should have thought about it > before pushing? I was. And I have not found even solid specification of man. So I did my best. Is it reason to drop man support? Maybe... > >> One general answer to this. >> I will be much more happy to hunt minor bugs in this generator, then check till >> madness three similar - but based on different sources - types of >> documentation. Maybe the current formatters are not perfect (without maybe,... >> thy are not even pretending to be complex. They are single-purposed ones) but do >> they job. And I doubt some more text will be added in close or more remote >> future. > > Oh, I am pretty sure we are going to add documentation. Just because of the simple fact that it is > currently very rudimentary and /explaining/ very little. > >> The context of static texts have changed in years only few times, and >> really only a bit. It was the properties, files and switches which were changed >> significantly and *always* forgotten to be documented and,. more horribly left >> also completely outdated. I really do not wont to check those errors anymore. >> Rather this. > > This may sound like a reasonable or maybe even /noble/ cause but it is no excuse for not thinking a > proposed solution through before applying it. As I have told you before, it is going to be quite > difficult to get a Maybe. But rather this, then the state it was before. Acording to that /noble/ experience I had in past years, I would rather give shot to this generator. > documentation generator right but you have carelessly swept away all of my > warnings. The code is definitely in a much worse shape now than it has been before the document I did not. I'm marking your notes, And I hope to fix most of them. > generator changeset. IMHO you should pull back the document generator changeset, work it to an > acceptable shape, and then test it. So what if it could take like a few months and may become quite > big? Who cares! Just give it a few rfc iterations. But, what is most important is that we get clean > changesets instead of fixes of fixes to half-baked changesets. Sorry, but it must be clear that I disagree with this rebuke. Main thing - for such a big changset you can not expect one clean hangeset. We already burned our hands doing so. Always at the end, was 99% of the changset same during a big review, and only few parts were constantly changing. Such an parts may be fixed any time, while the rest of teh changeset may be soaking into project, other patches may have benefit from it -and is being constantly tested. We have at lest 3 months, more correctly I would guess even 6 months before 1.6 release. it is plenty of time to improve this. Ad I definitely do not wont to maintain this patch off repo. Well -let me bring up an example - you have created amazing windows port. Do you wont to push it as it is, or close to state where it is, or tune it to perfection and push then? I think the last is not what you wont to do. Anyway - except the ' char we ar eno longer discussing this changeset. May I proceed somehow? (probably with '' fix. and with resolution from lawyers around. From jvanek at redhat.com Thu Sep 18 10:40:46 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 18 Sep 2014 12:40:46 +0200 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <20140917195740.GD2198@redhat.com> References: <5419696D.9000400@redhat.com> <20140917195740.GD2198@redhat.com> Message-ID: <541AB6AE.7080709@redhat.com> On 09/17/2014 09:57 PM, Omair Majid wrote: > * Jiri Vanek [2014-09-17 07:00]: ok. I thought the answer will be like that:) Note - I do not insist on this patch. But I would really like to know why is which approach better. They both have advantages and disadvantages. From my point of view, the "my" approach is little bit better. >> Attached patch is changing our new Transaltor to be immutable. > > That's great! I love immutable classes! > >> And so get rid of enum in favor of class, and so use handler idiom for creation.... > > Wait, what. How does this follow from the above? Testability? > >> Personally, why people use enums for singletons?!?!?! > > Please see Effective Java for an explanation. There's a summary on > StackOverflow [0] too. I read both. The approaches seems to me equal. And whether use enum or "my" depends on actual needs. > >> Well very simple >> singletons .. yes, but once there is some logic... Ouch they are so so >> *clumsy* ... So clamsy taht they can not be even properly tested ( no >> instance!, no overrload!). > >> And once singleton is not immutbale.... Is it still singleton? > > A singleton is a class designed to be instantiated (at max) once. It > should not be instantiated again. If you class is, by design, acceptable > to instantiate more than once, then it's not a singleton. Is lit like that? :)) Yes, the "A singleton is a class designed to be instantiated (at max) once. " is absolutely correct. But in scope of application, not universe,or not? From definition of singleton is clear that it have to have max 1 isntance in app. But nowhere is written, that you are forbid to create testing instances. > > I am not sure how immutability affects singleton. I mean, most > singletons are mutable, but it might be possible that you have a global > shared resources that can be initialized only once and is basically > immutable (or a constant) after. > >> + Translator() { > >> + Translator(String s) { > >> + Translator(ResourceBundle resources) { > > Is it intentional that these constructs are now visible package-wide? > Because this kind of violates the singleton instance requirement. I Does it? The principle says, that there is none or one isntance, not that you are not allwoed to create another (esepcially for testing) > mean, it's fine if you want to lean more heavily towards having a > testable class rather than > hell-will-break-loose-if-another-instance-of-this-class-is-created It does not :) > class. > > Thanks, > Omair > > [0] http://stackoverflow.com/a/71399/3561275 Thank you! However, the benefits of enum over the holder pattern (in this case) were not told:) Any ideas how to - keep enum, made it immutbale, and test it? or - made it immutbale, testable and eget rid of those constructors? - here I have idea - to made the properties actually protected final. And to hide all contructors in Transaltor itself, but create special constructor in TestableTrasnslator? Again, thank you for inputs. J From bugzilla-daemon at icedtea.classpath.org Thu Sep 18 12:35:58 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 18 Sep 2014 12:35:58 +0000 Subject: [Bug 2004] When accessing applet it will crash In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 --- Comment #3 from Deepak Bhole --- Hi, does it always crash for you when you try to visit the page? -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From omajid at redhat.com Thu Sep 18 13:55:18 2014 From: omajid at redhat.com (Omair Majid) Date: Thu, 18 Sep 2014 09:55:18 -0400 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <541AB6AE.7080709@redhat.com> References: <5419696D.9000400@redhat.com> <20140917195740.GD2198@redhat.com> <541AB6AE.7080709@redhat.com> Message-ID: <20140918135518.GB2324@redhat.com> * Jiri Vanek [2014-09-18 06:44]: > ok. I thought the answer will be like that:) > > Note - I do not insist on this patch. But I would really like to know > why is which approach better. They both have advantages and > disadvantages. From my point of view, the "my" approach is little bit > better. As you said, both have advantages and disadvantages. One of the advantages of the current approach is that it forces the JVM to deal with all the issues of correctness/initialization even in the presence of multi-threading and serialization. It's basically bullet-proof - a programmer can do whatever he (or she) wants but the JVM will not allow creating another instance. Your approach is obviously better for testing since someone can create a fake instance of the class and use it, and still allow a single global instance to be used. > On 09/17/2014 09:57 PM, Omair Majid wrote: > >Wait, what. How does this follow from the above? > > Testability? Okay, sure, then call the patch that, please. Saying that the patch is making the class immutable when immutability does not require your other changes is slightly misleading. Saying that the ability to test is driving this change is more accurate, I think. > >>Personally, why people use enums for singletons?!?!?! > > > >Please see Effective Java for an explanation. There's a summary on > >StackOverflow [0] too. > > I read both. The approaches seems to me equal. And whether use enum > or "my" depends on actual needs. I am not disagreeing, btw :) A variant of "your" approach is sort-of the recommended approach to enable testing in Working Effectively With Legacy Code. > From definition of singleton is clear that it have to have max 1 isntance in > app. But nowhere is written, that you are forbid to create testing > instances. I see your point. And I agree that for better testing, we should be able to create sub-instances of it. That said, I am pretty sure the goal of a singleton is to have exactly one instance - including the instance in tests. It's not often considered an anti-pattern for no reason :) > Any ideas how to > - keep enum, made it immutbale, and test it? > or > - made it immutbale, testable and eget rid of those constructors? > - here I have idea - to made the properties actually protected final. And > to hide all contructors in Transaltor itself, but create special constructor > in TestableTrasnslator? > Let's split out the immutable problem. I am pretty sure it can be made immutable using the current approach too (enums can have constructors). So the issue is how to make it testable. Can you define your goal for 'being testable'? Do you want to test the class itself, or are you more interested in testing other code that uses this class? Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From jvanek at redhat.com Thu Sep 18 14:01:10 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 18 Sep 2014 16:01:10 +0200 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <20140918135518.GB2324@redhat.com> References: <5419696D.9000400@redhat.com> <20140917195740.GD2198@redhat.com> <541AB6AE.7080709@redhat.com> <20140918135518.GB2324@redhat.com> Message-ID: <541AE5A6.7020500@redhat.com> On 09/18/2014 03:55 PM, Omair Majid wrote: > * Jiri Vanek [2014-09-18 06:44]: >> ok. I thought the answer will be like that:) >> >> Note - I do not insist on this patch. But I would really like to know >> why is which approach better. They both have advantages and >> disadvantages. From my point of view, the "my" approach is little bit >> better. > > As you said, both have advantages and disadvantages. One of the > advantages of the current approach is that it forces the JVM to deal > with all the issues of correctness/initialization even in the presence > of multi-threading and serialization. It's basically bullet-proof - a > programmer can do whatever he (or she) wants but the JVM will not allow > creating another instance. > > Your approach is obviously better for testing since someone can create a > fake instance of the class and use it, and still allow a single global > instance to be used. > >> On 09/17/2014 09:57 PM, Omair Majid wrote: >>> Wait, what. How does this follow from the above? >> >> Testability? > > Okay, sure, then call the patch that, please. Saying that the patch is > making the class immutable when immutability does not require your other > changes is slightly misleading. Saying that the ability to test is > driving this change is more accurate, I think. > >>>> Personally, why people use enums for singletons?!?!?! >>> >>> Please see Effective Java for an explanation. There's a summary on >>> StackOverflow [0] too. >> >> I read both. The approaches seems to me equal. And whether use enum >> or "my" depends on actual needs. > > I am not disagreeing, btw :) A variant of "your" approach is sort-of the > recommended approach to enable testing in Working Effectively With > Legacy Code. > >> From definition of singleton is clear that it have to have max 1 isntance in >> app. But nowhere is written, that you are forbid to create testing >> instances. > > I see your point. And I agree that for better testing, we should be able > to create sub-instances of it. That said, I am pretty sure the goal of a > singleton is to have exactly one instance - including the instance in > tests. It's not often considered an anti-pattern for no reason :) > >> Any ideas how to >> - keep enum, made it immutbale, and test it? >> or >> - made it immutbale, testable and eget rid of those constructors? >> - here I have idea - to made the properties actually protected final. And >> to hide all contructors in Transaltor itself, but create special constructor >> in TestableTrasnslator? >> > > Let's split out the immutable problem. I am pretty sure it can be made > immutable using the current approach too (enums can have constructors). > So the issue is how to make it testable. > > Can you define your goal for 'being testable'? Do you want to test the > class itself, or are you more interested in testing other code that uses > this class? > I wont to keep it testable in similar way Jie did in original changeset - as is the test now. == on fake data. Also I wont to allow tests of real singleton (well thats easy) And change properties to be final and so get rid of the terrible laodProperties method. Is it clarified? Sorry for confusion. J From jvanek at redhat.com Thu Sep 18 14:25:05 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 18 Sep 2014 16:25:05 +0200 Subject: [rfc][icedtea-web] Option Parser In-Reply-To: <1128387955.5149807.1410799155448.JavaMail.zimbra@redhat.com> References: <1652694837.24549917.1408718657180.JavaMail.zimbra@redhat.com> <1020811778.2293874.1410276519536.JavaMail.zimbra@redhat.com> <540F27F6.4050602@redhat.com> <1887532824.2369149.1410286878320.JavaMail.zimbra@redhat.com> <1467651074.2470228.1410293867916.JavaMail.zimbra@redhat.com> <5410777C.6070506@redhat.com> <854154890.3936468.1410464305025.JavaMail.zimbra@redhat.com> <5412D841.4020104@redhat.com> <1128387955.5149807.1410799155448.JavaMail.zimbra@redhat.com> Message-ID: <541AEB41.4020807@redhat.com> Uff. Please change the changelog a bit header: +2014-09-15 Lukasz Dracz + + Added New Option Parser + Changed Boot to use option parser. Option Parser changes how arguments + are parsed for, and adds more flexibility in how options and arguments + can be passed in. Added OptionParser unit tests. to 2014-09-18 Lukasz Dracz Added New Option Parser and used in boot of javaws body - left tests as last files in the list. In new files, do not enumerate all methods!! (tests:-/ whatever :-//) - in case of new file - only write new file, short purpose description Well I'm the alst one to check semeones changelogs:) With those please push. This is taking already too long. Don't forget to modify also itw settings and policyeditor in close future! Thank you! J. On 09/15/2014 06:39 PM, Lukasz Dracz wrote: > Hello, > >>> >>> - String key = props[i].substring(0, equals); >>> - String value = props[i].substring(equals + 1, >>> props[i].length()); >>> + String key = input.split("=")[0]; >>> + String value = input.split("=")[1]; >> >> >> Unluckily the behaviour changed here. What if vale contains equals chat to? >> >> Please keep prevoius indexOf approach:( > > Okay, changed back to indexOf approach > > >>> - ParserSettings settings = >>> ParserSettings.setGlobalParserSettingsFromArgs(args); >>> + ParserSettings settings = new >>> ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT), >>> true, !optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); >>> + ParserSettings.setGlobalParserSettings(settings); >> >> Please hide those two lines. > > Okay > >> add >> public whatever setGlobalParserSettingsFromOptionParser(Optionparser >> optionParser){ >> ParserSettings settings = new >> ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT), >> true, >> !optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); >> this.setGlobalParserSettings(settings); >> >> } >> >> in ParserSettings >> >> and here call setGlobalParserSettingsFromOptionParser(optionParser) >> only >> >> Consequentially return (modified) the rmeoved test. > > Test is back and added one more test as well. > >> >> If you fulfill all nits above, please add also chnagelog in next iteration. I >> believe it will be >> last one.. Otherwise we both grow old and turn gray before it is finish. > > Okay added the ChangeLog. > Also I reworked findMainArg method, before it would choose the first value without a dash from the last args, which does not make sense now that we accept arguments with/without dashes. Now it checks for the last value that is not an option or does not have an option right before it that takes OneArgument / OneOrMoreArguments. My reasoning for this is if you have for ex. 'command -arg green blue File.jnlp -update 25' we know update only takes one argument so we know > 25 is not the user's main argument but File.jnlp is since blue is not an option. Also for ex. 'command -arg green blue File.jnlp -arg yellow' I figured we know arg takes one or more arguments but if it has exactly one argument then it is > intentional by the user so in this case File.jnlp is found as the main arg instead of yellow. However if the user does 'command -arg green blue File.jnlp -arg yellow red' then the parser will use red as the main argument which I think is okay and the user should specify in this case either by putting File.jnlp after red or -jnlp infront of File.jnlp. > > Also added four unit tests to OptionParserTest to make sure this is working as intended. > >> Also remember, your next task is to port ITWsettings and polieditor to use >> this class. > > Yes, I have been looking at how ITWsettings does its parsing and will probably tackle this one next and PolicyEditor after. > >> Looking forward to have this in! >> J. >> > > Thank you, > Lukasz Dracz > From omajid at redhat.com Thu Sep 18 14:30:32 2014 From: omajid at redhat.com (Omair Majid) Date: Thu, 18 Sep 2014 10:30:32 -0400 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <541AE5A6.7020500@redhat.com> References: <5419696D.9000400@redhat.com> <20140917195740.GD2198@redhat.com> <541AB6AE.7080709@redhat.com> <20140918135518.GB2324@redhat.com> <541AE5A6.7020500@redhat.com> Message-ID: <20140918143032.GC2324@redhat.com> * Jiri Vanek [2014-09-18 10:03]: > Is it clarified? Yes. I was missing quite a bit of background information. So, if I understand you correctly, you want to be able to unit test Translator (using another resource bundle), you dont want to mutate Translator by supplying another resource. That basically forces us down to the path of subclassing (which means ditching the enum-singleton approach). In that case, your approach seems perfectly fine. FWIW, if you want to test other code to see if it's using Translator correctly (and don't want to pass Translator around), you will probably need to replace the global shared instance of Translator with a testable instance during unit tests. Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From jvanek at redhat.com Thu Sep 18 14:36:17 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 18 Sep 2014 16:36:17 +0200 Subject: [rfc][icedtea-web] DeploymentConfiguration Key Additions In-Reply-To: <1727399995.6725538.1410980266113.JavaMail.zimbra@redhat.com> References: <1727399995.6725538.1410980266113.JavaMail.zimbra@redhat.com> Message-ID: <541AEDE1.9060109@redhat.com> On 09/17/2014 08:57 PM, Jie Kang wrote: > Hello, > > For consistency purposes, this patch adds three new keys to DeploymentConfiguration used by other parts of ITW. > > + public static final String KEY_CACHE_MAX_SIZE = "deployment.cache.max.size"; > + > + public static final String KEY_CACHE_ENABLED = "deployment.javapi.cache.enabled"; > + public static final String KEY_CACHE_COMPRESSION_ENABLED = "deployment.cache.jarcompression"; > > The parts of ITW that use these keys have been refactored to make use of these instead of private enums or strings. > > Thoughts? Okay to push? > > > Regards, > > Sounds perfectly reasonable. Thank you for crawling in those ancient regions! J. From jkang at redhat.com Thu Sep 18 14:47:43 2014 From: jkang at redhat.com (Jie Kang) Date: Thu, 18 Sep 2014 10:47:43 -0400 (EDT) Subject: [rfc][icedtea-web] Makefile Reproducer Tests Patch In-Reply-To: <5419A1C0.8010204@redhat.com> References: <2099979744.6142171.1410899772899.JavaMail.zimbra@redhat.com> <54198326.1010305@redhat.com> <458293683.6459001.1410958464590.JavaMail.zimbra@redhat.com> <5419A1C0.8010204@redhat.com> Message-ID: <1291906436.7217009.1411051663387.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/17/2014 02:54 PM, Jie Kang wrote: > > > > > > ----- Original Message ----- > >> On 09/16/2014 10:36 PM, Jie Kang wrote: > >>> Hello, > >>> > >>> > >>> This patch modifies the makefile and causes it to only process (compile, > >>> copy, etc.) tests in the whitelist. > >>> > >>> This feature is greatly beneficial when running say > >>> > >>> 'make run-netx-dist-tests' > >>> > >>> which uses the whitelist to only run tests in the whitelist. Prior to > >>> this > >>> patch, though the tests ran were filtered by the whitelist, all tests > >>> were > >>> processed (compiled, resources moved, etc.). This wastes a large amount > >>> of > >>> time processing tests that aren't run. > >>> > >>> Thoughts? > >>> > >>> > >>> Regards. > >>> > >> > >> By doing so, the dependences of reproducer may not be compiled and > >> installed. > >> Is it what you wont? > > > > Hello, > > > > > > If a reproducer depends on another reproducer than I think it should be up > > to the dev to deal with that appropriately through documentation, etc. In > > the best-case scenario, no test, including reproducers, should have any > > dependency on another test. > > > > Maybe we can add this functionality as a separate option? Then test-runner > > can choose to compile+install all tests, or compile+install only tests in > > the whitelist. This might be a good compromise. > > > > > I would say no. > > The author of whitelist modifications should be aware of his depnedencies. > They are moreover easily > grep-able from jnlp. Hello, Just some clarification and comments :) I think this is also what I meant when I said dev; The person who changes whitelist (probably a developer, but I guess not always) should know his dependencies. > > So on one side I would be happy for this change. On second side I'm > hesitating. Imagine test testing > class not found, loading some remote depndence. Then it will not clear if it > failed because of > whitelist, or becasue of bug. And imagine you are fresh to itw and encounter > this. > > The configure option seems to be good compromise. BY default all will be > compiled+isntalled. On > demand, only whitelist. Okay. Sounds good, I will work on this. > > if you wont you may (read must in this case) add this configure option as > another changeset. I am a little confused here. When you say another changeset, do you mean I should push the current change and then add a new one on top for the 'configure option'? Or create new change and discard the current one? > > The only request for now is that "*" must keep working :) * does work for this patch :) Thanks for the review!! > > > J. > -- Jie Kang From sbaiduzh at redhat.com Thu Sep 18 14:51:53 2014 From: sbaiduzh at redhat.com (Stanislav Baiduzhyi) Date: Thu, 18 Sep 2014 16:51:53 +0200 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <20140918135518.GB2324@redhat.com> References: <5419696D.9000400@redhat.com> <541AB6AE.7080709@redhat.com> <20140918135518.GB2324@redhat.com> Message-ID: <8989312.HC7D0WKClE@sbaiduzh-main.redhat> On Thursday 18 September 2014 09:55:18 Omair Majid wrote: > I am not disagreeing, btw :) A variant of "your" approach is sort-of the > recommended approach to enable testing in Working Effectively With > Legacy Code. I apologize for intruding, but I have to :) Jiri's approach is "lazier" than enum. So I'd better summarize it like that: * if you're working somewhere around serialization - use enum singleton, but do not expect it to be very lazy. * if not and singleton instance is really heavy - use holder. -- Regards, Stas From bugzilla-daemon at icedtea.classpath.org Thu Sep 18 14:53:26 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 18 Sep 2014 14:53:26 +0000 Subject: [Bug 2006] Client queries too much data from mv-memory-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2006 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Thu Sep 18 15:00:50 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 18 Sep 2014 15:00:50 +0000 Subject: [Bug 2007] Client queries too much data from vm-cpu-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2007 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Thu Sep 18 15:02:46 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 18 Sep 2014 15:02:46 +0000 Subject: [Bug 2006] Client queries too much data from vm-memory-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2006 Severin Gehwolf changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |sgehwolf at redhat.com Summary|Client queries too much |Client queries too much |data from mv-memory-stats |data from vm-memory-stats -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Thu Sep 18 15:22:21 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 18 Sep 2014 15:22:21 +0000 Subject: [Bug 2008] New: Read configuration/secrets from environment variables Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2008 Bug ID: 2008 Summary: Read configuration/secrets from environment variables Product: Thermostat Version: hg Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: Thermostat Assignee: unassigned at icedtea.classpath.org Reporter: omajid at redhat.com CC: thermostat at icedtea.classpath.org A recommended approach for storing secrets is to use environment variables rather than keeping them on disk. You can see it on these pages: - http://exploreflask.com/configuration.html - http://daniel.fone.net.nz/blog/2013/05/20/a-better-way-to-manage-the-rails-secret-token/ - https://devcenter.heroku.com/articles/config-vars - https://appsembler.readthedocs.org/en/latest/secret_settings.html Perhaps thermostat (agent? storage? webservice?) should support this. -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Thu Sep 18 17:51:35 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 18 Sep 2014 17:51:35 +0000 Subject: [Bug 2004] When accessing applet it will crash In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 JiriVanek changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jvanek at redhat.com --- Comment #4 from JiriVanek --- Hi! two hints - try to updtae to turn off selinux and update to icedtea-web 1.5.1 (latest). I rember to see this line at net.sourceforge.jnlp.NetxPanel.runLoader(NetxPanel.java:116) already, and I belive it was fixed. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ldracz at redhat.com Thu Sep 18 21:28:04 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Thu, 18 Sep 2014 17:28:04 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] itweb-settings use Option Parser In-Reply-To: <1615757896.7478363.1411073873657.JavaMail.zimbra@redhat.com> Message-ID: <2136433079.7489666.1411075684213.JavaMail.zimbra@redhat.com> Hello, I have worked on changing itwebsettings to use the Option Parser. The biggest change this code brings is the ability to do multiple itwebsettings options at once, you can for example set and get or reset and set (reset happens first then set is applied). Also I have reworked get, info, set, and reset to allow to take in multiple args instead of just one. Ex. 'itweb-settings get deployment.security.level deployment.manifest.attributes.check deployment.console.startup.mode' will get all three. itweb-settings help will display the main help, where as itwebsettings get help will display the specific help for get. If help is present and other options are present it will get the help for all the other options Ex. itweb-settings get help reset check will get the help for (get, reset and check). A limitation is you can't do for ex. 'itweb-setting get help reset all info deployment.javapi.cache.enabled' this will simply display help for get, reset and info only. I can look into getting it to work by displaying help for get, resetting all and getting the info for deployment.javapi.cache.enabled, but then I think I am going to have to limit the help to appear right after the command which would lead to for example, itweb-settings get help reset help info help to get help for all. I'm just wondering if anyone has an opinion on this matter of what would be the preferred way to handle this. Also looking at the main help that is outputted 'check name - Checks that the current value of the setting is a valid value.' that description is not accurate of what happens in the code. The check option checks through all the values and outputs those that are wrong. Should I implement it to work by just checking the named value if available and just check all if nothing is specified or should the help message text be changed ? Personally I think it is fine as it is and the help message text should just be changed to how it works. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: itwebsettingsOptionParser-2.patch Type: text/x-patch Size: 19456 bytes Desc: not available URL: From tdaitx at br.ibm.com Sat Sep 6 05:29:28 2014 From: tdaitx at br.ibm.com (Tiago =?ISO-8859-1?Q?St=FCrmer?= Daitx) Date: Sat, 06 Sep 2014 02:29:28 -0300 Subject: Template interpreter status in JDK7/IcedTea 2.5.2 for PPC64/PPC64LE Message-ID: <1409981368.3930.9.camel@ocdc.br.ibm.com> All- What's the status of the template interpreter for JDK7 in the ppc-aix-port? I can see that JDK 9 does build with the Template Interpreter for both PPC64 and PPC64LE, but JDK7 seems to be still using the C++ Interpreter on both archs - at least when build from IcedTea 2.5.2, which supposedly merged the head from PPC-AIX-Port repo (I haven't build JDK 7 directly from the PPC-AIX-Port repo to compare the results... yet). What am I missing? How should/can I be sure to enable the template interpreter in a JDK7 build? I used $ nm -C libjvm.so | grep TemplateTable::initialize $ nm -C libjvm.so | grep CppInterpreter::initialize to identify which interpreter was build (stolen from [1]), let me know if there an easier way to do that. Regards, Tiago [1] http://mail.openjdk.java.net/pipermail/hotspot-dev/2013-October/011431.html -- Tiago St?rmer Daitx Linux Technology Center [LTC|IBM] tdaitx at br.ibm.com From ldracz at icedtea.classpath.org Wed Sep 10 14:22:54 2014 From: ldracz at icedtea.classpath.org (ldracz at icedtea.classpath.org) Date: Wed, 10 Sep 2014 14:22:54 +0000 Subject: /hg/icedtea-web: Refactor of Cache Panel GUI in itweb-settings Message-ID: changeset e30d71ab91c6 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=e30d71ab91c6 author: Lukasz Dracz date: Wed Sep 10 10:22:46 2014 -0400 Refactor of Cache Panel GUI in itweb-settings 2014-09-10 Lukasz Dracz Refactor of the cache panel GUI in itweb-settings * netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java: Changed slider into a spinner for cache size, changed order of elements in the panel, added a checkbox to limit the cache size, added disabling of components based on whether they are needed * netx/net/sourceforge/jnlp/resources/Messages.properties diffstat: ChangeLog | 9 + netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java | 427 ++++++--- netx/net/sourceforge/jnlp/resources/Messages.properties | 4 + 3 files changed, 311 insertions(+), 129 deletions(-) diffs (truncated from 553 to 500 lines): diff -r af89bcaa02a2 -r e30d71ab91c6 ChangeLog --- a/ChangeLog Wed Sep 10 09:45:10 2014 -0400 +++ b/ChangeLog Wed Sep 10 10:22:46 2014 -0400 @@ -1,3 +1,12 @@ +2014-09-10 Lukasz Dracz + + Refactor of the cache panel GUI in itweb-settings + * netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java: + Changed slider into a spinner for cache size, changed order of elements + in the panel, added a checkbox to limit the cache size, + added disabling of components based on whether they are needed + * netx/net/sourceforge/jnlp/resources/Messages.properties + 2014-09-10 Jie Kang Changed CacheLRUWrapper to use PropertiesFile's provided locking system diff -r af89bcaa02a2 -r e30d71ab91c6 netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Wed Sep 10 09:45:10 2014 -0400 +++ b/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Wed Sep 10 10:22:46 2014 -0400 @@ -18,33 +18,36 @@ package net.sourceforge.jnlp.controlpanel; -import java.awt.BorderLayout; -import java.awt.FlowLayout; -import java.awt.GridBagConstraints; -import java.awt.GridBagLayout; +import java.awt.*; + +import net.sourceforge.jnlp.config.DeploymentConfiguration; +import net.sourceforge.jnlp.runtime.Translator; + +import javax.swing.event.ChangeEvent; +import javax.swing.event.ChangeListener; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; +import java.awt.event.ComponentAdapter; +import java.awt.event.ComponentEvent; import java.awt.event.ItemEvent; import java.awt.event.ItemListener; import java.io.File; +import java.util.ArrayList; +import java.util.List; import javax.swing.JButton; import javax.swing.JCheckBox; import javax.swing.JComboBox; -import javax.swing.JComponent; import javax.swing.JFileChooser; import javax.swing.JLabel; import javax.swing.JOptionPane; import javax.swing.JPanel; -import javax.swing.JSlider; import javax.swing.JSpinner; import javax.swing.JTextField; import javax.swing.SpinnerNumberModel; -import javax.swing.event.ChangeEvent; -import javax.swing.event.ChangeListener; -import net.sourceforge.jnlp.config.DeploymentConfiguration; -import net.sourceforge.jnlp.runtime.Translator; +import static java.lang.Integer.parseInt; +import static java.lang.Long.parseLong; /** * The actual panel that contains the fields that the user can edit accordingly. @@ -56,56 +59,153 @@ * */ @SuppressWarnings("serial") -public class TemporaryInternetFilesPanel extends NamedBorderPanel implements ChangeListener { +public class TemporaryInternetFilesPanel extends NamedBorderPanel { - private DeploymentConfiguration config; - private int minSize = -1; - private int maxSize = 1000; + private static enum Properties { + CACHE_ENABLED("deployment.javapi.cache.enabled"), + USER_CACHEDIR("deployment.user.cachedir"), + CACHE_MAX_SIZE("deployment.cache.max.size"), + COMPRESSION_ENABLED("deployment.cache.jarcompression"); - /** List of properties used by this panel */ - public static String[] properties = { "deployment.javapi.cache.enabled", // false == enabled - "deployment.user.cachedir", - "deployment.cache.max.size", // Specified in MB - "deployment.cache.jarcompression", // Allows values 0-9 - }; + private final String prop; + Properties(final String prop) { + this.prop = prop; + } - private JComponent defaultFocusComponent = null; - JSpinner spCacheSize; - JSlider slCacheSize; + @Override + public String toString() { + return prop; + } + } - public TemporaryInternetFilesPanel(DeploymentConfiguration config) { + private static final Long CACHE_UNLIMITED_SIZE = Long.valueOf(-1l); + private static final Long CACHE_MIN_SIZE = Long.valueOf(0l); + private static final Long CACHE_MAX_SIZE = (long) Integer.MAX_VALUE; + private static final Long SPINNER_STEP_SIZE = Long.valueOf(10l); + private final JSpinner cacheSizeSpinner; + + private static final long BYTES_TO_MEGABYTES = 1024l * 1024l; + private final File cacheDir; + final long usableDiskSpace; + + private final JCheckBox limitCacheSizeCheckBox; + private final JLabel cacheSizeWarningLabel; + private final DeploymentConfiguration config; + private final JComboBox cbCompression; + private final JButton bLocation; + private final JTextField location; + private final JLabel locationDescription; + private final JLabel lCompression; + private final JLabel lCacheSize; + private final JButton bViewFiles; + private final JPanel diskSpacePanel; + + public TemporaryInternetFilesPanel(final DeploymentConfiguration config) { super(Translator.R("CPHeadTempInternetFiles")); this.config = config; setLayout(new BorderLayout()); + cacheSizeSpinner = new JSpinner(); + limitCacheSizeCheckBox = new JCheckBox(Translator.R("TIFPLimitCacheSize")); + cacheSizeWarningLabel = new JLabel(); + lCacheSize = new JLabel(Translator.R("TIFPCacheSize") + ":"); + + ComboItem[] compressionOptions = {new ComboItem(Translator.R("TIFPNone"), "0"), + new ComboItem("1", "1"), + new ComboItem("2", "2"), + new ComboItem("3", "3"), + new ComboItem("4", "4"), + new ComboItem("5", "5"), + new ComboItem("6", "6"), + new ComboItem("7", "7"), + new ComboItem("8", "8"), + new ComboItem(Translator.R("TIFPMax"), "9"),}; + cbCompression = new JComboBox<>(compressionOptions); + lCompression = new JLabel(Translator.R("TIFPCompressionLevel") + ":"); // Sets compression level for jar files. + + bLocation = new JButton(Translator.R("TIFPChange") + "..."); + location = new JTextField(this.config.getProperty(Properties.USER_CACHEDIR.toString())); + locationDescription = new JLabel(Translator.R("TIFPLocationLabel") + ":"); + bViewFiles = new JButton(Translator.R("TIFPViewFiles")); + + diskSpacePanel = new JPanel(); + diskSpacePanel.setLayout(new GridBagLayout()); + + cacheDir = new File(config.getProperty(DeploymentConfiguration.KEY_USER_CACHE_DIR)); + usableDiskSpace = cacheDir.getUsableSpace() / BYTES_TO_MEGABYTES; // getUsableSpace returns bytes addComponents(); + if (limitCacheSizeCheckBox.isSelected()) { + showCacheSizeSpinnerGUIElements(true); + + if (parseLong(cacheSizeSpinner.getValue().toString()) == 0) { + showCompressionAndLocationGUIElements(false); + } else { + showCompressionAndLocationGUIElements(true); + } + + } else { + showCacheSizeSpinnerGUIElements(false); + showCompressionAndLocationGUIElements(true); + } } /** * Add components to panel. */ private void addComponents() { - JPanel topPanel = new JPanel(new GridBagLayout()); GridBagConstraints c = new GridBagConstraints(); c.fill = GridBagConstraints.BOTH; - JLabel description = new JLabel("" + Translator.R("CPTempInternetFilesDescription") + "
    "); + JLabel description = new JLabel(Translator.R("CPTempInternetFilesDescription")); - JCheckBox enableCaching = new JCheckBox(Translator.R("TIFPEnableCache"), !Boolean.parseBoolean(this.config.getProperty(properties[0]))); - enableCaching.addItemListener(new ItemListener() { + // This section deals with how to use the disk space. + cbCompression.setSelectedIndex(parseInt(this.config.getProperty(Properties.COMPRESSION_ENABLED.toString()))); + cbCompression.addItemListener(new ItemListener() { @Override public void itemStateChanged(ItemEvent e) { - config.setProperty(properties[0], String.valueOf(!(e.getStateChange() == ItemEvent.SELECTED))); + config.setProperty(Properties.COMPRESSION_ENABLED.toString(), ((ComboItem) e.getItem()).getValue()); } }); + //Override getNextValue and getPreviousValue to make it jump to the closest increment/decrement of step size + final Long configCacheSize = parseLong(this.config.getProperty(Properties.CACHE_MAX_SIZE.toString())); + final Long initialCacheSize = configCacheSize < CACHE_MIN_SIZE ? CACHE_MIN_SIZE : configCacheSize; + final SpinnerNumberModel snmCacheSize = new PowerOfSpinnerNumberModel(initialCacheSize, TemporaryInternetFilesPanel.CACHE_MIN_SIZE, TemporaryInternetFilesPanel.CACHE_MAX_SIZE, TemporaryInternetFilesPanel.SPINNER_STEP_SIZE); + cacheSizeSpinner.setModel(snmCacheSize); + + final SpinnerChangeListener listener = new SpinnerChangeListener(); + cacheSizeSpinner.addChangeListener(listener); + cacheSizeSpinner.setToolTipText(Translator.R("TIFPCacheSizeSpinnerTooltip", CACHE_MIN_SIZE, CACHE_MAX_SIZE)); + + limitCacheSizeCheckBox.setSelected(configCacheSize >= CACHE_MIN_SIZE); + limitCacheSizeCheckBox.addItemListener(new CheckboxItemListener()); + + + c.gridx = 0; + c.weightx = 1; + c.gridy = 0; + diskSpacePanel.add(limitCacheSizeCheckBox, c); + c.gridy = 1; + diskSpacePanel.add(lCacheSize, c); + c.gridx = 1; + c.weightx = 1; + c.gridwidth = 2; + diskSpacePanel.add(cacheSizeSpinner, c); + c.gridwidth = 1; + c.gridy = 2; + c.gridx = 0; + diskSpacePanel.add(cacheSizeWarningLabel, c); + + c.gridx = 0; + c.gridy = 3; + diskSpacePanel.add(lCompression, c); + c.gridx = 1; + c.gridwidth = 2; + diskSpacePanel.add(cbCompression, c); + // This displays the option for changing location of cache // User can NOT edit the text field must do it through dialog. - JPanel locationPanel = new NamedBorderPanel(Translator.R("TIFPLocation"), new GridBagLayout()); - JLabel locationDescription = new JLabel(Translator.R("TIFPLocationLabel") + ":"); - final JTextField location = new JTextField(this.config.getProperty(properties[1])); location.setEditable(false); // Can not c&p into the location field. - JButton bLocation = new JButton(Translator.R("TIFPChange") + "..."); bLocation.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { @@ -119,129 +219,198 @@ String result = fileChooser.getSelectedFile().getAbsolutePath(); File dirLocation = new File(result); boolean canWrite = dirLocation.canWrite(); - while (!canWrite && dirLocation != null){ // File does not exist, or no permission. - + while (!canWrite && dirLocation != null) { // File does not exist, or no permission. + if (dirLocation.exists()) { JOptionPane.showMessageDialog(null, "No permission to write to this location."); return; } - + dirLocation = dirLocation.getParentFile(); canWrite = dirLocation.canWrite(); } - + if (canWrite) { location.setText(result); - config.setProperty(properties[1], result); + config.setProperty(Properties.USER_CACHEDIR.toString(), result); } } } }); - c.weightx = 1; - c.gridwidth = GridBagConstraints.REMAINDER; - c.gridx = 0; - c.gridy = 0; - locationPanel.add(locationDescription, c); - c.gridwidth = 1; - c.gridy = 1; - locationPanel.add(location, c); - c.gridx = 1; - c.weightx = 0; - locationPanel.add(bLocation, c); - - // This section deals with how to use the disk space. - JPanel diskSpacePanel = new NamedBorderPanel(Translator.R("TIFPDiskSpace"), new GridBagLayout()); - JLabel lCompression = new JLabel(Translator.R("TIFPCompressionLevel")); // Sets compression level for jar files. - ComboItem[] compressionOptions = { new ComboItem(Translator.R("TIFPNone"), "0"), - new ComboItem("1", "1"), - new ComboItem("2", "2"), - new ComboItem("3", "3"), - new ComboItem("4", "4"), - new ComboItem("5", "5"), - new ComboItem("6", "6"), - new ComboItem("7", "7"), - new ComboItem("8", "8"), - new ComboItem(Translator.R("TIFPMax"), "9"), }; - JComboBox cbCompression = new JComboBox<>(compressionOptions); - cbCompression.setSelectedIndex(Integer.parseInt(this.config.getProperty(properties[3]))); - cbCompression.addItemListener(new ItemListener() { - @Override - public void itemStateChanged(ItemEvent e) { - config.setProperty(properties[3], ((ComboItem) e.getItem()).getValue()); - } - }); - - JLabel lCacheSize = new JLabel(Translator.R("TIFPCacheSize") + ":"); - slCacheSize = new JSlider(minSize, maxSize, Integer.parseInt(this.config.getProperty(properties[2]))); - slCacheSize.setMinorTickSpacing(50); - slCacheSize.setPaintTicks(true); - SpinnerNumberModel snmCacheSize = new SpinnerNumberModel(Integer.parseInt(this.config.getProperty(properties[2])), minSize, maxSize, 1); - spCacheSize = new JSpinner(snmCacheSize); - - slCacheSize.addChangeListener(this); - spCacheSize.addChangeListener(this); - - c.gridy = 0; - c.gridx = 0; - c.weightx = 1; - diskSpacePanel.add(lCompression, c); - c.gridx = 1; - c.weightx = 0; - diskSpacePanel.add(cbCompression, c); - c.gridy = 1; - c.gridx = 0; - c.gridwidth = GridBagConstraints.REMAINDER; - c.weightx = 1; - diskSpacePanel.add(lCacheSize, c); - c.gridwidth = 1; - c.gridy = 2; - diskSpacePanel.add(slCacheSize, c); - c.gridx = 1; - diskSpacePanel.add(spCacheSize, c); - - JPanel buttonDeleteRestore = new JPanel(new FlowLayout(FlowLayout.TRAILING)); - JButton bViewFiles = new JButton(Translator.R("TIFPViewFiles")); bViewFiles.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { CacheViewer.showCacheDialog(config); } }); - buttonDeleteRestore.add(bViewFiles); - c.weighty = 0; + c.gridy = 4; c.gridx = 0; - c.gridy = 0; - topPanel.add(enableCaching, c); - c.gridy = 1; - topPanel.add(locationPanel, c); - c.gridy = 2; - topPanel.add(diskSpacePanel, c); - c.weighty = 1; - c.gridy = 3; - topPanel.add(buttonDeleteRestore, c); - add(description, BorderLayout.NORTH); - add(topPanel, BorderLayout.CENTER); + c.weightx = 1; + c.gridwidth = 1; + diskSpacePanel.add(locationDescription, c); + c.gridy = 5; + c.gridwidth = 1; + diskSpacePanel.add(location, c); + c.gridx = 1; + c.weightx = 0.5; + diskSpacePanel.add(bLocation, c); + c.gridx = 2; + diskSpacePanel.add(bViewFiles, c); + + JPanel panel = new JPanel(); + panel.setLayout(new BorderLayout()); + panel.add(description, BorderLayout.NORTH); + panel.add(diskSpacePanel, BorderLayout.CENTER); + add(panel, BorderLayout.CENTER); + + this.addComponentListener(new ComponentAdapter() { + @Override + public void componentShown(final ComponentEvent componentEvent) { + listener.stateChanged(null); + } + }); + } - /** - * Give focus to the default button. - */ - public void focusOnDefaultButton() { - if (defaultFocusComponent != null) { - defaultFocusComponent.requestFocusInWindow(); + private static class PowerOfSpinnerNumberModel extends SpinnerNumberModel { + private final List powersOf; + + public PowerOfSpinnerNumberModel(final Long initialCacheSize, final Long cacheMinSize, final Long cacheMaxSize, final Long spinnerStepSize) { + super(initialCacheSize, cacheMinSize, cacheMaxSize, spinnerStepSize); + powersOf = new ArrayList<>(); + final int powersListSize = (int) Math.floor(Math.log(cacheMaxSize) / Math.log(spinnerStepSize) + 1); + + for (int i = 0; i < powersListSize; i++) { + final long powerOfTen = (long) Math.pow(spinnerStepSize, i); + powersOf.add(powerOfTen); + } + } + + @Override + public Long getNextValue() { + final Number raw = (Number) super.getValue(); + if (super.getNextValue() == null) { + return (Long) getMaximum(); + } + + final Long original = raw.longValue(); + final Long result = original - (original % powersOf.get(String.valueOf(original).length() - 1)) + powersOf.get(String.valueOf(original).length() - 1); + if (result < (Long) getMaximum()) { + return result; + } + + return (Long) getMaximum(); + } + + @Override + public Long getPreviousValue() { + final Number raw = (Number) super.getValue(); + final Long original = raw.longValue(); + if (super.getPreviousValue() == null) { + if (original > 0) { + return original - 1; + } + + return (Long) getMinimum(); + } + + final Long result; + if (powersOf.contains(original)) { + result = original - powersOf.get(String.valueOf(original).length() - 2); + return result; + } else { + + if (original % powersOf.get(String.valueOf(original).length() - 1) == 0) { + result = original - powersOf.get(String.valueOf(original).length() - 1); + } else { + result = original - original % powersOf.get(String.valueOf(original).length() - 1); + } + + if (result > Long.valueOf(0)) { + return result; + } + } + + return Long.valueOf(0); + } + + } + + private class SpinnerChangeListener implements ChangeListener { + + @Override + public void stateChanged(final ChangeEvent e) { + final long cacheSizeSpinnerValue = (long) cacheSizeSpinner.getValue(); + + if (limitCacheSizeCheckBox.isSelected()) { + showCompressionAndLocationGUIElements(true); + + if (cacheSizeSpinnerValue > usableDiskSpace) { + cacheSizeSpinner.setToolTipText(null); + cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSpinnerValueTooLargeWarning", usableDiskSpace)); + } else if (cacheSizeSpinnerValue == 0) { + cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSetToNoCaching")); + showCompressionAndLocationGUIElements(false); + } else { + cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSpinnerLargeValueWarning", usableDiskSpace)); + } + + config.setProperty(Properties.CACHE_MAX_SIZE.toString(), Long.valueOf(cacheSizeSpinnerValue).toString()); + } else { + showCacheSizeSpinnerGUIElements(false); + showCompressionAndLocationGUIElements(true); + } } } - @Override - public void stateChanged(ChangeEvent e) { - Object o = e.getSource(); - if (o instanceof JSlider) - spCacheSize.setValue(((JSlider) o).getValue()); - else if (o instanceof JSpinner) - slCacheSize.setValue((Integer) ((JSpinner) o).getValue()); + private class CheckboxItemListener implements ItemListener { + @Override + public void itemStateChanged(final ItemEvent e) { + final boolean selected = e.getStateChange() == ItemEvent.SELECTED; + showCacheSizeSpinnerGUIElements(selected); - config.setProperty(properties[2], spCacheSize.getValue().toString()); + if (parseLong(cacheSizeSpinner.getValue().toString()) == 0 && selected) { + showCompressionAndLocationGUIElements(false); + } else { + showCompressionAndLocationGUIElements(true); + } From mattias.eliasson at guru.se Mon Sep 15 14:45:58 2014 From: mattias.eliasson at guru.se (Mattias Eliasson) Date: Mon, 15 Sep 2014 16:45:58 +0200 Subject: [rfc][icedtea-web] IcedTea-Web for Windows In-Reply-To: <5410FCF8.7040600@gmx.de> References: <5410FCF8.7040600@gmx.de> Message-ID: <5416FBA6.2040908@guru.se> Hi! I have previously discussed using FireBreath as a plugin abstraction layer for icedtea-web. It provides a C++ abstraction layer on top of both NPAPI and IE:s COM/OLE/ActiveX plugin API. I argued that it would make icedtea-web cleaner by hiding all the NPAPI stuff, but it's oven more valid in this use case. As you are planning to use add the IE API you should consider using FireBreath instead, and hopefully it will also solve your NPAPI worries. You do not implement a IOleObject interface with FB, it generates one for you. I totally agree with you on the need for a Windows/IE plugin and I wish I had the time to work on this myself. //Mattias Den 2014-09-11 03:38, Jacob Wisor skrev: > Hello there! > > I was thinking about bringing IcedTea-Web to Windows for quite some time now. So I have looked into the current plug-in code for Un*x systems. Unfortunately, it has dependencies on pthreads and GTK+. Although these could be compiled in statically, this would actually not solve all the problems to it. > Mainly, three things would not work. > First, error logging. Because Windows has slightly different pipe and IPC semantics to POSIX the current code makes to many assumptions on their behavior while only applicable to POSIX. Although I am pretty sure the GTK+ library tries to resemble POSIX semantics as close as possible, or abstract them away with its concept of channels, I am also sure that we would run into some bogus and hard to track down bugs later on. Error logging from Java applications has to be designed on Windows quite differently. > > Second, sub-process shutdown. Windows has some quite different process semantics than POSIX. Terminating the JVM in-process server in Windows properly requires really Windows specific code. Ports of pthreads and GTK+ won't do much here. > > Third, plug-in registration, detection, and install/uninstall. These tasks involve the Windows registry, which of course is highly Windows specific. GTK+ has nothing to offer here. And lastly (or forth), getting the plug-in on the Internet Explorer is absolutely impossible without registering and providing a scriptable COM component. While Mozilla compatible browsers can load plug-ins from designated folders, the Internet Explorer relies entirely on the OLE server and COM infrastructure, so registration is required. So, why bother about IE anyway? Well, it's like the No. 1 browser on the Windows platform. Without support for IE, most people will have even less incentive to use open-source IcedTea-Web. > > Long story short, I came to the conclusion that it is probably best to start implementing Windows specific code now and to blend it with the existing Un*x code later. > > At this stage, the plug-in does not do much, except for registering the plug-in with Mozilla compatible browsers and COM. However, you won't see it in the list of Add-ons in IE. Simply because IE requires an implemented IOleObject interface, which I did not come to yet. ;-) But, the plug-in does show up in Mozilla compatible browsers! I have been trying to test the Chrome browser too but to no avail. So far, I have been building and testing the 64 bit version only. > > How to build > > True to IcedTea's motto, you will not need any proprietary or closed source tools to build. However, you will need MinGW, mingw-make, XulRunner SDK (a Linux package works too), and OpenJDK with Windows headers. Actually, I have been coding in F20 entirely, and the only thing I had to pull manually were the JVM Windows headers, hence you should be good on almost every Linux distro. > Before building, look into the Makefile.mingw file to setup your paths or to find out about the make variables to set on the command line. Then invoke > > mingw-make -C plugin/icedteanp/windows -f Makefile.mingw all > > or for the 64 bit version > > mingw-make -C plugin/icedteanp/windows -f Makefile.mingw \ > PROCESSOR_ARCHITECTURE=AMD64 all > > I have designed the make file to build on Un*x and Windows systems, although I have not tested building on Windows yet. > > Have fun and thank you for reviewing! > > Jacob From ldracz at icedtea.classpath.org Mon Sep 15 18:09:36 2014 From: ldracz at icedtea.classpath.org (ldracz at icedtea.classpath.org) Date: Mon, 15 Sep 2014 18:09:36 +0000 Subject: /hg/icedtea-web: Fix itweb-settings Cache Panel Tooltip Message-ID: changeset d8e057783109 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=d8e057783109 author: Lukasz Dracz date: Mon Sep 15 14:09:30 2014 -0400 Fix itweb-settings Cache Panel Tooltip 2014-09-15 Lukasz Dracz Fix itweb-settings Cache Panel Tooltip * netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java: Tooltip appears when spinner is enabled and hovered over * netx/net/sourceforge/jnlp/resources/Messages.properties: Removed not needed html tags diffstat: ChangeLog | 8 ++++++++ netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java | 3 ++- netx/net/sourceforge/jnlp/resources/Messages.properties | 5 +++-- 3 files changed, 13 insertions(+), 3 deletions(-) diffs (53 lines): diff -r 1e274216ee4c -r d8e057783109 ChangeLog --- a/ChangeLog Mon Sep 15 11:42:08 2014 -0400 +++ b/ChangeLog Mon Sep 15 14:09:30 2014 -0400 @@ -1,3 +1,11 @@ +2014-09-15 Lukasz Dracz + + Fix itweb-settings Cache Panel Tooltip + * netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java: + Tooltip appears when spinner is enabled and hovered over + * netx/net/sourceforge/jnlp/resources/Messages.properties: + Removed not needed html tags + 2014-09-15 Jie Kang Moved translator responsibility from JNLPRuntime to Translator diff -r 1e274216ee4c -r d8e057783109 netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Mon Sep 15 11:42:08 2014 -0400 +++ b/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Mon Sep 15 14:09:30 2014 -0400 @@ -348,7 +348,6 @@ showCompressionAndLocationGUIElements(true); if (cacheSizeSpinnerValue > usableDiskSpace) { - cacheSizeSpinner.setToolTipText(null); cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSpinnerValueTooLargeWarning", usableDiskSpace)); } else if (cacheSizeSpinnerValue == 0) { cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSetToNoCaching")); @@ -402,9 +401,11 @@ cacheSizeWarningLabel.setEnabled(bool); if(bool == false) { + cacheSizeSpinner.setToolTipText(null); cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSpinnerLargeValueWarning", usableDiskSpace)); } else { + cacheSizeSpinner.setToolTipText(Translator.R("TIFPCacheSizeSpinnerTooltip", CACHE_MIN_SIZE, CACHE_MAX_SIZE)); final long cacheSizeSpinnerValue = (long) cacheSizeSpinner.getValue(); if(cacheSizeSpinnerValue > usableDiskSpace) { cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSpinnerValueTooLargeWarning", usableDiskSpace)); diff -r 1e274216ee4c -r d8e057783109 netx/net/sourceforge/jnlp/resources/Messages.properties --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Sep 15 11:42:08 2014 -0400 +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Sep 15 14:09:30 2014 -0400 @@ -805,8 +805,9 @@ TIFPFileChooserChooseButton=Choose TIFPLimitCacheSize=Limit cache size TIFPCacheSizeSpinnerValueTooLargeWarning=WARNING: Uses more space than {0} MB available -TIFPCacheSizeSpinnerLargeValueWarning= Available: {0} MB -TIFPCacheSizeSetToNoCaching=Cached files will be deleted on icedtea-web close. +TIFPCacheSizeSpinnerLargeValueWarning=Available: {0} MB +TIFPCacheSizeSetToNoCaching=Cached files will be deleted when IcedTea-Web terminates. +TIFPCacheSizeSpinnerTooltip=Minimum: {0} Maximum: {1} # Control Panel - Cache Viewer CVCPDialogTitle=Cache Viewer From ldracz at icedtea.classpath.org Thu Sep 18 17:18:24 2014 From: ldracz at icedtea.classpath.org (ldracz at icedtea.classpath.org) Date: Thu, 18 Sep 2014 17:18:24 +0000 Subject: /hg/icedtea-web: Added New Option Parser and used in boot of javaws Message-ID: changeset e1c7156ed0a1 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=e1c7156ed0a1 author: Lukasz Dracz date: Thu Sep 18 13:18:11 2014 -0400 Added New Option Parser and used in boot of javaws 2014-09-18 Lukasz Dracz Added New Option Parser and used in boot of javaws * netx/net/sourceforge/jnlp/Launcher.java: (addProperties, addArguments, addParameters) refactored to take in a List instead of String[] * netx/net/sourceforge/jnlp/OptionsDefinitions.java: added JNLP to enum OPTIONS * netx/net/sourceforge/jnlp/ParserSettings.java (setGlobalParserSettingsFromOptionParser): refactored to take in an OptionParser instead of args * netx/net/sourceforge/jnlp/runtime/Boot.java: Uses OptionParser to parse arguments for options and check whether an option is present. (getJNLPFile): changed to use OptionParser, and look for one main argument or one value from the JNLP option, if not present then throws an InvalidArgumentException * netx/net/sourceforge/jnlp/util/optionparser/InvalidArgumentException.java: added * netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java: new file, a common parser for options and their values (parseContents): called in OptionParser constructor, parses and populates values in a map based on their option (findMainArg): Takes arguments and parses them backwards to find the first value that is eligible to be a main arg (not an option or a value for an option with one value) (addMainArg): adds the specified arg to main and removes it from its current placement in the map (stringEqualsOption): used to determine whether a string fits an option keyword irrespective if it has a leading dash or is followed by a equals char * tests/netx/unit/net/sourceforge/jnlp/ParserSettingsTest.java: (testSetGlobalParserSettingsFromOptionParser, testSetGlobalParserSettingsFromOptionParserHasSameOptionsAsOptionParser): added * tests/netx/unit/net/sourceforge/jnlp/util/optionparser/OptionParserTest.java: new file to test parser works as intended diffstat: ChangeLog | 36 + NEWS | 2 + netx/net/sourceforge/jnlp/Launcher.java | 42 +- netx/net/sourceforge/jnlp/OptionsDefinitions.java | 4 +- netx/net/sourceforge/jnlp/ParserSettings.java | 14 +- netx/net/sourceforge/jnlp/runtime/Boot.java | 137 +-- netx/net/sourceforge/jnlp/util/optionparser/InvalidArgumentException.java | 43 + netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java | 217 +++++ tests/netx/unit/net/sourceforge/jnlp/ParserSettingsTest.java | 45 +- tests/netx/unit/net/sourceforge/jnlp/util/optionparser/OptionParserTest.java | 400 ++++++++++ 10 files changed, 808 insertions(+), 132 deletions(-) diffs (truncated from 1218 to 500 lines): diff -r e7f5499a75d3 -r e1c7156ed0a1 ChangeLog --- a/ChangeLog Wed Sep 17 14:20:31 2014 +0200 +++ b/ChangeLog Thu Sep 18 13:18:11 2014 -0400 @@ -1,3 +1,39 @@ +2014-09-18 Lukasz Dracz + + Added New Option Parser and used in boot of javaws + * netx/net/sourceforge/jnlp/Launcher.java: + (addProperties, addArguments, addParameters) refactored to take in + a List instead of String[] + * netx/net/sourceforge/jnlp/OptionsDefinitions.java: + added JNLP to enum OPTIONS + * netx/net/sourceforge/jnlp/ParserSettings.java + (setGlobalParserSettingsFromOptionParser): refactored to take in + an OptionParser instead of args + * netx/net/sourceforge/jnlp/runtime/Boot.java: + Uses OptionParser to parse arguments for options and check whether + an option is present. (getJNLPFile): changed to use OptionParser, + and look for one main argument or one value from the JNLP option, if + not present then throws an InvalidArgumentException + * netx/net/sourceforge/jnlp/util/optionparser/InvalidArgumentException.java: + added + * netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java: + new file, a common parser for options and their values + (parseContents): called in OptionParser constructor, parses and populates + values in a map based on their option + (findMainArg): Takes arguments and parses them backwards to find the + first value that is eligible to be a main arg (not an option or a value + for an option with one value) + (addMainArg): adds the specified arg to main and removes it from its + current placement in the map + (stringEqualsOption): used to determine whether a string fits an option + keyword irrespective if it has a leading dash or is followed by a equals char + * tests/netx/unit/net/sourceforge/jnlp/ParserSettingsTest.java: + (testSetGlobalParserSettingsFromOptionParser, + testSetGlobalParserSettingsFromOptionParserHasSameOptionsAsOptionParser): + added + * tests/netx/unit/net/sourceforge/jnlp/util/optionparser/OptionParserTest.java: + new file to test parser works as intended + 2014-09-17 Jiri Vanek Javaws and PolicyEditor made localizable diff -r e7f5499a75d3 -r e1c7156ed0a1 NEWS --- a/NEWS Wed Sep 17 14:20:31 2014 +0200 +++ b/NEWS Thu Sep 18 13:18:11 2014 -0400 @@ -21,6 +21,8 @@ - PR1858: Java Console accepts multi-byte encodings - PR1859: Java Console UI improvement for lower resolutions (800*600) - RH1091563: [abrt] icedtea-web-1.5-2.fc20: Uncaught exception java.lang.ClassCastException in method sun.applet.PluginAppletViewer$8.run() + - Dropped support for long unmaintained -basedir argument + - Returned support for -jnlp argument * Plugin - PR1743 - Intermittant deadlock in PluginRequestProcessor - RH1121549: coverity defects diff -r e7f5499a75d3 -r e1c7156ed0a1 netx/net/sourceforge/jnlp/Launcher.java --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Sep 17 14:20:31 2014 +0200 +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Sep 18 13:18:11 2014 -0400 @@ -83,7 +83,7 @@ private ParserSettings parserSettings = new ParserSettings(); - private Map extra = null; + private Map> extra = null; /** * Create a launcher with the runtime's default update policy @@ -191,7 +191,7 @@ * the values for keys "arguments", "parameters", and "properties" are * used. */ - public void setInformationToMerge(Map input) { + public void setInformationToMerge(Map> input) { this.extra = input; } @@ -295,22 +295,22 @@ * @throws LaunchException if an exception occurs while extracting * extra information */ - private void mergeExtraInformation(JNLPFile file, Map extra) throws LaunchException { + private void mergeExtraInformation(JNLPFile file, Map> extra) throws LaunchException { if (extra == null) { return; } - String[] properties = extra.get("properties"); + List properties = extra.get("properties"); if (properties != null) { addProperties(file, properties); } - String[] arguments = extra.get("arguments"); + List arguments = extra.get("arguments"); if (arguments != null && file.isApplication()) { addArguments(file, arguments); } - String[] parameters = extra.get("parameters"); + List parameters = extra.get("parameters"); if (parameters != null && file.isApplet()) { addParameters(file, parameters); } @@ -321,18 +321,18 @@ * @throws LaunchException if an exception occurs while extracting * extra information */ - private void addProperties(JNLPFile file, String[] props) throws LaunchException { + private void addProperties(JNLPFile file, List props) throws LaunchException { ResourcesDesc resources = file.getResources(); - for (int i = 0; i < props.length; i++) { + for (String input : props) { // allows empty property, not sure about validity of that. - int equals = props[i].indexOf("="); + int equals = input.indexOf("="); if (equals == -1) { - throw launchError(new LaunchException(R("BBadProp", props[i]))); + throw launchError(new LaunchException(R("BBadProp", input))); } - String key = props[i].substring(0, equals); - String value = props[i].substring(equals + 1, props[i].length()); + String key = input.substring(0, equals); + String value = input.substring(equals + 1, input.length()); resources.addResource(new PropertyDesc(key, value)); } @@ -344,18 +344,18 @@ * @throws LaunchException if an exception occurs while extracting * extra information */ - private void addParameters(JNLPFile file, String[] params) throws LaunchException { + private void addParameters(JNLPFile file, List params) throws LaunchException { AppletDesc applet = file.getApplet(); - for (int i = 0; i < params.length; i++) { + for (String input : params) { // allows empty param, not sure about validity of that. - int equals = params[i].indexOf("="); + int equals = input.indexOf("="); if (equals == -1) { - throw launchError(new LaunchException(R("BBadParam", params[i]))); + throw launchError(new LaunchException(R("BBadParam", input))); } - String name = params[i].substring(0, equals); - String value = params[i].substring(equals + 1, params[i].length()); + String name = input.substring(0, equals); + String value = input.substring(equals + 1, input.length()); applet.addParameter(name, value); } @@ -365,11 +365,11 @@ * Add the arguments to the JNLP file; only call if file is * actually an application (not installer). */ - private void addArguments(JNLPFile file, String[] args) { + private void addArguments(JNLPFile file, List args) { ApplicationDesc app = file.getApplication(); - for (int i = 0; i < args.length; i++) { - app.addArgument(args[i]); + for (String input : args ) { + app.addArgument(input); } } diff -r e7f5499a75d3 -r e1c7156ed0a1 netx/net/sourceforge/jnlp/OptionsDefinitions.java --- a/netx/net/sourceforge/jnlp/OptionsDefinitions.java Wed Sep 17 14:20:31 2014 +0200 +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 18 13:18:11 2014 -0400 @@ -71,6 +71,7 @@ NOHEADERS("-Xignoreheaders", "BXignoreheaders"), OFFLINE("-Xoffline", "BXoffline"), TRUSTNONE("-Xtrustnone","BOTrustnone"), + JNLP("-jnlp","BOJnlp", NumberOfArguments.ONE), //itweb settings NODASHHELP("help", "IBOHelp"), LIST("list", "IBOList"), @@ -200,7 +201,8 @@ OPTIONS.NOFORK, OPTIONS.NOHEADERS, OPTIONS.OFFLINE, - OPTIONS.TRUSTNONE}); + OPTIONS.TRUSTNONE, + OPTIONS.JNLP}); } public static List getJavaWsOptions() { diff -r e7f5499a75d3 -r e1c7156ed0a1 netx/net/sourceforge/jnlp/ParserSettings.java --- a/netx/net/sourceforge/jnlp/ParserSettings.java Wed Sep 17 14:20:31 2014 +0200 +++ b/netx/net/sourceforge/jnlp/ParserSettings.java Thu Sep 18 13:18:11 2014 -0400 @@ -37,8 +37,7 @@ package net.sourceforge.jnlp; -import java.util.Arrays; -import java.util.List; +import net.sourceforge.jnlp.util.optionparser.OptionParser; /** * Contains settings to be used by the Parser while parsing JNLP files. @@ -99,12 +98,11 @@ * at boot on the command line. These settings are also stored so they * can be retrieved at a later time. */ - public static ParserSettings setGlobalParserSettingsFromArgs(String[] cmdArgs) { - List argList = Arrays.asList(cmdArgs); - boolean strict = argList.contains("-strict"); - boolean malformedXmlAllowed = !argList.contains("-xml"); - - globalParserSettings = new ParserSettings(strict, true, malformedXmlAllowed); + public static ParserSettings setGlobalParserSettingsFromOptionParser(OptionParser optionParser) { + ParserSettings settings = new + ParserSettings(optionParser.hasOption(OptionsDefinitions.OPTIONS.STRICT), true, + !optionParser.hasOption(OptionsDefinitions.OPTIONS.XML)); + setGlobalParserSettings(settings); return globalParserSettings; } diff -r e7f5499a75d3 -r e1c7156ed0a1 netx/net/sourceforge/jnlp/runtime/Boot.java --- a/netx/net/sourceforge/jnlp/runtime/Boot.java Wed Sep 17 14:20:31 2014 +0200 +++ b/netx/net/sourceforge/jnlp/runtime/Boot.java Thu Sep 18 13:18:11 2014 -0400 @@ -22,7 +22,6 @@ import java.net.URL; import java.security.AccessController; import java.security.PrivilegedAction; -import java.util.ArrayList; import java.util.Arrays; import java.util.HashMap; import java.util.List; @@ -32,6 +31,7 @@ import net.sourceforge.jnlp.LaunchException; import net.sourceforge.jnlp.Launcher; +import net.sourceforge.jnlp.OptionsDefinitions; import net.sourceforge.jnlp.ParserSettings; import net.sourceforge.jnlp.about.AboutDialog; import net.sourceforge.jnlp.cache.CacheUtil; @@ -44,6 +44,8 @@ import net.sourceforge.jnlp.util.docprovider.TextsProvider; import net.sourceforge.jnlp.util.docprovider.formatters.formatters.PlainTextFormatter; import net.sourceforge.jnlp.util.logging.OutputController; +import net.sourceforge.jnlp.util.optionparser.InvalidArgumentException; +import net.sourceforge.jnlp.util.optionparser.OptionParser; import sun.awt.AppContext; import sun.awt.SunToolkit; @@ -88,30 +90,32 @@ + " Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n" + "\n"; - private static final String doubleArgs = "-basedir -jnlp -arg -param -property -update"; - - private static String args[]; // avoid the hot potato + private static OptionParser optionParser; /** * Launch the JNLP file specified by the command-line arguments. */ public static void main(String[] argsIn) { - args = argsIn; + optionParser = new OptionParser(argsIn, OptionsDefinitions.getJavaWsOptions()); - if (null != getOption("-verbose")) { + if (!optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP)) { + optionParser.findMainArg(); + } + + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.VERBOSE)) { JNLPRuntime.setDebug(true); } if (AppContext.getAppContext() == null) { SunToolkit.createNewAppContext(); } - if (null != getOption("-headless")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.HEADLESS)) { JNLPRuntime.setHeadless(true); } DeploymentConfiguration.move14AndOlderFilesTo15StructureCatched(); - if (null != getOption("-viewer")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.VIEWER)) { try { CertificateViewer.main(null); JNLPRuntime.exit(0); @@ -120,24 +124,24 @@ } } - if (null != getOption("-version")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.VERSION)) { OutputController.getLogger().printOutLn(nameAndVersion); JNLPRuntime.exit(0); } - if (null != getOption("-license")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.LICENSE)) { OutputController.getLogger().printOutLn(miniLicense); JNLPRuntime.exit(0); } - if (null != getOption("-help")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.HELP)) { handleMessage(); JNLPRuntime.exit(0); } - if (null != getOption("-about")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.ABOUT)) { handleAbout(); - if (null != getOption("-headless")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.HEADLESS)) { JNLPRuntime.exit(0); } else { try { @@ -152,27 +156,27 @@ } - if (null != getOption("-update")) { - int value = Integer.parseInt(getOption("-update")); + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.UPDATE)) { + int value = Integer.parseInt(optionParser.getValue(OptionsDefinitions.OPTIONS.UPDATE)); JNLPRuntime.setDefaultUpdatePolicy(new UpdatePolicy(value * 1000l)); } - if (null != getOption("-noupdate")) + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.NOUPDATE)) JNLPRuntime.setDefaultUpdatePolicy(UpdatePolicy.NEVER); - if (null != getOption("-Xnofork")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.NOFORK)) { JNLPRuntime.setForksAllowed(false); } - if (null != getOption("-Xtrustall")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.TRUSTALL)) { JNLPRuntime.setTrustAll(true); } - if (null != getOption("-Xtrustnone")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.TRUSTNONE)) { JNLPRuntime.setTrustNone(true); } - if (null != getOption("-Xignoreheaders")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.NOHEADERS)) { JNLPRuntime.setIgnoreHeaders(true); } - if (null != getOption("-allowredirect")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.REDIRECT)) { JNLPRuntime.setAllowRedirect(true); } @@ -218,8 +222,8 @@ * The privileged part (jdk1.3 compatibility). */ public Void run() { - JNLPRuntime.setSecurityEnabled(null == getOption("-nosecurity")); - JNLPRuntime.setOfflineForced(null != getOption("-Xoffline")); + JNLPRuntime.setSecurityEnabled(!optionParser.hasOption(OptionsDefinitions.OPTIONS.NOSEC)); + JNLPRuntime.setOfflineForced(optionParser.hasOption(OptionsDefinitions.OPTIONS.OFFLINE)); JNLPRuntime.initialize(true); /* @@ -228,17 +232,17 @@ * code. But we need to know what the cache and base directories are, * and baseDir is initialized here */ - if (null != getOption("-Xclearcache")) { + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.CLEARCACHE)) { CacheUtil.clearCache(); return null; } - Map extra = new HashMap(); - extra.put("arguments", getOptions("-arg")); - extra.put("parameters", getOptions("-param")); - extra.put("properties", getOptions("-property")); + Map> extra = new HashMap>(); + extra.put("arguments", optionParser.getValues(OptionsDefinitions.OPTIONS.ARG)); + extra.put("parameters", optionParser.getValues(OptionsDefinitions.OPTIONS.PARAM)); + extra.put("properties", optionParser.getValues(OptionsDefinitions.OPTIONS.PROPERTY)); - ParserSettings settings = ParserSettings.setGlobalParserSettingsFromArgs(args); + ParserSettings settings = ParserSettings.setGlobalParserSettingsFromOptionParser(optionParser); try { Launcher launcher = new Launcher(false); @@ -266,7 +270,13 @@ */ private static URL getFileLocation() { - String location = getJNLPFile(); + String location = null; + try { + location = getJNLPFile(); + } catch (InvalidArgumentException e) { + OutputController.getLogger().log(e); + fatalError("Invalid argument: "+e); + } if (location == null) { handleMessage(); @@ -294,64 +304,19 @@ /** * Gets the JNLP file from the command line arguments, or exits upon error. */ - private static String getJNLPFile() { + private static String getJNLPFile() throws InvalidArgumentException { + if (optionParser.getMainArgs().size() > 1 || (optionParser.mainArgExists() + && optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP))) { + throw new InvalidArgumentException(optionParser.getMainArg()); + } else if (optionParser.hasOption(OptionsDefinitions.OPTIONS.JNLP)) { + return optionParser.getValue(OptionsDefinitions.OPTIONS.JNLP); + } else if (optionParser.mainArgExists()) { + return optionParser.getMainArg(); + } - if (args.length == 0) { - handleMessage(); - JNLPRuntime.exit(0); - } else if (args.length == 1) { - return args[args.length - 1]; - } else { - String lastArg = args[args.length - 1]; - String secondLastArg = args[args.length - 2]; - - if (doubleArgs.indexOf(secondLastArg) == -1) { - return lastArg; - } else { - handleMessage(); - JNLPRuntime.exit(0); - } - } + handleMessage(); + JNLPRuntime.exit(0); return null; } - /** - * Return value of the first occurence of the specified - * option, or null if the option is not present. If the - * option is a flag (0-parameter) and is present then the - * option name is returned. - */ - private static String getOption(String option) { - String result[] = getOptions(option); - - if (result.length == 0) - return null; - else - return result[0]; - } - - /** - * Return all the values of the specified option, or an empty - * array if the option is not present. If the option is a - * flag (0-parameter) and is present then the option name is - * returned once for each occurrence. - */ - private static String[] getOptions(String option) { - List result = new ArrayList(); - - for (int i = 0; i < args.length; i++) { - if (option.equals(args[i])) { - if (-1 == doubleArgs.indexOf(option)) - result.add(option); - else if (i + 1 < args.length) - result.add(args[i + 1]); - } - - if (args[i].startsWith("-") && -1 != doubleArgs.indexOf(args[i])) - i++; - } - - return result.toArray(new String[result.size()]); - } - } diff -r e7f5499a75d3 -r e1c7156ed0a1 netx/net/sourceforge/jnlp/util/optionparser/InvalidArgumentException.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/util/optionparser/InvalidArgumentException.java Thu Sep 18 13:18:11 2014 -0400 @@ -0,0 +1,43 @@ +/*Copyright (C) 2014 Red Hat, Inc. + +This file is part of IcedTea. + +IcedTea is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License as published by +the Free Software Foundation, version 2. + +IcedTea is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with IcedTea; see the file COPYING. If not, write to +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 01:37:18 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 01:37:18 +0000 Subject: [Bug 2009] New: [IcedTea7] Checksum of policy JAR files changes on every build Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 Bug ID: 2009 Summary: [IcedTea7] Checksum of policy JAR files changes on every build Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org See https://bugzilla.redhat.com/show_bug.cgi?id=1142153 The checksum should only change when the actual content of the policy changes. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 01:37:34 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 01:37:34 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED URL| |https://bugzilla.redhat.com | |/show_bug.cgi?id=1142153 Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Fri Sep 19 01:38:25 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Fri, 19 Sep 2014 01:38:25 +0000 Subject: /hg/icedtea7-forest/jdk: PR2009: Checksum of policy JAR files ch... Message-ID: changeset d5d2aed90aa8 in /hg/icedtea7-forest/jdk details: http://icedtea.classpath.org/hg/icedtea7-forest/jdk?cmd=changeset;node=d5d2aed90aa8 author: andrew date: Fri Sep 19 02:38:01 2014 +0100 PR2009: Checksum of policy JAR files changes on every build diffstat: make/javax/crypto/Makefile | 63 +++++++++++++++++++++++++++++++++++---------- 1 files changed, 49 insertions(+), 14 deletions(-) diffs (95 lines): diff -r 930f4626048e -r d5d2aed90aa8 make/javax/crypto/Makefile --- a/make/javax/crypto/Makefile Wed Sep 17 15:43:58 2014 +0100 +++ b/make/javax/crypto/Makefile Fri Sep 19 02:38:01 2014 +0100 @@ -258,6 +258,8 @@ POLICY_DESTDIR = $(LIBDIR)/security UNSIGNED_POLICY_BUILDDIR = $(UNSIGNED_DIR)/policy +TEMPDIR_UNLIMITED = $(TEMPDIR)/unlimited +TEMPDIR_LIMITED = $(TEMPDIR)/limited build-policy: unlimited limited @@ -270,21 +272,37 @@ $(UNSIGNED_POLICY_BUILDDIR)/unlimited/US_export_policy.jar: \ policy/unlimited/default_US_export.policy \ - policy/unlimited/UNLIMITED + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF $(prep-target) - $(BOOT_JAR_CMD) cmf policy/unlimited/UNLIMITED $@ \ - -C policy/unlimited default_US_export.policy \ - $(BOOT_JAR_JFLAGS) - @$(java-vm-cleanup) + $(CP) policy/unlimited/default_US_export.policy \ + $(TEMPDIR_UNLIMITED) + $(TOUCH) -r $(TEMPDIR_UNLIMITED)/META-INF \ + $(TEMPDIR_UNLIMITED)/default_US_export.policy + ( $(CD) $(TEMPDIR_UNLIMITED) && $(ZIPEXE) -Xr $@ META-INF \ + default_US_export.policy ) $(UNSIGNED_POLICY_BUILDDIR)/unlimited/local_policy.jar: \ policy/unlimited/default_local.policy \ + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF + $(prep-target) + $(CP) policy/unlimited/default_local.policy \ + $(TEMPDIR_UNLIMITED) + $(TOUCH) -r $(TEMPDIR_UNLIMITED)/META-INF \ + $(TEMPDIR_UNLIMITED)/default_local.policy + ( $(CD) $(TEMPDIR_UNLIMITED) && $(ZIPEXE) -Xr $@ META-INF \ + default_local.policy ) + +$(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF: \ policy/unlimited/UNLIMITED $(prep-target) - $(BOOT_JAR_CMD) cmf policy/unlimited/UNLIMITED $@ \ - -C policy/unlimited default_local.policy \ - $(BOOT_JAR_JFLAGS) - @$(java-vm-cleanup) + $(MKDIR) -p $(TEMPDIR_UNLIMITED)/META-INF + $(ECHO) "Manifest-Version: 1.0" > \ + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF + $(CAT) policy/unlimited/UNLIMITED >> \ + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF + $(TOUCH) -t 198001010000 $(TEMPDIR_UNLIMITED)/META-INF + $(TOUCH) -r $(TEMPDIR_UNLIMITED)/META-INF \ + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF # # Build the unsigned limited policy files. @@ -303,13 +321,30 @@ $(UNSIGNED_POLICY_BUILDDIR)/limited/local_policy.jar: \ policy/limited/default_local.policy \ policy/limited/exempt_local.policy \ + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF + $(prep-target) + $(CP) policy/limited/default_local.policy \ + $(TEMPDIR_LIMITED) + $(CP) policy/limited/exempt_local.policy \ + $(TEMPDIR_LIMITED) + $(TOUCH) -r $(TEMPDIR_LIMITED)/META-INF \ + $(TEMPDIR_LIMITED)/default_local.policy + $(TOUCH) -r $(TEMPDIR_LIMITED)/META-INF \ + $(TEMPDIR_LIMITED)/exempt_local.policy + ( $(CD) $(TEMPDIR_UNLIMITED) && $(ZIPEXE) -Xr $@ META-INF \ + default_local.policy exempt_local.policy ) + +$(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF: \ policy/limited/LIMITED $(prep-target) - $(BOOT_JAR_CMD) cmf policy/limited/LIMITED $@ \ - -C policy/limited default_local.policy \ - -C policy/limited exempt_local.policy \ - $(BOOT_JAR_JFLAGS) - @$(java-vm-cleanup) + $(MKDIR) -p $(TEMPDIR_LIMITED)/META-INF + $(ECHO) "Manifest-Version: 1.0" > \ + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF + $(CAT) policy/limited/LIMITED >> \ + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF + $(TOUCH) -t 198001010000 $(TEMPDIR_LIMITED)/META-INF + $(TOUCH) -r $(TEMPDIR_LIMITED)/META-INF \ + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF UNSIGNED_POLICY_FILES = \ $(UNSIGNED_POLICY_BUILDDIR)/unlimited/US_export_policy.jar \ From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 01:38:33 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 01:38:33 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 --- Comment #1 from hg commits --- details: http://icedtea.classpath.org//hg/icedtea7-forest/jdk?cmd=changeset;node=d5d2aed90aa8 author: andrew date: Fri Sep 19 02:38:01 2014 +0100 PR2009: Checksum of policy JAR files changes on every build -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 09:48:15 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 09:48:15 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 JiriVanek changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jvanek at redhat.com --- Comment #2 from JiriVanek --- Hi! Thank you for handling this Few nits (applicable for all hunks): 1.63 + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF 1.64 + $(prep-target) 1.65 + $(CP) policy/limited/default_local.policy \ 1.66 + $(TEMPDIR_LIMITED) 1.67 + $(CP) policy/limited/exempt_local.policy \ I think that the files should be handled in bulk - copy content of limited foldr perhaps? 1.68 + $(TEMPDIR_LIMITED) 1.69 + $(TOUCH) -r $(TEMPDIR_LIMITED)/META-INF \ 1.70 + $(TEMPDIR_LIMITED)/default_local.policy 1.71 + $(TOUCH) -r $(TEMPDIR_LIMITED)/META-INF \ And same here. Instead of individual touches some bulk change. Well both those nits are probably valid only if there is slightest possibility that any change amy come. Then would be nice to actually not modify this code, but expect that the cp and touch will be applied. 1.72 + $(TEMPDIR_LIMITED)/exempt_local.policy 1.73 + ( $(CD) $(TEMPDIR_UNLIMITED) && $(ZIPEXE) -Xr $@ META-INF \ 1.74 + default_local.policy exempt_local.policy ) Last nit - why 1.1. 1980? It is not star of epoch nor anything I know. I would probably vote fo today - the date of actual change... And as final - are you sure, that custom manifest and zip instead of jar may not cause any harm in future? -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 09:51:38 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 09:51:38 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 --- Comment #3 from JiriVanek --- Also, are you planing to usptream it? -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Fri Sep 19 11:57:27 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 19 Sep 2014 13:57:27 +0200 Subject: [rfc][icedtea-web] Makefile Reproducer Tests Patch In-Reply-To: <1291906436.7217009.1411051663387.JavaMail.zimbra@redhat.com> References: <2099979744.6142171.1410899772899.JavaMail.zimbra@redhat.com> <54198326.1010305@redhat.com> <458293683.6459001.1410958464590.JavaMail.zimbra@redhat.com> <5419A1C0.8010204@redhat.com> <1291906436.7217009.1411051663387.JavaMail.zimbra@redhat.com> Message-ID: <541C1A27.9070708@redhat.com> On 09/18/2014 04:47 PM, Jie Kang wrote: > > > ----- Original Message ----- >> On 09/17/2014 02:54 PM, Jie Kang wrote: >>> >>> >>> ----- Original Message ----- >>>> On 09/16/2014 10:36 PM, Jie Kang wrote: >>>>> Hello, >>>>> >>>>> >>>>> This patch modifies the makefile and causes it to only process (compile, >>>>> copy, etc.) tests in the whitelist. >>>>> >>>>> This feature is greatly beneficial when running say >>>>> >>>>> 'make run-netx-dist-tests' >>>>> >>>>> which uses the whitelist to only run tests in the whitelist. Prior to >>>>> this >>>>> patch, though the tests ran were filtered by the whitelist, all tests >>>>> were >>>>> processed (compiled, resources moved, etc.). This wastes a large amount >>>>> of >>>>> time processing tests that aren't run. >>>>> >>>>> Thoughts? >>>>> >>>>> >>>>> Regards. >>>>> >>>> >>>> By doing so, the dependences of reproducer may not be compiled and >>>> installed. >>>> Is it what you wont? >>> >>> Hello, >>> >>> >>> If a reproducer depends on another reproducer than I think it should be up >>> to the dev to deal with that appropriately through documentation, etc. In >>> the best-case scenario, no test, including reproducers, should have any >>> dependency on another test. >>> >>> Maybe we can add this functionality as a separate option? Then test-runner >>> can choose to compile+install all tests, or compile+install only tests in >>> the whitelist. This might be a good compromise. >>> >>> >> I would say no. >> >> The author of whitelist modifications should be aware of his depnedencies. >> They are moreover easily >> grep-able from jnlp. > > Hello, > > > Just some clarification and comments :) > > > I think this is also what I meant when I said dev; The person who changes whitelist (probably a developer, but I guess not always) should know his dependencies. Sure. But consider case, that you are actually hacking some old reproducr:( Even you have missed the possibility to grep jnlp fiels for depndencies. So imagine someone less expiriecned. Also there may be some strange cornercase reproducers, where the jars are laoded dynamicaly, so it really may not be clear. > >> >> So on one side I would be happy for this change. On second side I'm >> hesitating. Imagine test testing >> class not found, loading some remote depndence. Then it will not clear if it >> failed because of >> whitelist, or becasue of bug. And imagine you are fresh to itw and encounter >> this. >> >> The configure option seems to be good compromise. BY default all will be >> compiled+isntalled. On >> demand, only whitelist. > > Okay. Sounds good, I will work on this. > >> >> if you wont you may (read must in this case) add this configure option as >> another changeset. > > I am a little confused here. When you say another changeset, do you mean I should push the current change and then add a new one on top for the 'configure option'? Or create new change and discard the current one? Yes. If you wont, you may push as it is, but you must add option later. Or you may wait, and post it as one bigger changeset. TBH I prefer the first. > >> >> The only request for now is that "*" must keep working :) > > * does work for this patch :) great. The daily report will tell;) > > > Thanks for the review!! > >> You are welcomed :) J, From jkang at redhat.com Fri Sep 19 13:09:22 2014 From: jkang at redhat.com (Jie Kang) Date: Fri, 19 Sep 2014 09:09:22 -0400 (EDT) Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <5419696D.9000400@redhat.com> References: <5419696D.9000400@redhat.com> Message-ID: <199273052.7817728.1411132162563.JavaMail.zimbra@redhat.com> Hello, I think this patch is fine. Okay for me :) On a side note: I think at this point you can ditch the singleton pattern. I am pretty sure the existence of non-private constructors, even protected ones, invalidates the singleton pattern but this is kind of semantics. I mean, you could say a class with public constructors that's only ever instantiated once is a singleton then. I think an important concept to the singleton pattern is the compile-time guarantee that no instances outside of your singleton(s) will ever get instantiated. Also, the singleton pattern by design is untestable, however the choice of use is cost-benefit. You gain the benefits of single instance with a compile-time guarantee among other things, with the costs of untestability, inability to subclass, etc. I think in general, you should really question any singleton use and try to avoid it as much as possible. If you want a testable singleton, it just doesn't really exist. For why people use enums when they choose to create a singleton, it's really because it is simple and provides pretty much everything a singleton needs. A guarantee that there is only one instance, the ability to serialize without extra work, what's not to like? Apart from the fact that it's a singleton I guess. I feel like you mean to ask, why do people use singletons, instead of why do people use enums for singletons :D Regards, ----- Original Message ----- > Hi! > > Attached patch is changing our new Transaltor to be immutable. > > > The only desired change was to > - private ResourceBundle resources; > + private final ResourceBundle resources; > > > and so .. get rid of loadResourceBundle, and so allow constructor chain of > Translator() { > this("net.sourceforge.jnlp.resources.Messages"); > } > > Translator(String s) { > this(ResourceBundle.getBundle(s)); > } > } > > Translator(ResourceBundle resources) { > this.resources = resources; > } > > And so make it instantiatable and consequentially adapt the test.... > And so get rid of enum in favor of class, and so use handler idiom for > creation.... > > > Personally, why people use enums for singletons?!?!?! Well very simple > singletons .. yes, but once > there is some logic... Ouch they are so so *clumsy* ... So clamsy taht they > can not be even properly > tested ( no instance!, no overrload!). And once singleton is not > immutbale.... Is it still singleton? > > Afaik the state after the patch is better: > - singleton is still singleton > - newly: > - initialized on demand > - immutable > - the tets are done on separate copy, not on the changed singleton itself > (aaargh) > > > Any comment why to keep enum welcomed.... > > > J. > -- Jie Kang From jvanek at redhat.com Fri Sep 19 13:34:53 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 19 Sep 2014 15:34:53 +0200 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <199273052.7817728.1411132162563.JavaMail.zimbra@redhat.com> References: <5419696D.9000400@redhat.com> <199273052.7817728.1411132162563.JavaMail.zimbra@redhat.com> Message-ID: <541C30FD.7070406@redhat.com> On 09/19/2014 03:09 PM, Jie Kang wrote: > Hello, > > I think this patch is fine. Okay for me :) > > > On a side note: > > I think at this point you can ditch the singleton pattern. I am pretty sure the existence of non-private constructors, even protected ones, invalidates the singleton pattern but this is kind of semantics. I mean, you could say a class with public constructors that's only ever instantiated once is a singleton then. I think an important concept to the singleton pattern is the compile-time guarantee that no instances outside of your singleton(s) will ever get instantiated. > > Also, the singleton pattern by design is untestable, however the choice of use is cost-benefit. You gain the benefits of single instance with a compile-time guarantee among other things, with the costs of untestability, inability to subclass, etc. I think in general, you should really question any singleton use and try to avoid it as much as possible. If you want a testable singleton, it just doesn't really exist. > I'm not sure how to feel about that. Partially I agree, And I already once experienced, that another programmer was happily instantiate singletons, simply because he could. And that flaw was found really late. So from this point, the enum is much MUCH better. However, this can be solved by private constructor. And imho even our case canbe transformed to this more correct case. Do you wont to as exercise? :) By this trick* the enum lost all its disadvantages. Another way how to achive this is to heve also getInstance private, and have only static api... > > For why people use enums when they choose to create a singleton, it's really because it is simple and provides pretty much everything a singleton needs. A guarantee that there is only one instance, the ability to serialize without extra work, what's not to like? Apart from the fact that it's a singleton I guess. * trick - yes - because you need to bent the testable instances classes to workaround it. Is the enum really so protective? Imho not - on level of bytecode you can manipualte it and all those check you wont from it are gone.... > > I feel like you mean to ask, why do people use singletons, instead of why do people use enums for singletons :D Oh definitely not. Acctually I'm big fan of singletons. And I prefer theirs usages over static where possible. > > > Regards, Sumamrised my inner thoughts - to be able to test is more necessary then compile time check on singularity. How is this achived, and checked ..well impelmented . is different issue ... - more social engineering then artificial one. J. From sbaiduzh at redhat.com Fri Sep 19 13:47:40 2014 From: sbaiduzh at redhat.com (Stanislav Baiduzhyi) Date: Fri, 19 Sep 2014 15:47:40 +0200 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <541C30FD.7070406@redhat.com> References: <5419696D.9000400@redhat.com> <199273052.7817728.1411132162563.JavaMail.zimbra@redhat.com> <541C30FD.7070406@redhat.com> Message-ID: <10692133.0vgS1ngEfF@sbaiduzh-main.redhat> On Friday 19 September 2014 15:34:53 Jiri Vanek wrote: > Oh definitely not. Acctually I'm big fan of singletons. And I prefer theirs > usages over static where possible. Huh. You're just exchanging evil for little lesser evil, that's it. Try Guice and forget about the issue all together. You'll have both cleaner code and testability, and there will be no need to fight for the best implementation of singleton. -- Regards, Stas From jvanek at redhat.com Fri Sep 19 13:52:45 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 19 Sep 2014 15:52:45 +0200 Subject: [rfc][icedtea-web] immutbale transaltor In-Reply-To: <10692133.0vgS1ngEfF@sbaiduzh-main.redhat> References: <5419696D.9000400@redhat.com> <199273052.7817728.1411132162563.JavaMail.zimbra@redhat.com> <541C30FD.7070406@redhat.com> <10692133.0vgS1ngEfF@sbaiduzh-main.redhat> Message-ID: <541C352D.5080208@redhat.com> On 09/19/2014 03:47 PM, Stanislav Baiduzhyi wrote: > On Friday 19 September 2014 15:34:53 Jiri Vanek wrote: >> Oh definitely not. Acctually I'm big fan of singletons. And I prefer theirs >> usages over static where possible. > > Huh. You're just exchanging evil for little lesser evil, that's it. Try Guice > and forget about the issue all together. You'll have both cleaner code and > testability, and there will be no need to fight for the best implementation of > singleton. > Fair enough. Dependency injection is cure for most of this kind of issues. J. From jvanek at redhat.com Fri Sep 19 14:11:33 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 19 Sep 2014 16:11:33 +0200 Subject: [rfc][icedtea-web][itweb-settings] itweb-settings use Option Parser In-Reply-To: <2136433079.7489666.1411075684213.JavaMail.zimbra@redhat.com> References: <2136433079.7489666.1411075684213.JavaMail.zimbra@redhat.com> Message-ID: <541C3995.2080104@redhat.com> On 09/18/2014 11:28 PM, Lukasz Dracz wrote: > Hello, > > I have worked on changing itwebsettings to use the Option Parser. It odes not :) It changes the argument recognition of itweb-settings completely.... Although this change may be dangerous, I like it. > The biggest change this code brings is the ability to do multiple itwebsettings options at once, you can for example > set and get or reset and set (reset happens first then set is applied). Also I have reworked get, info, set, and reset to allow to take in multiple args instead of just one. Ex. 'itweb-settings get deployment.security.level deployment.manifest.attributes.check deployment.console.startup.mode' will get all three. > > itweb-settings help will display the main help, where as itwebsettings get help will display the specific help for get. If help is present and other options are present it will get the help for all the other options Ex. itweb-settings get help reset check will get the help for (get, reset and check). A limitation is you can't do for ex. 'itweb-setting get help reset all info deployment.javapi.cache.enabled' this will simply display help for get, reset and info only. I can look into getting it to work by displaying help for get, resetting all and getting the info for deployment.javapi.cache.enabled, but then I think I am going to have to limit the help to appear right after the command which would lead to for example, itweb-settings get help reset help info help to get help for all. I'm just wondering if anyone has an opinion on this matter of what would be the preferred way to handle this. > > Also looking at the main help that is outputted 'check name - Checks that the current value of the setting is a valid value.' that description is not accurate of what happens in the code. The check option checks through all the values and outputs those that are wrong. Should I implement it to work by just checking the named value if available and just check all if nothing is specified or should the help message text be changed ? Personally I think it is fine as it is and the help message text should just be changed to how it works. Mayor hints - when resetAll is presented - then no metter of other arguments, the processing have tobe stopped, and user warned - Something like "resetAl found. If you wont to use this comamnd, use it alone. Otherwise reomvoe it from comamndline". And halt. - the docs must be adjusted - description of all affected OptionDefinitions in messages. properties. - general documentation to itweb=settings commandline (can be done as separate changeset) - there is bug in check's docs - it stays it need parameter what to check - there is (unrelated to your changset) "bug" in check - it is ruing validators, and validators do (if application is running under X ) poping joption pane - maybe we can add hedless support ? (afaik only need is to JNLPruntime.setHeadless(parser.has(HEADLESS) ) - but needs testing - zzz 10minutel alter - nother bug - once reset(all) is caled - then it runs validators on old values.. whyyyy? - how does it behave when multiple combinations of reset,set,get,info are presented? - what about some cornercase like set property=value get something set p.t=abc reset aaa get aaa set aaa=bbbb .... - I would expect it will set proeprty to value, prints out vlae of something, set p.t to abc, reset aaa to defaul and set aaa to bbbb - it does not seem to do this:( - after your patch - it does only set proeprty to value, prints out vlae of something. The second set would never be executed. right? - imho the safest way is to allow only one of set | reset | get | chec.. And if more of thsoe is present.Simply die. Is it even possibele with your current parserimplementation to recognize two identical options presented two times? If no, then stop execution is the only way:( - there is significant change in behaviour - before it was accepting set name value - now it seems to me to accept set name=value, or not? - considering the nature of purpos of this tool, I would stay withold approach, or with both. Not only with new ;( little bit more inline > > Thank you, > Lukasz Dracz > > > itwebsettingsOptionParser-2.patch > > > diff -r e1c7156ed0a1 netx/net/sourceforge/jnlp/OptionsDefinitions.java > --- a/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 18 13:18:11 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 18 17:01:32 2014 -0400 > @@ -75,11 +75,11 @@ > //itweb settings > NODASHHELP("help", "IBOHelp"), > LIST("list", "IBOList"), > - GET("get", "name", "IBOGet"), > - INFO("info", "name", "IBOInfo"), > - SET("set", "name value", "IBOSet"), > + GET("get", "name", "IBOGet", NumberOfArguments.ONE_OR_MORE), > + INFO("info", "name", "IBOInfo", NumberOfArguments.ONE_OR_MORE), > + SET("set", "name value", "IBOSet", NumberOfArguments.ONE_OR_MORE), > RESETALL("reset", "all", "IBOResetAll"), > - RESET("reset", "name", "IBOReset"), > + RESET("reset", "name", "IBOReset", NumberOfArguments.ONE_OR_MORE), > CHECK("check", "name", "IBOCheck"), > //policyeditor > //-help > @@ -160,8 +160,8 @@ > OPTIONS.GET, > OPTIONS.INFO, > OPTIONS.SET, > + OPTIONS.RESET, > OPTIONS.RESETALL, > - OPTIONS.RESET, > OPTIONS.CHECK > }); > } > diff -r e1c7156ed0a1 netx/net/sourceforge/jnlp/controlpanel/CommandLine.java > --- a/netx/net/sourceforge/jnlp/controlpanel/CommandLine.java Thu Sep 18 13:18:11 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/controlpanel/CommandLine.java Thu Sep 18 17:01:32 2014 -0400 > @@ -37,16 +37,18 @@ > import net.sourceforge.jnlp.util.docprovider.TextsProvider; > import net.sourceforge.jnlp.util.docprovider.formatters.formatters.PlainTextFormatter; > import net.sourceforge.jnlp.util.logging.OutputController; > +import net.sourceforge.jnlp.util.optionparser.OptionParser; > +import sun.net.dns.ResolverConfiguration; You left unused imports here. > > /** > * Encapsulates a command line interface to the deployment configuration. > *

    > - * The central method is {@link #handle(String[])}, which calls one of the > - * various 'handle' methods. The commands listed in {@link #allCommands} are > + * The central method is {@link #handle()}, which calls one of the > + * various 'handle' methods. The commands listed in OptionsDefinitions are > * supported. For each supported command, a method handleCOMMANDCommand exists. > * This method actually takes action based on the command. Generally, a > * printCOMMANDHelp method also exists, and prints out the help message for > - * that specific command. For example, see {@link #handleListCommand(List)} > + * that specific command. For example, see {@link #handleListCommand()} > * and {@link #printListHelp()}. > *

    > * Sample usage: ... > - val = handleCheckCommand(arguments); > - } else { > - OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownCommand", command)); > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.SET)) { > + val = handleSetCommand(); > + } > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.GET)) { > + val = handleGetCommand(); > + } > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.INFO)) { > + val = handleInfoCommand(); > + } > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.CHECK)) { > + val = handleCheckCommand(); > + } Oooooou.. I like this so much... > + if (optionParser.mainArgExists()) { > + OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownCommand", optionParser.getMainArgs())); > handleHelpCommand(); > val = ERROR; > + } else if (optionParser.hasOption(OptionsDefinitions.OPTIONS.NODASHHELP) && optionParser.getNumberOfOptions() == 1) { > + val = handleHelpCommand(); > } > > return val; > @@ -467,11 +461,13 @@ > */ > public static void main(String[] args) throws Exception { > DeploymentConfiguration.move14AndOlderFilesTo15StructureCatched(); > + optionParser = new OptionParser(args, OptionsDefinitions.getItwsettingsCommands()); > + > if (args.length == 0) { > ControlPanel.main(new String[] {}); > } else { > CommandLine cli = new CommandLine(); > - int result = cli.handle(args); > + int result = cli.handle(); > > // instead of returning, use JNLPRuntime.exit() so we can pass back > // error codes indicating success or failure. Otherwise using > diff -r e1c7156ed0a1 netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java > --- a/netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java Thu Sep 18 13:18:11 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java Thu Sep 18 17:01:32 2014 -0400 > @@ -83,12 +83,20 @@ > } else { > lastOption = args[i]; > if (parsedOptions.keySet().contains(getOption(lastOption))) { > + > if (getOption(lastOption).hasOneOrMoreArguments()) { > - result = new ArrayList<>(parsedOptions.get(getOption(lastOption))); > + > + if (parsedOptions.get(getOption(lastOption)) == null) { > + result = new ArrayList<>(); > + } else { > + result = new ArrayList<>(parsedOptions.get(getOption(lastOption))); > + } > } > + } else { > + parsedOptions.put(getOption(lastOption), null); > } > + > if (getOption(lastOption).hasNoArguments()) { > - parsedOptions.put(getOption(lastOption), null); > lastOption = MAINARG; > } > } > @@ -214,4 +222,30 @@ > } > return new ArrayList<>(); > } > + > + public List getValuesSplitOn(OptionsDefinitions.OPTIONS option, String symbol) { > + List values = new ArrayList<>(); > + for (String arg : getValues(option)) { > + if (arg.contains(symbol)) { > + for (String val : arg.split(symbol)) { > + values.add(val); > + } > + } else { > + values.add(arg); > + } > + } > + return values; > + } Here is valid same issue as in your first opton parser. What is value consists of symbol? param=va=lu=e will be broken :( But this will be valid only if we agree on bothold and new style. If we agree only on old one those will go out:( Anyway - nitpickers nit - tey both should be static and tested :) > + > + public List getValuesSplitOnEquals(OptionsDefinitions.OPTIONS option) { > + return getValuesSplitOn(option, "="); > + } > + > + public int getNumberOfOptions() { > + if (mainArgExists()) { > + return parsedOptions.size() - 1; > + } > + return parsedOptions.size(); > + } > + > } > int to two "unrelated" bugs - both shoud be fixe din this changeset - as tis is mayor rework of the inpur handling. Thak you! (well compared to this, th epolicyeditor will be children's palyground for you :) ) J. From jvanek at icedtea.classpath.org Fri Sep 19 14:13:58 2014 From: jvanek at icedtea.classpath.org (jvanek at icedtea.classpath.org) Date: Fri, 19 Sep 2014 14:13:58 +0000 Subject: /hg/icedtea-web: Translator made immutable Message-ID: changeset 85ede1a5ab91 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=85ede1a5ab91 author: Jiri Vanek date: Fri Sep 19 14:06:23 2014 +0200 Translator made immutable diffstat: ChangeLog | 10 ++ netx/net/sourceforge/jnlp/runtime/Translator.java | 48 ++++++--- tests/netx/unit/net/sourceforge/jnlp/runtime/TranslatorTest.java | 36 ++++++- 3 files changed, 73 insertions(+), 21 deletions(-) diffs (172 lines): diff -r e1c7156ed0a1 -r 85ede1a5ab91 ChangeLog --- a/ChangeLog Thu Sep 18 13:18:11 2014 -0400 +++ b/ChangeLog Fri Sep 19 14:06:23 2014 +0200 @@ -1,3 +1,13 @@ +2014-09-19 Jiri Vanek + + Translator made immutable + * netx/net/sourceforge/jnlp/runtime/Translator.java: changed form enum to class, + initialization handled by holder pattern, resources made final, removed + loadResourceBundle, getMessage made protected. + * tests/netx/unit/net/sourceforge/jnlp/runtime/TranslatorTest.java: (setup) + (and all tests) now uses special instance based on fake resources. Added + two tests to test singleton instance itself. + 2014-09-18 Lukasz Dracz Added New Option Parser and used in boot of javaws diff -r e1c7156ed0a1 -r 85ede1a5ab91 netx/net/sourceforge/jnlp/runtime/Translator.java --- a/netx/net/sourceforge/jnlp/runtime/Translator.java Thu Sep 18 13:18:11 2014 -0400 +++ b/netx/net/sourceforge/jnlp/runtime/Translator.java Fri Sep 19 14:06:23 2014 +0200 @@ -24,24 +24,43 @@ /** * Utility class to provide simple methods to help localize messages */ -public enum Translator { +public class Translator { - INSTANCE; + private static class TranslatorHolder { - /** the localized resource strings */ - private ResourceBundle resources; + //https://en.wikipedia.org/wiki/Double-checked_locking#Usage_in_Java + //https://en.wikipedia.org/wiki/Initialization_on_demand_holder_idiom + private static final Translator INSTANCE = new Translator(); - private Translator() { - try { - resources = ResourceBundle.getBundle("net.sourceforge.jnlp.resources.Messages"); - } catch (Exception ex) { - throw new IllegalStateException("No bundles found for Locale: " + Locale.getDefault().toString() + - "and missing base resource bundle in netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); + private static Translator getTransaltor() { + return TranslatorHolder.INSTANCE; } } + /** + * the localized resource strings + */ + private final ResourceBundle resources; + + Translator() { + this("net.sourceforge.jnlp.resources.Messages"); + } + + Translator(String s) { + try { + resources = ResourceBundle.getBundle(s); + } catch (Exception ex) { + throw new IllegalStateException("No bundles found for Locale: " + Locale.getDefault().toString() + + "and missing base resource bundle in netx.jar:net/sourceforge/jnlp/resource/Messages.properties"); + } + } + + Translator(ResourceBundle resources) { + this.resources = resources; + } + public static Translator getInstance() { - return Translator.INSTANCE; + return TranslatorHolder.getTransaltor(); } /** @@ -60,16 +79,13 @@ return getInstance().getMessage(message, params); } - protected void loadResourceBundle(ResourceBundle bundle) { - this.resources = bundle; - } - + /** * Returns the localized resource string using the specified arguments. * * @param args the formatting arguments to the resource string */ - private String getMessage(String key, Object... args) { + protected String getMessage(String key, Object... args) { return MessageFormat.format(getMessage(key), args); } diff -r e1c7156ed0a1 -r 85ede1a5ab91 tests/netx/unit/net/sourceforge/jnlp/runtime/TranslatorTest.java --- a/tests/netx/unit/net/sourceforge/jnlp/runtime/TranslatorTest.java Thu Sep 18 13:18:11 2014 -0400 +++ b/tests/netx/unit/net/sourceforge/jnlp/runtime/TranslatorTest.java Fri Sep 19 14:06:23 2014 +0200 @@ -9,12 +9,27 @@ import java.net.URLClassLoader; import java.util.Locale; import java.util.ResourceBundle; +import org.junit.Assert; import org.junit.Before; import org.junit.Test; public class TranslatorTest { + private static class TestableTranslator extends Translator { + + public TestableTranslator(ResourceBundle bundle) { + super(bundle); + } + + public String translate(String message, Object... params) { + return super.getMessage(message, params); + } + } + TestableTranslator translator; + + + @Before public void setup() throws IOException { File f = new File(System.getProperty("java.io.tmpdir"), "test.properties"); @@ -31,30 +46,41 @@ ClassLoader loader = new URLClassLoader(new URL[] {u}); ResourceBundle bundle = ResourceBundle.getBundle("test", Locale.getDefault(), loader); - Translator.getInstance().loadResourceBundle(bundle); + translator = new TestableTranslator(bundle); } @Test public void testTranslateNonExistingMessage() { - String message = Translator.R("doesn't-exist"); + String message = translator.translate("doesn't-exist"); assertEquals("no-resource", message); } @Test public void testTranslateNullMessage() { - String message = Translator.R(null); + String message = translator.translate(null); assertEquals("no-resource", message); } @Test public void testTranslateMessage() { - String message = Translator.R("key"); + String message = translator.translate("key"); assertEquals("value", message); } @Test public void testTranslateMessageWithArgs() { - String message = Translator.R("argkey", new Object[] {"Hello"}); + String message = translator.translate("argkey", new Object[] {"Hello"}); assertEquals("value Hello", message); } + + @Test + public void singletonTest1() { + String message = Translator.R("key"); + Assert.assertNotEquals("value", message); + } + @Test + public void singletonTest2() { + String message = Translator.R("unknown-key"); + Assert.assertTrue(message.contains("unknown-key")); + } } From gnu.andrew at redhat.com Fri Sep 19 14:52:19 2014 From: gnu.andrew at redhat.com (Andrew Hughes) Date: Fri, 19 Sep 2014 10:52:19 -0400 (EDT) Subject: open jdk iced tea 7u09 In-Reply-To: <1407697445.98883.YahooMailNeo@web133004.mail.ir2.yahoo.com> References: <1407697445.98883.YahooMailNeo@web133004.mail.ir2.yahoo.com> Message-ID: <575456914.25558182.1411138339967.JavaMail.zimbra@redhat.com> ----- Original Message ----- > Hello > I'm looking for open jdk iced tea 7u09 that is distributed with redhat 6.4 I > cannot find it in the website, ould you please help me ? > > > Thanks > Stefano 7u09 is the OpenJDK version used by IcedTea, not the IcedTea version. We list the corresponding versions here: http://icedtea.classpath.org/wiki/Main_Page but 7u09 is now very old and no longer listed. Looking through older versions, I can't actually see a u09. 2.1 = u03 2.2 = u05 2.3 = u25 My guess would be that what you have is an very old version of 2.3. However, RHEL uses just the OpenJDK forest from IcedTea, rather than IcedTea itself, so it's hard to tell what you actually have. I would suggest upgrading if you're running this, as there are many security issues present in that version. Hope that helps, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) PGP Key: 248BDC07 (https://keys.indymedia.org/) Fingerprint = EC5A 1F5E C0AD 1D15 8F1F 8F91 3B96 A578 248B DC07 From jkang at redhat.com Fri Sep 19 17:51:45 2014 From: jkang at redhat.com (Jie Kang) Date: Fri, 19 Sep 2014 13:51:45 -0400 (EDT) Subject: [rfc][icedtea-web] possible class cast exception in splashcontroler In-Reply-To: <5419596C.7060101@redhat.com> References: <5419596C.7060101@redhat.com> Message-ID: <1688856320.8186878.1411149105125.JavaMail.zimbra@redhat.com> ----- Original Message ----- > Some applets, may not be using the original apllet-viewer-pane, but rather > *detach*, and are in > separate window. > > If such an applet fails, the error screen can not be drawn, because the > applications frame is not > SpalshController. > > As splash logic can live happily with null splashcontoloere (==not work, and > silently exit) , the > class cast exception is unnecessary. > > There is nothing to be done to save the application as it already died, but > the error is imho really > unnecessary. Hello, Can you fix the type in: getSplashControler() to getSplashController() Could you also see if a test/reproducer can be added to make sure that a null return value is okay? (Can be another changeset) I looked through the code and it should be fine but a test to make sure would be great. Apart from that the patch looks fine. Regards, > > J > > -- Jie Kang From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 18:11:45 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 18:11:45 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 --- Comment #4 from Andrew John Hughes --- I see your point about using the whole directory, but I went with individual files because they are explicitly mentioned as dependencies in the Makefile rules and were explicitly referenced in creating the JAR files originally. So, the original version would have suffered from the same issue too if new files were added. Additionally, the downside of using the whole directory is we might equally pick up something we don't want... I also wrote the unlimited versions (the ones we actually use) first, so the limited one ended up being copy and paste ;) 1/1/1980 is the epoch for ZIP files (based on MS-DOS I presume). I use 1/1/1970 (the UNIX epoch) initially and it became 1/1/1980. Using the current date would make the policy file newer than it already is (2010, I think), so I used the epoch as that's using what's used if the date is "don't know" (tar files with no timestamps use 1-1-1970, for instance). I can't see it causing any harm. Looking at the code that uses this, the manifest is never used, as far as I can see. I think the only reason it's in a JAR file at all is because Oracle sign their versions. If it wasn't for this, the original text file could have just been used, without all these issues. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 18:12:24 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 18:12:24 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 --- Comment #5 from Andrew John Hughes --- Oh, and yes, I plan to upstream it, but I have to do an 8 & 9 version first... That's the blocker with most of my patches. This new build is a real pain in that respect. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Fri Sep 19 19:07:00 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:07:00 +0000 Subject: /hg/release/icedtea7-forest-2.5/jdk: 8 new changesets Message-ID: changeset f37b9f3ff913 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=f37b9f3ff913 author: andrew date: Wed Aug 27 16:20:16 2014 +0100 4963723: Implement SHA-224 Summary: Add support for SHA-224, SHA224withRSA, SHA224withECDSA, HmacSHA224 and OAEPwithSHA-224AndMGF1Padding. Reviewed-by: vinnie Original-by: valeriep changeset 8692818e60c5 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=8692818e60c5 author: andrew date: Wed Aug 27 18:40:41 2014 +0100 7044060: Need to support NSA Suite B Cryptography algorithms Summary: Add support for DSA parameter generation and OIDs for NSA Suite B algorithms. Reviewed-by: vinnie Original-by: valeriep changeset c24a5c865b22 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=c24a5c865b22 author: xuelei date: Thu Apr 18 22:23:56 2013 -0700 8006935: Need to take care of long secret keys in HMAC/PRF compuation Reviewed-by: valeriep changeset 9332dff476b5 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=9332dff476b5 author: andrew date: Mon Sep 08 18:46:06 2014 +0100 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose changeset 0312f617199a in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=0312f617199a author: andrew date: Wed Sep 10 17:12:24 2014 +0100 PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 changeset d743166ebdd2 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=d743166ebdd2 author: andrew date: Wed Sep 17 15:43:58 2014 +0100 PR2003: --disable-system-gtk option broken by refactoring in PR1736 changeset 5a15406ba951 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=5a15406ba951 author: andrew date: Fri Sep 19 02:38:01 2014 +0100 PR2009: Checksum of policy JAR files changes on every build changeset fa4e5dae68e1 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=fa4e5dae68e1 author: andrew date: Fri Sep 19 20:06:43 2014 +0100 Bump to 2.5.3pre01 diffstat: make/javax/crypto/Makefile | 63 +- make/jdk_generic_profile.sh | 84 +- make/sun/gtk/Makefile | 2 + src/share/classes/com/sun/crypto/provider/AESCipher.java | 113 +- src/share/classes/com/sun/crypto/provider/AESWrapCipher.java | 36 +- src/share/classes/com/sun/crypto/provider/DHKeyPairGenerator.java | 17 +- src/share/classes/com/sun/crypto/provider/DHParameterGenerator.java | 10 +- src/share/classes/com/sun/crypto/provider/HmacCore.java | 159 +- src/share/classes/com/sun/crypto/provider/HmacMD5.java | 92 +- src/share/classes/com/sun/crypto/provider/HmacPKCS12PBESHA1.java | 81 +- src/share/classes/com/sun/crypto/provider/HmacSHA1.java | 92 +- src/share/classes/com/sun/crypto/provider/KeyGeneratorCore.java | 63 +- src/share/classes/com/sun/crypto/provider/OAEPParameters.java | 4 +- src/share/classes/com/sun/crypto/provider/SunJCE.java | 95 +- src/share/classes/com/sun/crypto/provider/TlsPrfGenerator.java | 21 +- src/share/classes/java/security/interfaces/DSAKeyPairGenerator.java | 16 +- src/share/classes/java/security/spec/MGF1ParameterSpec.java | 3 +- src/share/classes/java/security/spec/PSSParameterSpec.java | 3 +- src/share/classes/sun/security/ec/ECDSASignature.java | 10 +- src/share/classes/sun/security/ec/SunECEntries.java | 20 +- src/share/classes/sun/security/pkcs11/P11Cipher.java | 34 +- src/share/classes/sun/security/pkcs11/P11Digest.java | 5 +- src/share/classes/sun/security/pkcs11/P11Mac.java | 9 +- src/share/classes/sun/security/pkcs11/P11Signature.java | 10 + src/share/classes/sun/security/pkcs11/SunPKCS11.java | 72 +- src/share/classes/sun/security/pkcs11/wrapper/Functions.java | 7 +- src/share/classes/sun/security/provider/DSA.java | 810 +++++---- src/share/classes/sun/security/provider/DSAKeyPairGenerator.java | 92 +- src/share/classes/sun/security/provider/DSAParameterGenerator.java | 269 +- src/share/classes/sun/security/provider/DigestBase.java | 27 +- src/share/classes/sun/security/provider/MD2.java | 21 +- src/share/classes/sun/security/provider/MD4.java | 18 +- src/share/classes/sun/security/provider/MD5.java | 18 +- src/share/classes/sun/security/provider/ParameterCache.java | 166 +- src/share/classes/sun/security/provider/SHA.java | 19 +- src/share/classes/sun/security/provider/SHA2.java | 72 +- src/share/classes/sun/security/provider/SHA5.java | 38 +- src/share/classes/sun/security/provider/SunEntries.java | 46 +- src/share/classes/sun/security/rsa/RSASignature.java | 13 +- src/share/classes/sun/security/rsa/SunRsaSignEntries.java | 8 +- src/share/classes/sun/security/spec/DSAGenParameterSpec.java | 129 + src/share/classes/sun/security/x509/AlgorithmId.java | 49 +- src/solaris/native/common/deps/gtk2/gtk_fp.c | 3 - src/solaris/native/common/deps/gtk2/gtk_fp.h | 10 +- src/solaris/native/common/deps/gtk2/gtk_fp_check.c | 2 + src/solaris/native/common/deps/gtk2/gtk_fp_check.h | 17 + src/solaris/native/sun/net/spi/DefaultProxySelector.c | 97 +- src/windows/classes/sun/security/mscapi/RSASignature.java | 13 +- src/windows/classes/sun/security/mscapi/SunMSCAPI.java | 20 +- test/com/sun/crypto/provider/Cipher/RSA/TestOAEP.java | 16 +- test/com/sun/crypto/provider/Cipher/RSA/TestOAEPParameterSpec.java | 3 +- test/com/sun/crypto/provider/Cipher/RSA/TestOAEPWithParams.java | 6 +- test/com/sun/crypto/provider/KeyAgreement/TestExponentSize.java | 24 +- test/com/sun/crypto/provider/KeyGenerator/Test4628062.java | 68 +- test/com/sun/crypto/provider/Mac/MacClone.java | 46 +- test/com/sun/crypto/provider/Mac/MacKAT.java | 29 +- test/sun/security/mscapi/SignUsingNONEwithRSA.java | 8 +- test/sun/security/mscapi/SignUsingSHA2withRSA.java | 6 +- test/sun/security/pkcs11/MessageDigest/DigestKAT.java | 8 +- test/sun/security/pkcs11/MessageDigest/TestCloning.java | 2 +- test/sun/security/pkcs11/Signature/TestRSAKeyLength.java | 4 +- test/sun/security/pkcs11/ec/TestCurves.java | 3 +- test/sun/security/pkcs11/ec/TestECDH2.java | 127 + test/sun/security/pkcs11/ec/TestECDSA2.java | 122 + test/sun/security/pkcs11/rsa/TestKeyPairGenerator.java | 3 +- test/sun/security/pkcs11/rsa/TestSignatures.java | 3 +- test/sun/security/provider/DSA/TestAlgParameterGenerator.java | 117 + test/sun/security/provider/DSA/TestDSA2.java | 96 + test/sun/security/provider/DSA/TestKeyPairGenerator.java | 6 +- test/sun/security/provider/MessageDigest/DigestKAT.java | 10 +- test/sun/security/provider/MessageDigest/Offsets.java | 3 +- test/sun/security/provider/MessageDigest/TestSHAClone.java | 6 +- test/sun/security/rsa/TestKeyPairGenerator.java | 5 +- test/sun/security/rsa/TestSignatures.java | 5 +- 74 files changed, 2450 insertions(+), 1354 deletions(-) diffs (truncated from 6289 to 500 lines): diff -r eb70b48e4211 -r fa4e5dae68e1 make/javax/crypto/Makefile --- a/make/javax/crypto/Makefile Wed Sep 03 15:34:29 2014 +0100 +++ b/make/javax/crypto/Makefile Fri Sep 19 20:06:43 2014 +0100 @@ -258,6 +258,8 @@ POLICY_DESTDIR = $(LIBDIR)/security UNSIGNED_POLICY_BUILDDIR = $(UNSIGNED_DIR)/policy +TEMPDIR_UNLIMITED = $(TEMPDIR)/unlimited +TEMPDIR_LIMITED = $(TEMPDIR)/limited build-policy: unlimited limited @@ -270,21 +272,37 @@ $(UNSIGNED_POLICY_BUILDDIR)/unlimited/US_export_policy.jar: \ policy/unlimited/default_US_export.policy \ - policy/unlimited/UNLIMITED + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF $(prep-target) - $(BOOT_JAR_CMD) cmf policy/unlimited/UNLIMITED $@ \ - -C policy/unlimited default_US_export.policy \ - $(BOOT_JAR_JFLAGS) - @$(java-vm-cleanup) + $(CP) policy/unlimited/default_US_export.policy \ + $(TEMPDIR_UNLIMITED) + $(TOUCH) -r $(TEMPDIR_UNLIMITED)/META-INF \ + $(TEMPDIR_UNLIMITED)/default_US_export.policy + ( $(CD) $(TEMPDIR_UNLIMITED) && $(ZIPEXE) -Xr $@ META-INF \ + default_US_export.policy ) $(UNSIGNED_POLICY_BUILDDIR)/unlimited/local_policy.jar: \ policy/unlimited/default_local.policy \ + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF + $(prep-target) + $(CP) policy/unlimited/default_local.policy \ + $(TEMPDIR_UNLIMITED) + $(TOUCH) -r $(TEMPDIR_UNLIMITED)/META-INF \ + $(TEMPDIR_UNLIMITED)/default_local.policy + ( $(CD) $(TEMPDIR_UNLIMITED) && $(ZIPEXE) -Xr $@ META-INF \ + default_local.policy ) + +$(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF: \ policy/unlimited/UNLIMITED $(prep-target) - $(BOOT_JAR_CMD) cmf policy/unlimited/UNLIMITED $@ \ - -C policy/unlimited default_local.policy \ - $(BOOT_JAR_JFLAGS) - @$(java-vm-cleanup) + $(MKDIR) -p $(TEMPDIR_UNLIMITED)/META-INF + $(ECHO) "Manifest-Version: 1.0" > \ + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF + $(CAT) policy/unlimited/UNLIMITED >> \ + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF + $(TOUCH) -t 198001010000 $(TEMPDIR_UNLIMITED)/META-INF + $(TOUCH) -r $(TEMPDIR_UNLIMITED)/META-INF \ + $(TEMPDIR_UNLIMITED)/META-INF/MANIFEST.MF # # Build the unsigned limited policy files. @@ -303,13 +321,30 @@ $(UNSIGNED_POLICY_BUILDDIR)/limited/local_policy.jar: \ policy/limited/default_local.policy \ policy/limited/exempt_local.policy \ + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF + $(prep-target) + $(CP) policy/limited/default_local.policy \ + $(TEMPDIR_LIMITED) + $(CP) policy/limited/exempt_local.policy \ + $(TEMPDIR_LIMITED) + $(TOUCH) -r $(TEMPDIR_LIMITED)/META-INF \ + $(TEMPDIR_LIMITED)/default_local.policy + $(TOUCH) -r $(TEMPDIR_LIMITED)/META-INF \ + $(TEMPDIR_LIMITED)/exempt_local.policy + ( $(CD) $(TEMPDIR_UNLIMITED) && $(ZIPEXE) -Xr $@ META-INF \ + default_local.policy exempt_local.policy ) + +$(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF: \ policy/limited/LIMITED $(prep-target) - $(BOOT_JAR_CMD) cmf policy/limited/LIMITED $@ \ - -C policy/limited default_local.policy \ - -C policy/limited exempt_local.policy \ - $(BOOT_JAR_JFLAGS) - @$(java-vm-cleanup) + $(MKDIR) -p $(TEMPDIR_LIMITED)/META-INF + $(ECHO) "Manifest-Version: 1.0" > \ + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF + $(CAT) policy/limited/LIMITED >> \ + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF + $(TOUCH) -t 198001010000 $(TEMPDIR_LIMITED)/META-INF + $(TOUCH) -r $(TEMPDIR_LIMITED)/META-INF \ + $(TEMPDIR_LIMITED)/META-INF/MANIFEST.MF UNSIGNED_POLICY_FILES = \ $(UNSIGNED_POLICY_BUILDDIR)/unlimited/US_export_policy.jar \ diff -r eb70b48e4211 -r fa4e5dae68e1 make/jdk_generic_profile.sh --- a/make/jdk_generic_profile.sh Wed Sep 03 15:34:29 2014 +0100 +++ b/make/jdk_generic_profile.sh Fri Sep 19 20:06:43 2014 +0100 @@ -245,11 +245,27 @@ PATH="${path4sdk}" export PATH +# Obtain pkgconfig for libs +pkgconfig=$(which pkg-config 2>/dev/null) +echo "pkgconfig=${pkgconfig}" + +# Find source location +jdk_topdir=$(dirname ${BASH_SOURCE})/.. +if [ ! -e ${jdk_topdir}/src ] ; then + jdk_topdir=$(hg root) ; +fi +echo "jdk_topdir=${jdk_topdir}" + # Export variables required for Zero +if [ "x${ZERO_BUILD}" = "x" ] ; then ZERO_BUILD=false; fi +if [ "x${SHARK_BUILD}" = "x" ] ; then SHARK_BUILD=false; fi if [ "${SHARK_BUILD}" = true ] ; then ZERO_BUILD=true export ZERO_BUILD fi +echo "Building Zero: ${ZERO_BUILD}" +echo "Building Shark: ${SHARK_BUILD}" + if [ "${ZERO_BUILD}" = true ] ; then # ZERO_LIBARCH is the name of the architecture-specific # subdirectory under $JAVA_HOME/jre/lib @@ -264,6 +280,7 @@ *) ZERO_LIBARCH="$(arch)" esac export ZERO_LIBARCH + echo "Zero library architecture: ${ZERO_LIBARCH}" # ARCH_DATA_MODEL is the number of bits in a pointer case "${ZERO_LIBARCH}" in @@ -278,6 +295,7 @@ exit 1 esac export ARCH_DATA_MODEL + echo "Zero architecture data model: ${ARCH_DATA_MODEL}" # ZERO_ENDIANNESS is the endianness of the processor case "${ZERO_LIBARCH}" in @@ -292,6 +310,7 @@ exit 1 esac export ZERO_ENDIANNESS + echo "Zero endianness: ${ZERO_ENDIANNESS}" # ZERO_ARCHDEF is used to enable architecture-specific code case "${ZERO_LIBARCH}" in @@ -302,6 +321,7 @@ *) ZERO_ARCHDEF=$(echo "${ZERO_LIBARCH}" | tr a-z A-Z) esac export ZERO_ARCHDEF + echo "Zero architecture definition: ${ZERO_ARCHDEF}" # ZERO_ARCHFLAG tells the compiler which mode to build for case "${ZERO_LIBARCH}" in @@ -315,10 +335,10 @@ ZERO_ARCHFLAG="-m${ARCH_DATA_MODEL}" esac export ZERO_ARCHFLAG + echo "Zero architecture flag: ${ZERO_ARCHFLAG}" # LIBFFI_CFLAGS and LIBFFI_LIBS tell the compiler how to compile and # link against libffi - pkgconfig=$(which pkg-config 2>/dev/null) if [ -x "${pkgconfig}" ] ; then if [ "${LIBFFI_CFLAGS}" = "" ] ; then LIBFFI_CFLAGS=$("${pkgconfig}" --cflags libffi) @@ -328,11 +348,14 @@ fi fi if [ "${LIBFFI_LIBS}" = "" ] ; then + echo "No libffi detected."; LIBFFI_LIBS="-lffi" fi export LIBFFI_CFLAGS export LIBFFI_LIBS - + echo "Using LIBFFI_CFLAGS=${LIBFFI_CFLAGS}" + echo "Using LIBFFI_LIBS=${LIBFFI_LIBS}" + # LLVM_CFLAGS, LLVM_LDFLAGS and LLVM_LIBS tell the compiler how to # compile and link against LLVM if [ "${SHARK_BUILD}" = true ] ; then @@ -382,12 +405,12 @@ export LLVM_CFLAGS export LLVM_LDFLAGS export LLVM_LIBS + echo "Using LLVM_CFLAGS=${LLVM_CFLAGS}" + echo "Using LLVM_LDFLAGS=${LLVM_LDFLAGS}" + echo "Using LLVM_LIBS=${LLVM_LIBS}" fi fi -# Obtain pkgconfig for libs -pkgconfig=$(which pkg-config 2>/dev/null) - # Export variables for system zlib # ZLIB_CFLAGS and ZLIB_LIBS tell the compiler how to compile and # link against zlib @@ -400,10 +423,13 @@ fi fi if [ "${ZLIB_LIBS}" = "" ] ; then + echo "No zlib detected."; ZLIB_LIBS="-lz" fi export ZLIB_CFLAGS export ZLIB_LIBS +echo "Using ZLIB_CFLAGS=${ZLIB_CFLAGS}" +echo "Using ZLIB_LIBS=${ZLIB_LIBS}" # Export variables for system LCMS # LCMS_CFLAGS and LCMS_LIBS tell the compiler how to compile and @@ -417,10 +443,13 @@ fi fi if [ "${LCMS_LIBS}" = "" ] ; then + echo "No LCMS detected."; LCMS_LIBS="-llcms2" fi export LCMS_CFLAGS export LCMS_LIBS +echo "Using LCMS_CFLAGS=${LCMS_CFLAGS}" +echo "Using LCMS_LIBS=${LCMS_LIBS}" # Export variables for system jpeg # JPEG_CFLAGS and JPEG_LIBS tell the compiler how to compile and @@ -429,6 +458,7 @@ JPEG_LIBS="-ljpeg" fi export JPEG_LIBS +echo "Using JPEG_LIBS=${JPEG_LIBS}" # Export variables for system libpng # PNG_CFLAGS and PNG_LIBS tell the compiler how to compile and @@ -442,10 +472,13 @@ fi fi if [ "${PNG_LIBS}" = "" ] ; then + echo "No libpng detected."; PNG_LIBS="-lpng" fi export PNG_CFLAGS export PNG_LIBS +echo "Using PNG_CFLAGS=${PNG_CFLAGS}" +echo "Using PNG_LIBS=${PNG_LIBS}" # Export variables for system giflib # GIF_CFLAGS and GIF_LIBS tell the compiler how to compile and @@ -454,6 +487,7 @@ GIF_LIBS="-lgif" fi export GIF_LIBS +echo "Using GIF_LIBS=${GIF_LIBS}" # Export variables for system krb5 # KRB5_CFLAGS and KRB5_LIBS tell the compiler how to compile and @@ -462,6 +496,7 @@ KRB5_LIBS="-lkrb5" fi export KRB5_LIBS +echo "Using KRB5_LIBS=${KRB5_LIBS}" # Export variables for system CUPS # CUPS_CFLAGS and CUPS_LIBS tell the compiler how to compile and @@ -470,6 +505,7 @@ CUPS_LIBS="-lcups" fi export CUPS_LIBS +echo "Using CUPS_LIBS=${CUPS_LIBS}" # Export variables for system libgtk # GTK_CFLAGS and GTK_LIBS tell the compiler how to compile and @@ -484,6 +520,8 @@ fi export GTK_CFLAGS export GTK_LIBS +echo "Using GTK_CFLAGS=${GTK_CFLAGS}" +echo "Using GTK_LIBS=${GTK_LIBS}" # Export variables for system libgio # GIO_CFLAGS and GIO_LIBS tell the compiler how to compile and @@ -500,6 +538,8 @@ fi export GIO_CFLAGS export GIO_LIBS +echo "Using GIO_CFLAGS=${GIO_CFLAGS}" +echo "Using GIO_LIBS=${GIO_LIBS}" # Export variables for system libpcsc # PCSC_CFLAGS and PCSC_LIBS tell the compiler how to compile and @@ -515,10 +555,13 @@ fi fi if [ "${PCSC_LIBS}" = "" ] ; then + echo "No libpcsclite detected."; PCSC_LIBS="-lpcsclite" fi export PCSC_CFLAGS export PCSC_LIBS +echo "Using PCSC_CFLAGS=${PCSC_CFLAGS}" +echo "Using PCSC_LIBS=${PCSC_LIBS}" # Export variables for system fontconfig # FONTCONFIG_CFLAGS and FONTCONFIG_LIBS tell the compiler how to compile and @@ -532,21 +575,28 @@ fi fi if [ "${FONTCONFIG_LIBS}" = "" ] ; then + echo "No fontconfig detected."; FONTCONFIG_LIBS="-lfontconfig" fi export FONTCONFIG_CFLAGS export FONTCONFIG_LIBS +echo "Using FONTCONFIG_CFLAGS=${FONTCONFIG_CFLAGS}" +echo "Using FONTCONFIG_LIBS=${FONTCONFIG_LIBS}" # Setup nss.cfg using location of NSS libraries if [ -x "${pkgconfig}" ] ; then - jdk_topdir=$(dirname ${BASH_SOURCE})/.. - if [ ! -e ${jdk_topdir}/src ] ; then - jdk_topdir=$(hg root) ; + if [ "${NSS_LIBDIR}" = "" ] ; then + NSS_LIBDIR=$("${pkgconfig}" --variable=libdir nss) fi - sed -e "s#@NSS_LIBDIR@#$(${pkgconfig} --variable=libdir nss)#" \ - ${jdk_topdir}/src/share/lib/security/nss.cfg.in \ - > ${jdk_topdir}/src/share/lib/security/nss.cfg fi +if [ "${NSS_LIBDIR}" = "" ] ; then + NSS_LIBDIR="/usr/lib"; + echo "No NSS library directory detected."; +fi +echo "Using NSS_LIBDIR=${NSS_LIBDIR}" +sed -e "s#@NSS_LIBDIR@#$()#" \ + ${jdk_topdir}/src/share/lib/security/nss.cfg.in \ + > ${jdk_topdir}/src/share/lib/security/nss.cfg # IcedTea defaults; use system libraries export SYSTEM_LCMS=true @@ -561,10 +611,12 @@ export COMPILE_AGAINST_SYSCALLS=true if [ "x${GTK_LIBS}" != "x" ] ; then + echo "Gtk+ detected; enabling system linking."; export SYSTEM_GTK=true fi if [ "x${GIO_LIBS}" != "x" ] ; then + echo "GIO detected; enabling system linking."; export SYSTEM_GIO=true fi @@ -573,23 +625,27 @@ # IcedTea versioning export ICEDTEA_NAME="IcedTea" -export PACKAGE_VERSION="2.5.3pre00" +export PACKAGE_VERSION="2.5.3pre01" export DERIVATIVE_ID="${ICEDTEA_NAME} ${PACKAGE_VERSION}" +echo "Building ${DERIVATIVE_ID}" if [ -e ${jdk_topdir} ] ; then if hg -R ${jdk_topdir} id &>/dev/null ; then export JDK_REVID="r$(hg -R ${jdk_topdir} id -i)"; + echo "JDK Mercurial revision: ${JDK_REVID}" fi fi hotspot_topdir=${jdk_topdir}/../hotspot if [ -e ${hotspot_topdir} ] ; then if hg -R ${hotspot_topdir} id &>/dev/null ; then export HOTSPOT_BUILD_VERSION="r$(hg -R ${hotspot_topdir} id -i)"; + echo "HotSpot Mercurial revision: ${HOTSPOT_BUILD_VERSION}" fi fi lsbrelease=$(which lsb_release 2>/dev/null) -if [ -x ${lsbrelease} ] ; then +echo "lsbrelease=${lsbrelease}" +if [ -x "${lsbrelease}" ] ; then lsbinfo="$(${lsbrelease} -ds | sed 's/^"//;s/"$//')" if test "x${PKGVERSION}" = "x"; then export DISTRIBUTION_ID="Built on ${lsbinfo} ($(date))" @@ -597,4 +653,6 @@ export DISTRIBUTION_ID="${lsbinfo}, package $PKGVERSION" fi export DISTRO_NAME="$(${lsbrelease} -is | sed 's/^"//;s/"$//')" + echo "Distribution ID: ${DISTRIBUTION_ID}" + echo "Distribution Name: ${DISTRO_NAME}" fi diff -r eb70b48e4211 -r fa4e5dae68e1 make/sun/gtk/Makefile --- a/make/sun/gtk/Makefile Wed Sep 03 15:34:29 2014 +0100 +++ b/make/sun/gtk/Makefile Fri Sep 19 20:06:43 2014 +0100 @@ -58,6 +58,8 @@ ifeq ($(SYSTEM_GTK), true) OTHER_LDLIBS += $(GTK_LIBS) +else + OTHER_LDLIBS += $(LIBDL) endif ifeq ($(PLATFORM), solaris) diff -r eb70b48e4211 -r fa4e5dae68e1 src/share/classes/com/sun/crypto/provider/AESCipher.java --- a/src/share/classes/com/sun/crypto/provider/AESCipher.java Wed Sep 03 15:34:29 2014 +0100 +++ b/src/share/classes/com/sun/crypto/provider/AESCipher.java Fri Sep 19 20:06:43 2014 +0100 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2009, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2012, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,18 +47,122 @@ * @see OutputFeedback */ -public final class AESCipher extends CipherSpi { +abstract class AESCipher extends CipherSpi { + public static final class General extends AESCipher { + public General() { + super(-1); + } + } + abstract static class OidImpl extends AESCipher { + protected OidImpl(int keySize, String mode, String padding) { + super(keySize); + try { + engineSetMode(mode); + engineSetPadding(padding); + } catch (GeneralSecurityException gse) { + // internal error; re-throw as provider exception + ProviderException pe =new ProviderException("Internal Error"); + pe.initCause(gse); + throw pe; + } + } + } + public static final class AES128_ECB_NoPadding extends OidImpl { + public AES128_ECB_NoPadding() { + super(16, "ECB", "NOPADDING"); + } + } + public static final class AES192_ECB_NoPadding extends OidImpl { + public AES192_ECB_NoPadding() { + super(24, "ECB", "NOPADDING"); + } + } + public static final class AES256_ECB_NoPadding extends OidImpl { + public AES256_ECB_NoPadding() { + super(32, "ECB", "NOPADDING"); + } + } + public static final class AES128_CBC_NoPadding extends OidImpl { + public AES128_CBC_NoPadding() { + super(16, "CBC", "NOPADDING"); + } + } + public static final class AES192_CBC_NoPadding extends OidImpl { + public AES192_CBC_NoPadding() { + super(24, "CBC", "NOPADDING"); + } + } + public static final class AES256_CBC_NoPadding extends OidImpl { + public AES256_CBC_NoPadding() { + super(32, "CBC", "NOPADDING"); + } + } + public static final class AES128_OFB_NoPadding extends OidImpl { + public AES128_OFB_NoPadding() { + super(16, "OFB", "NOPADDING"); + } + } + public static final class AES192_OFB_NoPadding extends OidImpl { + public AES192_OFB_NoPadding() { + super(24, "OFB", "NOPADDING"); + } + } + public static final class AES256_OFB_NoPadding extends OidImpl { + public AES256_OFB_NoPadding() { + super(32, "OFB", "NOPADDING"); + } + } + public static final class AES128_CFB_NoPadding extends OidImpl { + public AES128_CFB_NoPadding() { + super(16, "CFB", "NOPADDING"); + } + } + public static final class AES192_CFB_NoPadding extends OidImpl { + public AES192_CFB_NoPadding() { + super(24, "CFB", "NOPADDING"); + } + } + public static final class AES256_CFB_NoPadding extends OidImpl { + public AES256_CFB_NoPadding() { + super(32, "CFB", "NOPADDING"); + } + } From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 19:07:09 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:07:09 +0000 Subject: [Bug 1989] [IcedTea7] Make jdk_generic_profile.sh handle missing programs better and be more verbose In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1989 --- Comment #3 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=9332dff476b5 author: andrew date: Mon Sep 08 18:46:06 2014 +0100 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 19:07:15 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:07:15 +0000 Subject: [Bug 1992] [IcedTea7] Support retrieving proxy settings on GNOME 3 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1992 --- Comment #3 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=0312f617199a author: andrew date: Wed Sep 10 17:12:24 2014 +0100 PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 19:07:23 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:07:23 +0000 Subject: [Bug 1736] Awt loads gtk3 in all the look and feel configurations In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1736 --- Comment #8 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=d743166ebdd2 author: andrew date: Wed Sep 17 15:43:58 2014 +0100 PR2003: --disable-system-gtk option broken by refactoring in PR1736 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 19:07:27 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:07:27 +0000 Subject: [Bug 2003] [IcedTea7] --disable-system-gtk option broken by refactoring in PR1736 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2003 --- Comment #2 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=d743166ebdd2 author: andrew date: Wed Sep 17 15:43:58 2014 +0100 PR2003: --disable-system-gtk option broken by refactoring in PR1736 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 19:07:34 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:07:34 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 --- Comment #6 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=5a15406ba951 author: andrew date: Fri Sep 19 02:38:01 2014 +0100 PR2009: Checksum of policy JAR files changes on every build -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Fri Sep 19 19:12:57 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:12:57 +0000 Subject: /hg/release/icedtea7-forest-2.5/hotspot: PR1988: C++ Interpreter... Message-ID: changeset 9f719e4c80af in /hg/release/icedtea7-forest-2.5/hotspot details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=9f719e4c80af author: andrew date: Mon Sep 08 17:44:42 2014 +0100 PR1988: C++ Interpreter should no longer be used on ppc64 diffstat: make/defs.make | 4 ---- make/linux/platform_ppc64 | 2 +- 2 files changed, 1 insertions(+), 5 deletions(-) diffs (23 lines): diff -r 51c1c024f887 -r 9f719e4c80af make/defs.make --- a/make/defs.make Fri Aug 29 21:08:29 2014 +0100 +++ b/make/defs.make Mon Sep 08 17:44:42 2014 +0100 @@ -307,10 +307,6 @@ LP64_ARCH = sparcv9 amd64 ia64 ppc64 zero endif -ifeq ($(ARCH), ppc64) - CC_INTERP=true -endif - # Required make macro settings for all platforms MAKE_ARGS += JAVA_HOME=$(ABS_BOOTDIR) MAKE_ARGS += OUTPUTDIR=$(ABS_OUTPUTDIR) diff -r 51c1c024f887 -r 9f719e4c80af make/linux/platform_ppc64 --- a/make/linux/platform_ppc64 Fri Aug 29 21:08:29 2014 +0100 +++ b/make/linux/platform_ppc64 Mon Sep 08 17:44:42 2014 +0100 @@ -14,4 +14,4 @@ gnu_dis_arch = ppc64 -sysdefs = -DLINUX -D_GNU_SOURCE -DPPC64 -DCC_INTERP +sysdefs = -DLINUX -D_GNU_SOURCE -DPPC64 From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 19:13:03 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:13:03 +0000 Subject: [Bug 1988] [IcedTea7] C++ Interpreter should no longer be used on ppc64 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1988 --- Comment #3 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=9f719e4c80af author: andrew date: Mon Sep 08 17:44:42 2014 +0100 PR1988: C++ Interpreter should no longer be used on ppc64 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at icedtea.classpath.org Fri Sep 19 19:48:01 2014 From: jkang at icedtea.classpath.org (jkang at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:48:01 +0000 Subject: /hg/icedtea-web: Added three keys to DeploymentConfiguration. Ma... Message-ID: changeset 6e689ab02eb0 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=6e689ab02eb0 author: Jie Kang date: Fri Sep 19 15:47:00 2014 -0400 Added three keys to DeploymentConfiguration. Max cache size, cache enable, and cache compression enable. 2014-09-19 Jie Kang Added three keys to DeploymentConfiguration. Max cache size, cache enable, and cache compression enable. * netx/net/sourceforge/jnlp/CacheUtil.java: now uses keys * netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java: now uses keys * netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: diffstat: ChangeLog | 9 + netx/net/sourceforge/jnlp/cache/CacheUtil.java | 2 +- netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java | 18 ++- netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java | 54 +++------ 4 files changed, 44 insertions(+), 39 deletions(-) diffs (205 lines): diff -r 85ede1a5ab91 -r 6e689ab02eb0 ChangeLog --- a/ChangeLog Fri Sep 19 14:06:23 2014 +0200 +++ b/ChangeLog Fri Sep 19 15:47:00 2014 -0400 @@ -1,3 +1,12 @@ +2014-09-19 Jie Kang + + Added three keys to DeploymentConfiguration. Max cache size, cache enable, + and cache compression enable. + * netx/net/sourceforge/jnlp/CacheUtil.java: now uses keys + * netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java: + now uses keys + * netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: + 2014-09-19 Jiri Vanek Translator made immutable diff -r 85ede1a5ab91 -r 6e689ab02eb0 netx/net/sourceforge/jnlp/cache/CacheUtil.java --- a/netx/net/sourceforge/jnlp/cache/CacheUtil.java Fri Sep 19 14:06:23 2014 +0200 +++ b/netx/net/sourceforge/jnlp/cache/CacheUtil.java Fri Sep 19 15:47:00 2014 -0400 @@ -545,7 +545,7 @@ long maxSize = -1; // Default try { - maxSize = Long.parseLong(JNLPRuntime.getConfiguration().getProperty("deployment.cache.max.size")); + maxSize = Long.parseLong(JNLPRuntime.getConfiguration().getProperty(DeploymentConfiguration.KEY_CACHE_MAX_SIZE)); } catch (NumberFormatException nfe) { } diff -r 85ede1a5ab91 -r 6e689ab02eb0 netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java --- a/netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java Fri Sep 19 14:06:23 2014 +0200 +++ b/netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java Fri Sep 19 15:47:00 2014 -0400 @@ -16,6 +16,13 @@ package net.sourceforge.jnlp.config; +import static net.sourceforge.jnlp.config.PathsAndFiles.JAVA_DEPLOYMENT_PROP_FILE; +import static net.sourceforge.jnlp.config.PathsAndFiles.USER_CACHE_HOME; +import static net.sourceforge.jnlp.config.PathsAndFiles.USER_CONFIG_HOME; +import static net.sourceforge.jnlp.config.PathsAndFiles.USER_DEPLOYMENT_FILE; +import static net.sourceforge.jnlp.config.PathsAndFiles.USER_SECURITY; +import static net.sourceforge.jnlp.runtime.Translator.R; + import java.io.BufferedOutputStream; import java.io.BufferedReader; import java.io.File; @@ -32,13 +39,12 @@ import java.util.Map; import java.util.Properties; import java.util.Set; + import javax.naming.ConfigurationException; import javax.swing.JOptionPane; + import net.sourceforge.jnlp.cache.CacheLRUWrapper; -import static net.sourceforge.jnlp.config.PathsAndFiles.*; import net.sourceforge.jnlp.runtime.JNLPRuntime; -import static net.sourceforge.jnlp.runtime.Translator.R; - import net.sourceforge.jnlp.util.FileUtils; import net.sourceforge.jnlp.util.logging.OutputController; @@ -90,6 +96,12 @@ public static final String KEY_USER_CACHE_DIR = "deployment.user.cachedir"; public static final String KEY_USER_PERSISTENCE_CACHE_DIR = "deployment.user.pcachedir"; public static final String KEY_SYSTEM_CACHE_DIR = "deployment.system.cachedir"; + + public static final String KEY_CACHE_MAX_SIZE = "deployment.cache.max.size"; + + public static final String KEY_CACHE_ENABLED = "deployment.javapi.cache.enabled"; + public static final String KEY_CACHE_COMPRESSION_ENABLED = "deployment.cache.jarcompression"; + public static final String KEY_USER_LOG_DIR = "deployment.user.logdir"; public static final String KEY_USER_TMP_DIR = "deployment.user.tmp"; /** the directory containing locks for single instance applications */ diff -r 85ede1a5ab91 -r 6e689ab02eb0 netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Fri Sep 19 14:06:23 2014 +0200 +++ b/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Fri Sep 19 15:47:00 2014 -0400 @@ -18,13 +18,12 @@ package net.sourceforge.jnlp.controlpanel; -import java.awt.*; +import static java.lang.Integer.parseInt; +import static java.lang.Long.parseLong; -import net.sourceforge.jnlp.config.DeploymentConfiguration; -import net.sourceforge.jnlp.runtime.Translator; - -import javax.swing.event.ChangeEvent; -import javax.swing.event.ChangeListener; +import java.awt.BorderLayout; +import java.awt.GridBagConstraints; +import java.awt.GridBagLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.ComponentAdapter; @@ -45,9 +44,11 @@ import javax.swing.JSpinner; import javax.swing.JTextField; import javax.swing.SpinnerNumberModel; +import javax.swing.event.ChangeEvent; +import javax.swing.event.ChangeListener; -import static java.lang.Integer.parseInt; -import static java.lang.Long.parseLong; +import net.sourceforge.jnlp.config.DeploymentConfiguration; +import net.sourceforge.jnlp.runtime.Translator; /** * The actual panel that contains the fields that the user can edit accordingly. @@ -61,23 +62,6 @@ @SuppressWarnings("serial") public class TemporaryInternetFilesPanel extends NamedBorderPanel { - private static enum Properties { - CACHE_ENABLED("deployment.javapi.cache.enabled"), - USER_CACHEDIR("deployment.user.cachedir"), - CACHE_MAX_SIZE("deployment.cache.max.size"), - COMPRESSION_ENABLED("deployment.cache.jarcompression"); - - private final String prop; - Properties(final String prop) { - this.prop = prop; - } - - @Override - public String toString() { - return prop; - } - } - private static final Long CACHE_UNLIMITED_SIZE = Long.valueOf(-1l); private static final Long CACHE_MIN_SIZE = Long.valueOf(0l); private static final Long CACHE_MAX_SIZE = (long) Integer.MAX_VALUE; @@ -123,14 +107,14 @@ lCompression = new JLabel(Translator.R("TIFPCompressionLevel") + ":"); // Sets compression level for jar files. bLocation = new JButton(Translator.R("TIFPChange") + "..."); - location = new JTextField(this.config.getProperty(Properties.USER_CACHEDIR.toString())); + location = new JTextField(this.config.getProperty(DeploymentConfiguration.KEY_USER_CACHE_DIR)); locationDescription = new JLabel(Translator.R("TIFPLocationLabel") + ":"); bViewFiles = new JButton(Translator.R("TIFPViewFiles")); diskSpacePanel = new JPanel(); diskSpacePanel.setLayout(new GridBagLayout()); - cacheDir = new File(config.getProperty(DeploymentConfiguration.KEY_USER_CACHE_DIR)); + cacheDir = new File(this.config.getProperty(DeploymentConfiguration.KEY_USER_CACHE_DIR)); usableDiskSpace = cacheDir.getUsableSpace() / BYTES_TO_MEGABYTES; // getUsableSpace returns bytes addComponents(); @@ -159,16 +143,16 @@ JLabel description = new JLabel(Translator.R("CPTempInternetFilesDescription")); // This section deals with how to use the disk space. - cbCompression.setSelectedIndex(parseInt(this.config.getProperty(Properties.COMPRESSION_ENABLED.toString()))); + cbCompression.setSelectedIndex(parseInt(this.config.getProperty(DeploymentConfiguration.KEY_CACHE_COMPRESSION_ENABLED))); cbCompression.addItemListener(new ItemListener() { @Override public void itemStateChanged(ItemEvent e) { - config.setProperty(Properties.COMPRESSION_ENABLED.toString(), ((ComboItem) e.getItem()).getValue()); + config.setProperty(DeploymentConfiguration.KEY_CACHE_COMPRESSION_ENABLED, ((ComboItem) e.getItem()).getValue()); } }); //Override getNextValue and getPreviousValue to make it jump to the closest increment/decrement of step size - final Long configCacheSize = parseLong(this.config.getProperty(Properties.CACHE_MAX_SIZE.toString())); + final Long configCacheSize = parseLong(this.config.getProperty(DeploymentConfiguration.KEY_CACHE_MAX_SIZE)); final Long initialCacheSize = configCacheSize < CACHE_MIN_SIZE ? CACHE_MIN_SIZE : configCacheSize; final SpinnerNumberModel snmCacheSize = new PowerOfSpinnerNumberModel(initialCacheSize, TemporaryInternetFilesPanel.CACHE_MIN_SIZE, TemporaryInternetFilesPanel.CACHE_MAX_SIZE, TemporaryInternetFilesPanel.SPINNER_STEP_SIZE); cacheSizeSpinner.setModel(snmCacheSize); @@ -232,7 +216,7 @@ if (canWrite) { location.setText(result); - config.setProperty(Properties.USER_CACHEDIR.toString(), result); + config.setProperty(DeploymentConfiguration.KEY_USER_CACHE_DIR, result); } } } @@ -356,7 +340,7 @@ cacheSizeWarningLabel.setText(Translator.R("TIFPCacheSizeSpinnerLargeValueWarning", usableDiskSpace)); } - config.setProperty(Properties.CACHE_MAX_SIZE.toString(), Long.valueOf(cacheSizeSpinnerValue).toString()); + config.setProperty(DeploymentConfiguration.KEY_CACHE_MAX_SIZE, Long.valueOf(cacheSizeSpinnerValue).toString()); } else { showCacheSizeSpinnerGUIElements(false); showCompressionAndLocationGUIElements(true); @@ -377,12 +361,12 @@ } if (selected) { - config.setProperty(Properties.CACHE_MAX_SIZE.toString(), cacheSizeSpinner.getValue().toString()); + config.setProperty(DeploymentConfiguration.KEY_CACHE_MAX_SIZE, cacheSizeSpinner.getValue().toString()); } else { - config.setProperty(Properties.CACHE_MAX_SIZE.toString(), Long.toString(CACHE_UNLIMITED_SIZE)); + config.setProperty(DeploymentConfiguration.KEY_CACHE_MAX_SIZE, Long.toString(CACHE_UNLIMITED_SIZE)); } - config.setProperty(Properties.CACHE_ENABLED.toString(), String.valueOf(!selected)); + config.setProperty(DeploymentConfiguration.KEY_CACHE_ENABLED, String.valueOf(!selected)); } } From jkang at icedtea.classpath.org Fri Sep 19 19:51:24 2014 From: jkang at icedtea.classpath.org (jkang at icedtea.classpath.org) Date: Fri, 19 Sep 2014 19:51:24 +0000 Subject: /hg/icedtea-web: Modified Makefile.am to process only whiteliste... Message-ID: changeset 9fbfc6ef9237 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=9fbfc6ef9237 author: Jie Kang date: Fri Sep 19 15:51:19 2014 -0400 Modified Makefile.am to process only whitelisted reproducers. 2014-09-19 Jie Kang Modified Makefile.am to use whitelist when processing reproducers. * Makefile.am: Now filters reproducers using netx-dist-tests-whitelist diffstat: ChangeLog | 5 +++++ Makefile.am | 22 ++++++++++++++++------ 2 files changed, 21 insertions(+), 6 deletions(-) diffs (58 lines): diff -r 6e689ab02eb0 -r 9fbfc6ef9237 ChangeLog --- a/ChangeLog Fri Sep 19 15:47:00 2014 -0400 +++ b/ChangeLog Fri Sep 19 15:51:19 2014 -0400 @@ -1,3 +1,8 @@ +2014-09-19 Jie Kang + + Modified Makefile.am to use whitelist when processing reproducers. + * Makefile.am: Now filters reproducers using netx-dist-tests-whitelist + 2014-09-19 Jie Kang Added three keys to DeploymentConfiguration. Max cache size, cache enable, diff -r 6e689ab02eb0 -r 9fbfc6ef9237 Makefile.am --- a/Makefile.am Fri Sep 19 15:47:00 2014 -0400 +++ b/Makefile.am Fri Sep 19 15:51:19 2014 -0400 @@ -691,19 +691,28 @@ mkdir -p $(REPRODUCERS_BUILD_DIR) touch $@ -junit-jnlp-dist-custom.txt: +junit-jnlp-dist-custom.txt: $(REPRODUCERS_CLASS_WHITELIST) cd $(REPRODUCERS_TESTS_SRCDIR)/$(CUSTOM_REPRODUCERS)/ ; \ - find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" > $(abs_top_builddir)/$@ + whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ + for x in $$whiteListed ; do \ + find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > $(abs_top_builddir)/$@ || true ; \ + done -junit-jnlp-dist-simple.txt: +junit-jnlp-dist-simple.txt: $(REPRODUCERS_CLASS_WHITELIST) cd $(REPRODUCERS_TESTS_SRCDIR)/simple/ ; \ - find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" > $(abs_top_builddir)/$@ + whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ + for x in $$whiteListed ; do \ + find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > $(abs_top_builddir)/$@ || true ; \ + done -stamps/junit-jnlp-dist-signed.stamp: +stamps/junit-jnlp-dist-signed.stamp: $(REPRODUCERS_CLASS_WHITELIST) types=($(SIGNED_REPRODUCERS)) ; \ for which in "$${types[@]}" ; do \ pushd $(REPRODUCERS_TESTS_SRCDIR)/$$which/ ; \ - find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" > $(abs_top_builddir)/junit-jnlp-dist-$$which.txt ; \ + whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ + for x in $$whiteListed ; do \ + find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > $(abs_top_builddir)/junit-jnlp-dist-$$which.txt ; \ + done ; \ popd ; \ done ; \ mkdir -p stamps && \ @@ -874,6 +883,7 @@ simpleReproducers=(`cat $(abs_top_builddir)/junit-jnlp-dist-$$which.txt `); \ IFS="$$IFS_BACKUP" ; \ for dir in "$${simpleReproducers[@]}" ; do \ + echo "compiling" $$dir ; \ $(BOOT_DIR)/bin/javac $(IT_JAVACFLAGS) \ -d $(TEST_EXTENSIONS_TESTS_DIR) \ -classpath $(JUNIT_JAR):$(NETX_DIR)/lib/classes.jar:$(TEST_EXTENSIONS_DIR) \ From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 20:15:02 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 20:15:02 +0000 Subject: [Bug 2004] When accessing applet it will crash In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 --- Comment #5 from Diego --- HI, Thanks for all the help so far. I have tried to update to icedtea-web 1.5.1 but I get the below error and no matter what I have tried can't solve it.. checking for a JDK home directory... configure: error: "A JDK home directory could not be found." Thanks -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 19 20:38:06 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 19 Sep 2014 20:38:06 +0000 Subject: [Bug 2004] When accessing applet it will crash In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 Deepak Bhole changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|dbhole at redhat.com |jvanek at redhat.com --- Comment #6 from Deepak Bhole --- Assigning to Jiri to investigate -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Fri Sep 19 20:52:00 2014 From: jkang at redhat.com (Jie Kang) Date: Fri, 19 Sep 2014 16:52:00 -0400 (EDT) Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <54199ED2.7000707@redhat.com> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> <54199ED2.7000707@redhat.com> Message-ID: <757174978.8263445.1411159920251.JavaMail.zimbra@redhat.com> ----- Original Message ----- > ... > >> + mkdir -p $(DOCS_DIR) ; \ > >> + HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html ; \ > >> + PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain ; \ > >> + MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man/ ; \ > > > > Drop the trailing slash. > > fixed > > > >> mkdir $$HTML_DOCS_TARGET_DIR ; \ > >> mkdir $$PLAIN_DOCS_TARGET_DIR ; \ > >> - mkdir -p $$MAN_DOCS_TARGET_DIR ; \ > >> + mkdir $$MAN_DOCS_TARGET_DIR ; \ > > > > Why did you remove the "-p" switch? It is probably best to have this switch > > almost always on in > > scripts to avoid running into errors just because of non-existing parent > > directories. > > I prefer opposite. To not use -p. If some typo seek in, then it can create > whole branch in some > really strange lcoation... Hello, I would also prefer a consistency in the makefile for mkdir using -p. When you use it in one place and not in another, it leads viewer to wonder why it's needed in one place and not in another. This means extra work to figure out the reason. Maybe some comments in-file here could help? If the only reason to not use '-p' is because typos would cause weird things to happen, then I would keep the -p. Typos shouldn't be a worry since we should in theory never accept things with typos. I think some of the strings in Message.properties can be reworded to fix grammar mistakes and help formatting but that can be done in another patch. I will probably submit some changes to the strings myself :D Apart from that it seems okay. I haven't thought of any good solutions to the issue with @BOLD_OPEN, etc. but I will keep thinking. Regards, > > Before this dline created two levels of diretories. So there was -p.Now it > does not. > > however, the > -export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs > +export DOCS_DIR=$(TOP_BUILD_DIR)/icedtea-web-docs/$(FULL_VERSION) > ... > - mkdir $(DOCS_DIR) ; \ > + mkdir -p $(DOCS_DIR) ; \ > > does. > > so not "fixed" > > > > >> [...] > >> diff -r e30d71ab91c6 > >> netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java > >> --- a/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java > >> Wed Sep 10 10:22:46 2014 > >> -0400 > >> +++ b/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java > >> Fri Sep 12 15:21:39 2014 > >> +0200 > >> @@ -58,17 +58,17 @@ > >> @SuppressWarnings("serial") > >> public class NetworkSettingsPanel extends JPanel implements > >> ActionListener { > >> > >> - private DeploymentConfiguration config; > >> + private final DeploymentConfiguration config; > >> > >> private JPanel description; > >> - private ArrayList proxyPanels = new ArrayList(); // > >> The stuff with editable > >> fields > >> + private final ArrayList proxyPanels = new ArrayList<>(); // > >> The stuff with editable > >> fields > >> > >> /** List of properties used by this panel */ > >> - public static String[] properties = { "deployment.proxy.type", > >> - "deployment.proxy.http.host", > >> - "deployment.proxy.http.port", > >> - "deployment.proxy.bypass.local", > >> - "deployment.proxy.auto.config.url", }; > >> + public static String[] properties = { > >> DeploymentConfiguration.KEY_PROXY_TYPE, > >> + DeploymentConfiguration.KEY_PROXY_HTTP_HOST, > >> + DeploymentConfiguration.KEY_PROXY_HTTP_PORT, > >> + DeploymentConfiguration.KEY_PROXY_BYPASS_LOCAL, > >> + DeploymentConfiguration.KEY_PROXY_AUTO_CONFIG_URL, }; > > > > The formatting here should probably go here like this: > > public static String[] properties = { > > DeploymentConfiguration.KEY_PROXY_TYPE, > > DeploymentConfiguration.KEY_PROXY_HTTP_HOST, > > DeploymentConfiguration.KEY_PROXY_HTTP_PORT, > > DeploymentConfiguration.KEY_PROXY_BYPASS_LOCAL, > > DeploymentConfiguration.KEY_PROXY_AUTO_CONFIG_URL > > }; > > > > Please also mind the comma after the last element. > > Thank you! > > Fixed and reformatted. > > > >> /** > >> * Creates a new instance of the network settings panel. > >> @@ -259,18 +259,23 @@ > >> */ > ... > >> CBCheckSignedAppletDontMatchException = Signed applets are not allowed to > >> run when their actual > >> Codebase does not match the Codebase specified in their manifest. > >> Expected: {0}. Actual: {1}. See: > >> http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/no_redeploy.html > >> for details. > >> CBCheckSignedFail = Application Codebase does NOT match the Codebase > >> specified in the > >> application's manifest, and this application is signed. You are strongly > >> discouraged from running > >> this application. See: > >> http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/security/no_redeploy.html > >> for details. > >> > >> +#itweb-settings man (note, spaces (especially the one around @@ > >> markup)are important due to man > >> pages markup > >> +ITWSintro= - view and modify settings for @BOLD_OPEN at javaws > >> @BOLD_CLOSE at and the > >> @BOLD_OPEN at browser plugin at BOLD_CLOSE@ > > > > What are those "@BOLD_OPEN@" and "@BOLD_CLOSE@" tags? Are they some sort of > > project specific markup > > language? If so, I am very unhappy with this. Where is the documentation > > for this? Does it handle @ > > escapes correctly? > > > > Is "... @BOLD_OPEN at javaws @BOLD_CLOSE at and ..." actually correct? > > Yes all those are correct. See the @@ explanation lower. > > > >> +ITWSsynops=command arguments > >> +IWSdescL1=is a command line and a GUI program to modify and edit settings > >> used by the icedtea-web > >> implementation \ > >> +of at BOLD_OPEN@ javaws @BOLD_CLOSE at and the @BOLD_OPEN at browser > >> plugin at BOLD_CLOSE@. > > > > Why did you suddenly introduce broken lines or line continuing characters > > to Message.properties, > > since you have always been strictly against them? > > You remember, do you? :)) Well its not that I'm 100% against, I like the > i18ns and original file > keeping same style. > > Also I don't like cutting on 80chars. Then maybe wee all can throw away our > wide monitors... So > easily spoken - here i broke, because it seemed to me more readable. > > > so not "fixed" > > > > > Is "... of at BOLD_OPEN@ javaws @BOLD_CLOSE at and ..." actually correct? > > > >> +IWSdescL2=If executed without any arguments, it starts up a GUI. > >> Otherwise, it tries to do what > >> is specified in the argument. > >> +IWSdescL3=The command-line allows quickly searching, making a copy of and > >> modifying specific > >> settings without having to hunt through a UI. > >> +IWSexampleL1=Show the GUI editor > >> +IWSexampleL2=Resets the value of `{0}` setting. > > > > Are the "`" characters literals in the man page or markups? > > copypaste from my summary email:) > Originally there were the ' (" ' ") char, however, I noted, then If I put {n} > into '' like '{0}' the > properties fiel do not evaluate it correctly. Same for " char and no > escaping helped.. So I put > here ` char:( > Anyway - no markup mentioned. In original text it was just quoting - making > it readable or similar. > So it have nothing to do with any markup, and AFAIK all plain, html and man > output is ok with it.I > will be happy to change it if you dont like it ad know replacement. > > > > >> +ITWSdefault=default > >> +IWSexampleL3=Known properties > >> +IWSexampleL31=(key, value and default value (if different)): > >> +IWSexampleL32=(key and default value): > >> + > >> +#itweb-plugin man (note, spaces (especially the one around @@ markup)are > >> important due to man > >> pages markup > >> +ITWPintro=- allow to run @BOLD_OPEN at java applets @BOLD_CLOSE at in your > >> favourite > >> @BOLD_OPEN at browser@BOLD_CLOSE@ > > > > Check double spaces. > > fixed. Thanx! > > Is "... run @BOLD_OPEN at java applets @BOLD_CLOSE at in ..." actually correct? > > > >> +ITWPsynopsL1=is working in your browser, once your browser knows about > >> this files. > >> +ITWPsynopsL2=The {0} must be placed, or linked iniside specific > >> direcotries. See {1} > > > > Spelling! > > Fixed:( > > > >> +ITWPsynopsL3=@BOLD_OPEN@ Mozzila compliant browsers @BOLD_CLOSE at like > >> Firefox, Midori, Epiphany, > >> Chrome or Chromium use: > > > > Spelling! The foundation's name is Mozilla! > fixed:( > > > > >> +ITWPsynopsL4=@BOLD_OPEN@ Opera family browsers @BOLD_CLOSE at like Opera > >> use: > > > > Please be careful when mentioning registered trademark and product names. > > If you mention them, you > > will probably need to include a statement on their legal status somewhere > > in the documentation for > > certain jurisdictions. Hence, it is best to avoid them. However, I am also > > aware that avoiding them > > completely is not always possible. Therefore, I strongly suggest to use the > > term "Mozilla > > compatible" only, wherever required. "NPAPI compatible" is also acceptable > > but far more technical > > and probably unknown to most users. "Mozilla compatible" covers all > > browsers currently supported by > > IcedTea-Web and avoids entanglements with too many entities. Because > > Mozilla is also the original > > author of the NPAPI, it describes the technical aspect sufficiently enough. > > And, although Mozilla is > > trademarked as well, the term would nevertheless reduce any legal risks to > > a minimum, especially > > given the Mozilla foundation's nature and history in free software. Of > > course, this does not relieve > > us of placing a legal notice in the documentation about Mozilla either, but > > reduces any efforts to > > just one entity. > > Ouch that is the long one. What is conclusion? It really was not celar :( I > added the" > > +ITWPtrademarks=All browsers or company names in this section may be subjects > of trademarks and/or > copyrights. > > line to end of paragraph. > > > >> [...] > >> diff -r e30d71ab91c6 > >> netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java > >> --- > >> a/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java > >> Wed Sep 10 > >> 10:22:46 2014 -0400 > >> +++ > >> b/netx/net/sourceforge/jnlp/util/docprovider/ItwebPluginTextProvider.java > >> Fri Sep 12 > >> 15:21:39 2014 +0200 > >> @@ -38,6 +38,7 @@ > >> > >> import java.io.IOException; > >> import net.sourceforge.jnlp.config.PathsAndFiles; > >> +import net.sourceforge.jnlp.runtime.Translator; > >> import > >> net.sourceforge.jnlp.util.docprovider.formatters.formatters.Formatter; > > > > Generally speaking, I am really having trouble accepting this kind of > > custom formatter to > > IcedTea-Web. Actually, this goes for any project which is not specifically > > concerned with parsing a > > well specified language. Unfortunately, most developers greatly > > underestimate the prerequisites for > > a properly working formatter. The probability of not getting it right is > > far greater than one would > > initially assume. This starts with checking inputs and outputs, goes over > > properly handling encoded > > strings, and ends on handling escapes properly. The amount of testing > > required to get /and/ keep a > > formatter correct is just enormous. Then, it has to be documented and > > everybody who wants to add > > documentation on a new feature that he/she has just implemented is required > > to (a) know how the > > documentation generator works and (b) understand its formatting. > > So ultimately, we should get rid of this formatter and any @TAG@ tags. If > > you really need formatting > > tags for man pages then the documentation generator should be able to > > include them itself > > automatically. Otherwise, adding documentation becomes unnecessarily > > difficult and overly complex. > > It's a pity that you rushed to push the documentation generator... > > > > Fixing all this paragraph is definitely for another changesets. > > Copypasted from summary:: > > the @bold@ whatever@ stuff: > - It is placeholder for and in html or \n.B \n and /n in man. > Tbh Right now I dont > know solid workaround > - I would like to get rid of of all this @@ markups. And I'm successfully > doing so:) > - I Get rid of all except the @bold@, Which I found as necessary evil. But > if workaround will be > found. I will be most happy to get rid of it. > > > ..end of coopypaste: > > > Well yes, Actually exactly this was reason why I rushed with this. Yes this > can be improved, but > also that can be improved! or that? But I do not wont to update so big > patch until eternity. > So I now will be focusing on such a parts which are not considered nice on > some ends. > > > The @bold@ substitution, I dont know the perfect cure. Maybe repalce by > and which can be > repalced to plain or man as is now @bold@ @bold close@ ? > > Yes I agree, "project specific markup" is not nice. And I'm(will) be working > on removal of it. > > No escaping is now done. And I'm not sure if it is wonted/needed in current > state of things. > If it will become needed, it will be added. > > Yes, testing is needed. I wont to add unittests, and also automatic tests by > xmllint on resulting > html. I don't know how to validate man :( And not sure If I wont validate > plain :) > > > One general answer to this. > I will be much more happy to hunt minor bugs in this generator, then check > till madness three > similar - but based on different sources - types of documentation. Maybe > the current formatters > are not perfect (without maybe,... thy are not even pretending to be complex. > They are > single-purposed ones) but do they job. And I doubt some more text will be > added in close or more > remote future. The context of static texts have changed in years only few > times, and really only a > bit. It was the properties, files and switches which were changed > significantly and *always* > forgotten to be documented and,. more horribly left also completely outdated. > I really do not wont > to check those errors anymore. Rather this. > > > J. > > > > > -- Jie Kang From gitne at gmx.de Sat Sep 20 02:05:39 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sat, 20 Sep 2014 04:05:39 +0200 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <757174978.8263445.1411159920251.JavaMail.zimbra@redhat.com> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> <54199ED2.7000707@redhat.com> <757174978.8263445.1411159920251.JavaMail.zimbra@redhat.com> Message-ID: <541CE0F3.7020308@gmx.de> On 09/19/2014 at 10:52 PM, Jie Kang wrote: > ----- Original Message ----- >> ... >>>> + mkdir -p $(DOCS_DIR) ; \ >>>> + HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html ; \ >>>> + PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain ; \ >>>> + MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man/ ; \ >>> >>> Drop the trailing slash. >> >> fixed >>> >>>> mkdir $$HTML_DOCS_TARGET_DIR ; \ >>>> mkdir $$PLAIN_DOCS_TARGET_DIR ; \ >>>> - mkdir -p $$MAN_DOCS_TARGET_DIR ; \ >>>> + mkdir $$MAN_DOCS_TARGET_DIR ; \ >>> >>> Why did you remove the "-p" switch? It is probably best to have this switch >>> almost always on in >>> scripts to avoid running into errors just because of non-existing parent >>> directories. >> >> I prefer opposite. To not use -p. If some typo seek in, then it can create >> whole branch in some >> really strange lcoation... > Hello, > > I would also prefer a consistency in the makefile for mkdir using -p. When you use it in one place and not in another, it leads viewer to wonder why it's needed in one place and not in another. This means extra work to figure out the reason. Maybe some comments in-file here could help? If the only reason to not use '-p' is because typos would cause weird things to happen, then I would keep the -p. Typos shouldn't be a worry since we should in theory never accept things with typos. Right. Besides, HTML_DOCS_TARGET_DIR, PLAIN_DOCS_TARGET_DIR, and/or MAN_DOCS_TARGET_DIR may have been defined before make is invoked, or at make's invocation. > I think some of the strings in Message.properties can be reworded to fix grammar mistakes and help formatting but that can be done in another patch. I will probably submit some changes to the strings myself :D Yes please. Message.properties is full grammar mistakes which sometimes even cause semantic mistakes. Of course, you are free to fix /all/ or /any/ of the grammar mistakes, regardless of their origin or connection to any specific changeset. ;-) Thank you for taking care of this. > Apart from that it seems okay. I haven't thought of any good solutions to the issue with @BOLD_OPEN, etc. but I will keep thinking. The simplest and possibly most consistent approach to get rid of those awful @TAG@ tags is just to allow man page formatting in message strings and have them removed by the lately introduced Translator. Now, I am unaware whether the text providers depend on the Translator too. If they do the Translator's kind of getText() method could be overloaded with one that has an additional boolean parameter which causes the man formatting to be preserved or ignored. Then the text providers could set this parameter to true when generating documentation. I do not know, it is just an idea. Jacob From bugzilla-daemon at icedtea.classpath.org Sat Sep 20 20:00:23 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Sat, 20 Sep 2014 20:00:23 +0000 Subject: [Bug 2010] New: Problematic frame: [libjvm.so+0x82f383] Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2010 Bug ID: 2010 Summary: Problematic frame: [libjvm.so+0x82f383] Product: IcedTea Version: 2.5.2 Hardware: x86_64 OS: Linux Status: NEW Severity: blocker Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: pvjose at gmail.com CC: unassigned at icedtea.classpath.org Created attachment 1173 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1173&action=edit . # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007ffa4f6df383, pid=26987, tid=140712871966464 # # JRE version: OpenJDK Runtime Environment (7.0_65-b32) (build 1.7.0_65-b32) # Java VM: OpenJDK 64-Bit Server VM (24.65-b04 mixed mode linux-amd64 compressed oops) # Derivative: IcedTea 2.5.2 # Distribution: Ubuntu 14.04 LTS, package 7u65-2.5.2-3~14.04 # Problematic frame: # V [libjvm.so+0x82f383] oopDesc* PSPromotionManager::copy_to_survivor_space(oopDesc*)+0x253 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From aazores at icedtea.classpath.org Sun Sep 21 14:44:22 2014 From: aazores at icedtea.classpath.org (aazores at icedtea.classpath.org) Date: Sun, 21 Sep 2014 14:44:22 +0000 Subject: /hg/release/icedtea-web-1.5: Fix javaws.1 man page typos and for... Message-ID: changeset e66c55de3d22 in /hg/release/icedtea-web-1.5 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.5?cmd=changeset;node=e66c55de3d22 author: Andrew Azores date: Sun Sep 21 10:43:48 2014 -0400 Fix javaws.1 man page typos and formatting 2014-09-21 Andrew Azores * netx/javaws.1: Fixed typos, made formatting more consistent, and added missing documentation for -Xoffline switch. diffstat: ChangeLog | 5 ++++ netx/javaws.1 | 72 +++++++++++++++++++++++++++++++++++++--------------------- 2 files changed, 51 insertions(+), 26 deletions(-) diffs (166 lines): diff -r 4f76df2f1438 -r e66c55de3d22 ChangeLog --- a/ChangeLog Fri Aug 15 09:49:16 2014 +0200 +++ b/ChangeLog Sun Sep 21 10:43:48 2014 -0400 @@ -1,3 +1,8 @@ +2014-09-21 Andrew Azores + + * netx/javaws.1: Fixed typos, made formatting more consistent, and added + missing documentation for -Xoffline switch. + 2014-08-15 Jiri Vanek Post 1.5 changes diff -r 4f76df2f1438 -r e66c55de3d22 netx/javaws.1 --- a/netx/javaws.1 Fri Aug 15 09:49:16 2014 +0200 +++ b/netx/javaws.1 Sun Sep 21 10:43:48 2014 -0400 @@ -1,4 +1,4 @@ -.TH javaws 1 "9 Sep 2010" +.TH javaws 1 "23 Aug 2014" .SH NAME javaws - a Java Web Start client .SH SYNOPSIS @@ -15,22 +15,22 @@ .B javaws is from the IcedTea project and is based on the NetX project. .PP -A JNLP file is an xml file that describes how to securely run a +A JNLP file is an XML file that describes how to securely run a remote Java application or a Java applet. .SH OPTIONS -When specifying options, the name of the jnlp file must be the last +When specifying options, the name of the JNLP file must be the last argument to .B javaws -- all the options must preceede it. +- all the options must precede it. .PP -The jnlp-file can either be a url or a local path. +The JNLP-file can either be a URL or a local path. .PP .B Control Options .PP By default .B javaws -will launch the jnlp file specified on the command line. The control +will launch the JNLP file specified on the command line. The control options can be used to change this behaviour. .TP 12 \-about @@ -61,7 +61,7 @@ Sets a system property before launching. .TP \-update seconds -Update check if seconds since last checked. +Check for applet/application updates if "seconds" seconds have elapsed since the last check. .TP \-license Display the GPL license and exit. @@ -76,7 +76,7 @@ Disables checking for updates. .TP \-headless -Disables download window, other UIs. +Disables the download window and other extra UI elements. .TP \-strict Enables strict checking of JNLP file format. Any deviations from @@ -85,11 +85,18 @@ to abort. .TP \-xml -The jnlp files will be checked more strictly for XML validity +Enables stricter XML validity checking for JNLP files. .TP \-allowredirect -Allow to follow 301, 302, 303, 307 and 308 redirections for javaws -applications +Enables following 301, 302, 303, 307 and 308 HTTP redirects for +.B javaws +applications. +.TP +\-Xoffline +IcedTea-Web will not attempt to connect to the network to check for or download +newer versions of the requested applet or application. Locally cached application +files will be used instead, if available. The application itself may still +establish its own network connections. .TP \-Xnofork Do not create another JVM, even if the JNLP file asks for running in @@ -102,41 +109,53 @@ Skip jar header verification. .TP \-Jjava-option -This passes along java-option to the java binary that is running -javaws. For example, to make javaws run with a max heap size +This passes along java-option to the Java binary (JVM) which +.B javaws +will be executed within. For example, to make +.B javaws +run with a max heap size of 80m, use -J-Xmx80m. .TP \-help -Print a help message and exit. +Print the +.B javaws +help message and exit. .SH FILES -$XDG_CONFIG_DIR/icedtea-web/deployment.properties specifies the settings used by javaws +$XDG_CONFIG_DIR/icedtea-web/deployment.properties specifies the settings used by +.B javaws $XDG_CONFIG_DIR/icedtea-web/log (may be set to different location by you) contains file log files (if enabled). itw-cplugin-date_time.log for native part of plugin, itw-javantx-date_time.log for everything else. -$XDG_CONFIG_DIR/icedtea-web/security/java.policy contains granted permissions for selected unsigned apps +$XDG_CONFIG_DIR/icedtea-web/security/java.policy contains the user's security policy, which may grant extra permissions to applets. -$XDG_CONFIG_DIR/icedtea-web/security/trusted.*certs contains various stored certificates +$XDG_CONFIG_DIR/icedtea-web/security/trusted.*certs contains various stored certificates. -$XDG_CACHE_DIR/icedtea-web/cache contains cached runtime entries (amy be changed by you) +$XDG_CACHE_DIR/icedtea-web/cache contains cached runtime entries (may be modified by the user). -$XDG_CACHE_DIR/icedtea-web/pcache contains saved application data +$XDG_CACHE_DIR/icedtea-web/pcache contains saved application data. -$XDG_CACHE_DIR/icedtea-web/tmp contains temporary runtime files +$XDG_CACHE_DIR/icedtea-web/tmp contains temporary runtime files. $XDG_RUNTIME_DIR/icedteaplugin-user-*/ contains in and out pipe for native<->java communication and (if enabled) debugging pipe -Where $XDG_CONFIG_DIR, $XDG_CACHE_DIR and $XDG_RUNTIME_DIR are set as ~/.config, ~/.cache and /tmp or /var/tmp if not set. +Where $XDG_CONFIG_DIR, $XDG_CACHE_DIR and $XDG_RUNTIME_DIR are defined as $HOME/.config, $HOME/.cache and either /tmp or /var/tmp by default. +This is in accordance with the FreeDesktop Base Directory Specification: + http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html .SH BUGS -There arent any known bugs. If you come across one, please file it at +There aren't any known bugs. If you come across one, please file it at http://icedtea.classpath.org/bugzilla/ .br -Please run javaws in debug (-verbose switch or itw-settings setting or ICEDTEAPLUGIN_DEBUG variable set to true) -mode and include that output (best is from java console) with URL to jnlp or html file -(ot the jnlp/html file or application itself) when filing out the bug report. +Please run +.B javaws +in debug (via -verbose switch, +.B itweb-settings +configuration, or ICEDTEAPLUGIN_DEBUG environment variable set to true) +mode and include that output (best is from java console) with URL to JNLP or HTML file +(not the JNLP/HTML file or application itself) when filing out the bug report. .SH AUTHOR Originally written by Jon. A. Maxwell. @@ -144,6 +163,7 @@ Currently maintained by the IcedTea contributors. See javaws -about for more info .SH SEE ALSO -.BR java (1) +.BR java (1), +.BR itweb-settings (1) .br http://icedtea.classpath.org/wiki/IcedTea-Web From aazores at redhat.com Sun Sep 21 15:50:34 2014 From: aazores at redhat.com (Andrew Azores) Date: Sun, 21 Sep 2014 11:50:34 -0400 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <757174978.8263445.1411159920251.JavaMail.zimbra@redhat.com> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> <54199ED2.7000707@redhat.com> <757174978.8263445.1411159920251.JavaMail.zimbra@redhat.com> Message-ID: <541EF3CA.1000906@redhat.com> On 09/19/2014 04:52 PM, Jie Kang wrote: > ----- Original Message ----- >> ... >>>> + mkdir -p $(DOCS_DIR) ; \ >>>> + HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html ; \ >>>> + PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain ; \ >>>> + MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man/ ; \ >>> >>> Drop the trailing slash. >> >> fixed >>> >>>> mkdir $$HTML_DOCS_TARGET_DIR ; \ >>>> mkdir $$PLAIN_DOCS_TARGET_DIR ; \ >>>> - mkdir -p $$MAN_DOCS_TARGET_DIR ; \ >>>> + mkdir $$MAN_DOCS_TARGET_DIR ; \ >>> >>> Why did you remove the "-p" switch? It is probably best to have this switch >>> almost always on in >>> scripts to avoid running into errors just because of non-existing parent >>> directories. >> >> I prefer opposite. To not use -p. If some typo seek in, then it can create >> whole branch in some >> really strange lcoation... > Hello, > > I would also prefer a consistency in the makefile for mkdir using -p. When you use it in one place and not in another, it leads viewer to wonder why it's needed in one place and not in another. This means extra work to figure out the reason. Maybe some comments in-file here could help? If the only reason to not use '-p' is because typos would cause weird things to happen, then I would keep the -p. Generally agreed here. I'd also lean on the side of consistency, although I do also think Jiri's motivation for removing it does make sense. As "risky" as the -p switch may be in case of the arguments to mkdir being incorrect, I think it's still acceptable if you're always essentially in direct control of those arguments. If the directory path was coming from a user then yea definitely don't put a -p there, but if it's just given a default value from the Makefile, or some non-default from configure because a developer wants it somewhere else... then I think it's reasonable to assume that the input is relatively "sanitized" already. >Typos shouldn't be a worry since we should in theory never accept things with typos. Really not agreed here. How exactly are we supposed to detect, let alone even decide on accepting, what is a typo when attempting to create a directory given only its name? To me this is a ludicrous proposition. It's completely context dependent. You can try to deem a location as being a "typo" if its parents don't yet exist and the -p switch isn't in use, but this is not actually equivalent to being a typo. It's just a weak-ish heuristic for it. It's one thing to simply assume that there aren't typos but that isn't the same as asserting that typos will be rejected. > > I think some of the strings in Message.properties can be reworded to fix grammar mistakes and help formatting but that can be done in another patch. I will probably submit some changes to the strings myself :D > > Apart from that it seems okay. I haven't thought of any good solutions to the issue with @BOLD_OPEN, etc. but I will keep thinking. > Thanks, -- Andrew Azores From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 12:10:35 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 12:10:35 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 --- Comment #7 from JiriVanek --- oh well. Fair enough then.Ty! -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 12:14:20 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 12:14:20 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 --- Comment #8 from JiriVanek --- > > I also wrote the unlimited versions (the ones we actually use) first, so the > limited one ended up being copy and paste ;) can it be done real copy then? I mean only cp the final jar under new name.... -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Mon Sep 22 12:51:26 2014 From: jkang at redhat.com (Jie Kang) Date: Mon, 22 Sep 2014 08:51:26 -0400 (EDT) Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <541EF3CA.1000906@redhat.com> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> <54199ED2.7000707@redhat.com> <757174978.8263445.1411159920251.JavaMail.zimbra@redhat.com> <541EF3CA.1000906@redhat.com> Message-ID: <1404663745.8975941.1411390286091.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/19/2014 04:52 PM, Jie Kang wrote: > > ----- Original Message ----- > >> ... > >>>> + mkdir -p $(DOCS_DIR) ; \ > >>>> + HTML_DOCS_TARGET_DIR=$(DOCS_DIR)/html ; \ > >>>> + PLAIN_DOCS_TARGET_DIR=$(DOCS_DIR)/plain ; \ > >>>> + MAN_DOCS_TARGET_DIR=$(DOCS_DIR)/man/ ; \ > >>> > >>> Drop the trailing slash. > >> > >> fixed > >>> > >>>> mkdir $$HTML_DOCS_TARGET_DIR ; \ > >>>> mkdir $$PLAIN_DOCS_TARGET_DIR ; \ > >>>> - mkdir -p $$MAN_DOCS_TARGET_DIR ; \ > >>>> + mkdir $$MAN_DOCS_TARGET_DIR ; \ > >>> > >>> Why did you remove the "-p" switch? It is probably best to have this > >>> switch > >>> almost always on in > >>> scripts to avoid running into errors just because of non-existing parent > >>> directories. > >> > >> I prefer opposite. To not use -p. If some typo seek in, then it can create > >> whole branch in some > >> really strange lcoation... > > Hello, > > > > I would also prefer a consistency in the makefile for mkdir using -p. When > > you use it in one place and not in another, it leads viewer to wonder why > > it's needed in one place and not in another. This means extra work to > > figure out the reason. Maybe some comments in-file here could help? If the > > only reason to not use '-p' is because typos would cause weird things to > > happen, then I would keep the -p. > > Generally agreed here. I'd also lean on the side of consistency, > although I do also think Jiri's motivation for removing it does make > sense. As "risky" as the -p switch may be in case of the arguments to > mkdir being incorrect, I think it's still acceptable if you're always > essentially in direct control of those arguments. If the directory path > was coming from a user then yea definitely don't put a -p there, but if > it's just given a default value from the Makefile, or some non-default > from configure because a developer wants it somewhere else... then I > think it's reasonable to assume that the input is relatively "sanitized" > already. > > >Typos shouldn't be a worry since we should in theory never accept things > >with typos. > > Really not agreed here. How exactly are we supposed to detect, let alone > even decide on accepting, what is a typo when attempting to create a > directory given only its name? To me this is a ludicrous proposition. > It's completely context dependent. You can try to deem a location as > being a "typo" if its parents don't yet exist and the -p switch isn't in > use, but this is not actually equivalent to being a typo. It's just a > weak-ish heuristic for it. > > It's one thing to simply assume that there aren't typos but that isn't > the same as asserting that typos will be rejected. You misunderstood me. I meant we ourselves shouldn't write typos and push them into the repo. Since we're in direct control of the directory name we shouldn't be making typos and so the -p issue shouldn't be a worry. I didn't mean the code should check for typos. Regards, > > > > > I think some of the strings in Message.properties can be reworded to fix > > grammar mistakes and help formatting but that can be done in another > > patch. I will probably submit some changes to the strings myself :D > > > > Apart from that it seems okay. I haven't thought of any good solutions to > > the issue with @BOLD_OPEN, etc. but I will keep thinking. > > > > > Thanks, > -- > Andrew Azores > -- Jie Kang From jvanek at redhat.com Mon Sep 22 12:55:56 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 22 Sep 2014 14:55:56 +0200 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <1404663745.8975941.1411390286091.JavaMail.zimbra@redhat.com> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> <54199ED2.7000707@redhat.com> <757174978.8263445.1411159920251.JavaMail.zimbra@redhat.com> <541EF3CA.1000906@redhat.com> <1404663745.8975941.1411390286091.JavaMail.zimbra@redhat.com> Message-ID: <54201C5C.3050500@redhat.com> >> >>> Typos shouldn't be a worry since we should in theory never accept things >>> with typos. >> >> Really not agreed here. How exactly are we supposed to detect, let alone >> even decide on accepting, what is a typo when attempting to create a >> directory given only its name? To me this is a ludicrous proposition. >> It's completely context dependent. You can try to deem a location as >> being a "typo" if its parents don't yet exist and the -p switch isn't in >> use, but this is not actually equivalent to being a typo. It's just a >> weak-ish heuristic for it. >> >> It's one thing to simply assume that there aren't typos but that isn't >> the same as asserting that typos will be rejected. > > You misunderstood me. I meant we ourselves shouldn't write typos and push them into the repo. Since we're in direct control of the directory name we shouldn't be making typos and so the -p issue shouldn't be a worry. I didn't mean the code should check for typos. > > Imho he did not. W should not do typos, reviewer should check typos, we should hire human spellchecker.... no metter how this list is long,there is no guarantee that no typo sneak through... I can simply imagine scenario like - patch approved, so I prepare to push, final check on chnages, and some unlucky key press just before closing editor and sin is done. So yes. Typoless ideall world will be really great, but is ...(not nearly, but utterly) impossible. So the -p can be dangerous anyway. J. From jvanek at redhat.com Mon Sep 22 12:57:11 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 22 Sep 2014 14:57:11 +0200 Subject: Fwd: Re: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <54199ED2.7000707@redhat.com> References: <54199ED2.7000707@redhat.com> Message-ID: <54201CA7.10707@redhat.com> zzzz... This thread is about issuse unrelated to this changeset. May I proceed? J. -------------- next part -------------- A non-text attachment was scrubbed... Name: localizabblePlugin+settings+fix+cleanup2.patch Type: text/x-patch Size: 16989 bytes Desc: not available URL: From jvanek at redhat.com Mon Sep 22 13:17:45 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 22 Sep 2014 15:17:45 +0200 Subject: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <541CE0F3.7020308@gmx.de> References: <5412F405.7050807@redhat.com> <5414DCFF.4000200@gmx.de> <54199ED2.7000707@redhat.com> <757174978.8263445.1411159920251.JavaMail.zimbra@redhat.com> <541CE0F3.7020308@gmx.de> Message-ID: <54202179.9000604@redhat.com> ... >> >> I would also prefer a consistency in the makefile for mkdir using -p. When you use it in one place >> and not in another, it leads viewer to wonder why it's needed in one place and not in another. >> This means extra work to figure out the reason. Maybe some comments in-file here could help? If >> the only reason to not use '-p' is because typos would cause weird things to happen, then I would >> keep the -p. Typos shouldn't be a worry since we should in theory never accept things with typos. > > Right. Besides, HTML_DOCS_TARGET_DIR, PLAIN_DOCS_TARGET_DIR, and/or MAN_DOCS_TARGET_DIR may have > been defined before make is invoked, or at make's invocation. > >> I think some of the strings in Message.properties can be reworded to fix grammar mistakes and help >> formatting but that can be done in another patch. I will probably submit some changes to the >> strings myself :D > > Yes please. Message.properties is full grammar mistakes which sometimes even cause semantic > mistakes. Of course, you are free to fix /all/ or /any/ of the grammar mistakes, regardless of their > origin or connection to any specific changeset. ;-) Thank you for taking care of this. > Not sure how much is Jie native speaker .. . But good to have an volunteer O:) >> Apart from that it seems okay. I haven't thought of any good solutions to the issue with >> @BOLD_OPEN, etc. but I will keep thinking. > > The simplest and possibly most consistent approach to get rid of those awful @TAG@ tags is just to > allow man page formatting in message strings and have them removed by the lately introduced > Translator. Now, I am unaware whether the text providers depend on the Translator too. If they do > the Translator's kind of getText() method could be overloaded with one that has an additional > boolean parameter which causes the man formatting to be preserved or ignored. Then the text > providers could set this parameter to true when generating documentation. I do not know, it is just > an idea. > This is refreshing idea, but have several drawbacks. The Translator is responsible for delivering message from proeperties to target, according to language. It should have nothing to do formating. We breake this principle on places, where the output should be html. It is saving a lot of work, so afiak it is ok. But translator itself have nothing to do with formatting. So although current doc provider is using translator to get sentences or titles, it is responsible for collecting sentences to paragraphs, adding headers, headlines and footers and adding, based on formatter, add correct formatting. J. From jvanek at redhat.com Mon Sep 22 14:55:57 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 22 Sep 2014 16:55:57 +0200 Subject: [rfc][icedtea-web] possible class cast exception in splashcontroler In-Reply-To: <1688856320.8186878.1411149105125.JavaMail.zimbra@redhat.com> References: <5419596C.7060101@redhat.com> <1688856320.8186878.1411149105125.JavaMail.zimbra@redhat.com> Message-ID: <5420387D.3070101@redhat.com> On 09/19/2014 07:51 PM, Jie Kang wrote: > > > ----- Original Message ----- >> Some applets, may not be using the original apllet-viewer-pane, but rather >> *detach*, and are in >> separate window. >> >> If such an applet fails, the error screen can not be drawn, because the >> applications frame is not >> SpalshController. >> >> As splash logic can live happily with null splashcontoloere (==not work, and >> silently exit) , the >> class cast exception is unnecessary. >> >> There is nothing to be done to save the application as it already died, but >> the error is imho really >> unnecessary. > > Hello, > > > Can you fix the type in: > getSplashControler() > to > getSplashController() Done. > > Could you also see if a test/reproducer can be added to make sure that a null return value is okay? (Can be another changeset) I looked through the code and it should be fine but a test to make sure would be great. > > Apart from that the patch looks fine. > Added small test to check null values do not throw NPEs. Pushing to head. I would like to push it also to 1.5. ok? Ty for check! J. -------------- next part -------------- A non-text attachment was scrubbed... Name: splashCastFix2.patch Type: text/x-patch Size: 2158 bytes Desc: not available URL: From jkang at redhat.com Mon Sep 22 14:58:18 2014 From: jkang at redhat.com (Jie Kang) Date: Mon, 22 Sep 2014 10:58:18 -0400 (EDT) Subject: [rfc][icedtea-web] possible class cast exception in splashcontroler In-Reply-To: <5420387D.3070101@redhat.com> References: <5419596C.7060101@redhat.com> <1688856320.8186878.1411149105125.JavaMail.zimbra@redhat.com> <5420387D.3070101@redhat.com> Message-ID: <1306626496.9082619.1411397898520.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/19/2014 07:51 PM, Jie Kang wrote: > > > > > > ----- Original Message ----- > >> Some applets, may not be using the original apllet-viewer-pane, but rather > >> *detach*, and are in > >> separate window. > >> > >> If such an applet fails, the error screen can not be drawn, because the > >> applications frame is not > >> SpalshController. > >> > >> As splash logic can live happily with null splashcontoloere (==not work, > >> and > >> silently exit) , the > >> class cast exception is unnecessary. > >> > >> There is nothing to be done to save the application as it already died, > >> but > >> the error is imho really > >> unnecessary. > > > > Hello, > > > > > > Can you fix the type in: > > getSplashControler() > > to > > getSplashController() > > > Done. > > > > Could you also see if a test/reproducer can be added to make sure that a > > null return value is okay? (Can be another changeset) I looked through the > > code and it should be fine but a test to make sure would be great. > > > > Apart from that the patch looks fine. > > > > Added small test to check null values do not throw NPEs. > > > Pushing to head. I would like to push it also to 1.5. ok? > Hello, Push to 1.5 should be good too :) Regards, > Ty for check! > > J. > > -- Jie Kang From jvanek at icedtea.classpath.org Mon Sep 22 15:10:19 2014 From: jvanek at icedtea.classpath.org (jvanek at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:10:19 +0000 Subject: /hg/icedtea-web: Preventing rare class cast exception in erroneo... Message-ID: changeset 6d62f68fb037 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=6d62f68fb037 author: Jiri Vanek date: Mon Sep 22 17:10:07 2014 +0200 Preventing rare class cast exception in erroneous detached applets diffstat: ChangeLog | 10 ++++++++++ netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java | 9 ++++++--- netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java | 2 +- tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java | 10 ++++++++++ 4 files changed, 27 insertions(+), 4 deletions(-) diffs (74 lines): diff -r 9fbfc6ef9237 -r 6d62f68fb037 ChangeLog --- a/ChangeLog Fri Sep 19 15:51:19 2014 -0400 +++ b/ChangeLog Mon Sep 22 17:10:07 2014 +0200 @@ -1,3 +1,13 @@ +2014-09-22 Jiri Vanek + + Preventing rare class cast exception in erroneous detached applets + * netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java: getSplashControler + renamed to getSplashController. (getSplashController) added check for + SplashController instance. Returning null if not so. + * netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java: adapted to renaming + * tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java: + added (assertNulsAreOkInShow) test to check null values for showError methods + 2014-09-19 Jie Kang Modified Makefile.am to use whitelist when processing reproducers. diff -r 9fbfc6ef9237 -r 6d62f68fb037 netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java --- a/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java Fri Sep 19 15:51:19 2014 -0400 +++ b/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java Mon Sep 22 17:10:07 2014 +0200 @@ -138,9 +138,12 @@ * container must be SplashContoler * */ - public SplashController getSplashControler() { - - return (SplashController)cont; + public SplashController getSplashController() { + if (cont instanceof SplashController) { + return (SplashController) cont; + } else { + return null; + } } /** diff -r 9fbfc6ef9237 -r 6d62f68fb037 netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java --- a/netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java Fri Sep 19 15:51:19 2014 -0400 +++ b/netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java Mon Sep 22 17:10:07 2014 +0200 @@ -94,7 +94,7 @@ if (ae == null) { return; } - SplashController p = ae.getSplashControler(); + SplashController p = ae.getSplashController(); showError(ex, p); } diff -r 9fbfc6ef9237 -r 6d62f68fb037 tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java --- a/tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java Fri Sep 19 15:51:19 2014 -0400 +++ b/tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java Mon Sep 22 17:10:07 2014 +0200 @@ -40,6 +40,8 @@ import java.util.Collections; import java.util.HashMap; import java.util.Map; +import net.sourceforge.jnlp.runtime.AppletEnvironment; +import net.sourceforge.jnlp.runtime.AppletInstance; import net.sourceforge.jnlp.runtime.JNLPRuntime; import net.sourceforge.jnlp.splashscreen.impls.*; import org.junit.Assert; @@ -251,5 +253,13 @@ field.setAccessible(true); field.set(null, newValue); } + + @Test + public void assertNulsAreOkInShow() { + SplashUtils.showError(null, (AppletEnvironment)null); + SplashUtils.showError(null, (AppletInstance)null); + SplashUtils.showError(null, (SplashController)null); + } + } From andrew at icedtea.classpath.org Mon Sep 22 15:10:50 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:10:50 +0000 Subject: /hg/release/icedtea7-forest-2.5: Added tag icedtea-2.5.3pre01 fo... Message-ID: changeset 6f40002d1813 in /hg/release/icedtea7-forest-2.5 details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5?cmd=changeset;node=6f40002d1813 author: andrew date: Mon Sep 22 15:44:17 2014 +0100 Added tag icedtea-2.5.3pre01 for changeset dfe93c56a5f6 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r dfe93c56a5f6 -r 6f40002d1813 .hgtags --- a/.hgtags Fri Aug 29 21:08:27 2014 +0100 +++ b/.hgtags Mon Sep 22 15:44:17 2014 +0100 @@ -487,3 +487,4 @@ 64dbd70735c775bef1faf873e4bec65d73d597cb jdk7u65-b19 483622a291d726960c8ccca5650de9569f269d7a icedtea-2.5.1 de1fbcb0855887e803b71a8da642c377c85c3780 icedtea-2.5.2 +dfe93c56a5f60a4ef0f3b3727d7784b6879a5bd9 icedtea-2.5.3pre01 From andrew at icedtea.classpath.org Mon Sep 22 15:10:56 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:10:56 +0000 Subject: /hg/release/icedtea7-forest-2.5/corba: Added tag icedtea-2.5.3pr... Message-ID: changeset 090fc686cf0b in /hg/release/icedtea7-forest-2.5/corba details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/corba?cmd=changeset;node=090fc686cf0b author: andrew date: Mon Sep 22 15:44:05 2014 +0100 Added tag icedtea-2.5.3pre01 for changeset 1d178f96bc11 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r 1d178f96bc11 -r 090fc686cf0b .hgtags --- a/.hgtags Fri Aug 29 21:08:14 2014 +0100 +++ b/.hgtags Mon Sep 22 15:44:05 2014 +0100 @@ -489,3 +489,4 @@ 50ddba8882e7e95150418a30bfc3ee62e3c28c6c jdk7u65-b19 895c6b10499623eaf8897a9ed0d28a34e4cd4a89 icedtea-2.5.1 06663e4cfbbeade300222eeae55856940b2ffbee icedtea-2.5.2 +1d178f96bc11a65290eb4787edbca3c08c83a4f4 icedtea-2.5.3pre01 From andrew at icedtea.classpath.org Mon Sep 22 15:11:01 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:11:01 +0000 Subject: /hg/release/icedtea7-forest-2.5/jaxp: Added tag icedtea-2.5.3pre... Message-ID: changeset a4e4e763970f in /hg/release/icedtea7-forest-2.5/jaxp details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jaxp?cmd=changeset;node=a4e4e763970f author: andrew date: Mon Sep 22 15:44:06 2014 +0100 Added tag icedtea-2.5.3pre01 for changeset 771d2a0e90ae diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r 771d2a0e90ae -r a4e4e763970f .hgtags --- a/.hgtags Fri Aug 29 21:08:15 2014 +0100 +++ b/.hgtags Mon Sep 22 15:44:06 2014 +0100 @@ -490,3 +490,4 @@ 4e323af07c47061109fb5f585613b0cc4b4208ca jdk7u65-b19 59a1a3e441089798763016eedfcc066e6f437bd2 icedtea-2.5.1 d77720c6a36f0b9c995e47badb8efddd0e8f2021 icedtea-2.5.2 +771d2a0e90aef31fd70a2eda48b2d1aff8c15101 icedtea-2.5.3pre01 From andrew at icedtea.classpath.org Mon Sep 22 15:11:07 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:11:07 +0000 Subject: /hg/release/icedtea7-forest-2.5/jaxws: Added tag icedtea-2.5.3pr... Message-ID: changeset dcb5afbd4d7d in /hg/release/icedtea7-forest-2.5/jaxws details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jaxws?cmd=changeset;node=dcb5afbd4d7d author: andrew date: Mon Sep 22 15:44:07 2014 +0100 Added tag icedtea-2.5.3pre01 for changeset c46dd3a579f0 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r c46dd3a579f0 -r dcb5afbd4d7d .hgtags --- a/.hgtags Fri Aug 29 21:08:17 2014 +0100 +++ b/.hgtags Mon Sep 22 15:44:07 2014 +0100 @@ -489,3 +489,4 @@ db4cccbfd72fc265b736a273797963754434a7d2 jdk7u65-b19 b5384b2fb987fc5310167a9524b4a5ee1880f56b icedtea-2.5.1 aac78bd724c437cefd9ba8abb280df34609ca936 icedtea-2.5.2 +c46dd3a579f036318ca043387f4619aa2a3a0f33 icedtea-2.5.3pre01 From andrew at icedtea.classpath.org Mon Sep 22 15:11:13 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:11:13 +0000 Subject: /hg/release/icedtea7-forest-2.5/langtools: Added tag icedtea-2.5... Message-ID: changeset 0e3fd42f2696 in /hg/release/icedtea7-forest-2.5/langtools details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/langtools?cmd=changeset;node=0e3fd42f2696 author: andrew date: Mon Sep 22 15:44:16 2014 +0100 Added tag icedtea-2.5.3pre01 for changeset fe8926c95af9 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r fe8926c95af9 -r 0e3fd42f2696 .hgtags --- a/.hgtags Fri Aug 29 21:08:26 2014 +0100 +++ b/.hgtags Mon Sep 22 15:44:16 2014 +0100 @@ -489,3 +489,4 @@ eae289997f58ef6396dc323c3d5b93a56fb43573 jdk7u65-b19 4c827dc3de054b03008402f571ca645cbf7939e6 icedtea-2.5.1 f444e2a7764393fa62cc1ec9dcaa3a9f7ebbc551 icedtea-2.5.2 +fe8926c95af9d3c2cd4b1b6a6e107edbd52542cd icedtea-2.5.3pre01 From andrew at icedtea.classpath.org Mon Sep 22 15:11:20 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:11:20 +0000 Subject: /hg/release/icedtea7-forest-2.5/hotspot: Added tag icedtea-2.5.3... Message-ID: changeset f5202a835c05 in /hg/release/icedtea7-forest-2.5/hotspot details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/hotspot?cmd=changeset;node=f5202a835c05 author: andrew date: Mon Sep 22 15:44:19 2014 +0100 Added tag icedtea-2.5.3pre01 for changeset 9f719e4c80af diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r 9f719e4c80af -r f5202a835c05 .hgtags --- a/.hgtags Mon Sep 08 17:44:42 2014 +0100 +++ b/.hgtags Mon Sep 22 15:44:19 2014 +0100 @@ -709,3 +709,4 @@ 1d8226b3e9896656451801393eb3ae394faeb638 jdk7u65-b19 02066294d005e81a81d3a01ec549716ebcc65723 icedtea-2.5.1 4ad43b271fd439317ec422b5ea35ea3483d40922 icedtea-2.5.2 +9f719e4c80af23dc6574df3e431ad85c29a1937d icedtea-2.5.3pre01 From andrew at icedtea.classpath.org Mon Sep 22 15:11:27 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:11:27 +0000 Subject: /hg/release/icedtea7-forest-2.5/jdk: Added tag icedtea-2.5.3pre0... Message-ID: changeset 59ce33d99e27 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=59ce33d99e27 author: andrew date: Mon Sep 22 15:44:14 2014 +0100 Added tag icedtea-2.5.3pre01 for changeset fa4e5dae68e1 diffstat: .hgtags | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diffs (8 lines): diff -r fa4e5dae68e1 -r 59ce33d99e27 .hgtags --- a/.hgtags Fri Sep 19 20:06:43 2014 +0100 +++ b/.hgtags Mon Sep 22 15:44:14 2014 +0100 @@ -473,3 +473,4 @@ ba6cef21c369076be97dd8133fd4a158cd486bd8 jdk7u65-b19 d6d4b6c9f5b48254a6dc1430dee9ee85d7f86b97 icedtea-2.5.1 1e6a8564aa3400fe8f84085c908f55a942d426f0 icedtea-2.5.2 +fa4e5dae68e19bdd1f0bac703889a4cf30a59754 icedtea-2.5.3pre01 From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 15:12:08 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:12:08 +0000 Subject: [Bug 2010] Problematic frame: [libjvm.so+0x82f383] In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2010 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|blocker |normal --- Comment #1 from Andrew John Hughes --- Do you have a reproducer for this issue? -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at icedtea.classpath.org Mon Sep 22 15:13:26 2014 From: jvanek at icedtea.classpath.org (jvanek at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:13:26 +0000 Subject: /hg/release/icedtea-web-1.5: Preventing rare class cast exceptio... Message-ID: changeset 249435147a0b in /hg/release/icedtea-web-1.5 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.5?cmd=changeset;node=249435147a0b author: Jiri Vanek date: Mon Sep 22 17:13:19 2014 +0200 Preventing rare class cast exception in erroneous detached applets diffstat: ChangeLog | 10 ++++++++++ netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java | 9 ++++++--- netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java | 2 +- tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java | 10 ++++++++++ tests/netx/unit/net/sourceforge/jnlp/util/logging/JavaConsoleTest.java | 2 +- 5 files changed, 28 insertions(+), 5 deletions(-) diffs (86 lines): diff -r e66c55de3d22 -r 249435147a0b ChangeLog --- a/ChangeLog Sun Sep 21 10:43:48 2014 -0400 +++ b/ChangeLog Mon Sep 22 17:13:19 2014 +0200 @@ -1,3 +1,13 @@ +2014-09-22 Jiri Vanek + + Preventing rare class cast exception in erroneous detached applets + * netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java: getSplashControler + renamed to getSplashController. (getSplashController) added check for + SplashController instance. Returning null if not so. + * netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java: adapted to renaming + * tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java: + added (assertNulsAreOkInShow) test to check null values for showError methods + 2014-09-21 Andrew Azores * netx/javaws.1: Fixed typos, made formatting more consistent, and added diff -r e66c55de3d22 -r 249435147a0b netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java --- a/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java Sun Sep 21 10:43:48 2014 -0400 +++ b/netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java Mon Sep 22 17:13:19 2014 +0200 @@ -138,9 +138,12 @@ * container must be SplashContoler * */ - public SplashController getSplashControler() { - - return (SplashController)cont; + public SplashController getSplashController() { + if (cont instanceof SplashController) { + return (SplashController) cont; + } else { + return null; + } } /** diff -r e66c55de3d22 -r 249435147a0b netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java --- a/netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java Sun Sep 21 10:43:48 2014 -0400 +++ b/netx/net/sourceforge/jnlp/splashscreen/SplashUtils.java Mon Sep 22 17:13:19 2014 +0200 @@ -94,7 +94,7 @@ if (ae == null) { return; } - SplashController p = ae.getSplashControler(); + SplashController p = ae.getSplashController(); showError(ex, p); } diff -r e66c55de3d22 -r 249435147a0b tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java --- a/tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java Sun Sep 21 10:43:48 2014 -0400 +++ b/tests/netx/unit/net/sourceforge/jnlp/splashscreen/SplashUtilsTest.java Mon Sep 22 17:13:19 2014 +0200 @@ -40,6 +40,8 @@ import java.util.Collections; import java.util.HashMap; import java.util.Map; +import net.sourceforge.jnlp.runtime.AppletEnvironment; +import net.sourceforge.jnlp.runtime.AppletInstance; import net.sourceforge.jnlp.runtime.JNLPRuntime; import net.sourceforge.jnlp.splashscreen.impls.*; import org.junit.Assert; @@ -251,5 +253,13 @@ field.setAccessible(true); field.set(null, newValue); } + + @Test + public void assertNulsAreOkInShow() { + SplashUtils.showError(null, (AppletEnvironment)null); + SplashUtils.showError(null, (AppletInstance)null); + SplashUtils.showError(null, (SplashController)null); + } + } diff -r e66c55de3d22 -r 249435147a0b tests/netx/unit/net/sourceforge/jnlp/util/logging/JavaConsoleTest.java --- a/tests/netx/unit/net/sourceforge/jnlp/util/logging/JavaConsoleTest.java Sun Sep 21 10:43:48 2014 -0400 +++ b/tests/netx/unit/net/sourceforge/jnlp/util/logging/JavaConsoleTest.java Mon Sep 22 17:13:19 2014 +0200 @@ -26,7 +26,7 @@ Assert.assertFalse(p3.wasError); Assert.assertTrue(p1.header.isC); Assert.assertTrue(p3.header.isC); - Assert.assertEquals(OutputController.Level.MESSAGE_DEBUG,p1.header.level); + Assert.assertEquals(OutputController.Levgl.MESSAGE_DEBUG,p1.header.level); Assert.assertEquals(OutputController.Level.ERROR_ALL,p3.header.level); Assert.assertTrue(p1.header.date.toString().contains("Tue Nov 19 09:43:50") && p1.header.date.toString().contains("2013")); Assert.assertTrue(p3.header.date.toString().contains("Tue Nov 19 09:43:50") && p3.header.date.toString().contains("2013")); From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 15:16:10 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:16:10 +0000 Subject: [Bug 1884] ProjectLibre just did close and nothing else. I didn't saw another problem or a strange behavior. In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1884 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Version|6-hg |6-1.13.4 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Mon Sep 22 15:41:18 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:41:18 +0000 Subject: /hg/release/icedtea7-2.5: Bump to icedtea-2.5.3pre01. Message-ID: changeset f362ae34fe1b in /hg/release/icedtea7-2.5 details: http://icedtea.classpath.org/hg/release/icedtea7-2.5?cmd=changeset;node=f362ae34fe1b author: Andrew John Hughes date: Mon Sep 22 16:41:07 2014 +0100 Bump to icedtea-2.5.3pre01. 2014-09-22 Andrew John Hughes * Makefile.am: (CORBA_CHANGESET): Update to icedtea-2.5.3pre01 tag. (JAXP_CHANGESET): Likewise. (JAXWS_CHANGESET): Likewise. (JDK_CHANGESET): Likewise. (LANGTOOLS_CHANGESET): Likewise. (OPENJDK_CHANGESET): Likewise. (CORBA_SHA256SUM): Likewise. (JAXP_SHA256SUM): Likewise. (JAXWS_SHA256SUM): Likewise. (JDK_SHA256SUM): Likewise. (LANGTOOLS_SHA256SUM): Likewise. (OPENJDK_SHA256SUM): Likewise. (ICEDTEA_URL): Temporarily hardcode 2.5.3 until pre versions can be handled (PR2000). * NEWS: Updated. * configure.ac: Bump to 2.5.3pre01. * hotspot.map: Update to icedtea-2.5.3pre01 tag. diffstat: ChangeLog | 21 +++++++++++++++++++++ Makefile.am | 26 +++++++++++++------------- NEWS | 11 +++++++++++ configure.ac | 2 +- hotspot.map | 2 +- 5 files changed, 47 insertions(+), 15 deletions(-) diffs (110 lines): diff -r 00016055e63f -r f362ae34fe1b ChangeLog --- a/ChangeLog Wed Sep 03 15:33:40 2014 +0100 +++ b/ChangeLog Mon Sep 22 16:41:07 2014 +0100 @@ -1,3 +1,24 @@ +2014-09-22 Andrew John Hughes + + * Makefile.am: + (CORBA_CHANGESET): Update to icedtea-2.5.3pre01 tag. + (JAXP_CHANGESET): Likewise. + (JAXWS_CHANGESET): Likewise. + (JDK_CHANGESET): Likewise. + (LANGTOOLS_CHANGESET): Likewise. + (OPENJDK_CHANGESET): Likewise. + (CORBA_SHA256SUM): Likewise. + (JAXP_SHA256SUM): Likewise. + (JAXWS_SHA256SUM): Likewise. + (JDK_SHA256SUM): Likewise. + (LANGTOOLS_SHA256SUM): Likewise. + (OPENJDK_SHA256SUM): Likewise. + (ICEDTEA_URL): Temporarily hardcode 2.5.3 until + pre versions can be handled (PR2000). + * NEWS: Updated. + * configure.ac: Bump to 2.5.3pre01. + * hotspot.map: Update to icedtea-2.5.3pre01 tag. + 2014-09-03 Andrew John Hughes * configure.ac: Set to 2.5.3pre00. diff -r 00016055e63f -r f362ae34fe1b Makefile.am --- a/Makefile.am Wed Sep 03 15:33:40 2014 +0100 +++ b/Makefile.am Mon Sep 22 16:41:07 2014 +0100 @@ -4,19 +4,19 @@ BUILD_VERSION = b32 COMBINED_VERSION = $(JDK_UPDATE_VERSION)-$(BUILD_VERSION) -CORBA_CHANGESET = 06663e4cfbbe -JAXP_CHANGESET = d77720c6a36f -JAXWS_CHANGESET = aac78bd724c4 -JDK_CHANGESET = 1e6a8564aa34 -LANGTOOLS_CHANGESET = f444e2a77643 -OPENJDK_CHANGESET = de1fbcb08558 +CORBA_CHANGESET = 1d178f96bc11 +JAXP_CHANGESET = 771d2a0e90ae +JAXWS_CHANGESET = c46dd3a579f0 +JDK_CHANGESET = fa4e5dae68e1 +LANGTOOLS_CHANGESET = fe8926c95af9 +OPENJDK_CHANGESET = dfe93c56a5f6 -CORBA_SHA256SUM = f6afe3f5dbec8723d650ac4ecbaf6aa41cd90759eb6503f0397248098a9e1c77 -JAXP_SHA256SUM = abd68afe382a92b51a45547bd272c12569cf0d166a1f2f00cc3a9ef0fa988a4b -JAXWS_SHA256SUM = 069def5538e1e52ed831f9657a9b9ea8e9401788390b54290f2fd7c1bd0b6ccc -JDK_SHA256SUM = 992a726be72bce1ad9a275b1fc1782c0beb0f80c50de35a989258a56fdfd2ffd -LANGTOOLS_SHA256SUM = 5f04fffdcbb4a76cd57c8319c676537c9481625e0c686e172a152deeb7871811 -OPENJDK_SHA256SUM = a0f1e39980d4774fec4d6d1096a7c6c5858920536977dec294ec14c5c93d4fb9 +CORBA_SHA256SUM = fd3047579013676db55324e1ed74c74652b23dc7d1255165d118e0e56be1478b +JAXP_SHA256SUM = 1cfa25ddd8da271d845de2dde8d23bad103c76684a8412196dc1396edaf28037 +JAXWS_SHA256SUM = 47dcfced6ca076e912d036e4068edf8cdc44ae7def5ab338e54ed40d34c66a5e +JDK_SHA256SUM = 263336cb065d74e0c52fe356bbd93b971fdcd1c25d11784255f8f84263a885a3 +LANGTOOLS_SHA256SUM = 18f0bcc0ad9d338f70219e9bdc11cd6639875b79858c72cbf875411238ff351e +OPENJDK_SHA256SUM = 9a8f19e12cfb243df60bfebadff9c30def79ad0be90df512c5ea8f86eef94fab DROP_URL = http://icedtea.classpath.org/download/drops @@ -36,7 +36,7 @@ ICEDTEA_BRANCH = 2.5 ICEDTEA_PREFIX = $(ICEDTEA_MAJOR)-forest-$(ICEDTEA_BRANCH) ICEDTEA_HG_URL = http://icedtea.classpath.org/hg/release/$(ICEDTEA_PREFIX) -ICEDTEA_URL = $(DROP_URL)/$(ICEDTEA_MAJOR)/$(PACKAGE_VERSION) +ICEDTEA_URL = $(DROP_URL)/$(ICEDTEA_MAJOR)/2.5.3 HS_TYPE = "`$(AWK) 'version==$$1 {print $$2}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" HS_URL = "`$(AWK) 'version==$$1 {print $$3}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" diff -r 00016055e63f -r f362ae34fe1b NEWS --- a/NEWS Wed Sep 03 15:33:40 2014 +0100 +++ b/NEWS Mon Sep 22 16:41:07 2014 +0100 @@ -14,6 +14,17 @@ New in release 2.5.3 (2014-10-XX): +* Backports + - S4963723: Implement SHA-224 + - S7044060: Need to support NSA Suite B Cryptography algorithms + - S8006935: Need to take care of long secret keys in HMAC/PRF compuation +* Bug fixes + - PR1988: C++ Interpreter should no longer be used on ppc64 + - PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose + - PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 + - PR2003: --disable-system-gtk option broken by refactoring in PR1736 + - PR2009: Checksum of policy JAR files changes on every build + New in release 2.5.2 (2014-08-29): * Backports diff -r 00016055e63f -r f362ae34fe1b configure.ac --- a/configure.ac Wed Sep 03 15:33:40 2014 +0100 +++ b/configure.ac Mon Sep 22 16:41:07 2014 +0100 @@ -1,4 +1,4 @@ -AC_INIT([icedtea], [2.5.3pre00], [distro-pkg-dev at openjdk.java.net]) +AC_INIT([icedtea], [2.5.3pre01], [distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AM_MAINTAINER_MODE([enable]) AC_CONFIG_FILES([Makefile]) diff -r 00016055e63f -r f362ae34fe1b hotspot.map --- a/hotspot.map Wed Sep 03 15:33:40 2014 +0100 +++ b/hotspot.map Mon Sep 22 16:41:07 2014 +0100 @@ -1,3 +1,3 @@ # version type(drop/hg) url changeset sha256sum -default drop http://icedtea.classpath.org/download/drops/icedtea7/2.5.2 4ad43b271fd4 b8c1f0e6560a3300d145784c1a73e02ddecbad38b8ce9511a930b1e7599c8c51 +default drop http://icedtea.classpath.org/download/drops/icedtea7/2.5.3 9f719e4c80af 63b824ef5ffbf702838fbe2917ddfab563b271576871edf23101db265584e49d aarch64 drop http://icedtea.classpath.org/download/drops/aarch64/2.5.1 a03843f2ff15 e88ca1ef9eeafa9bac7f0e5277a927129288547f241f0ed1e53969c6888177f2 From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 15:41:25 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 15:41:25 +0000 Subject: [Bug 2000] [IcedTea7] Synchronise HEAD tarball paths with release branch paths In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2000 --- Comment #3 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=f362ae34fe1b author: Andrew John Hughes date: Mon Sep 22 16:41:07 2014 +0100 Bump to icedtea-2.5.3pre01. 2014-09-22 Andrew John Hughes * Makefile.am: (CORBA_CHANGESET): Update to icedtea-2.5.3pre01 tag. (JAXP_CHANGESET): Likewise. (JAXWS_CHANGESET): Likewise. (JDK_CHANGESET): Likewise. (LANGTOOLS_CHANGESET): Likewise. (OPENJDK_CHANGESET): Likewise. (CORBA_SHA256SUM): Likewise. (JAXP_SHA256SUM): Likewise. (JAXWS_SHA256SUM): Likewise. (JDK_SHA256SUM): Likewise. (LANGTOOLS_SHA256SUM): Likewise. (OPENJDK_SHA256SUM): Likewise. (ICEDTEA_URL): Temporarily hardcode 2.5.3 until pre versions can be handled (PR2000). * NEWS: Updated. * configure.ac: Bump to 2.5.3pre01. * hotspot.map: Update to icedtea-2.5.3pre01 tag. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Mon Sep 22 15:45:00 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Mon, 22 Sep 2014 17:45:00 +0200 Subject: Fwd: Re: [rfc][icedtea-web] localizable Plugin+settings+fix+cleanup In-Reply-To: <54201CA7.10707@redhat.com> References: <54199ED2.7000707@redhat.com> <54201CA7.10707@redhat.com> Message-ID: <542043FC.8040901@redhat.com> On 09/22/2014 02:57 PM, Jiri Vanek wrote: > > zzzz... This thread is about issuse unrelated to this changeset. May I proceed? > > J. > +ITWPsynopsL4=@BOLD_OPEN@ Opera family browsers @BOLD_CLOSE at like Opera use: > +ITWPtrademarks=All browsers or company names in this section may be subjects of trademarks and/or copyrights. > + For some reason this sentence sneaked in. I will remove ti, or replace by "All third-party trademarks are the property of their respective owners" Both solutions (remove ITWPtrademarks completely or repalce it by above) seemed ok to the lawyer. J. From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:14:08 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:14:08 +0000 Subject: [Bug 2000] [IcedTea7] Obtain release version from configure and use in URLs In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2000 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|[IcedTea7] Synchronise HEAD |[IcedTea7] Obtain release |tarball paths with release |version from configure and |branch paths |use in URLs -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Mon Sep 22 16:14:23 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:14:23 +0000 Subject: /hg/release/icedtea7-2.5: PR2000: Obtain release version from co... Message-ID: changeset 34c6a0fa1764 in /hg/release/icedtea7-2.5 details: http://icedtea.classpath.org/hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. diffstat: ChangeLog | 27 +++++++++++++++++++++++++++ Makefile.am | 13 ++++++------- NEWS | 2 ++ acinclude.m4 | 11 +++++++++++ configure.ac | 3 +++ hotspot.map | 3 --- hotspot.map.in | 3 +++ 7 files changed, 52 insertions(+), 10 deletions(-) diffs (125 lines): diff -r f362ae34fe1b -r 34c6a0fa1764 ChangeLog --- a/ChangeLog Mon Sep 22 16:41:07 2014 +0100 +++ b/ChangeLog Mon Sep 22 17:12:45 2014 +0100 @@ -1,3 +1,30 @@ +2014-09-16 Andrew John Hughes + + * Makefile.am: + (HS_TYPE): Fix hotspot.map path. + (HS_URL): Likewise. + (HS_CHANGESET): Likewise. + (HS_SHA256SUM): Likewise. + (EXTRA_DIST): Remove hotspot.map. + hotspot.map.in is automatically added + by autoconf. + * NEWS: Updated. + +2014-09-16 Andrew John Hughes + + * hotspot.map: Moved to... + * Makefile.am: + (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain + release version. + * NEWS: Updated. + * acinclude.m4: + (IT_DETERMINE_VERSION): Obtain branch and release + version automatically from package version. + * configure.ac: Call IT_DETERMINE_VERSION and + generate hotspot.map. + * hotspot.map.in: ... here so the URL can be + generated using the release version. + 2014-09-22 Andrew John Hughes * Makefile.am: diff -r f362ae34fe1b -r 34c6a0fa1764 Makefile.am --- a/Makefile.am Mon Sep 22 16:41:07 2014 +0100 +++ b/Makefile.am Mon Sep 22 17:12:45 2014 +0100 @@ -36,12 +36,12 @@ ICEDTEA_BRANCH = 2.5 ICEDTEA_PREFIX = $(ICEDTEA_MAJOR)-forest-$(ICEDTEA_BRANCH) ICEDTEA_HG_URL = http://icedtea.classpath.org/hg/release/$(ICEDTEA_PREFIX) -ICEDTEA_URL = $(DROP_URL)/$(ICEDTEA_MAJOR)/2.5.3 +ICEDTEA_URL = $(DROP_URL)/$(ICEDTEA_MAJOR)/$(ICEDTEA_RELEASE) -HS_TYPE = "`$(AWK) 'version==$$1 {print $$2}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" -HS_URL = "`$(AWK) 'version==$$1 {print $$3}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" -HS_CHANGESET = "`$(AWK) 'version==$$1 {print $$4}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" -HS_SHA256SUM = "`$(AWK) 'version==$$1 {print $$5}' version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map`" +HS_TYPE = "`$(AWK) 'version==$$1 {print $$2}' version=$(HSBUILD) $(abs_top_builddir)/hotspot.map`" +HS_URL = "`$(AWK) 'version==$$1 {print $$3}' version=$(HSBUILD) $(abs_top_builddir)/hotspot.map`" +HS_CHANGESET = "`$(AWK) 'version==$$1 {print $$4}' version=$(HSBUILD) $(abs_top_builddir)/hotspot.map`" +HS_SHA256SUM = "`$(AWK) 'version==$$1 {print $$5}' version=$(HSBUILD) $(abs_top_builddir)/hotspot.map`" # Build directories @@ -757,8 +757,7 @@ $(top_srcdir)/patches/hotspot/*/*.patch \ tools-copy contrib overlays \ jconsole.desktop policytool.desktop \ - $(JTREG_SRCS) HACKING fsg.sh \ - hotspot.map autogen.sh \ + $(JTREG_SRCS) HACKING fsg.sh autogen.sh \ tapset/hotspot.stp.in \ tapset/hotspot_jni.stp.in \ tapset/jstack.stp.in \ diff -r f362ae34fe1b -r 34c6a0fa1764 NEWS --- a/NEWS Mon Sep 22 16:41:07 2014 +0100 +++ b/NEWS Mon Sep 22 17:12:45 2014 +0100 @@ -22,6 +22,8 @@ - PR1988: C++ Interpreter should no longer be used on ppc64 - PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose - PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 + - PR2000: Synchronise HEAD tarball paths with release branch paths + - PR2002: Fix references to hotspot.map following PR2000 - PR2003: --disable-system-gtk option broken by refactoring in PR1736 - PR2009: Checksum of policy JAR files changes on every build diff -r f362ae34fe1b -r 34c6a0fa1764 acinclude.m4 --- a/acinclude.m4 Mon Sep 22 16:41:07 2014 +0100 +++ b/acinclude.m4 Mon Sep 22 17:12:45 2014 +0100 @@ -2808,6 +2808,17 @@ AC_MSG_RESULT([$has_native_hotspot_port]) ]) +AC_DEFUN_ONCE([IT_DETERMINE_VERSION], +[ + AC_MSG_CHECKING([which branch and release of IcedTea is being built]) + ICEDTEA_RELEASE=$(echo ${PACKAGE_VERSION} | sed 's#pre.*##') + ICEDTEA_BRANCH=$(echo ${ICEDTEA_RELEASE}|sed 's|\.[[0-9]]$||') + AC_MSG_RESULT([branch ${ICEDTEA_BRANCH}, release ${ICEDTEA_RELEASE}]) + AC_SUBST([ICEDTEA_RELEASE]) + AC_SUBST([ICEDTEA_BRANCH]) +]) + + AC_DEFUN_ONCE([IT_ENABLE_INFINALITY], [ AC_REQUIRE([IT_CHECK_FOR_FONTCONFIG]) diff -r f362ae34fe1b -r 34c6a0fa1764 configure.ac --- a/configure.ac Mon Sep 22 16:41:07 2014 +0100 +++ b/configure.ac Mon Sep 22 17:12:45 2014 +0100 @@ -12,6 +12,9 @@ cd $abs_top_builddir AC_SUBST(abs_top_srcdir) +IT_DETERMINE_VERSION +AC_CONFIG_FILES([hotspot.map]) + AC_CANONICAL_HOST AC_PREFIX_DEFAULT([bootstrap]) diff -r f362ae34fe1b -r 34c6a0fa1764 hotspot.map --- a/hotspot.map Mon Sep 22 16:41:07 2014 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -# version type(drop/hg) url changeset sha256sum -default drop http://icedtea.classpath.org/download/drops/icedtea7/2.5.3 9f719e4c80af 63b824ef5ffbf702838fbe2917ddfab563b271576871edf23101db265584e49d -aarch64 drop http://icedtea.classpath.org/download/drops/aarch64/2.5.1 a03843f2ff15 e88ca1ef9eeafa9bac7f0e5277a927129288547f241f0ed1e53969c6888177f2 diff -r f362ae34fe1b -r 34c6a0fa1764 hotspot.map.in --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/hotspot.map.in Mon Sep 22 17:12:45 2014 +0100 @@ -0,0 +1,3 @@ +# version type(drop/hg) url changeset sha256sum +default drop http://icedtea.classpath.org/download/drops/icedtea7/@ICEDTEA_RELEASE@ 9f719e4c80af 63b824ef5ffbf702838fbe2917ddfab563b271576871edf23101db265584e49d +aarch64 drop http://icedtea.classpath.org/download/drops/aarch64/2.5.1 a03843f2ff15 e88ca1ef9eeafa9bac7f0e5277a927129288547f241f0ed1e53969c6888177f2 From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:14:42 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:14:42 +0000 Subject: [Bug 1988] [IcedTea7] C++ Interpreter should no longer be used on ppc64 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1988 --- Comment #4 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:14:44 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:14:44 +0000 Subject: [Bug 1989] [IcedTea7] Make jdk_generic_profile.sh handle missing programs better and be more verbose In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1989 --- Comment #4 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:14:47 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:14:47 +0000 Subject: [Bug 1736] Awt loads gtk3 in all the look and feel configurations In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1736 --- Comment #9 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:14:50 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:14:50 +0000 Subject: [Bug 2000] [IcedTea7] Obtain release version from configure and use in URLs In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2000 --- Comment #4 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:14:53 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:14:53 +0000 Subject: [Bug 1992] [IcedTea7] Support retrieving proxy settings on GNOME 3 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1992 --- Comment #4 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:14:57 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:14:57 +0000 Subject: [Bug 2002] [IcedTea7] Fix references to hotspot.map following PR2000 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2002 --- Comment #3 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:15:00 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:15:00 +0000 Subject: [Bug 2003] [IcedTea7] --disable-system-gtk option broken by refactoring in PR1736 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2003 --- Comment #3 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:15:03 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:15:03 +0000 Subject: [Bug 2009] [IcedTea7] Checksum of policy JAR files changes on every build In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2009 --- Comment #9 from hg commits --- details: http://icedtea.classpath.org//hg/release/icedtea7-2.5?cmd=changeset;node=34c6a0fa1764 author: Andrew John Hughes date: Mon Sep 22 17:12:45 2014 +0100 PR2000: Obtain release version from configure and use in URLs PR2002: Fix references to hotspot.map following PR2000 Included in 2.5.3pre01 (previous commit): PR1988: C++ Interpreter should no longer be used on ppc64 PR1989: Make jdk_generic_profile.sh handle missing programs better and be more verbose PR1992, RH735336: Support retrieving proxy settings on GNOME 3.12.2 PR2003: --disable-system-gtk option broken by refactoring in PR1736 PR2009: Checksum of policy JAR files changes on every build S4963723: Implement SHA-224 S7044060: Need to support NSA Suite B Cryptography algorithms S8006935: Need to take care of long secret keys in HMAC/PRF compuation 2014-09-16 Andrew John Hughes * Makefile.am: (HS_TYPE): Fix hotspot.map path. (HS_URL): Likewise. (HS_CHANGESET): Likewise. (HS_SHA256SUM): Likewise. (EXTRA_DIST): Remove hotspot.map. hotspot.map.in is automatically added by autoconf. * NEWS: Updated. 2014-09-16 Andrew John Hughes * hotspot.map: Moved to... * Makefile.am: (ICEDTEA_URL): Use $(ICEDTEA_RELEASE) to obtain release version. * NEWS: Updated. * acinclude.m4: (IT_DETERMINE_VERSION): Obtain branch and release version automatically from package version. * configure.ac: Call IT_DETERMINE_VERSION and generate hotspot.map. * hotspot.map.in: ... here so the URL can be generated using the release version. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:17:26 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:17:26 +0000 Subject: [Bug 2000] [IcedTea7] Obtain release version from configure and use in URLs In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2000 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:20:45 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:20:45 +0000 Subject: [Bug 1992] [IcedTea7] Support retrieving proxy settings on GNOME 3 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1992 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:28:18 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:28:18 +0000 Subject: [Bug 2002] [IcedTea7] Fix references to hotspot.map following PR2000 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2002 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:31:05 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:31:05 +0000 Subject: [Bug 1988] [IcedTea7] C++ Interpreter should no longer be used on ppc64 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1988 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:31:59 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:31:59 +0000 Subject: [Bug 1989] [IcedTea7] Make jdk_generic_profile.sh handle missing programs better and be more verbose In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1989 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:41:42 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:41:42 +0000 Subject: [Bug 2014] New: [IcedTea7] Use version from hotspot.map to create tarball filename Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2014 Bug ID: 2014 Summary: [IcedTea7] Use version from hotspot.map to create tarball filename Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org At present, the tarball file name for a HotSpot drop is always "hotspot.tar.bz2". This prevents two different versions sharing the same directory. We should instead use the version to create the tarball name (e.g. "aarch64" -> "aarch64.tar.bz2"), with "default" retaining the translation to "hotspot.tar.bz2". -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:42:11 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:42:11 +0000 Subject: [Bug 2014] [IcedTea7] Use version from hotspot.map to create tarball filename In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2014 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:43:23 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:43:23 +0000 Subject: [Bug 2015] New: [IcedTea7] Update hotspot.map documentation in INSTALL Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2015 Bug ID: 2015 Summary: [IcedTea7] Update hotspot.map documentation in INSTALL Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org The documentation in INSTALL needs to be updated to cover: * The presence of the AArch64 HotSpot * The new type field (drop/hg) * The changes in PR2014 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:43:39 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:43:39 +0000 Subject: [Bug 2015] [IcedTea7] Update hotspot.map documentation in INSTALL In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2015 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Depends on| |2014 Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 22 16:43:39 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 22 Sep 2014 16:43:39 +0000 Subject: [Bug 2014] [IcedTea7] Use version from hotspot.map to create tarball filename In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2014 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |2015 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at complang.tuwien.ac.at Mon Sep 22 20:37:01 2014 From: stefan at complang.tuwien.ac.at (Stefan Ring) Date: Mon, 22 Sep 2014 22:37:01 +0200 Subject: open jdk iced tea 7u09 In-Reply-To: <1407697445.98883.YahooMailNeo@web133004.mail.ir2.yahoo.com> References: <1407697445.98883.YahooMailNeo@web133004.mail.ir2.yahoo.com> Message-ID: On Sun, Aug 10, 2014 at 9:04 PM, neddihmail-bol32245 at yahoo.it wrote: > Hello > I'm looking for open jdk iced tea 7u09 that is distributed with redhat 6.4 I > cannot find it in the website, ould you please help me ? For the SRPM, I would look here: http://mirror.nsc.liu.se/centos-store/6.4/os/Source/SPackages/java-1.7.0-openjdk-1.7.0.9-2.3.4.1.el6_3.src.rpm From ldracz at redhat.com Mon Sep 22 20:54:41 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Mon, 22 Sep 2014 16:54:41 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] itweb-settings use Option Parser In-Reply-To: <541C3995.2080104@redhat.com> References: <2136433079.7489666.1411075684213.JavaMail.zimbra@redhat.com> <541C3995.2080104@redhat.com> Message-ID: <1888728818.9296441.1411419281545.JavaMail.zimbra@redhat.com> Hello, I have changed the parser to take into account the order of options it receives. For itweb-settings it goes through the options in order, so the order in which the commands are issued matter. Ex. 'itweb-settings get deployment.log.file set deployment.log.file true get deployment.log.file reset deployment.log.file get deployment.log.file' will go through in order with the first get then set it to true, show you it is true with get then reset it and use get after the reset. Also now help can be combined with options so 'itweb-settings get help set deployment.log.file true' will show the help for get and do the specified set option. This does mean to get the big main help message the help command has to be present right after itweb-settings or you could do itweb-settings headless help. > Mayor hints > - when resetAll is presented - then no metter of other arguments, the > processing have tobe > stopped, and user warned - Something like "resetAl found. If you wont to use > this comamnd, use it > alone. Otherwise reomvoe it from comamndline". And halt. I have changed how it works, and don't agree with reset all not being allowed to use with other commands. For ex. Someone might want to see what a command is before they reset everything so they know what to set it to after 'itweb-settings get deployment.log.file reset all' OR they want exactly one setting to be changed apart from the default so something like 'itweb-settings reset all set deployment.security.level=ALLOW_UNSIGNED' I think now that order to the options is possible, allowing reset all with other commands is fine. > - the docs must be adjusted > - description of all affected OptionDefinitions in messages. properties. > - general documentation to itweb=settings commandline (can be done as > separate changeset) > - there is bug in check's docs - it stays it need parameter what to check > - there is (unrelated to your changset) "bug" in check - it is ruing > validators, and validators do > (if application is running under X ) poping joption pane - maybe we can add > hedless support ? (afaik > only need is to JNLPruntime.setHeadless(parser.has(HEADLESS) ) - but needs > testing Added a check for headless as you suggested. Also changed launchers.in as needed. > - how does it behave when multiple combinations of reset,set,get,info are > presented? > - what about some cornercase like set property=value get something set > p.t=abc reset aaa get aaa > set aaa=bbbb .... > - I would expect it will set proeprty to value, prints out vlae of > something, set p.t to abc, > reset aaa to defaul and set aaa to bbbb With the new order it should do this. > - it does not seem to do this:( > - after your patch - it does only set proeprty to value, prints out vlae > of something. The > second set would never be executed. right? > - imho the safest way is to allow only one of set | reset | get | chec.. > And if more of thsoe > is present.Simply die. Is it even possibele with your current > parserimplementation to recognize two > identical options presented two times? If no, then stop execution is the only > way:( It wasn't possible, but I updated OptionParser to make this possible. I think allowing multiple set | reset | get | check is fine now. > > - there is significant change in behaviour > - before it was accepting set name value > - now it seems to me to accept set name=value, or not? > - considering the nature of purpos of this tool, I would stay withold > approach, or with both. Not > only with new ;( > Yes I added support for set name=value because that is how they are stored in deployment.properties so I thought a user seeing the file might want to set them in the same manner. It also works in the old way where you place a space between name and value. I thought it would make it easier to use, I don't foresee the issue of "name" having a "=" in it as a legitimate property. Yes something like na=me=value if 'na=me' was a legitimate property would read the propery as na with value me and value would be the next property seen. If you think name might have equals / there is another issue I will change it back, I just thought this would make it easier for the user. > > Here is valid same issue as in your first opton parser. What is value > consists of symbol? > param=va=lu=e will be broken :( I could make it just break on the first equals it finds. Would that be more desirable behaviour ? So in this case set param=va=lu=e would be the same as set param va=lu=e. > > But this will be valid only if we agree on bothold and new style. If we agree > only on old one those > will go out:( > > Anyway - nitpickers nit - tey both should be static and tested :) > > + > > + public List getValuesSplitOnEquals(OptionsDefinitions.OPTIONS > > option) { > > + return getValuesSplitOn(option, "="); > > + } > > + > > + public int getNumberOfOptions() { > > + if (mainArgExists()) { > > + return parsedOptions.size() - 1; > > + } > > + return parsedOptions.size(); > > + } > > + > > } > > Made these two static and added unit tests for them as well as the other new methods added. > int to two "unrelated" bugs - both shoud be fixe din this changeset - as tis > is mayor rework of the > inpur handling. > > > Thak you! > > (well compared to this, th epolicyeditor will be children's palyground for > you :) ) I guess so :) Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: itweb-settingsOptionParser-5.patch Type: text/x-patch Size: 31494 bytes Desc: not available URL: From jkang at redhat.com Mon Sep 22 21:17:47 2014 From: jkang at redhat.com (Jie Kang) Date: Mon, 22 Sep 2014 17:17:47 -0400 (EDT) Subject: [rfc][icedtea-web] Makefile New Whitelisted-Dist-Test option In-Reply-To: <1366689686.9202815.1411409847249.JavaMail.zimbra@redhat.com> Message-ID: <1294941468.9304595.1411420667650.JavaMail.zimbra@redhat.com> Hello, This patch expands on the Makefile Reproducer Test patch [1]. [1] http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-September/029581.html There is now a new make rule: 'run-netx-whitelisted-dist-tests' This rule runs the reproducers similar to 'run-netx-dist-tests', except it only processes (compiles, etc.) the resources filtered by the whitelist. As well, the rule 'run-netx-dist-tests' has now reverted back to processing all resources (ie. what it used to do before the Makefile Reproducer Test patch [1]) Thoughts? Just a note, the purpose of the "stamps/whitelist-filter.stamp" rule having: echo ".*" ... is to maintain compatibility. Though the "all-whitelist" rule also contains duplicate code, there can be situations where neither "all-whitelist" or "filtered-whitelist" are not called. E.g. if user runs "make stamps/netx-dist-tests-prepare-reproducers.stamp". This is the solution I came up with to allow for all possible make commands to continue to work and for the user to be able to quickly switch between running "make run-netx-dist-tests" and "make run-netx-whitelisted-dist-tests" without always having to perform "make clean-netx-dist-tests". I guess a TLDR is that it's to prevent regressions. If this patch is accepted I will update the wiki and documentation for this feature. Regards, -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-makefile-whitelisted-2.patch Type: text/x-patch Size: 3718 bytes Desc: not available URL: From omajid at redhat.com Mon Sep 22 21:40:37 2014 From: omajid at redhat.com (Omair Majid) Date: Mon, 22 Sep 2014 17:40:37 -0400 Subject: open jdk iced tea 7u09 In-Reply-To: <1407697445.98883.YahooMailNeo@web133004.mail.ir2.yahoo.com> References: <1407697445.98883.YahooMailNeo@web133004.mail.ir2.yahoo.com> Message-ID: <20140922214037.GB2388@redhat.com> * neddihmail-bol32245 at yahoo.it [2014-09-18 18:54]: > I'm looking for open jdk iced tea 7u09 that is distributed with redhat 6.4 I > cannot find it in the website, ould you please help me ? If you have the package installed, `rpm -q java-1.7.0-openjdk` will tell you the version. You can find the SRPMs matching the package versions here: http://ftp.redhat.com/redhat/linux/enterprise/6Server/en/os/SRPMS/ One of these should be what you are looking for: java-1.7.0-openjdk-1.7.0.9-2.3.3.2.el6_3.src.rpm java-1.7.0-openjdk-1.7.0.9-2.3.3.el6_3.1.src.rpm java-1.7.0-openjdk-1.7.0.9-2.3.4.1.el6_3.src.rpm java-1.7.0-openjdk-1.7.0.9-2.3.8.0.el6_4.src.rpm Hope that helps! Cheers, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From helpcrypto at gmail.com Tue Sep 23 09:51:33 2014 From: helpcrypto at gmail.com (helpcrypto helpcrypto) Date: Tue, 23 Sep 2014 11:51:33 +0200 Subject: Painting issues with "autosize". My fault? Your fault? In-Reply-To: References: <537CBE81.2050907@redhat.com> <537F47A3.6080008@redhat.com> Message-ID: ping? On Wed, May 28, 2014 at 2:57 PM, helpcrypto helpcrypto wrote: > Just filled Bug 1798 - Pack and repaint doesnt seem to work properly > ;) > > > On Fri, May 23, 2014 at 3:05 PM, Jiri Vanek wrote: > >> On 05/23/2014 09:53 AM, helpcrypto helpcrypto wrote: >> >>> Thanks as usual, Jiri. >>> >>> I'll prepare the test and fill a bug as soon as I can...very busy days >>> at work >>> (why the TODO list is always growing faster than the DONE list???) >>> >>> Have a great weekend. >>> >> >> >> Hmm. It seems that this is new issue. All ITW AWT reproducers started to >> fail. They simply never paint their components are based on JDialogue... >> >> Andrew, may you elaborate on them? >> >> [send from phone] >> >> >> >>> >>> On Wed, May 21, 2014 at 4:56 PM, Jiri Vanek >> jvanek at redhat.com>> wrote: >>> >>> On 05/16/2014 09:43 AM, helpcrypto helpcrypto wrote: >>> >>> Hi. >>> >>> >>> Before filling a bug, I would like to ask if I'm doing it >>> properly. >>> >>> Consider the following scenario: >>> -Dialog+BorderLayout+center JPanel with JLabel >>> >>> In runtime I modify the label from "" to "lorem >>> ipsum..." (The lorem ipsum part are several paragraphs) >>> And do pack() and repaint(). >>> >>> *The objective is to automatically resize the dialog depending >>> on panels contents* >>> >>> >>> >>> Using ORACLE JRE the dialog is redrawn to fit the content, but >>> this is not happening on icedtea-web, so part of the text is hidden under >>> north, south, east and west panels. >>> >>> Did I explained myself properly? >>> Should I file a bug and attach a test case or I must do it >>> another way? >>> >>> >>> >>> >>> Yes this sounds like a bug. But From desciption is not clear wheter >>> it is IcedTea-Web or Openjdk. >>> >>> It is worthy to try openjdk 6 / 7 / 8 snd proprietary plugin and >>> Proprietary JDK 7/8 and icedtea-web to eliminate dead branches. >>> >>> And hence you see it in Jdialog I suspect OpenJDK itself. Not >>> Icedtea web. >>> >>> Was the window manager always the same? >>> >>> Are you able to prepare minimalistic reproducer? ( I guess main >>> class with few lines of jdialog setup). ? >>> >>> Then we can try on various JDKS for you. >>> >>> J. >>> >>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jvanek at redhat.com Tue Sep 23 12:08:35 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 23 Sep 2014 14:08:35 +0200 Subject: [rfc][icedtea-web] Makefile New Whitelisted-Dist-Test option In-Reply-To: <1294941468.9304595.1411420667650.JavaMail.zimbra@redhat.com> References: <1294941468.9304595.1411420667650.JavaMail.zimbra@redhat.com> Message-ID: <542162C3.1010400@redhat.com> On 09/22/2014 11:17 PM, Jie Kang wrote: > Hello, > > This patch expands on the Makefile Reproducer Test patch [1]. > > [1] http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-September/029581.html > > > There is now a new make rule: 'run-netx-whitelisted-dist-tests' > > This rule runs the reproducers similar to 'run-netx-dist-tests', except it only processes (compiles, etc.) the resources filtered by the whitelist. > > As well, the rule 'run-netx-dist-tests' has now reverted back to processing all resources (ie. what it used to do before the Makefile Reproducer Test patch [1]) > > Thoughts? > > Just a note, the purpose of the "stamps/whitelist-filter.stamp" rule having: > echo ".*" ... > is to maintain compatibility. Though the "all-whitelist" rule also contains duplicate code, there can be situations where neither "all-whitelist" or "filtered-whitelist" are not called. E.g. if user runs "make stamps/netx-dist-tests-prepare-reproducers.stamp". This is the solution I came up with to allow for all possible make commands to continue to work and for the user to be able to quickly switch between running "make run-netx-dist-tests" and "make run-netx-whitelisted-dist-tests" without always having to perform "make clean-netx-dist-tests". I guess a TLDR is that it's to prevent regressions. > > If this patch is accepted I will update the wiki and documentation for this feature. > > > Regards, > Hm. only hint to approach. Why not configure switch? This seems to me overcomplexed. What is advantage of this? Once the new and old targets will be run in unpredicted order, the result can be unpredictible. Also I can not see the reverted part in patch. J. From jkang at redhat.com Tue Sep 23 15:07:37 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 23 Sep 2014 11:07:37 -0400 (EDT) Subject: [rfc][icedtea-web] Cache Locking Tests : Potential Deadlock Fix In-Reply-To: <2103989617.9655152.1411481967464.JavaMail.zimbra@redhat.com> Message-ID: <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> Hello, Jiri reported deadlock occurring in the unit tests for CacheLRUWrapper. This most likely occurred in the multi-threaded test where the parent thread sleeps for 2 seconds, before attempting to wake the sleeping children. If the children have not completed their tasks within two seconds, they will not be waiting for the parent thread to wake them, and a deadlock can occur. This issue could also occur in CacheEntry, which has a multi-threaded test that functions similarly. This patch resolves the problem. Sorry for the mistake. Regards, -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-cachelock-deadlock-1.patch Type: text/x-patch Size: 7629 bytes Desc: not available URL: From jvanek at redhat.com Tue Sep 23 15:31:13 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Tue, 23 Sep 2014 17:31:13 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <541516F5.3020504@gmx.de> References: <54071FE9.2000309@redhat.com> <54101CEB.1040104@redhat.com> <541516F5.3020504@gmx.de> Message-ID: <54219241.6060705@redhat.com> On 09/14/2014 06:17 AM, Jacob Wisor wrote: > On 09/10/2014 at 11:42 AM, Jiri Vanek wrote: >> ping? > > Unfortunately, because tip has change in the meantime in regards to this patch I could not actually > do runtime tests. However, I have commented on the code. Please, can you post a patch based on the > current tip? > Hi. The attached patch is only adaptation of previous one to head and with fixed minors and with fixes you suggested. According to yours previous hints, the approach needs revisiting. See inline., and especially bottom. TY for the inputs! >> -------- Original Message -------- >> Subject: Re: [rfc][icedtea-web] https probing >> Date: Wed, 03 Sep 2014 16:04:25 +0200 >> From: Jiri Vanek >> To: Jacob Wisor , distro-pkg-dev at openjdk.java.net >> >> On 08/26/2014 09:51 AM, Jacob Wisor wrote: >>> On 08/26/2014 09:16 AM, Jiri Vanek wrote: >>>> ping? >>>> >>>> On 08/20/2014 08:30 PM, Jiri Vanek wrote: >>>>> On 08/19/2014 11:25 PM, Jacob Wisor wrote: >>>>>> On 08/18/2014 08:46 PM, Omair Majid wrote: >>>>>>> Hi, >>>>>>> >>>>>>> >>>>>>> * Jacob Wisor [2014-08-11 12:12]: >>>>>>>> On 08/08/2014 10:37 AM, Jiri Vanek wrote: >>>>>>>>> Unluckily this fix patch is not helping obscure servers to do exists. >>>>>>>>> It really fixes bugs. >>>>>>>>> >>>>>>>>> First part of fix is delivered to be able handle SSLv2 handshake, Those >>>>>>>>> servers >>>>>>>>> do exists, and have no reason nor need to update or patch or whatever. >>>>>>>>> We are >>>>>>>>> wrong by not allowing it right now. >>>>>>>>> See System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); in code. >>>>>>>> >>>>>>>> Oh yes they do need fixing. SSLv2 is insecure and has been revoked by the >>>>>>>> IETF, period. Nobody should be using it. Even SSL 3.0 is deemed by the IETF >>>>>>>> as historic (https://datatracker.ietf.org/doc/rfc6101) although it is >>>>>>>> largely identical to TLS 1.0. Nevertheless, nobody should be using it >>>>>>>> either. Just one of many reasons is that it does not even support such a >>>>>>>> common hash algorithm as SHA1 (which by the way has been deprecated by NIST >>>>>>>> in favor of SHA256 too). Everybody should really upgrade to at least TLS >>>>>>>> 1.0, even though possible security leaks have been discovered in TLS 1.0 on >>>>>>>> specific configuration settings permutations. >>>>>>>> >>>>>>>> DO NOT use SSL anymore and DO NOT promote them in your software. Upgrade to >>>>>>>> TLS. >>>>>>> >>>>>>> This isn't SSv2, though. It's a SSLv2 hello packet wrapping an SSLv3 >>>>>>> packet: http://bugs.java.com/bugdatabase/view_bug.do?bug_id=4915862 >>>>>>> >>>>>>> It's actually part of the TLS 1.0 spec: >>>>>>> https://www.ietf.org/rfc/rfc2246.txt, Appendix E. >>>>>> >>>>>> This part describes backward compatibility of TLS 1.0 clients to SSL 3.0 and >>>>>> SSL 2.0 servers (and >>>>>> vice versa). >>>>>> >>>>>> "TLS 1.0 clients that support SSL Version 2.0 servers must send SSL >>>>>> Version 2.0 client hello messages [SSL2]. TLS servers should accept >>>>>> either client hello format if they wish to support SSL 2.0 clients on >>>>>> the same connection port. The only deviations from the Version 2.0 >>>>>> specification are the ability to specify a version with a value of >>>>>> three and the support for more ciphering types in the CipherSpec." >>>>>> >>>>>> Currently, IcedTea-Web is a TLS 1.0 or SSL 3.0 client. According to this >>>>>> paragraph, TLS 1.0 clients >>>>>> send SSL 2.0 client hello messages in order to connect to SSL 2.0 servers, >>>>>> that is, to negotiate a >>>>>> SSL 2.0 connection. So no, SSL 2.0 servers do not upgrade automagically to >>>>>> TLS 1.0 when they receive >>>>>> SSL 2.0 client hello messages from TLS 1.0 clients. Pure old SSL 2.0 servers >>>>>> will never speak >>>>>> anything later than SSL 2.0. >>>>>> >>>>>> One reason behind this paragraph was for TLS 1.0 clients to allow probing SSL >>>>>> 2.0 servers with >>>>>> cipher specifications in SSL 2.0 and those introduced in TLS 1.0. In >>>>>> practice, SSL 2.0 servers will >>>>>> _never_ negotiate to a cipher specification introduced since TLS 1.0 because >>>>>> they were simply not >>>>>> built for that. >>>>>> >>>>>> Another reason for this paragraph back in 1999 (!) was to allow implementors >>>>>> of TLS 1.0 to ease >>>>>> transition from SSL to TLS and to give them the option to merge TLS into >>>>>> their existing SSL >>>>>> libraries (or as much as possible build on top of them). Again, this has >>>>>> nothing to do with >>>>>> automagically upgrading SSL 2.0 servers to TLS. It is just a description of >>>>>> how TLS 1.0 clients >>>>>> could fallback to SSL 2.0, if they wish to. >>>>>> And, I am most certain nobody should want this, unless one has no clue what >>>>>> transport security is >>>>>> all about or is a complete lunatic. >>>>>> >>>>>> The next paragraph says it all: >>>>>> >>>>>> " Warning: The ability to send Version 2.0 client hello messages will be >>>>>> phased out with all due haste. Implementors should make every >>>>>> effort to move forward as quickly as possible. Version 3.0 >>>>>> provides better mechanisms for moving to newer versions." >>>>>> >>>>>> So, the Java API should have got rid of the option to fallback to SSL 2.0 >>>>>> years before. It's a shame >>>>>> that J2SE still supports SSL 2.0 connections in 2014. Why? Because this has >>>>>> nothing to do with >>>>>> compatibility but with *security*. >>>>>> >>>>> >>>>> Ok. Thank you for patience with me. (really!) >>>>> >>>>> So there is another approach. >>>>> >>>>> Now the ssl2 is tested as last attempt, and if it is possible to connect like >>>>> that, then the user is >>>>> warned and error is thrown (which leads to skipping resource from that >>>>> >>>>> >>>>> The not-checking certificate now can be allowed or forbidden by properties. By >>>>> default it asks user >>>>> by every such invalid certs its found. How to deal with human intraction is >>>>> todo. > > This property needs to bo documented, especially for administrators. Sure. The properties definitions support description long for time. It is jsut null in all cases :( And new documentation generator will atuomatically include it in man pages... If there is need to higlighti somehow, and current chngelog html+itwebsettings list or generated manpage is not enough, maybe we can add some "since version" to definition? Anyway it seems that tehy will be abandoned because of properties flaw you discovered. > > Does IcedTea-Web ask for /every/ invalid or unverifiable certificate in the certificate chain or > just the first highest one in the chain? I am asking because the verification process can actually > stop and assume the users answer or the property setting for all certificates beneath the first > highest invalid or unverifiable certificate in the chain. I think it stops on highest one. > >>>>> The reason for this message is to get verbose logical error emsssage, not only >>>>> "itw do not work again" > > I understand. It's always nice to have sane and useful error messages. :-) > >> diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/cache/CacheUtil.java >> --- a/netx/net/sourceforge/jnlp/cache/CacheUtil.java Wed Sep 03 14:45:40 2014 +0200 >> +++ b/netx/net/sourceforge/jnlp/cache/CacheUtil.java Wed Sep 03 16:02:36 2014 +0200 >> [...] >> @@ -99,11 +99,9 @@ >> } else { >> try { >> // this is what URLClassLoader does >> - URLConnection conn = location.openConnection(); >> + URLConnection conn = >> ConnectionFactory.getConnectionFactory().openConnection(location); > > Please make "conn" final. done > >> result = conn.getPermission(); >> - if (conn instanceof HttpURLConnection) { >> - ((HttpURLConnection) conn).disconnect(); >> - } >> + ConnectionFactory.getConnectionFactory().disconnect(conn); > > Formatting. done > >> [...] >> diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/cache/ResourceTracker.java >> --- a/netx/net/sourceforge/jnlp/cache/ResourceTracker.java Wed Sep 03 14:45:40 2014 +0200 >> +++ b/netx/net/sourceforge/jnlp/cache/ResourceTracker.java Wed Sep 03 16:02:36 2014 +0200 >> @@ -56,6 +56,7 @@ >> import net.sourceforge.jnlp.event.DownloadEvent; >> import net.sourceforge.jnlp.event.DownloadListener; >> import net.sourceforge.jnlp.runtime.JNLPRuntime; >> +import net.sourceforge.jnlp.security.ConnectionFactory; >> import net.sourceforge.jnlp.util.HttpUtils; >> import net.sourceforge.jnlp.util.UrlUtils; >> import net.sourceforge.jnlp.util.WeakList; >> @@ -641,7 +642,7 @@ >> try { >> // create out second in case in does not exist >> URL realLocation = resource.getDownloadLocation(); > > "realLocation" can be final here too. done > >> - con = realLocation.openConnection(); >> + con = ConnectionFactory.getConnectionFactory().openConnection(realLocation); >> con.addRequestProperty("Accept-Encoding", "pack200-gzip, gzip"); >> >> con.connect(); >> @@ -698,8 +699,7 @@ >> out.close(); >> >> // explicitly close the URLConnection. >> - if (con instanceof HttpURLConnection) >> - ((HttpURLConnection) con).disconnect(); >> + ConnectionFactory.getConnectionFactory().disconnect(con); > > Is it safe to assume that "con" will never be null or ConnectionFactory.disconnect() will accept null? Yes. And it will not, then it is probably healthy to follow npe to current place of catching. > >> if (packgz || gzip) { >> // TODO why not set this otherwise? >> @@ -811,7 +811,7 @@ >> } >> >> resource.setDownloadLocation(finalLocation); >> - connection = finalLocation.openConnection(); // this won't change so should be >> okay unsynchronized >> + connection = >> ConnectionFactory.getConnectionFactory().openConnection(finalLocation); // this won't change so >> should be okay not-synchronized >> connection.addRequestProperty("Accept-Encoding", "pack200-gzip, gzip"); >> >> size = connection.getContentLength(); >> @@ -855,9 +855,7 @@ >> resource.fireDownloadEvent(); // fire CONNECTED >> >> // explicitly close the URLConnection. >> - if (connection instanceof HttpURLConnection) { >> - ((HttpURLConnection) connection).disconnect(); >> - } >> + ConnectionFactory.getConnectionFactory().disconnect(connection); >> } catch (Exception ex) { >> OutputController.getLogger().log(ex); >> resource.changeStatus(EnumSet.noneOf(Resource.Status.class), EnumSet.of(ERROR)); >> @@ -915,7 +913,7 @@ >> */ >> static CodeWithRedirect getUrlResponseCodeWithRedirectonResult(URL url, Map >> requestProperties, RequestMethods requestMethod) throws IOException { >> CodeWithRedirect result = new CodeWithRedirect(); >> - URLConnection connection = url.openConnection(); >> + URLConnection connection = ConnectionFactory.getConnectionFactory().openConnection(url); > > "connection" should probably be final here too. done > >> for (Map.Entry property : requestProperties.entrySet()) { >> connection.addRequestProperty(property.getKey(), property.getValue()); >> @@ -946,9 +944,7 @@ >> if (possibleRedirect != null && possibleRedirect.trim().length() > 0) { >> result.URL = new URL(possibleRedirect); >> } >> - if (connection instanceof HttpURLConnection) { >> - ((HttpURLConnection) connection).disconnect(); >> - } >> + ConnectionFactory.getConnectionFactory().disconnect(connection); >> >> return result; >> >> diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/config/Defaults.java >> --- a/netx/net/sourceforge/jnlp/config/Defaults.java Wed Sep 03 14:45:40 2014 +0200 >> +++ b/netx/net/sourceforge/jnlp/config/Defaults.java Wed Sep 03 16:02:36 2014 +0200 >> @@ -46,6 +46,7 @@ >> >> import net.sourceforge.jnlp.ShortcutDesc; >> import net.sourceforge.jnlp.runtime.JNLPProxySelector; >> +import net.sourceforge.jnlp.security.ConnectionFactory; >> >> /** >> * This class stores the default configuration >> @@ -434,6 +435,27 @@ >> DeploymentConfiguration.KEY_ENABLE_MANIFEST_ATTRIBUTES_CHECK, >> BasicValueValidators.getBooleanValidator(), >> String.valueOf(true) >> + }, >> + //https >> + { >> + DeploymentConfiguration.KEY_HTTPS_PROBINGALLOWED, >> + BasicValueValidators.getBooleanValidator(), >> + String.valueOf(true) >> + }, >> + { >> + DeploymentConfiguration.KEY_HTTPS_SYNCFORCED, >> + BasicValueValidators.getBooleanValidator(), >> + String.valueOf(false) >> + }, >> + { >> + DeploymentConfiguration.KEY_HTTPS_PROBEALWAYS, >> + BasicValueValidators.getBooleanValidator(), >> + String.valueOf(false) >> + }, >> + { >> + DeploymentConfiguration.KEY_HTTPS_ALLOWINSECURE, >> + ConnectionFactory.InsecureStates.validator, >> + ConnectionFactory.InsecureStates.ASK.toString() >> } >> }; >> >> diff -r 6061af9d5eb8 netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java >> --- a/netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java Wed Sep 03 14:45:40 2014 +0200 >> +++ b/netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java Wed Sep 03 16:02:36 2014 +0200 >> @@ -13,7 +13,6 @@ >> // You should have received a copy of the GNU Lesser General Public >> // License along with this library; if not, write to the Free Software >> // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. >> - >> package net.sourceforge.jnlp.config; >> >> import static net.sourceforge.jnlp.runtime.Translator.R; >> @@ -66,28 +65,32 @@ ... > > It is good of you to fix javadoc comments, but then please do it thoroughly. Please turn this > comment into a complete sentence. ;-) This was accidental format-all button. Reverted. > >> public static final String KEY_USER_LOCKS_DIR = "deployment.user.locksdir"; >> /** >> * The netx_running file is used to indicate if any instances of netx are >> @@ -124,8 +129,9 @@ >> /* >> * Security and access control >> */ >> - >> - /** Boolean. Only show security prompts to user if true */ >> + /** >> + * Boolean. Only show security prompts to user if true >> + */ > > Same goes here about javadoc. "Boolean." is certainly not a good brief description of > "KEY_SECURITY_PROMPT_USER". Please keep in mind that javadoc assumes all text up to the first dot to > be a brief description. This was accidental format-all button. Reverted.. > >> public static final String KEY_SECURITY_PROMPT_USER = "deployment.security.askgrantdialog.show"; >> >> //enum of AppletSecurityLevel in result >> @@ -133,23 +139,35 @@ >> >> public static final String KEY_SECURITY_TRUSTED_POLICY = "deployment.security.trusted.policy"; >> >> - /** Boolean. Only give AWTPermission("showWindowWithoutWarningBanner") if true */ >> + /** >> + * Boolean. Only give AWTPermission("showWindowWithoutWarningBanner") if >> + * true >> + */ > > Javadoc, see above. same... > >> public static final String KEY_SECURITY_ALLOW_HIDE_WINDOW_WARNING = >> "deployment.security.sandbox.awtwarningwindow"; >> >> - /** Boolean. Only prompt user for granting any JNLP permissions if true */ >> + /** >> + * Boolean. Only prompt user for granting any JNLP permissions if true >> + */ > > Javadoc, see above. same... > >> public static final String KEY_SECURITY_PROMPT_USER_FOR_JNLP = >> "deployment.security.sandbox.jnlp.enhanced"; >> >> - /** Boolean. Only install the custom authenticator if true */ >> + /** >> + * Boolean. Only install the custom authenticator if true >> + */ > > Javadoc, see above. same... > >> public static final String KEY_SECURITY_INSTALL_AUTHENTICATOR = >> "deployment.security.authenticator"; >> >> /* >> * Networking >> */ >> - >> - /** the proxy type. possible values are {@code JNLPProxySelector.PROXY_TYPE_*} */ >> + /** >> + * the proxy type. possible values are >> + * {@code JNLPProxySelector.PROXY_TYPE_*} >> + */ >> public static final String KEY_PROXY_TYPE = "deployment.proxy.type"; >> >> - /** Boolean. If true, the http host/port should be used for https and ftp as well */ >> + /** >> + * Boolean. If true, the http host/port should be used for https and ftp as >> + * well >> + */ > > Javadoc, see above. same... > >> public static final String KEY_PROXY_SAME = "deployment.proxy.same"; >> >> public static final String KEY_PROXY_AUTO_CONFIG_URL = "deployment.proxy.auto.config.url"; >> @@ -173,30 +191,23 @@ >> public static final String KEY_ENABLE_LOGGING_TOFILE = "deployment.log.file"; >> public static final String KEY_ENABLE_LOGGING_TOSTREAMS = "deployment.log.stdstreams"; >> public static final String KEY_ENABLE_LOGGING_TOSYSTEMLOG = "deployment.log.system"; >> - >> + >> /* >> * manifest check >> */ >> public static final String KEY_ENABLE_MANIFEST_ATTRIBUTES_CHECK = >> "deployment.manifest.attributes.check"; >> >> /** >> - * Console initial status. >> - * One of CONSOLE_* values >> - * See declaration above: >> - * CONSOLE_HIDE = "HIDE"; >> - * CONSOLE_SHOW = "SHOW"; >> - * CONSOLE_DISABLE = "DISABLE"; >> - * CONSOLE_SHOW_PLUGIN = "SHOW_PLUGIN_ONLY"; >> - * CONSOLE_SHOW_JAVAWS = "SHOW_JAVAWS_ONLY"; >> + * Console initial status. One of CONSOLE_* values See declaration above: >> + * CONSOLE_HIDE = "HIDE"; CONSOLE_SHOW = "SHOW"; CONSOLE_DISABLE = >> + * "DISABLE"; CONSOLE_SHOW_PLUGIN = "SHOW_PLUGIN_ONLY"; CONSOLE_SHOW_JAVAWS >> + * = "SHOW_JAVAWS_ONLY"; >> */ > > You should be probably using {@link} doc tags here. > same >> public static final String KEY_CONSOLE_STARTUP_MODE = "deployment.console.startup.mode"; >> - >> - >> >> /* >> * Desktop Integration >> */ >> - >> public static final String KEY_JNLP_ASSOCIATIONS = "deployment.javaws.associations"; >> public static final String KEY_CREATE_DESKTOP_SHORTCUT = "deployment.javaws.shortcut"; >> >> @@ -209,8 +220,17 @@ >> /* >> * JVM arguments for plugin >> */ >> - public static final String KEY_PLUGIN_JVM_ARGUMENTS= "deployment.plugin.jvm.arguments"; >> - public static final String KEY_JRE_DIR= "deployment.jre.dir"; >> + public static final String KEY_PLUGIN_JVM_ARGUMENTS = "deployment.plugin.jvm.arguments"; >> + public static final String KEY_JRE_DIR = "deployment.jre.dir"; >> + >> + /* >> + * https settings >> + */ >> + public static final String KEY_HTTPS_PROBINGALLOWED = >> "deployment.security.https.probing.allowed"; >> + public static final String KEY_HTTPS_SYNCFORCED = "deployment.security.https.syncforced"; >> + public static final String KEY_HTTPS_PROBEALWAYS = "deployment.security.https.probing.always"; >> + public static final String KEY_HTTPS_ALLOWINSECURE = "deployment.security.https.allowinsecure"; >> + >> private ConfigurationException loadingException = null; >> >> public void setLoadingException(ConfigurationException ex) { >> @@ -224,27 +244,37 @@ >> public void resetToDefaults() { >> currentConfiguration = Defaults.getDefaults(); >> } >> - >> >> public enum ConfigType { >> + >> System, User >> } >> >> - /** is it mandatory to load the system properties? */ >> + /** >> + * is it mandatory to load the system properties? >> + */ >> private boolean systemPropertiesMandatory = false; >> >> - /** The system's subdirResult deployment.config file */ >> + /** >> + * The system's subdirResult deployment.config file >> + */ > > "deployment.config" should probably be put into a {@code} doc tag to prevent terminating the brief > description on "deployment.". > >> private File systemPropertiesFile = null; >> - /** The user's subdirResult deployment.config file */ >> + /** >> + * The user's subdirResult deployment.config file >> + */ > > Same goes here for "deployment.config". > same. (sorry for that noise) >> private File userPropertiesFile = null; >> - >> + >> /*default user file*/ >> public static final File USER_DEPLOYMENT_PROPERTIES_FILE = new File(Defaults.USER_CONFIG_HOME >> + File.separator + DEPLOYMENT_PROPERTIES); >> >> - /** the current deployment properties */ >> + /** >> + * the current deployment properties >> + */ >> private Map> currentConfiguration; >> >> - /** the deployment properties that cannot be changed */ >> + /** >> + * the deployment properties that cannot be changed >> + */ >> private Map> unchangeableConfiguration; >> >> public DeploymentConfiguration() { >> @@ -254,7 +284,8 @@ >> >> /** >> * Initialize this deployment configuration by reading configuration files. >> - * Generally, it will try to continue and ignore errors it finds (such as file not found). >> + * Generally, it will try to continue and ignore errors it finds (such as >> + * file not found). >> * >> * @throws ConfigurationException if it encounters a fatal error. >> */ >> @@ -266,18 +297,19 @@ >> return new File(Defaults.USER_CONFIG_HOME + File.separator + APPLET_TRUST_SETTINGS); >> } >> >> - public static File getAppletTrustGlobalSettingsPath() { >> - return new File(File.separator + "etc" + File.separator + ".java" + File.separator >> + public static File getAppletTrustGlobalSettingsPath() { >> + return new File(File.separator + "etc" + File.separator + ".java" + File.separator >> + "deployment" + File.separator + APPLET_TRUST_SETTINGS); > > This is definitely not okay on Windows and probably not okay on Mac OS either but it seems > acceptable for now. removed - the files definitios changed since this time. > >> - >> + >> } >> >> /** >> * Initialize this deployment configuration by reading configuration files. >> - * Generally, it will try to continue and ignore errors it finds (such as file not found). >> + * Generally, it will try to continue and ignore errors it finds (such as >> + * file not found). >> * >> - * @param fixIssues If true, fix issues that are discovered when reading configuration by >> - * resorting to the default values >> + * @param fixIssues If true, fix issues that are discovered when reading >> + * configuration by resorting to the default values >> * @throws ConfigurationException if it encounters a fatal error. >> */ >> public void load(boolean fixIssues) throws ConfigurationException { >> @@ -303,7 +335,6 @@ >> * First, try to read the system's subdirResult deployment.config file to find if >> * there is a system-level deployment.poperties file >> */ >> - >> if (systemConfigFile != null) { >> if (loadSystemConfiguration(systemConfigFile)) { >> OutputController.getLogger().log("System level " + DEPLOYMENT_CONFIG_FILE + " is >> mandatory: " + systemPropertiesMandatory); >> @@ -431,9 +462,9 @@ >> >> /** ...snip... >> + * @author jvanek > > Please replace with full name and e-mail address. > >> + */ >> +public class ConnectionFactory { > > Do we really want to allow sub-classes? > >> + >> + public static enum InsecureStates { > > Naming: What are insecure states? ... axis of evil ...? :-D kept for now. See below (otherwise yes, something like that :)) ) > >> + >> + TRUE, FALSE, ASK; > > Are "TRUE", "FALSE", and "ASK" really insecure? What makes them insecure? > >> + >> + public static final ValueValidator validator = new ValueValidator() { > > Shouldn't this custom validator extend BasicValidator? Not necessarily. kept for now. See below. > >> + >> + @Override >> + public void validate(Object value) throws IllegalArgumentException { > > Please make "value" final. done > >> + if (value instanceof InsecureStates) { > > It's a pity ValueValidator cannot be parametrized. :-( This is a perfect example for making use of > generics. But, lets keep it as it is for now. Agree. > >> + return; >> + } >> + if (value instanceof String) { >> + try { >> + fromString((String) value); >> + } catch (RuntimeException ex) { >> + throw new IllegalArgumentException(ex); >> + } >> + } >> + throw new IllegalArgumentException("Expected InsecureStates type or string of one >> of " + getPossibleValues()); > > Get this InsecureStates' name via reflection for the exception message instead of hard coding it > into the string: InsecureStates.class.getName(). This will lead to a compile time error whenever the > enum's name changes (for what ever reason), so the enum won't escape renaming in the string. > Besides, this exception message should probably be localized. Not fixed, as it will probably flow away. See below > >> + } >> + >> + @Override >> + public String getPossibleValues() { >> + return TRUE.toString() + " " + FALSE.toString() + " " + ASK.toString(); >> + } >> + }; > > Besides, the validator's definition should not be located at > ConnectionFactory.InsecureStates.validator's initialization. Put its implementation into a named > nested class instead of an anonymous one. Not fixed, as it will probably flow away. See below > >> + >> + public static InsecureStates fromString(String s) { > > Please make "s" final. > And what about NPE? Should a NPE just break the program while incorrectly formatted strings just > throw a RuntimeException? Seems to me like an arbitrary decision. > >> + if (s.trim().equalsIgnoreCase("true")) { >> + return TRUE; >> + } >> + if (s.trim().equalsIgnoreCase("false")) { >> + return FALSE; >> + } >> + if (s.trim().equalsIgnoreCase("ask")) { >> + return ASK; >> + } > > You know, you could use the new switch control statement here. ;-) > >> + throw new RuntimeException("unknown value of " + s + " for " + >> DeploymentConfiguration.KEY_HTTPS_ALLOWINSECURE); > > This exception message should probably be localized too. Not fixed, as it will probably flow away. See below > >> + } >> + >> + } >> + private final List httpsConnections = new ArrayList<>(); >> + >> + private static class ConnectionFactoryHolder { >> + >> + //https://en.wikipedia.org/wiki/Double-checked_locking#Usage_in_Java >> + //https://en.wikipedia.org/wiki/Initialization_on_demand_holder_idiom >> + private static volatile ConnectionFactory INSTANCE = new ConnectionFactory(); >> + } >> + >> + public static boolean isProbingAllowed() { >> + return getBooleanProperty(DeploymentConfiguration.KEY_HTTPS_PROBINGALLOWED); >> + } >> + >> + public static boolean isSyncForced() { >> + return !getBooleanProperty(DeploymentConfiguration.KEY_HTTPS_SYNCFORCED); > > Why negate the result here? Not fixed, as it will probably flow away. See below > >> + } >> + >> + public static boolean isProbeAlways() { >> + return getBooleanProperty(DeploymentConfiguration.KEY_HTTPS_PROBEALWAYS); >> + } >> + >> + public static InsecureStates getInsecureStatus() { >> + return >> InsecureStates.fromString(JNLPRuntime.getConfiguration().getProperty(DeploymentConfiguration.KEY_HTTPS_ALLOWINSECURE)); >> >> + } >> + >> + public static boolean isInsecurePossible() { > > Do you see now why I insist on meaingful naming? What does it mean when "insecure is possible" > (isInsecurePossible() == true)? Insecure certificates, insecure connections? Does this method detect > whether insecure connections are possible to hosts? What does it mean? I see it since beggining. Thenaming is curent days more important thenalgotihm itself. I got harm-locked (harm is less then dead ,isnt it?) a bit on this. Not fixed here as it will proabbly flow away. > >> + InsecureStates i = getInsecureStatus(); >> + if (i.equals(InsecureStates.TRUE) || i.equals(InsecureStates.ASK)) { >> + return true; >> + } >> + return false; >> + } >> + >> + public static boolean getBooleanProperty(String s) { >> + String s3 = JNLPRuntime.getConfiguration().getProperty(s); > > What does "s3" mean? Anyway, please make it final. > fixed. >> + if (s3 == null || s3.trim().isEmpty()) { >> + return false; >> + } else { > > No need for "else:. ;-) I have heard that the else is a bit better. I kept it witrh else. But otherwise Idont have personal prefferences. > >> + return Boolean.valueOf(s3); >> + } >> + >> + } >> + >> + public static ConnectionFactory getConnectionFactory() { >> + return ConnectionFactoryHolder.INSTANCE; >> + } >> + >> + public URLConnection openConnection(URL url) throws IOException { >> + OutputController.getLogger().log("Connecting " + url.toExternalForm()); > > "Connecting *to* ..." ok. > >> + if (url.getProtocol().equalsIgnoreCase("https") && isProbingAllowed()) { >> + if (isSyncForced()) { >> + while (!httpsConnections.isEmpty()) { >> + try { >> + Thread.sleep(100); >> + } catch (InterruptedException ex) { >> + throw new IOException(ex); >> + } >> + } > > Polling? Really? Is this really the proper way to do it? And, do we really need to offer Actually yes. I dont know about better way here. I will be happy if you have some. What I wonted to take care about, is situatuion when the individual https settings differe. Then the first one must be disconnected, before second can apply for new settings. And so tehre is need to not accept other https conenctions until previous one disconnects. > synchronious connections? > Besides, what about infinite looping? Do you mean that it can deadlock here? Yes. I'm thinking the same. But The same deadlock will rise now too. For my pooling here, the timeout is most simple solutionand will roably appear in some next iterationchangeset > >> + } >> + return openHttpsConnection(url); >> + } else { >> + OutputController.getLogger().log("done " + url.toExternalForm()); >> + return url.openConnection(); >> + } >> + } >> + >> + private synchronized URLConnection openHttpsConnection(URL url) throws IOException { >> + URLConnection conn = null; >> + //yes,by default we assume that once initialized https settings are valid for all resources >> + //note the combination of async and try every time have no sense (it *may* change the >> opened connections => error >> + OutputController.getLogger().log("Probing " + url.toExternalForm()); >> + if (HttpsSettings.getHttpsSettings() == null || isProbeAlways()) { >> + HttpsProbeResult pr = HttpsSettings.initHttpsSettings(url); >> + if (pr.settings != null && pr.conn != null) { >> + conn = pr.conn; >> + } >> + } else { >> + conn = HttpsSettings.getHttpsSettings().openConnection(url); >> + } >> + httpsConnections.add(conn); > > "conn" can still be null and be added to "httpsConnections". This is probably not intended. This is now sanitized. > >> + OutputController.getLogger().log("done " + url.toExternalForm()); >> + return conn; > > Same here, because "conn" can be null, null may be returned. nope. The null connection s correctly returned. > >> + } >> + >> + public void disconnect(URLConnection conn) { >> + if (conn instanceof HttpsURLConnection) { >> + disconnectHttps((HttpsURLConnection) conn); >> + } else { >> + if (conn instanceof HttpURLConnection) { >> + ((HttpURLConnection) conn).disconnect(); >> + } >> + } >> + } >> + >> + public synchronized void disconnectHttps(HttpsURLConnection conn) { >> + conn.disconnect(); > > Possible NPE. Which should be ok. But no null shold pass the instanceof chkc. Method changed to private. > >> + //this s intentional search by object value. equals do not work >> + for (int i = 0; i < httpsConnections.size(); i++) { > > Start from the end, decrement to 0, and compare to 0. Comparing to 0 gives almost always far better > performance on modern processors because they are heavily optimized for branch predicion on 0. > >> + URLConnection uRLConnection = httpsConnections.get(i); >> + if (uRLConnection == conn) { >> + httpsConnections.remove(i); >> + i--; > > Besides, why not use ArrayList.removeAll(Collection) here? It is probably much faster, even though > you have to create a Collection instance. I'm not sure what you meanhere. > >> + } >> + >> + } >> + } >> + >> + private static class HttpsProbeResult { >> + >> + URLConnection conn; >> + HttpsSettings settings; >> + } >> + >> + private static class HttpsSettings { >> + >> + private static HttpsSettings INSTANCE; >> + private static SSLContext ctxOrig; >> + >> + @Override >> + public String toString() { >> + return "SSL 2.0: " + ssl2 + ", insecure " + insecure; >> + } >> + >> + public static HttpsSettings getHttpsSettings() { >> + return INSTANCE; >> + } >> + >> + private static HttpsProbeResult initHttpsSettings(URL initUrl) throws IOException { >> + try { >> + if (ctxOrig == null) { >> + ctxOrig = SSLContext.getDefault(); >> + } >> + HttpsProbeResult pr = new HttpsProbeResult(); >> + try { >> + pr.settings = new HttpsSettings(false, false); >> + pr.conn = pr.settings.openConnection(initUrl); >> + INSTANCE = pr.settings; >> + return pr; >> + } catch (IOException e) { >> + OutputController.getLogger().log(e); >> + } >> + if (isInsecurePossible()) { >> + try { >> + OutputController.getLogger().log("Probing " + initUrl.toExternalForm() + >> " without certificate check."); >> + pr.settings = new HttpsSettings(false, true); >> + pr.conn = pr.settings.openConnection(initUrl); >> + if (getInsecureStatus().equals(InsecureStates.ASK)) { >> + //TODO dialog for not trusted cert dialog >> + } >> + INSTANCE = pr.settings; >> + return pr; >> + } catch (IOException e) { >> + OutputController.getLogger().log(e); >> + } >> + } >> + HttpURLConnection conn = null; >> + try { >> + OutputController.getLogger().log("Probing " + initUrl.toExternalForm() + " >> with SSL 2.0 handshake."); >> + conn = (HttpURLConnection) HttpsSettings.openConnection(initUrl, true, false); >> + String s = "The " + initUrl.toExternalForm() + " was accessible only by >> insecure SSL 2.0 handshake. This is forbidden. Contact its administrator."; >> + OutputController.getLogger().log(OutputController.Level.WARNING_ALL, s); >> + throw new RuntimeException(s); >> + } catch (IOException e) { >> + OutputController.getLogger().log(e); >> + } finally { >> + if (conn != null) { >> + conn.disconnect(); >> + } >> + } >> + conn = null; >> + if (isInsecurePossible()) { >> + try { >> + OutputController.getLogger().log("Probing " + initUrl.toExternalForm() + >> " with SSL 2.0 and without certificate check."); >> + conn = (HttpURLConnection) HttpsSettings.openConnection(initUrl, true, >> true); >> + String s = "The " + initUrl.toExternalForm() + " was accessible only by >> insecure SSL 2.0 handshake and with unchecked certificate. The SSL 2.0 handshake is forbidden. >> Contact its administrator."; >> + OutputController.getLogger().log(OutputController.Level.WARNING_ALL, s); >> + throw new RuntimeException(s); >> + } catch (IOException e) { >> + OutputController.getLogger().log(e); >> + } finally { >> + if (conn != null) { >> + conn.disconnect(); >> + } >> + } >> + } >> + throw new IOException("All probing methods on " + initUrl.toExternalForm() + >> "failed."); >> + } catch (NoSuchAlgorithmException ex) { >> + throw new IOException(ex); >> + } >> + } >> + >> + private final boolean ssl2; >> + private final boolean insecure; >> + >> + private HttpsSettings(boolean ssl2, boolean insecure) { >> + this.ssl2 = ssl2; >> + this.insecure = insecure; >> + } >> + >> + private URLConnection openConnection(URL url) throws IOException { >> + return openConnection(url, ssl2, insecure); >> + } >> + >> + public static URLConnection openConnection(URL url, boolean ssl2, boolean insecure) >> throws IOException { >> + try { >> + if (ssl2) { >> + System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); >> + } else { >> + System.clearProperty("https.protocols"); >> + >> + } > > I am absolutely sure we do not want to modify *system* properties for *all* future connections here. > What about other existing and other future connections, especially connections created by a JNLP > application? > And then there SecurityManager implications. What if these or all system properties are read-only? > So no, we do not want to modify system properties at runtime. Ok.I made investigations and you are right. This is show stopper on current approach. Theissue helpcrypto is facing with jdk8 have solution based on properties to:( > >> + if (insecure) { >> + // configure the SSLContext without a TrustManager >> + SSLContext ctx = SSLContext.getInstance("TLS"); >> + ctx.init(new KeyManager[0], new TrustManager[]{new DummyTrustManager()}, new >> SecureRandom()); >> + SSLContext.setDefault(ctx); >> + } else { >> + SSLContext.setDefault(ctxOrig); >> + } >> + HttpsURLConnection conn = (HttpsURLConnection) url.openConnection(); >> + if (insecure) { >> + conn.setHostnameVerifier(new HostnameVerifier() { >> + @Override >> + public boolean verify(String arg0, SSLSession arg1) { >> + return true; >> + } >> + }); >> + } >> + >> + return conn; >> + } catch (KeyManagementException | NoSuchAlgorithmException ex) { >> + throw new IOException(ex); >> + } >> + } >> + >> + private static class DummyTrustManager implements X509TrustManager { >> + >> + public DummyTrustManager() { >> + } >> + >> + @Override >> + public void checkClientTrusted(X509Certificate[] arg0, String arg1) throws >> CertificateException { >> + } >> + >> + @Override >> + public void checkServerTrusted(X509Certificate[] arg0, String arg1) throws >> CertificateException { >> + } >> + >> + @Override >> + public X509Certificate[] getAcceptedIssuers() { >> + return null; >> + } >> + } >> + } >> + >> +} > > So much reviewing for now. I'll get back to it when you have a patch based on the current tip ready. > Thank you very much! Well the issue with proeprties is show stopper. I have not yet touch the paper with pen on fixing it, As I would like to know your opinion. By default, no probing will be done, and itw will work as before. There will be only one property - public static final String KEY_HTTPS_PROBINGALLOWED = "deployment.security.https.probing.allowed"; By default false, and with possible true/false Maybe probing will be possible to turn on in runtime, if https connection fails, on users approve. Once proobing is true, then the scenario will be same as attached (same as always in this thread) chnageset with : deployment.security.https.syncforced = true deployment.security.https.probing.always = true deployment.security.https.allowinsecure = ask set but the mian difference will be, that in disconnectHttps method,the https will be cleaned to default state. What do you think? Until you stop me, I will work on solution like this. Thank you for hints! J. -------------- next part -------------- A non-text attachment was scrubbed... Name: httpsSolution_06.patch Type: text/x-patch Size: 30535 bytes Desc: not available URL: From jkang at redhat.com Tue Sep 23 18:16:57 2014 From: jkang at redhat.com (Jie Kang) Date: Tue, 23 Sep 2014 14:16:57 -0400 (EDT) Subject: [rfc][icedtea-web] Makefile New Whitelisted-Dist-Test option In-Reply-To: <542162C3.1010400@redhat.com> References: <1294941468.9304595.1411420667650.JavaMail.zimbra@redhat.com> <542162C3.1010400@redhat.com> Message-ID: <1201728781.9838431.1411496217760.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/22/2014 11:17 PM, Jie Kang wrote: > > Hello, > > > > This patch expands on the Makefile Reproducer Test patch [1]. > > > > [1] > > http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-September/029581.html > > > > > > There is now a new make rule: 'run-netx-whitelisted-dist-tests' > > > > This rule runs the reproducers similar to 'run-netx-dist-tests', except it > > only processes (compiles, etc.) the resources filtered by the whitelist. > > > > As well, the rule 'run-netx-dist-tests' has now reverted back to processing > > all resources (ie. what it used to do before the Makefile Reproducer Test > > patch [1]) > > > > Thoughts? > > > > Just a note, the purpose of the "stamps/whitelist-filter.stamp" rule > > having: > > echo ".*" ... > > is to maintain compatibility. Though the "all-whitelist" rule also contains > > duplicate code, there can be situations where neither "all-whitelist" or > > "filtered-whitelist" are not called. E.g. if user runs "make > > stamps/netx-dist-tests-prepare-reproducers.stamp". This is the solution I > > came up with to allow for all possible make commands to continue to work > > and for the user to be able to quickly switch between running "make > > run-netx-dist-tests" and "make run-netx-whitelisted-dist-tests" without > > always having to perform "make clean-netx-dist-tests". I guess a TLDR is > > that it's to prevent regressions. > > > > If this patch is accepted I will update the wiki and documentation for this > > feature. > > > > > > Regards, > > > > Hm. only hint to approach. Why not configure switch? This seems to me > overcomplexed. What is > advantage of this? Hello, I have attached a completely new patch that follows your hint. Thanks a lot, it is much better now, and more simple. New option for configure: --enable-whitelist-processing With the flag on, the Makefile generated will filter by whitelist for processing, otherwise, it will process all, just like before patch [1]. [1] http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-September/029581.html > Once the new and old targets will be run in unpredicted order, the result can > be unpredictible. The complexity was to make sure running new and old targets in random order still worked hahah. And you could run them and stop them whenever, and still work properly like before too! But now no longer needed so... > Also I can not see the reverted part in patch. There wasn't really any reversion in code, just reversion in behaviour. Anyways, no longer relevant. Thanks a lot!! Regards, > > J. > -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-make-configure-whitelist-1.patch Type: text/x-patch Size: 2377 bytes Desc: not available URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 24 09:26:38 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 24 Sep 2014 09:26:38 +0000 Subject: [Bug 1897] vm crashes on IMAGEIO.read multithreaded / liblcms2-2 In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1897 classpath.org at tmp.dau-sicher.de changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |VERIFIED CC| |classpath.org at tmp.dau-siche | |r.de --- Comment #2 from classpath.org at tmp.dau-sicher.de --- Can confirm this for Debian Wheezy (liblcms2-2:amd64 2.2+git20110628-2.2+deb7u1). Seems to be a race condition if multiple threads access ImageIO.read (you don't need 64 to reproduce this). This error crashed my tomcat twice within two days. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From gitne at gmx.de Wed Sep 24 14:41:02 2014 From: gitne at gmx.de (Jacob Wisor) Date: Wed, 24 Sep 2014 16:41:02 +0200 Subject: [rfc][icedtea-web] https probing In-Reply-To: <54219241.6060705@redhat.com> References: <54071FE9.2000309@redhat.com> <54101CEB.1040104@redhat.com> <541516F5.3020504@gmx.de> <54219241.6060705@redhat.com> Message-ID: <5422D7FE.60004@gmx.de> On 09/23/2014 at 05:31 PM, Jiri Vanek wrote: > On 09/14/2014 06:17 AM, Jacob Wisor wrote: >> On 09/10/2014 at 11:42 AM, Jiri Vanek wrote: Because the discussion on this patch has become quite extensive I am going to focus on the two most important issues only. At least for now. [...] >>> + if (url.getProtocol().equalsIgnoreCase("https") && >>> isProbingAllowed()) { >>> + if (isSyncForced()) { >>> + while (!httpsConnections.isEmpty()) { >>> + try { >>> + Thread.sleep(100); >>> + } catch (InterruptedException ex) { >>> + throw new IOException(ex); >>> + } >>> + } >> >> Polling? Really? Is this really the proper way to do it? And, do we really >> need to offer > > > Actually yes. I dont know about better way here. I will be happy if you have some. > > What I wonted to take care about, is situatuion when the individual https > settings differe. Then the first one must be disconnected, before second can > apply for new settings. > And so tehre is need to not accept other https conenctions until previous one > disconnects. > > >> synchronous connections? >> Besides, what about infinite looping? > > Do you mean that it can deadlock here? Yes. I'm thinking the same. But The same > deadlock will rise now too. For my pooling here, the timeout is most simple > solution and will probably appear in some next iteration changeset I think you cannot avoid to pay tribute to the fact that networks are inherently asynchronous by their very nature (I am not talking about USB here ;-) ). Having said that, we /can/ support synchronous connection creating but it should be based on asynchronous calls because ... you guessed it, of a network's inherent asynchronous nature. Anyway, the Http(s)Factory should support creating HTTP /and/ HTTPS connections (and thus download JNLP resources) not only asynchronously but also concurrently. None of the protocols posses a property that prevents us from implementing asynchronous connection creating, forces us to support synchronous connection creating only (even when testing for multiple versions), nor imposes a limit on the full (logical) potential of a network. Besides, establishing connections synchronously only, is definitely not the state of the art for the 21st century. ;-) Also, please note that your current approach is not thread-safe, even for synchronous calls only! Thread-safety is actually a MUST for a Http(s)Factory. Simply putting the synchronized keyword in front of a method declaration is not fully solving the problem here nor should actually be done this way. What you actually want to synchronize is the access to the Http(s)Factory's internal state, not the access to the factory (its methods) itself. There is no need to block *all* other threads which want to create a connection just because one thread is using the factory or is waiting for the factory to complete creating a connection for it. I strongly advise you to rewrite the factory accordingly. The proper way to provide a synchronous call in an asynchronous environment is to block or yield. And, you certainly do not accomplish this with potentially infinite loops making the current thread wait an arbitrary amount of time. What you do is; you set off the asynchronous call and then wait (Object.wait()) until you get notified (Object.notify()) by the asynchronous call's on complete method. >>> [...] >>> + //this s intentional search by object value. equals do not work >>> + for (int i = 0; i < httpsConnections.size(); i++) { >> >> Start from the end, decrement to 0, and compare to 0. Comparing to 0 gives >> almost always far better >> performance on modern processors because they are heavily optimized for branch >> prediction on 0. >> >>> + URLConnection uRLConnection = httpsConnections.get(i); >>> + if (uRLConnection == conn) { >>> + httpsConnections.remove(i); >>> + i--; >> >> Besides, why not use ArrayList.removeAll(Collection) here? It is probably much >> faster, even though >> you have to create a Collection instance. > > > I'm not sure what you mean here. You are trying to remove all "conn" elements from the "httpsConnections" ArrayList the awkward way. The best way to do this is to call ArrayList.removeAll(Collection) instead of iterating through the ArrayList manually. >>> [...] >>> + public static URLConnection openConnection(URL url, boolean ssl2, >>> boolean insecure) >>> throws IOException { >>> + try { >>> + if (ssl2) { >>> + System.setProperty("https.protocols", "SSLv3,SSLv2Hello"); >>> + } else { >>> + System.clearProperty("https.protocols"); >>> + >>> + } >> >> I am absolutely sure we do not want to modify *system* properties for *all* >> future connections here. >> What about other existing and other future connections, especially connections >> created by a JNLP >> application? >> And then there are SecurityManager implications. What if these or all system >> properties are read-only? >> So no, we do not want to modify system properties at runtime. > > Ok.I made investigations and you are right. This is show stopper on current > approach. > The issue helpcrypto is facing with jdk8 have solution based on properties to:( This raises the question whether we should bother about this at all, since the SSL version of HTTPS connections can and have always been configurable by system properties in the JRE. :-D > By default, no probing will be done, and itw will work as before. > There will be only one property - public static final String > KEY_HTTPS_PROBINGALLOWED = "deployment.security.https.probing.allowed"; Then this property should be renamed to "deployment.security.https.probing.enabled". > By default false, and with possible true/false > > Maybe probing will be possible to turn on in runtime, if https connection fails, > on users approve. It could. But, on the other hand who or what would turn on probing for HTTPS connections at runtime? The JNLP application? Certainly not. A JNLP application does not even control downloading resources directly. Then perhaps the user? If so, this would require for the user to be able to change the desired JNLP application's JRE configuration in some kind of UI or command line interface provided by IcedTea-Web. And it would make tracing the configuration for every running JNLP application and visualizing system properties mandatory. This is counter intuitive and breaks JNLPRuntime's current concept which is to configure the JRE for a JNLP application's entire lifetime. Besides, there is currently no UI or infrastructure to support this in IcedTea-Web. > Once proobing is true, then the scenario will be same as attached (same as > always in this thread) chnageset with : > deployment.security.https.syncforced = true Why so? Why should creating HTTPS connections be synchronous only? There is no rational reason to impose such a limit. Besides, it definitely leads to increased latencies and possibly to decreased throughput. > deployment.security.https.probing.always = true > deployment.security.https.allowinsecure = ask Jacob From jvanek at redhat.com Wed Sep 24 15:35:06 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 24 Sep 2014 17:35:06 +0200 Subject: [rfc][icedtea-web] Makefile New Whitelisted-Dist-Test option In-Reply-To: <1201728781.9838431.1411496217760.JavaMail.zimbra@redhat.com> References: <1294941468.9304595.1411420667650.JavaMail.zimbra@redhat.com> <542162C3.1010400@redhat.com> <1201728781.9838431.1411496217760.JavaMail.zimbra@redhat.com> Message-ID: <5422E4AA.4020602@redhat.com> On 09/23/2014 08:16 PM, Jie Kang wrote: > ----- Original Message ----- >> >On 09/22/2014 11:17 PM, Jie Kang wrote: >>> > >Hello, >>> > > >>> > >This patch expands on the Makefile Reproducer Test patch [1]. >>> > > >>> > >[1] >>> > >http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-September/029581.html >>> > > >>> > > >>> > >There is now a new make rule: 'run-netx-whitelisted-dist-tests' >>> > > >>> > >This rule runs the reproducers similar to 'run-netx-dist-tests', except it >>> > >only processes (compiles, etc.) the resources filtered by the whitelist. >>> > > >>> > >As well, the rule 'run-netx-dist-tests' has now reverted back to processing >>> > >all resources (ie. what it used to do before the Makefile Reproducer Test >>> > >patch [1]) >>> > > >>> > >Thoughts? >>> > > >>> > >Just a note, the purpose of the "stamps/whitelist-filter.stamp" rule >>> > >having: >>> > > echo ".*" ... >>> > >is to maintain compatibility. Though the "all-whitelist" rule also contains >>> > >duplicate code, there can be situations where neither "all-whitelist" or >>> > >"filtered-whitelist" are not called. E.g. if user runs "make >>> > >stamps/netx-dist-tests-prepare-reproducers.stamp". This is the solution I >>> > >came up with to allow for all possible make commands to continue to work >>> > >and for the user to be able to quickly switch between running "make >>> > >run-netx-dist-tests" and "make run-netx-whitelisted-dist-tests" without >>> > >always having to perform "make clean-netx-dist-tests". I guess a TLDR is >>> > >that it's to prevent regressions. >>> > > >>> > >If this patch is accepted I will update the wiki and documentation for this >>> > >feature. >>> > > >>> > > >>> > >Regards, >>> > > >> > >> >Hm. only hint to approach. Why not configure switch? This seems to me >> >overcomplexed. What is >> >advantage of this? > Hello, > > I have attached a completely new patch that follows your hint. Thanks a lot, it is much better now, and more simple. > New option for configure: --enable-whitelist-processing > > With the flag on, the Makefile generated will filter by whitelist for processing, otherwise, it will process all, just like before patch [1]. > > [1]http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-September/029581.html > >> >Once the new and old targets will be run in unpredicted order, the result can >> >be unpredictible. > The complexity was to make sure running new and old targets in random order still worked hahah. And you could run them and stop them whenever, and still work properly like before too! But now no longer needed so... > >> >Also I can not see the reverted part in patch. > There wasn't really any reversion in code, just reversion in behaviour. Anyways, no longer relevant. > > > Thanks a lot!! > > > Regards, > >> > >> >J. >> > > -- Jie Kang > > > itw-make-configure-whitelist-1.patch > > > diff --git a/Makefile.am b/Makefile.am > --- a/Makefile.am > +++ b/Makefile.am > @@ -178,6 +178,12 @@ > endif > endif > > +if ENABLE_WHITELIST > +WHITELIST=`cat $(REPRODUCERS_CLASS_WHITELIST)` > +else > +WHITELIST=.* > +endif > + > if WITH_RHINO > RHINO_TESTS=stamps/check-pac-functions.stamp > else > @@ -691,26 +697,23 @@ > mkdir -p $(REPRODUCERS_BUILD_DIR) > touch $@ > > -junit-jnlp-dist-custom.txt: $(REPRODUCERS_CLASS_WHITELIST) > +junit-jnlp-dist-custom.txt: > cd $(REPRODUCERS_TESTS_SRCDIR)/$(CUSTOM_REPRODUCERS)/ ; \ > - whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ > - for x in $$whiteListed ; do \ > + for x in $(WHITELIST) ; do \ > find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > $(abs_top_builddir)/$@ || true ; \ > done > > -junit-jnlp-dist-simple.txt: $(REPRODUCERS_CLASS_WHITELIST) > +junit-jnlp-dist-simple.txt: > cd $(REPRODUCERS_TESTS_SRCDIR)/simple/ ; \ > - whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ > - for x in $$whiteListed ; do \ > + for x in $(WHITELIST) ; do \ > find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > $(abs_top_builddir)/$@ || true ; \ > done > > -stamps/junit-jnlp-dist-signed.stamp: $(REPRODUCERS_CLASS_WHITELIST) > +stamps/junit-jnlp-dist-signed.stamp: > types=($(SIGNED_REPRODUCERS)) ; \ > for which in "$${types[@]}" ; do \ > pushd $(REPRODUCERS_TESTS_SRCDIR)/$$which/ ; \ > - whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ > - for x in $$whiteListed ; do \ > + for x in $(WHITELIST) ; do \ > find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > $(abs_top_builddir)/junit-jnlp-dist-$$which.txt ; \ > done ; \ > popd ; \ > diff --git a/configure.ac b/configure.ac > --- a/configure.ac > +++ b/configure.ac > @@ -28,6 +28,14 @@ > AM_CONDITIONAL([ENABLE_DOCS], [test x$ENABLE_DOCS = xyes]) > AC_MSG_RESULT(${ENABLE_DOCS}) > > +AC_MSG_CHECKING([whether to process reproducers using whitelist]) > +AC_ARG_ENABLE([whitelist-processing], > + [AS_HELP_STRING([--enable-whitelist-processing], > + [Enable processing of reproducers using whitelist])], I would probably reflector those sentences. Even to me they are not much describing. Try to debug those sentences with somebody who never seen itw or our testuite :) Once he understood the help message, it is right. for ideas: AC_MSG_CHECKING([whether to process reproducers using whitelist]) - this will be nearly correct if you adapt my idea lower. No it imho is not, and should be like "whether to compile and deploy reproducers using filtering described whitelist" AC_ARG_ENABLE([whitelist-processing], [AS_HELP_STRING([--enable-whitelist-processing], [Enable processing of reproducers using whitelist])], Same: "Enable compilation and deploy of reproducers using filtering described whitelist" In this or in (below) suggested approach, I would like to mention all three targets (or more?) when the whitelist is used - compile, deploy run (some more?) > + [ENABLE_WHITELIST="${enableval}"], [ENABLE_WHITELIST='no']) > +AM_CONDITIONAL([ENABLE_WHITELIST], [test x$ENABLE_WHITELIST = xyes]) > +AC_MSG_RESULT(${ENABLE_WHITELIST}) > + > AC_PATH_PROG([BIN_BASH], [bash],, [/bin]) > if test x"$BIN_BASH" = x ; then > AC_MSG_ERROR([/bin/bash is used in runtime and for about generation. Dying sooner rather then later]) > Except this, looks ok. Well - one general hint. Right now, if ENABLE_WHITELIST is true, then: - only reprodcuers matching regeexes in list are compiled, deployed and run if ENABLE_WHITELIST is false then: - all reprodcuers are compiled and deployed, but only reprodcuers matching regeexes in whitelist are run. I was thinking about to unifying it - only reprodcuers matching regeexes in list are compiled, deployed and run if ENABLE_WHITELIST is false then: - all reprodcuers are compiled and deployed, and run Well - this have question - what to do with current whitelist. To kept it in repo enad ampty? As it is? To rmeove? I probably incline to first one. J. From jvanek at redhat.com Wed Sep 24 16:01:46 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Wed, 24 Sep 2014 18:01:46 +0200 Subject: [rfc][icedtea-web] Cache Locking Tests : Potential Deadlock Fix In-Reply-To: <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> References: <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> Message-ID: <5422EAEA.1090305@redhat.com> On 09/23/2014 05:07 PM, Jie Kang wrote: > Hello, > > Jiri reported deadlock occurring in the unit tests for CacheLRUWrapper. This most likely occurred in the multi-threaded test where the parent thread sleeps for 2 seconds, before attempting to wake the sleeping children. If the children have not completed their tasks within two seconds, they will not be waiting for the parent thread to wake them, and a deadlock can occur. This issue could also occur in CacheEntry, which has a multi-threaded test that functions similarly. This patch resolves the problem. Sorry for the mistake. > > Regards, > Uff... Quite hard to understand what is this supposed to do. ANyway - why the sleeps here? J. From bugzilla-daemon at icedtea.classpath.org Wed Sep 24 17:07:38 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 24 Sep 2014 17:07:38 +0000 Subject: [Bug 2004] When accessing applet it will crash In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 --- Comment #7 from Diego --- After updating the system I still get the following error message: IcedTea-Web Plugin version: 1.5 (1.5-1ubuntu1) 24/09/14 19:05 Exception was: java.lang.NullPointerException at net.sourceforge.jnlp.NetxPanel.runLoader(NetxPanel.java:117) at sun.applet.AppletPanel.run(AppletPanel.java:380) at java.lang.Thread.run(Thread.java:745) -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Wed Sep 24 17:08:34 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 24 Sep 2014 17:08:34 +0000 Subject: [Bug 2004] When accessing applet it will crash In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2004 Diego changed: What |Removed |Added ---------------------------------------------------------------------------- Version|1.4 |1.5 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From omajid at redhat.com Wed Sep 24 17:08:51 2014 From: omajid at redhat.com (Omair Majid) Date: Wed, 24 Sep 2014 13:08:51 -0400 Subject: [rfc][icedtea-web] Cache Locking Tests : Potential Deadlock Fix In-Reply-To: <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> References: <2103989617.9655152.1411481967464.JavaMail.zimbra@redhat.com> <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> Message-ID: <20140924170851.GB9537@redhat.com> * Jie Kang [2014-09-23 11:09]: > Jiri reported deadlock occurring in the unit tests for > CacheLRUWrapper. This most likely occurred in the multi-threaded test > where the parent thread sleeps for 2 seconds, before attempting to > wake the sleeping children. If the children have not completed their > tasks within two seconds, they will not be waiting for the parent > thread to wake them, and a deadlock can occur. I am not sure it counts as a deadlock; just sleeping threads that never wake up. Don't deadlocks require circular wait? > This issue could also occur in CacheEntry, which has a multi-threaded > test that functions similarly. This patch resolves the problem. Sorry > for the mistake. This is the classic lost-notify problem, right? Why not use a Semaphore? > +++ b/tests/netx/unit/net/sourceforge/jnlp/cache/CacheEntryTest.java > + //Would like thread a to acquire lock first > + Thread.sleep(1000l); > + Instead of sleeping (and making unit tests take longer) please use a semaphore to signal the readiness. > Thread b = new Thread(new WriteWorker(5, entry)); > b.start(); > > - Thread.sleep(2000l); > + //Wait for both children to signal (integer increments from 0, to 2) > + while (childSignal.get() < 2) { > + Thread.sleep(1000l); > + } > > - synchronized (listener) { > - num = 1; > - listener.notifyAll(); > + while (parentSignal.get() != 1) { > + synchronized (listener) { > + parentSignal.set(1); > + listener.notifyAll(); > + } Just to clarify, you want both threads to reach a point in their execution cycle and wait there until both have reached that same point? This sounds like a job for a CountDownLatch (or a Barrier). > try { > - boolean result = entry.tryLock(); > + entry.tryLock(); > entry.setLastModified(input); > - result = entry.store(); > - executorService.execute(new WriteRunnable(":" + input + ":" + result)); > - while (num == 0) { > + boolean result = entry.store(); > + synchronized (out) { > + out.println(":" + input + ":" + result); > + out.flush(); > + } > + childSignal.getAndIncrement(); > + while (parentSignal.get() == 0) { > synchronized (listener) { > listener.wait(); > } This code calls `entry.unlock()` unconditionally, even if the `entry.tryLock()` fails. This violates the contract of `unlock()`. Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From jkang at redhat.com Wed Sep 24 19:22:07 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 24 Sep 2014 15:22:07 -0400 (EDT) Subject: [rfc][icedtea-web] Cache Locking Tests : Potential Deadlock Fix In-Reply-To: <5422EAEA.1090305@redhat.com> References: <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> <5422EAEA.1090305@redhat.com> Message-ID: <304356085.10465007.1411586527023.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/23/2014 05:07 PM, Jie Kang wrote: > > Hello, > > > > Jiri reported deadlock occurring in the unit tests for CacheLRUWrapper. > > This most likely occurred in the multi-threaded test where the parent > > thread sleeps for 2 seconds, before attempting to wake the sleeping > > children. If the children have not completed their tasks within two > > seconds, they will not be waiting for the parent thread to wake them, and > > a deadlock can occur. This issue could also occur in CacheEntry, which has > > a multi-threaded test that functions similarly. This patch resolves the > > problem. Sorry for the mistake. > > > > Regards, > > > Uff... Quite hard to understand what is this supposed to do. ANyway - why the > sleeps here? Hello, Good question. After thinking about it some more I have changed them from sleeps to waits on listener objects. + //Would like thread a to acquire lock first + Thread.sleep(1000l); + This sleep is in the hopes that thread A will acquire the lock before we start thread B. Now that I think about it, the test can be changed to allow both threads to go whenever. The test now doesn't care which thread goes when, and now also runs 100 threads just to increase chance of concurrency issues being seen. + //Wait for both children to signal (integer increments from 0, to 2) + while (childSignal.get() < 2) { + Thread.sleep(1000l); + } These sleeps are to wait for both children to signal. Note that signalling does NOT mean that the thread has ended which is why I cannot use Thread.join. However..., now that I think about it this can be replaced with a wait on some new Object() lock. Now parent thread waits on parentListener and child threads wait on childListener. Parent signals children through parentSignal, children signal to parent through childrenSignal. It's a bit confusing though tbh. I have also added more comments to try to better explain what is going on. Attached is a revised patch. Thanks! > > > J. > -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-cachelock-deadlock-2.patch Type: text/x-patch Size: 14402 bytes Desc: not available URL: From jkang at redhat.com Wed Sep 24 19:51:43 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 24 Sep 2014 15:51:43 -0400 (EDT) Subject: [rfc][icedtea-web] Cache Locking Tests : Potential Deadlock Fix In-Reply-To: <20140924170851.GB9537@redhat.com> References: <2103989617.9655152.1411481967464.JavaMail.zimbra@redhat.com> <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> <20140924170851.GB9537@redhat.com> Message-ID: <936247043.10480762.1411588303412.JavaMail.zimbra@redhat.com> Hello Please ignore the previous message containing 'itw-cachelock-deadlock-2.patch'. After Omair's review I've improved it a bit. More comments in-line. ----- Original Message ----- > * Jie Kang [2014-09-23 11:09]: > > Jiri reported deadlock occurring in the unit tests for > > CacheLRUWrapper. This most likely occurred in the multi-threaded test > > where the parent thread sleeps for 2 seconds, before attempting to > > wake the sleeping children. If the children have not completed their > > tasks within two seconds, they will not be waiting for the parent > > thread to wake them, and a deadlock can occur. > > I am not sure it counts as a deadlock; just sleeping threads that never > wake up. Don't deadlocks require circular wait? Ah correct. > > > This issue could also occur in CacheEntry, which has a multi-threaded > > test that functions similarly. This patch resolves the problem. Sorry > > for the mistake. > > This is the classic lost-notify problem, right? Why not use a Semaphore? > > > +++ b/tests/netx/unit/net/sourceforge/jnlp/cache/CacheEntryTest.java > > > + //Would like thread a to acquire lock first > > + Thread.sleep(1000l); > > + > > Instead of sleeping (and making unit tests take longer) please use a > semaphore to signal the readiness. > > > Thread b = new Thread(new WriteWorker(5, entry)); > > b.start(); > > > > - Thread.sleep(2000l); > > + //Wait for both children to signal (integer increments from 0, to > > 2) > > + while (childSignal.get() < 2) { > > + Thread.sleep(1000l); > > + } > > > > - synchronized (listener) { > > - num = 1; > > - listener.notifyAll(); > > + while (parentSignal.get() != 1) { > > + synchronized (listener) { > > + parentSignal.set(1); > > + listener.notifyAll(); > > + } > > Just to clarify, you want both threads to reach a point in their > execution cycle and wait there until both have reached that same point? > This sounds like a job for a CountDownLatch (or a Barrier). Thanks. I didn't know of CountDownLatch but it has fit what I am trying to do perfectly. I guess I can treat this as good experience of writing my own poor-man's CountDownLatch... x-x The new patch is attached and is much cleaner. > > > try { > > - boolean result = entry.tryLock(); > > + entry.tryLock(); > > entry.setLastModified(input); > > - result = entry.store(); > > - executorService.execute(new WriteRunnable(":" + input + > > ":" + result)); > > - while (num == 0) { > > + boolean result = entry.store(); > > + synchronized (out) { > > + out.println(":" + input + ":" + result); > > + out.flush(); > > + } > > + childSignal.getAndIncrement(); > > + while (parentSignal.get() == 0) { > > synchronized (listener) { > > listener.wait(); > > } > > This code calls `entry.unlock()` unconditionally, even if the > `entry.tryLock()` fails. This violates the contract of `unlock()`. At the moment the unlock() doesn't care if the caller has the lock or not. If the caller has the lock, it unlocks, otherwise it does nothing. The underlying lock is a FileLock + ReentrantLock. FileLock chooses to do nothing on invalid unlocks [1] whereas ReentrantLocks throw an exception [2]. The function that calls ReentrantLock's unlock chooses to check for lockholder before calling unlock, and simply returns if it is incorrect. [3] [1] http://docs.oracle.com/javase/7/docs/api/java/nio/channels/FileLock.html#release() [2] http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/locks/ReentrantLock.html#unlock() [3] LockedFile.java public void unlock() throws IOException { if (JNLPRuntime.isWindows() || !this.threadLock.isHeldByCurrentThread()) { return; } ... Should this be changed? I am thinking of making all the void functions return booleans so callers can tell if locks/unlocks are successful, but the original code was all void so I was reluctant. > > Thanks, > Omair > > -- > PGP Key: 66484681 (http://pgp.mit.edu/) > Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 > -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-cachelock-deadlock-3.patch Type: text/x-patch Size: 13940 bytes Desc: not available URL: From jkang at redhat.com Wed Sep 24 20:55:46 2014 From: jkang at redhat.com (Jie Kang) Date: Wed, 24 Sep 2014 16:55:46 -0400 (EDT) Subject: [rfc][icedtea-web] Cache Locking Tests : Potential Deadlock Fix In-Reply-To: <936247043.10480762.1411588303412.JavaMail.zimbra@redhat.com> References: <2103989617.9655152.1411481967464.JavaMail.zimbra@redhat.com> <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> <20140924170851.GB9537@redhat.com> <936247043.10480762.1411588303412.JavaMail.zimbra@redhat.com> Message-ID: <935547535.10521973.1411592146362.JavaMail.zimbra@redhat.com> Hello, After some more suggestions from Omair, here is a revised and hopefully decent patch ^^ A CountDownLatch has been used in place of previous 'countdown-like' implementation and timeouts have been added so the tests won't cause any problems (apart from failing) if they somehow run forever. Thanks for all the help! Regards, ----- Original Message ----- > Hello > > > Please ignore the previous message containing > 'itw-cachelock-deadlock-2.patch'. After Omair's review I've improved it a > bit. More comments in-line. > > ----- Original Message ----- > > * Jie Kang [2014-09-23 11:09]: > > > Jiri reported deadlock occurring in the unit tests for > > > CacheLRUWrapper. This most likely occurred in the multi-threaded test > > > where the parent thread sleeps for 2 seconds, before attempting to > > > wake the sleeping children. If the children have not completed their > > > tasks within two seconds, they will not be waiting for the parent > > > thread to wake them, and a deadlock can occur. > > > > I am not sure it counts as a deadlock; just sleeping threads that never > > wake up. Don't deadlocks require circular wait? > > Ah correct. > > > > > > This issue could also occur in CacheEntry, which has a multi-threaded > > > test that functions similarly. This patch resolves the problem. Sorry > > > for the mistake. > > > > This is the classic lost-notify problem, right? Why not use a Semaphore? > > > > > +++ b/tests/netx/unit/net/sourceforge/jnlp/cache/CacheEntryTest.java > > > > > + //Would like thread a to acquire lock first > > > + Thread.sleep(1000l); > > > + > > > > Instead of sleeping (and making unit tests take longer) please use a > > semaphore to signal the readiness. > > > > > Thread b = new Thread(new WriteWorker(5, entry)); > > > b.start(); > > > > > > - Thread.sleep(2000l); > > > + //Wait for both children to signal (integer increments from 0, > > > to > > > 2) > > > + while (childSignal.get() < 2) { > > > + Thread.sleep(1000l); > > > + } > > > > > > - synchronized (listener) { > > > - num = 1; > > > - listener.notifyAll(); > > > + while (parentSignal.get() != 1) { > > > + synchronized (listener) { > > > + parentSignal.set(1); > > > + listener.notifyAll(); > > > + } > > > > Just to clarify, you want both threads to reach a point in their > > execution cycle and wait there until both have reached that same point? > > This sounds like a job for a CountDownLatch (or a Barrier). > > Thanks. I didn't know of CountDownLatch but it has fit what I am trying to do > perfectly. I guess I can treat this as good experience of writing my own > poor-man's CountDownLatch... x-x > > > The new patch is attached and is much cleaner. > > > > > > > try { > > > - boolean result = entry.tryLock(); > > > + entry.tryLock(); > > > entry.setLastModified(input); > > > - result = entry.store(); > > > - executorService.execute(new WriteRunnable(":" + input + > > > ":" + result)); > > > - while (num == 0) { > > > + boolean result = entry.store(); > > > + synchronized (out) { > > > + out.println(":" + input + ":" + result); > > > + out.flush(); > > > + } > > > + childSignal.getAndIncrement(); > > > + while (parentSignal.get() == 0) { > > > synchronized (listener) { > > > listener.wait(); > > > } > > > > This code calls `entry.unlock()` unconditionally, even if the > > `entry.tryLock()` fails. This violates the contract of `unlock()`. > > At the moment the unlock() doesn't care if the caller has the lock or not. If > the caller has the lock, it unlocks, otherwise it does nothing. > The underlying lock is a FileLock + ReentrantLock. FileLock chooses to do > nothing on invalid unlocks [1] whereas ReentrantLocks throw an exception > [2]. The function that calls ReentrantLock's unlock chooses to check for > lockholder before calling unlock, and simply returns if it is incorrect. [3] > > [1] > http://docs.oracle.com/javase/7/docs/api/java/nio/channels/FileLock.html#release() > [2] > http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/locks/ReentrantLock.html#unlock() > [3] LockedFile.java > public void unlock() throws IOException { > if (JNLPRuntime.isWindows() || > !this.threadLock.isHeldByCurrentThread()) { > return; > } > ... > > Should this be changed? I am thinking of making all the void functions return > booleans so callers can tell if locks/unlocks are successful, but the > original code was all void so I was reluctant. > > > > > Thanks, > > Omair > > > > -- > > PGP Key: 66484681 (http://pgp.mit.edu/) > > Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 > > > > -- > > Jie Kang -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-cachelock-deadlock-4.patch Type: text/x-patch Size: 13710 bytes Desc: not available URL: From jvanek at redhat.com Thu Sep 25 15:09:24 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 25 Sep 2014 17:09:24 +0200 Subject: [rfc][icedtea-web][itweb-settings] itweb-settings use Option Parser In-Reply-To: <1888728818.9296441.1411419281545.JavaMail.zimbra@redhat.com> References: <2136433079.7489666.1411075684213.JavaMail.zimbra@redhat.com> <541C3995.2080104@redhat.com> <1888728818.9296441.1411419281545.JavaMail.zimbra@redhat.com> Message-ID: <54243024.5050109@redhat.com> On 09/22/2014 10:54 PM, Lukasz Dracz wrote: > Hello, > > I have changed the parser to take into account the order of options it receives. > For itweb-settings it goes through the options in order, so the order in which the commands are issued matter. > Ex. 'itweb-settings get deployment.log.file set deployment.log.file true get deployment.log.file reset deployment.log.file > get deployment.log.file' will go through in order with the first get then set it to true, show you it is true with get > then reset it and use get after the reset. Also now help can be combined with options so 'itweb-settings get help set deployment.log.file true' > will show the help for get and do the specified set option. This does mean to get the big main help message the help command has to be present right > after itweb-settings or you could do itweb-settings headless help. Ufff... Much more mayor hints. Again. On one side I really like the possibility. On the other side, I'm not sure if it is worthy of introduced complexity. And from dark side, I'm definitely not with way how it is done (see inline). And from darkest side, I must disagree with your usecase. If you decide to go on with this "suport everything" approach, I will need to ask you also for few reproducers, to be sure that: itweb-settings set whatever set whatever2 get whatever reset whatever2 get whatever2 resetall set whatever get whatever really do the same as that itweb-settings set whatever ; itweb-settings set whatever2 ; itweb-settings get whatever itweb-settings reset whatever2 ; itweb-settings get whatever2 ; itweb-settings resetall itweb-settings set whatever ; itweb-settings get whatever For your usecase. I would nnever ever lunch iwebsettings set whatever tosomething get whatever reset whatever set whatever tosomethingeelse get whatever. I will always lunch it as separate commands and watch return values/outputs of commands - and so stop if something goes wrong. So Although on one side it is really cool to have such an powerful parser, I'm not sure if it worthy. It is bringing a lot of responsibility and maybe it have no target audience. (Added after finished the review) - seeing the complexity - I would really rather discourage you from this all-mightyapproach. > >> >Mayor hints >> > - when resetAll is presented - then no metter of other arguments, the ... > Yes I added support for set name=value because that is how they are stored in deployment.properties so I thought a user seeing the file might want to set them in the same manner. It also works in the old way where you place a space between name and value. I thought it would make it easier to use, I don't foresee the issue of "name" having a "=" in it as a legitimate property. Yes something like na=me=value if 'na=me' was a legitimate property would read the propery as na with value me and value would be the next property seen. If you think name might have equals / there is another issue I will change it back, I just thought this would make it easier for the user. I probably agree with support of this. > >> > >> >Here is valid same issue as in your first opton parser. What is value >> >consists of symbol? >> >param=va=lu=e will be broken :( > I could make it just break on the first equals it finds. Would that be more desirable behaviour ? So in this case set param=va=lu=e would be the same as set param va=lu=e. yes please. > >> > >> >But this will be valid only if we agree on bothold and new style. If we agree >> >only on old one those >> >will go out:( >> > >> >Anyway - nitpickers nit - tey both should be static and tested :) >>> > >+ >>> > >+ public List getValuesSplitOnEquals(OptionsDefinitions.OPTIONS >>> > >option) { >>> > >+ return getValuesSplitOn(option, "="); >>> > >+ } >>> > >+ >>> > >+ public int getNumberOfOptions() { >>> > >+ if (mainArgExists()) { >>> > >+ return parsedOptions.size() - 1; >>> > >+ } >>> > >+ return parsedOptions.size(); >>> > >+ } >>> > >+ >>> > > } >>> > > > Made these two static and added unit tests for them as well as the other new methods added. ty :) > >> >int to two "unrelated" bugs - both shoud be fixe din this changeset - as tis >> >is mayor rework of the >> >inpur handling. >> > >> > >> >Thak you! >> > >> >(well compared to this, th epolicyeditor will be children's palyground for >> >you :) ) > I guess so :) > > Thank you, > Lukasz Dracz > > > itweb-settingsOptionParser-5.patch > > > diff -r e1c7156ed0a1 launcher/launchers.in > --- a/launcher/launchers.in Thu Sep 18 13:18:11 2014 -0400 > +++ b/launcher/launchers.in Mon Sep 22 16:47:47 2014 -0400 > @@ -53,7 +53,7 @@ > *) > ARGS[$j]="$1" > j=$((j+1)) > - if [ "$1" = "-headless" ] ; then > + if [ "$1" = "-headless" ] || [ "$1" = "headless" ] ; then ouch. Where have you find this? This should not have reason to live... Well probably depends on taste, but test function have its own or. You shold uuse that. Anyway - your parser is supporting headless -headless --headless ... ------------*--------headless ... So even splash should. Please turn to regex/match (test *have* thisalready) > SPLASH="false" > fi > ;; > diff -r e1c7156ed0a1 netx/net/sourceforge/jnlp/OptionsDefinitions.java > --- a/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 18 13:18:11 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Mon Sep 22 16:47:47 2014 -0400 > @@ -75,11 +75,11 @@ > //itweb settings > NODASHHELP("help", "IBOHelp"), I think this also needs fix now - when your parser is no longer forcing - to swithces, then we don otneed HELP and NODASHHELP. But not sure how to keep in align with consistency javaws man looks like -option1 -option2 -help -optionN itweb-settings man loks like option1 option2 help OptionN So it would not be nice to have -option1 -option2 help -optionN or option1 option2 -help OptionN As PolicyEditor is using also -dash versions, maybe we can unify on them? And whats best, with your new parser we are automatically backward compatible. > LIST("list", "IBOList"), > - GET("get", "name", "IBOGet"), > - INFO("info", "name", "IBOInfo"), > - SET("set", "name value", "IBOSet"), > + GET("get", "name", "IBOGet", NumberOfArguments.ONE_OR_MORE), > + INFO("info", "name", "IBOInfo", NumberOfArguments.ONE_OR_MORE), > + SET("set", "name value", "IBOSet", NumberOfArguments.ONE_OR_MORE), > RESETALL("reset", "all", "IBOResetAll"), > - RESET("reset", "name", "IBOReset"), > + RESET("reset", "name", "IBOReset", NumberOfArguments.ONE_OR_MORE), > CHECK("check", "name", "IBOCheck"), I think we have an bug here. if you really decide to go with multiple set | get | reset | whatever you will need to add an field to the constructor. And if you will not decide to do so, resetall will force you The new field should be "expected quantity" so - in my world - eg restall - shouldbe EXACTLY_ONE_AND_ALONE get and set EXACTLY_ONE (and maybe alone?) list, info - shouldbe EXACTLY_ONE_AND_ALONE For javaws, most of the switches would be EXACTLY_ONE or ONE_OR_NONE (which I would set as default) - well except help :) Wchich shouldbe exactly one and alone :) In your world, for itwebsettings restall, get, and set or list, info - shouldbe ZERO_ONE_OR_MORETIMES ... Dependes how we agree here, but htis is the palce where to define it. Not hack *outside* parser ..somehow. According to ths change, different handling of arguments must be done. See later. *Anyway, the paresr must kill applciation if invalid combination/number of options apear.* minor note - if this field will be added, new enum will be probably created. Thsi enum will need same localizable schema as have NumberOfArguments. And Must be later added to docs generator. > //policyeditor > //-help > @@ -160,8 +160,9 @@ > OPTIONS.GET, > OPTIONS.INFO, > OPTIONS.SET, > + OPTIONS.RESET, > OPTIONS.RESETALL, > - OPTIONS.RESET, > + OPTIONS.HEADLESS, > OPTIONS.CHECK > }); > } > diff -r e1c7156ed0a1 netx/net/sourceforge/jnlp/controlpanel/CommandLine.java > --- a/netx/net/sourceforge/jnlp/controlpanel/CommandLine.java Thu Sep 18 13:18:11 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/controlpanel/CommandLine.java Mon Sep 22 16:47:47 2014 -0400 > @@ -21,8 +21,6 @@ > import static net.sourceforge.jnlp.runtime.Translator.R; > > import java.io.IOException; > -import java.util.ArrayList; > -import java.util.Arrays; > import java.util.List; > import java.util.Map; > > @@ -37,16 +35,17 @@ > import net.sourceforge.jnlp.util.docprovider.TextsProvider; > import net.sourceforge.jnlp.util.docprovider.formatters.formatters.PlainTextFormatter; > import net.sourceforge.jnlp.util.logging.OutputController; > +import net.sourceforge.jnlp.util.optionparser.OptionParser; > > /** > * Encapsulates a command line interface to the deployment configuration. > *

    > - * The central method is {@link #handle(String[])}, which calls one of the > - * various 'handle' methods. The commands listed in {@link #allCommands} are > + * The central method is {@link #handle()}, which calls one of the > + * various 'handle' methods. The commands listed in OptionsDefinitions are > * supported. For each supported command, a method handleCOMMANDCommand exists. > * This method actually takes action based on the command. Generally, a > * printCOMMANDHelp method also exists, and prints out the help message for > - * that specific command. For example, see {@link #handleListCommand(List)} > + * that specific command. For example, see {@link #handleListCommand(int)} > * and {@link #printListHelp()}. > *

    > * Sample usage: > @@ -72,6 +71,7 @@ > > > DeploymentConfiguration config = null; > + private static OptionParser optionParser; > > /** > * Creates a new instance > @@ -125,11 +125,11 @@ > /** > * Handles the 'list' command > * > - * @param args the arguments to the list command > * @return result of handling the command. SUCCESS if no errors occurred. > */ > - public int handleListCommand(List args) { > - if (args.contains("help")) { > + public int handleListCommand(int order) { > + List args = optionParser.getValuesFromOrder(order); > + if (optionParser.getOptionFromOrder(order + 1) == OptionsDefinitions.OPTIONS.NODASHHELP) { No op on this +1. It is terribly untrasnaprrent. See below. > printListHelp(); > return SUCCESS; > } > @@ -169,33 +169,29 @@ > /** > * Handles the 'get' command. > * > - * @param args the arguments to the get command > * @return an integer representing success (SUCCESS) or error handling the > * get command. > */ > - public int handleGetCommand(List args) { > - if (args.contains("help")) { > + public int handleGetCommand(int order) { > + List args = optionParser.getValuesFromOrder(order); > + if (optionParser.getOptionFromOrder(order + 1) == OptionsDefinitions.OPTIONS.NODASHHELP) { > printGetHelp(); > return SUCCESS; > } > > - if (args.size() != 1) { > - printGetHelp(); > - return ERROR; > - } > - > Map> all = config.getRaw(); > > - String key = args.get(0); > - String value = null; > - if (all.containsKey(key)) { > - value = all.get(key).getValue(); > - OutputController.getLogger().printOutLn(value); > - return SUCCESS; > - } else { > - OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownProperty", key)); > - return ERROR; > + for (String key : args) { > + String value = null; > + if (all.containsKey(key)) { > + value = all.get(key).getValue(); > + OutputController.getLogger().printOutLn(key+": "+value); > + } else { > + OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownProperty", key)); > + return ERROR; > + } > } > + return SUCCESS; > } > > /** > @@ -210,39 +206,46 @@ > /** > * Handles the 'set' command > * > - * @param args the arguments to the set command > * @return an integer indicating success (SUCCESS) or error in handling > * the command > */ > - public int handleSetCommand(List args) { > - if (args.contains("help")) { > + public int handleSetCommand(int order) { > + List args = optionParser.getValuesFromOrder(order); > + args = OptionParser.splitListOnEquals(args); > + if (optionParser.getOptionFromOrder(order + 1) == OptionsDefinitions.OPTIONS.NODASHHELP) { > printSetHelp(); > return SUCCESS; > } > > - if (args.size() != 2) { > + if (args.size() % 2 != 0) { > printSetHelp(); > return ERROR; > } > + String key = ""; > + String value; > > - String key = args.get(0); > - String value = args.get(1); > - > - if (config.getRaw().containsKey(key)) { > - Setting old = config.getRaw().get(key); > - if (old.getValidator() != null) { > - try { > - old.getValidator().validate(value); > - } catch (IllegalArgumentException e) { > - OutputController.getLogger().log(OutputController.Level.WARNING_ALL, R("CLIncorrectValue", old.getName(), value, old.getValidator().getPossibleValues())); > - OutputController.getLogger().log(e); > - return ERROR; > + for (String arg : args) { > + if (args.indexOf(arg) % 2 == 0) { > + key = arg; > + } else { > + value = arg; > + if (config.getRaw().containsKey(key)) { > + Setting old = config.getRaw().get(key); > + if (old.getValidator() != null) { > + try { > + old.getValidator().validate(value); > + } catch (IllegalArgumentException e) { > + OutputController.getLogger().log(OutputController.Level.WARNING_ALL, R("CLIncorrectValue", old.getName(), value, old.getValidator().getPossibleValues())); > + OutputController.getLogger().log(e); > + return ERROR; > + } > + } > + config.setProperty(key, value); > + } else { > + OutputController.getLogger().printOutLn(R("CLWarningUnknownProperty", key)); > + config.setProperty(key, value); > } > } > - config.setProperty(key, value); > - } else { > - OutputController.getLogger().printOutLn(R("CLWarningUnknownProperty", key)); > - config.setProperty(key, value); > } > > try { > @@ -267,33 +270,29 @@ > /** > * Handles the 'reset' command > * > - * @param args the arguments to the reset command > * @return an integer indicating success (SUCCESS) or error in handling > * the command > */ > - public int handleResetCommand(List args) { > - if (args.contains("help")) { > + public int handleResetCommand(int order) { > + List args = optionParser.getValuesFromOrder(order); > + if (optionParser.getOptionFromOrder(order + 1) == OptionsDefinitions.OPTIONS.NODASHHELP) { > printResetHelp(); > return SUCCESS; > } > > - if (args.size() != 1) { > - printResetHelp(); > - return ERROR; > - } > - > - String key = args.get(0); > - > boolean resetAll = false; > - if (key.equals("all")) { > + if (args.contains("all")) { > resetAll = true; > + if (args.size() > 1) { > + for (String arg : args) { > + if (!arg.equals("all")) { > + OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownCommand", arg)); > + } > + } > + } > } > > Map> all = config.getRaw(); > - if (!resetAll && !all.containsKey(key)) { > - OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownProperty", key)); > - return ERROR; > - } > > if (resetAll) { > for (String aKey: all.keySet()) { > @@ -301,8 +300,15 @@ > setting.setValue(setting.getDefaultValue()); > } > } else { > - Setting setting = all.get(key); > - setting.setValue(setting.getDefaultValue()); > + for(String key : args) { > + if (!all.containsKey(key)) { > + OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownProperty", key)); > + return ERROR; > + } else { > + Setting setting = all.get(key); > + setting.setValue(setting.getDefaultValue()); > + } > + } > } > > try { > @@ -325,42 +331,6 @@ > } > > /** > - * Handles the 'info' command > - * > - * @param args the arguments to the info command > - * @return an integer indicating success (SUCCESS) or error in handling > - * the command > - */ > - public int handleInfoCommand(List args) { > - if (args.contains("help")) { > - printInfoHelp(); > - return SUCCESS; > - } > - > - if (args.size() != 1) { > - printInfoHelp(); > - return ERROR; > - } > - > - Map> all = config.getRaw(); > - > - String key = args.get(0); > - Setting value = all.get(key); > - if (value == null) { > - OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLNoInfo")); > - return ERROR; > - } else { > - OutputController.getLogger().printOutLn(R("CLDescription", value.getDescription())); > - OutputController.getLogger().printOutLn(R("CLValue", value.getValue())); > - if (value.getValidator() != null) { > - OutputController.getLogger().printOutLn("\t" + R("VVPossibleValues", value.getValidator().getPossibleValues())); > - } > - OutputController.getLogger().printOutLn(R("CLValueSource", value.getSource())); > - return SUCCESS; > - } > - } > - > - /** > * Prints a help message for the 'check' command > */ > public void printCheckHelp() { > @@ -370,14 +340,46 @@ > } > > /** > - * Handles the 'check' command > + * Handles the 'info' command > * > - * @param args the arguments to the check command. > * @return an integer indicating success (SUCCESS) or error in handling > * the command > */ > - public int handleCheckCommand(List args) { > - if (args.contains("help")) { > + public int handleInfoCommand(int order) { > + List args = optionParser.getValuesFromOrder(order); > + if (optionParser.getOptionFromOrder(order + 1) == OptionsDefinitions.OPTIONS.NODASHHELP) { > + printInfoHelp(); > + return SUCCESS; > + } > + > + Map> all = config.getRaw(); > + > + for (String key : args) { > + Setting value = all.get(key); > + if (value == null) { > + OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLNoInfo")); > + return ERROR; > + } else { > + OutputController.getLogger().printOutLn(R("CLDescription", value.getDescription())); > + OutputController.getLogger().printOutLn(R("CLValue", value.getValue())); > + if (value.getValidator() != null) { > + OutputController.getLogger().printOutLn("\t" + R("VVPossibleValues", value.getValidator().getPossibleValues())); > + } > + OutputController.getLogger().printOutLn(R("CLValueSource", value.getSource())); > + } > + } > + return SUCCESS; > + } > + > + /** > + * Handles the 'check' command > + * > + * @return an integer indicating success (SUCCESS) or error in handling > + * the command > + */ > + public int handleCheckCommand(int order) { > + List args = optionParser.getValuesFromOrder(order); > + if (optionParser.getOptionFromOrder(order + 1) == OptionsDefinitions.OPTIONS.NODASHHELP) { > printCheckHelp(); > return SUCCESS; > } > @@ -416,48 +418,41 @@ > * into two pieces: the first element is assumend to be the command, and > * everything after is taken to be the argument to the command. > * > - * @param commandAndArgs A string array representing the command and > - * arguments to take action on > * @return an integer representing an error code or SUCCESS if no problems > * occurred. > */ > - public int handle(String[] commandAndArgs) { > + public int handle() { > > - if (commandAndArgs == null) { > - throw new NullPointerException("command is null"); > + int val = ERROR; > + int order = 0; > + for (OptionsDefinitions.OPTIONS option : optionParser.getOptionsOrder()) { > + if (option.equals(OptionsDefinitions.OPTIONS.RESET)) { > + val = handleResetCommand(order); > + } > + if (option.equals(OptionsDefinitions.OPTIONS.LIST)) { > + val = handleListCommand(order); > + } > + if (option.equals(OptionsDefinitions.OPTIONS.SET)) { > + val = handleSetCommand(order); > + } > + if (option.equals(OptionsDefinitions.OPTIONS.GET)) { > + val = handleGetCommand(order); > + } > + if (option.equals(OptionsDefinitions.OPTIONS.INFO)) { > + val = handleInfoCommand(order); > + } > + if (option.equals(OptionsDefinitions.OPTIONS.CHECK)) { > + val = handleCheckCommand(order); > + } > + if (optionParser.mainArgExists()) { > + OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownCommand", optionParser.getMainArgs())); > + handleHelpCommand(); > + val = ERROR; > + } else if (option.equals(OptionsDefinitions.OPTIONS.NODASHHELP) && (order == 0 || (optionParser.getOptionFromOrder(0) == OptionsDefinitions.OPTIONS.HEADLESS && order == 1))) { > + val = handleHelpCommand(); > + } > + order++; > } > - > - if (commandAndArgs.length == 0) { > - handleHelpCommand(); > - return ERROR; > - } > - > - String command = commandAndArgs[0]; > - String[] argsArray = new String[commandAndArgs.length - 1]; > - System.arraycopy(commandAndArgs, 1, argsArray, 0, commandAndArgs.length - 1); > - List arguments = new ArrayList<>(Arrays.asList(argsArray)); > - > - int val; > - if (command.equals(OptionsDefinitions.OPTIONS.NODASHHELP.option)) { > - val = handleHelpCommand(); > - } else if (command.equals(OptionsDefinitions.OPTIONS.LIST.option)) { > - val = handleListCommand(arguments); > - } else if (command.equals(OptionsDefinitions.OPTIONS.SET.option)) { > - val = handleSetCommand(arguments); > - } else if (command.equals(OptionsDefinitions.OPTIONS.RESET.option)) { > - val = handleResetCommand(arguments); > - } else if (command.equals(OptionsDefinitions.OPTIONS.GET.option)) { > - val = handleGetCommand(arguments); > - } else if (command.equals(OptionsDefinitions.OPTIONS.INFO.option)) { > - val = handleInfoCommand(arguments); > - } else if (command.equals(OptionsDefinitions.OPTIONS.CHECK.option)) { > - val = handleCheckCommand(arguments); > - } else { > - OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownCommand", command)); > - handleHelpCommand(); > - val = ERROR; > - } > - > return val; > } > > @@ -466,12 +461,17 @@ > * @param args the command line arguments to this program > */ > public static void main(String[] args) throws Exception { > + optionParser = new OptionParser(args, OptionsDefinitions.getItwsettingsCommands()); > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.HEADLESS)) { > + JNLPRuntime.setHeadless(true); > + } Yes. this is working for me. ty! > DeploymentConfiguration.move14AndOlderFilesTo15StructureCatched(); > + > if (args.length == 0) { > ControlPanel.main(new String[] {}); > } else { > CommandLine cli = new CommandLine(); > - int result = cli.handle(args); > + int result = cli.handle(); > > // instead of returning, use JNLPRuntime.exit() so we can pass back > // error codes indicating success or failure. Otherwise using > diff -r e1c7156ed0a1 netx/net/sourceforge/jnlp/resources/Messages.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Thu Sep 18 13:18:11 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Sep 22 16:47:47 2014 -0400 > @@ -297,7 +297,7 @@ > IBOSet=Sets the setting to the new value, after checking that it is an appropriate value. > IBOResetAll= Resets all settings to their original values. > IBOReset=Resets the named setting to its original value. > -IBOCheck=Checks that the current value of the setting is a valid value. > +IBOCheck=Checks that the current settings have valid values. > > PBOFile=Specifies a policy file path to open. If exactly one argument is given, and it is not this flag, it is interpreted as a file path to open, as if this flag was given first. This flag exists \ > mostly for compatibility with Policy Tool, but is also needed when opening a policy file and also using the -codebase flag. > diff -r e1c7156ed0a1 netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java > --- a/netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java Thu Sep 18 13:18:11 2014 -0400 > +++ b/netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java Mon Sep 22 16:47:47 2014 -0400 > @@ -40,6 +40,7 @@ > > import java.util.ArrayList; > import java.util.Arrays; > +import java.util.Collections; > import java.util.HashMap; > import java.util.List; > import java.util.Map; > @@ -58,7 +59,8 @@ > //null represents all values that are parsed that don't have a corresponding option which are potential main args > private final OptionsDefinitions.OPTIONS mainArg = null; > private List result; > - > + private List orderedOptions; > + private List orderedAmountOfValues; Ok. This is weekpoint. You cannot go by this hackisch way:( If you wont to support this ferature, you have to go by some deffinition similar to the one I suggested above, and adapt internal implementation of parser. In result the api of this parser will change. I'm c urrently not sure how. Probably return some list (arguments) of lists (their values)? But how to sanitize the order of different swithces. Some kind of iterable? In that case the Well This seems to me like in that case the parser will becoime moreover verifier and sanitizer. But also the transferer from string to objects... Well think about it :) See your reply! J. From omajid at redhat.com Thu Sep 25 16:24:44 2014 From: omajid at redhat.com (Omair Majid) Date: Thu, 25 Sep 2014 12:24:44 -0400 Subject: [rfc][icedtea-web] Cache Locking Tests : Potential Deadlock Fix In-Reply-To: <935547535.10521973.1411592146362.JavaMail.zimbra@redhat.com> References: <2103989617.9655152.1411481967464.JavaMail.zimbra@redhat.com> <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> <20140924170851.GB9537@redhat.com> <936247043.10480762.1411588303412.JavaMail.zimbra@redhat.com> <935547535.10521973.1411592146362.JavaMail.zimbra@redhat.com> Message-ID: <20140925162444.GA9482@redhat.com> * Jie Kang [2014-09-24 17:07]: > After some more suggestions from Omair, here is a revised and > hopefully decent patch ^^ > > A CountDownLatch has been used in place of previous 'countdown-like' > implementation and timeouts have been added so the tests won't cause > any problems (apart from failing) if they somehow run forever. > > > Thanks for all the help! You are welcome! > > ----- Original Message ----- > > [3] LockedFile.java > > public void unlock() throws IOException { > > if (JNLPRuntime.isWindows() || > > !this.threadLock.isHeldByCurrentThread()) { > > return; > > } > > ... > > > > Should this be changed? I am thinking of making all the void functions return > > booleans so callers can tell if locks/unlocks are successful, but the > > original code was all void so I was reluctant. FWIW, I think it should be changed to throw an error if the lock is not held. If a code implements methods from the Lock interface, it should try and follow the semantics (where possible) closely too. If it does not follow them, it should at least be documented. > + //Check if input string contains only one instance of given substring > + private boolean containsSingle(String in, String substr) { Call the method something like `stringContainsOnlySingleIntance(String input, String substring)` and you wont need the comment :) > + int start = in.indexOf(substr); //first match Maybe call it `int firstMatch`, then? > + String restOfString = in.substring(start+substr.length()); > + > + return !substr.contains(restOfString ); > } Another implementation might be: int firstIndex = in.indexOf(substr); int lastIndex = in.lastIndexOf(substr); boolean containsString = firstIndex != -1; boolean onlyOneInstance = firstIndex == lastIndex; return constainsString && onlyOneInstance; > + //Wait for writers to be done; > + try { > + writerSignal.await(); The comment makes me think the latch should be named `writersDone`. > + } catch (InterruptedException e) { > + e.printStackTrace(); Can you make this fail the test? > + } > long lastModified = entry.getLastModified(); > - executorService.execute(new WriteRunnable(":read:" + lastModified)); > + synchronized (out) { > + out.println(":read:" + lastModified); > + out.flush(); > + } I am a little confused here. When you run this test, does the `writerSignal.await()` mean that the writer is done and (possibly!) unlocked the lock? What is this test testing in that case? > + //Let people know reading is done There's nothing that does what the comment says :( > +++ b/tests/netx/unit/net/sourceforge/jnlp/cache/CacheLRUWrapperTest.java > @@ -99,36 +93,35 @@ > > final File cacheIndexFile = new File(clw.cacheDir + File.separator + cacheIndexFileName); > cacheIndexFile.delete(); > - try{ > - > - int noLoops = 1000; > + try { > + int noLoops = 1000; > > - long time[] = new long[noLoops]; > + long time[] = new long[noLoops]; > > - clw.lock(); > - clearCacheIndexFile(); > + clw.lock(); > + clearCacheIndexFile(); > > - fillCacheIndexFile(noEntriesCacheFile); > - clw.store(); > + fillCacheIndexFile(noEntriesCacheFile); > + clw.store(); > > - // FIXME: wait a second, because of file modification timestamp only provides accuracy on seconds. > - Thread.sleep(1000); > + // FIXME: wait a second, because of file modification timestamp only provides accuracy on seconds. > + Thread.sleep(1000); > > - long sum = 0; > - for(int i=0; i < noLoops - 1; i++) { > - time[i]= System.nanoTime(); > - clw.load(); > - time[i+1]= System.nanoTime(); > - if(i==0) > - continue; > - sum = sum + time[i] - time[i-1]; > - } > - > - double avg = sum / time.length; > - ServerAccess.logErrorReprint("Average = " + avg + "ns"); > + long sum = 0; > + for(int i=0; i < noLoops - 1; i++) { > + time[i]= System.nanoTime(); > + clw.load(); > + time[i+1]= System.nanoTime(); > + if(i==0) > + continue; > + sum = sum + time[i] - time[i-1]; > + } > > - // wait more than 100 microseconds for noLoops = 1000 and noEntries=1000 is bad > - assertTrue("load() must not take longer than 100 ??s, but took in avg " + avg/1000 + "??s", avg < 100 * 1000); > + double avg = sum / time.length; > + ServerAccess.logErrorReprint("Average = " + avg + "ns"); > + > + // wait more than 100 microseconds for noLoops = 1000 and noEntries=1000 is bad > + assertTrue("load() must not take longer than 100 ??s, but took in avg " + avg/1000 + "??s", avg < 100 * 1000); This is just an indentation change, right? I don't see code changes. > + //Check if input string contains only one instance of given substring > + private boolean containsSingle(String in, String substr) { A duplicate method? Please put it in some shared code. Thanks, Omair -- PGP Key: 66484681 (http://pgp.mit.edu/) Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 From ldracz at redhat.com Thu Sep 25 21:28:51 2014 From: ldracz at redhat.com (Lukasz Dracz) Date: Thu, 25 Sep 2014 17:28:51 -0400 (EDT) Subject: [rfc][icedtea-web][itweb-settings] itweb-settings use Option Parser In-Reply-To: <54243024.5050109@redhat.com> References: <2136433079.7489666.1411075684213.JavaMail.zimbra@redhat.com> <541C3995.2080104@redhat.com> <1888728818.9296441.1411419281545.JavaMail.zimbra@redhat.com> <54243024.5050109@redhat.com> Message-ID: <1795754452.11172633.1411680531876.JavaMail.zimbra@redhat.com> Hello, > Ufff... Much more mayor hints. > > > Again. On one side I really like the possibility. On the other side, I'm not > sure if it is worthy of > introduced complexity. And from dark side, I'm definitely not with way how > it is done (see inline). > And from darkest side, I must disagree with your usecase. > > If you decide to go on with this "suport everything" approach, I will need to > ask you also for few > reproducers, to be sure that: > itweb-settings set whatever set whatever2 get whatever reset whatever2 > get whatever2 > resetall set whatever get whatever > really do the same as > that itweb-settings set whatever ; itweb-settings set whatever2 ; > itweb-settings get whatever > itweb-settings reset whatever2 ; itweb-settings get whatever2 ; > itweb-settings resetall > itweb-settings set whatever ; itweb-settings get whatever > > > For your usecase. I would nnever ever lunch > > iwebsettings set whatever tosomething get whatever reset whatever set > whatever tosomethingeelse get > whatever. > > I will always lunch it as separate commands and watch return values/outputs > of commands - and so > stop if something goes wrong. Yeah, that's how I would do it too, I just wanted to give the ability to do it :) > So Although on one side it is really cool to have such an powerful parser, > I'm not sure if it > worthy. It is bringing a lot of responsibility and maybe it have no target > audience. Yeah you are right, this adds too much responsibility for no target audience. I thought it would be cool to have but my current implementation is too 'hackish'. I think the best way for itweb-settings to work is support only 1 command/option at a time, and just tell the user to use only one if they try to use more than one. The only other options allowed to be used at the same time are help and headless. Each option such as get or set still works with multiple values and I think that is a feature we should have. > > > > > > itweb-settingsOptionParser-5.patch > > > > > > diff -r e1c7156ed0a1 launcher/launchers.in > > --- a/launcher/launchers.in Thu Sep 18 13:18:11 2014 -0400 > > +++ b/launcher/launchers.in Mon Sep 22 16:47:47 2014 -0400 > > @@ -53,7 +53,7 @@ > > *) > > ARGS[$j]="$1" > > j=$((j+1)) > > - if [ "$1" = "-headless" ] ; then > > + if [ "$1" = "-headless" ] || [ "$1" = "headless" ] ; then > > > ouch. Where have you find this? This should not have reason to live... > Well probably depends on taste, but test function have its own or. You shold > uuse that. > > Anyway - your parser is supporting headless -headless --headless ... > ------------*--------headless ... > > So even splash should. > > Please turn to regex/match (test *have* thisalready) I changed the line to use a regex. > > SPLASH="false" > > fi > > ;; > > diff -r e1c7156ed0a1 netx/net/sourceforge/jnlp/OptionsDefinitions.java > > --- a/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 18 13:18:11 > > 2014 -0400 > > +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Mon Sep 22 16:47:47 > > 2014 -0400 > > @@ -75,11 +75,11 @@ > > //itweb settings > > NODASHHELP("help", "IBOHelp"), > > I think this also needs fix now - when your parser is no longer forcing - to > swithces, then we don > otneed HELP and NODASHHELP. I still have both, since each one has a different message it displays. Do we want to give them just one message and use only one ? > But not sure how to keep in align with consistency > javaws man looks like > > -option1 > -option2 > -help > -optionN > > itweb-settings man loks like > option1 > option2 > help > OptionN > > So it would not be nice to have > > -option1 > -option2 > help > -optionN > > or > > option1 > option2 > -help > OptionN > > > As PolicyEditor is using also -dash versions, maybe we can unify on them? > > And whats best, with your new parser we are automatically backward > compatible. Yeah I agree -option is better to use for all three since two of them use it already. > > LIST("list", "IBOList"), > > - GET("get", "name", "IBOGet"), > > - INFO("info", "name", "IBOInfo"), > > - SET("set", "name value", "IBOSet"), > > + GET("get", "name", "IBOGet", NumberOfArguments.ONE_OR_MORE), > > + INFO("info", "name", "IBOInfo", NumberOfArguments.ONE_OR_MORE), > > + SET("set", "name value", "IBOSet", NumberOfArguments.ONE_OR_MORE), > > RESETALL("reset", "all", "IBOResetAll"), > > - RESET("reset", "name", "IBOReset"), > > + RESET("reset", "name", "IBOReset", NumberOfArguments.ONE_OR_MORE), > > CHECK("check", "name", "IBOCheck"), > > > I think we have an bug here. > > > if you really decide to go with multiple set | get | reset | whatever you > will need to add an field > to the constructor. > And if you will not decide to do so, resetall will force you > > The new field should be "expected quantity" > > so - in my world - eg > restall - shouldbe EXACTLY_ONE_AND_ALONE > get and set EXACTLY_ONE (and maybe alone?) > list, info - shouldbe EXACTLY_ONE_AND_ALONE > > For javaws, most of the switches would be EXACTLY_ONE or ONE_OR_NONE (which I > would set as default) > - well except help :) Wchich shouldbe exactly one and alone :) > > > In your world, for itwebsettings > restall, get, and set or list, info - shouldbe ZERO_ONE_OR_MORETIMES ... > > > Dependes how we agree here, but htis is the palce where to define it. Not > hack *outside* parser > ..somehow. > > > According to ths change, different handling of arguments must be done. See > later. > > *Anyway, the paresr must kill applciation if invalid combination/number of > options apear.* > > minor note - if this field will be added, new enum will be probably created. > Thsi enum will need > same localizable schema as have NumberOfArguments. And Must be later added to > docs generator. Hmm okay I am a little unclear about this part since I thought NumberOfArguments's purpose was to outline the expected quantity of arguments. Also I changed it to work with only one command at a time so not sure if you still wanted this implemented. Also thought I would mention that RESETALL is *not really* supported, well it is supported but not tied to RESETALL but RESET instead. If two options have the same name in this case RESET and RESETALL, when parsing for it will match the one that is added to the list first in the getItwsettingsCommands(), which is why I moved RESET to be above RESETALL, since RESET expects one or more arguements. In handleResetCommand(), I also handle reset all. The only reason RESETALL exists is for when the user types itweb-settings help to see that reset all is a special case that is possible alongside reset name. > > //policyeditor > > //-help > > @@ -160,8 +160,9 @@ > > OPTIONS.GET, > > OPTIONS.INFO, > > OPTIONS.SET, > > + OPTIONS.RESET, > > OPTIONS.RESETALL, > > - OPTIONS.RESET, > > + OPTIONS.HEADLESS, > > OPTIONS.CHECK > > }); > > } > > diff -r e1c7156ed0a1 > > netx/net/sourceforge/jnlp/controlpanel/CommandLine.java > > --- a/netx/net/sourceforge/jnlp/controlpanel/CommandLine.java Thu Sep 18 > > 13:18:11 2014 -0400 > > +++ b/netx/net/sourceforge/jnlp/controlpanel/CommandLine.java Mon Sep 22 > > 16:47:47 2014 -0400 > > @@ -21,8 +21,6 @@ > > import static net.sourceforge.jnlp.runtime.Translator.R; > > > > import java.io.IOException; > > -import java.util.ArrayList; > > -import java.util.Arrays; > > import java.util.List; > > import java.util.Map; > > > > @@ -37,16 +35,17 @@ > > import net.sourceforge.jnlp.util.docprovider.TextsProvider; > > import > > net.sourceforge.jnlp.util.docprovider.formatters.formatters.PlainTextFormatter; > > import net.sourceforge.jnlp.util.logging.OutputController; > > +import net.sourceforge.jnlp.util.optionparser.OptionParser; > > > > /** > > * Encapsulates a command line interface to the deployment configuration. > > *

    > > - * The central method is {@link #handle(String[])}, which calls one of the > > - * various 'handle' methods. The commands listed in {@link #allCommands} > > are > > + * The central method is {@link #handle()}, which calls one of the > > + * various 'handle' methods. The commands listed in OptionsDefinitions are > > * supported. For each supported command, a method handleCOMMANDCommand > > exists. > > * This method actually takes action based on the command. Generally, a > > * printCOMMANDHelp method also exists, and prints out the help message > > for > > - * that specific command. For example, see {@link > > #handleListCommand(List)} > > + * that specific command. For example, see {@link #handleListCommand(int)} > > * and {@link #printListHelp()}. > > *

    > > * Sample usage: > > @@ -72,6 +71,7 @@ > > > > > > DeploymentConfiguration config = null; > > + private static OptionParser optionParser; > > > > /** > > * Creates a new instance > > @@ -125,11 +125,11 @@ > > /** > > * Handles the 'list' command > > * > > - * @param args the arguments to the list command > > * @return result of handling the command. SUCCESS if no errors > > occurred. > > */ > > - public int handleListCommand(List args) { > > - if (args.contains("help")) { > > + public int handleListCommand(int order) { > > + List args = optionParser.getValuesFromOrder(order); > > + if (optionParser.getOptionFromOrder(order + 1) == > > OptionsDefinitions.OPTIONS.NODASHHELP) { > > No op on this +1. It is terribly untrasnaprrent. See below. > > printListHelp(); > > return SUCCESS; > > } > > @@ -169,33 +169,29 @@ > > /** > > * Handles the 'get' command. > > * > > - * @param args the arguments to the get command > > * @return an integer representing success (SUCCESS) or error > > handling the > > * get command. > > */ > > - public int handleGetCommand(List args) { > > - if (args.contains("help")) { > > + public int handleGetCommand(int order) { > > + List args = optionParser.getValuesFromOrder(order); > > + if (optionParser.getOptionFromOrder(order + 1) == > > OptionsDefinitions.OPTIONS.NODASHHELP) { > > printGetHelp(); > > return SUCCESS; > > } > > > > - if (args.size() != 1) { > > - printGetHelp(); > > - return ERROR; > > - } > > - > > Map> all = config.getRaw(); > > > > - String key = args.get(0); > > - String value = null; > > - if (all.containsKey(key)) { > > - value = all.get(key).getValue(); > > - OutputController.getLogger().printOutLn(value); > > - return SUCCESS; > > - } else { > > - > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLUnknownProperty", key)); > > - return ERROR; > > + for (String key : args) { > > + String value = null; > > + if (all.containsKey(key)) { > > + value = all.get(key).getValue(); > > + OutputController.getLogger().printOutLn(key+": "+value); > > + } else { > > + > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLUnknownProperty", key)); > > + return ERROR; > > + } > > } > > + return SUCCESS; > > } > > > > /** > > @@ -210,39 +206,46 @@ > > /** > > * Handles the 'set' command > > * > > - * @param args the arguments to the set command > > * @return an integer indicating success (SUCCESS) or error in > > handling > > * the command > > */ > > - public int handleSetCommand(List args) { > > - if (args.contains("help")) { > > + public int handleSetCommand(int order) { > > + List args = optionParser.getValuesFromOrder(order); > > + args = OptionParser.splitListOnEquals(args); > > + if (optionParser.getOptionFromOrder(order + 1) == > > OptionsDefinitions.OPTIONS.NODASHHELP) { > > printSetHelp(); > > return SUCCESS; > > } > > > > - if (args.size() != 2) { > > + if (args.size() % 2 != 0) { > > printSetHelp(); > > return ERROR; > > } > > + String key = ""; > > + String value; > > > > - String key = args.get(0); > > - String value = args.get(1); > > - > > - if (config.getRaw().containsKey(key)) { > > - Setting old = config.getRaw().get(key); > > - if (old.getValidator() != null) { > > - try { > > - old.getValidator().validate(value); > > - } catch (IllegalArgumentException e) { > > - > > OutputController.getLogger().log(OutputController.Level.WARNING_ALL, > > R("CLIncorrectValue", old.getName(), value, > > old.getValidator().getPossibleValues())); > > - OutputController.getLogger().log(e); > > - return ERROR; > > + for (String arg : args) { > > + if (args.indexOf(arg) % 2 == 0) { > > + key = arg; > > + } else { > > + value = arg; > > + if (config.getRaw().containsKey(key)) { > > + Setting old = config.getRaw().get(key); > > + if (old.getValidator() != null) { > > + try { > > + old.getValidator().validate(value); > > + } catch (IllegalArgumentException e) { > > + > > OutputController.getLogger().log(OutputController.Level.WARNING_ALL, > > R("CLIncorrectValue", old.getName(), value, > > old.getValidator().getPossibleValues())); > > + OutputController.getLogger().log(e); > > + return ERROR; > > + } > > + } > > + config.setProperty(key, value); > > + } else { > > + > > OutputController.getLogger().printOutLn(R("CLWarningUnknownProperty", > > key)); > > + config.setProperty(key, value); > > } > > } > > - config.setProperty(key, value); > > - } else { > > - > > OutputController.getLogger().printOutLn(R("CLWarningUnknownProperty", > > key)); > > - config.setProperty(key, value); > > } > > > > try { > > @@ -267,33 +270,29 @@ > > /** > > * Handles the 'reset' command > > * > > - * @param args the arguments to the reset command > > * @return an integer indicating success (SUCCESS) or error in > > handling > > * the command > > */ > > - public int handleResetCommand(List args) { > > - if (args.contains("help")) { > > + public int handleResetCommand(int order) { > > + List args = optionParser.getValuesFromOrder(order); > > + if (optionParser.getOptionFromOrder(order + 1) == > > OptionsDefinitions.OPTIONS.NODASHHELP) { > > printResetHelp(); > > return SUCCESS; > > } > > > > - if (args.size() != 1) { > > - printResetHelp(); > > - return ERROR; > > - } > > - > > - String key = args.get(0); > > - > > boolean resetAll = false; > > - if (key.equals("all")) { > > + if (args.contains("all")) { > > resetAll = true; > > + if (args.size() > 1) { > > + for (String arg : args) { > > + if (!arg.equals("all")) { > > + > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLUnknownCommand", arg)); > > + } > > + } > > + } > > } > > > > Map> all = config.getRaw(); > > - if (!resetAll && !all.containsKey(key)) { > > - > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLUnknownProperty", key)); > > - return ERROR; > > - } > > > > if (resetAll) { > > for (String aKey: all.keySet()) { > > @@ -301,8 +300,15 @@ > > setting.setValue(setting.getDefaultValue()); > > } > > } else { > > - Setting setting = all.get(key); > > - setting.setValue(setting.getDefaultValue()); > > + for(String key : args) { > > + if (!all.containsKey(key)) { > > + > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLUnknownProperty", key)); > > + return ERROR; > > + } else { > > + Setting setting = all.get(key); > > + setting.setValue(setting.getDefaultValue()); > > + } > > + } > > } > > > > try { > > @@ -325,42 +331,6 @@ > > } > > > > /** > > - * Handles the 'info' command > > - * > > - * @param args the arguments to the info command > > - * @return an integer indicating success (SUCCESS) or error in > > handling > > - * the command > > - */ > > - public int handleInfoCommand(List args) { > > - if (args.contains("help")) { > > - printInfoHelp(); > > - return SUCCESS; > > - } > > - > > - if (args.size() != 1) { > > - printInfoHelp(); > > - return ERROR; > > - } > > - > > - Map> all = config.getRaw(); > > - > > - String key = args.get(0); > > - Setting value = all.get(key); > > - if (value == null) { > > - > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLNoInfo")); > > - return ERROR; > > - } else { > > - OutputController.getLogger().printOutLn(R("CLDescription", > > value.getDescription())); > > - OutputController.getLogger().printOutLn(R("CLValue", > > value.getValue())); > > - if (value.getValidator() != null) { > > - OutputController.getLogger().printOutLn("\t" + > > R("VVPossibleValues", value.getValidator().getPossibleValues())); > > - } > > - OutputController.getLogger().printOutLn(R("CLValueSource", > > value.getSource())); > > - return SUCCESS; > > - } > > - } > > - > > - /** > > * Prints a help message for the 'check' command > > */ > > public void printCheckHelp() { > > @@ -370,14 +340,46 @@ > > } > > > > /** > > - * Handles the 'check' command > > + * Handles the 'info' command > > * > > - * @param args the arguments to the check command. > > * @return an integer indicating success (SUCCESS) or error in > > handling > > * the command > > */ > > - public int handleCheckCommand(List args) { > > - if (args.contains("help")) { > > + public int handleInfoCommand(int order) { > > + List args = optionParser.getValuesFromOrder(order); > > + if (optionParser.getOptionFromOrder(order + 1) == > > OptionsDefinitions.OPTIONS.NODASHHELP) { > > + printInfoHelp(); > > + return SUCCESS; > > + } > > + > > + Map> all = config.getRaw(); > > + > > + for (String key : args) { > > + Setting value = all.get(key); > > + if (value == null) { > > + > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLNoInfo")); > > + return ERROR; > > + } else { > > + OutputController.getLogger().printOutLn(R("CLDescription", > > value.getDescription())); > > + OutputController.getLogger().printOutLn(R("CLValue", > > value.getValue())); > > + if (value.getValidator() != null) { > > + OutputController.getLogger().printOutLn("\t" + > > R("VVPossibleValues", value.getValidator().getPossibleValues())); > > + } > > + OutputController.getLogger().printOutLn(R("CLValueSource", > > value.getSource())); > > + } > > + } > > + return SUCCESS; > > + } > > + > > + /** > > + * Handles the 'check' command > > + * > > + * @return an integer indicating success (SUCCESS) or error in > > handling > > + * the command > > + */ > > + public int handleCheckCommand(int order) { > > + List args = optionParser.getValuesFromOrder(order); > > + if (optionParser.getOptionFromOrder(order + 1) == > > OptionsDefinitions.OPTIONS.NODASHHELP) { > > printCheckHelp(); > > return SUCCESS; > > } > > @@ -416,48 +418,41 @@ > > * into two pieces: the first element is assumend to be the command, > > and > > * everything after is taken to be the argument to the command. > > * > > - * @param commandAndArgs A string array representing the command and > > - * arguments to take action on > > * @return an integer representing an error code or SUCCESS if no > > problems > > * occurred. > > */ > > - public int handle(String[] commandAndArgs) { > > + public int handle() { > > > > - if (commandAndArgs == null) { > > - throw new NullPointerException("command is null"); > > + int val = ERROR; > > + int order = 0; > > + for (OptionsDefinitions.OPTIONS option : > > optionParser.getOptionsOrder()) { > > + if (option.equals(OptionsDefinitions.OPTIONS.RESET)) { > > + val = handleResetCommand(order); > > + } > > + if (option.equals(OptionsDefinitions.OPTIONS.LIST)) { > > + val = handleListCommand(order); > > + } > > + if (option.equals(OptionsDefinitions.OPTIONS.SET)) { > > + val = handleSetCommand(order); > > + } > > + if (option.equals(OptionsDefinitions.OPTIONS.GET)) { > > + val = handleGetCommand(order); > > + } > > + if (option.equals(OptionsDefinitions.OPTIONS.INFO)) { > > + val = handleInfoCommand(order); > > + } > > + if (option.equals(OptionsDefinitions.OPTIONS.CHECK)) { > > + val = handleCheckCommand(order); > > + } > > + if (optionParser.mainArgExists()) { > > + > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLUnknownCommand", optionParser.getMainArgs())); > > + handleHelpCommand(); > > + val = ERROR; > > + } else if > > (option.equals(OptionsDefinitions.OPTIONS.NODASHHELP) && (order == 0 || > > (optionParser.getOptionFromOrder(0) == OptionsDefinitions.OPTIONS.HEADLESS > > && order == 1))) { > > + val = handleHelpCommand(); > > + } > > + order++; > > } > > - > > - if (commandAndArgs.length == 0) { > > - handleHelpCommand(); > > - return ERROR; > > - } > > - > > - String command = commandAndArgs[0]; > > - String[] argsArray = new String[commandAndArgs.length - 1]; > > - System.arraycopy(commandAndArgs, 1, argsArray, 0, > > commandAndArgs.length - 1); > > - List arguments = new > > ArrayList<>(Arrays.asList(argsArray)); > > - > > - int val; > > - if (command.equals(OptionsDefinitions.OPTIONS.NODASHHELP.option)) > > { > > - val = handleHelpCommand(); > > - } else if (command.equals(OptionsDefinitions.OPTIONS.LIST.option)) > > { > > - val = handleListCommand(arguments); > > - } else if (command.equals(OptionsDefinitions.OPTIONS.SET.option)) > > { > > - val = handleSetCommand(arguments); > > - } else if > > (command.equals(OptionsDefinitions.OPTIONS.RESET.option)) { > > - val = handleResetCommand(arguments); > > - } else if (command.equals(OptionsDefinitions.OPTIONS.GET.option)) > > { > > - val = handleGetCommand(arguments); > > - } else if (command.equals(OptionsDefinitions.OPTIONS.INFO.option)) > > { > > - val = handleInfoCommand(arguments); > > - } else if > > (command.equals(OptionsDefinitions.OPTIONS.CHECK.option)) { > > - val = handleCheckCommand(arguments); > > - } else { > > - > > OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, > > R("CLUnknownCommand", command)); > > - handleHelpCommand(); > > - val = ERROR; > > - } > > - > > return val; > > } > > > > @@ -466,12 +461,17 @@ > > * @param args the command line arguments to this program > > */ > > public static void main(String[] args) throws Exception { > > + optionParser = new OptionParser(args, > > OptionsDefinitions.getItwsettingsCommands()); > > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.HEADLESS)) { > > + JNLPRuntime.setHeadless(true); > > + } > > Yes. this is working for me. ty! Glad to hear, thanks for your help ! I finally managed to get the pop up window to appear thanks to your help :) > > > DeploymentConfiguration.move14AndOlderFilesTo15StructureCatched(); > > + > > if (args.length == 0) { > > ControlPanel.main(new String[] {}); > > } else { > > CommandLine cli = new CommandLine(); > > - int result = cli.handle(args); > > + int result = cli.handle(); > > > > // instead of returning, use JNLPRuntime.exit() so we can > > pass back > > // error codes indicating success or failure. Otherwise using > > diff -r e1c7156ed0a1 > > netx/net/sourceforge/jnlp/resources/Messages.properties > > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Thu Sep 18 > > 13:18:11 2014 -0400 > > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Sep 22 > > 16:47:47 2014 -0400 > > @@ -297,7 +297,7 @@ > > IBOSet=Sets the setting to the new value, after checking that it is an > > appropriate value. > > IBOResetAll= Resets all settings to their original values. > > IBOReset=Resets the named setting to its original value. > > -IBOCheck=Checks that the current value of the setting is a valid value. > > +IBOCheck=Checks that the current settings have valid values. > > > > PBOFile=Specifies a policy file path to open. If exactly one argument is > > given, and it is not this flag, it is interpreted as a file path to > > open, as if this flag was given first. This flag exists \ > > mostly for compatibility with Policy Tool, but is also needed when > > opening a policy file and also using the -codebase flag. > > diff -r e1c7156ed0a1 > > netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java > > --- a/netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java Thu Sep > > 18 13:18:11 2014 -0400 > > +++ b/netx/net/sourceforge/jnlp/util/optionparser/OptionParser.java Mon Sep > > 22 16:47:47 2014 -0400 > > @@ -40,6 +40,7 @@ > > > > import java.util.ArrayList; > > import java.util.Arrays; > > +import java.util.Collections; > > import java.util.HashMap; > > import java.util.List; > > import java.util.Map; > > @@ -58,7 +59,8 @@ > > //null represents all values that are parsed that don't have a > > corresponding option which are potential main args > > private final OptionsDefinitions.OPTIONS mainArg = null; > > private List result; > > - > > + private List orderedOptions; > > + private List orderedAmountOfValues; > > > Ok. This is weekpoint. You cannot go by this hackisch way:( Agreed :) I was not happy with my implementation either, I could make another attempt if we want to support this but I think it is much simpler/better to allow only one command at a time, especially since you mentioned there is probably no target audience for this feature. > If you wont to support this ferature, you have to go by some deffinition > similar to the one I > suggested above, and adapt internal implementation of parser. > > In result the api of this parser will change. I'm c urrently not sure how. > Probably return some list > (arguments) of lists (their values)? But how to sanitize the order of > different swithces. Some > kind of iterable? In that case the > > Well This seems to me like in that case the parser will becoime moreover > verifier and sanitizer. But > also the transferer from string to objects... Well think about it :) > > See your reply! Yeah like I mentioned I agree we don't need this feature and keeping it simple is better in this case. I don't think it adds much benefit and I could see users preferring to use one command at a time like you mentioned to see each step is working as intended. > J. Thank you, Lukasz Dracz -------------- next part -------------- A non-text attachment was scrubbed... Name: itweb-settingsOptionParser-6.patch Type: text/x-patch Size: 24530 bytes Desc: not available URL: From jvanek at redhat.com Fri Sep 26 11:48:21 2014 From: jvanek at redhat.com (Jiri Vanek) Date: Fri, 26 Sep 2014 13:48:21 +0200 Subject: [rfc][icedtea-web][itweb-settings] itweb-settings use Option Parser In-Reply-To: <1795754452.11172633.1411680531876.JavaMail.zimbra@redhat.com> References: <2136433079.7489666.1411075684213.JavaMail.zimbra@redhat.com> <541C3995.2080104@redhat.com> <1888728818.9296441.1411419281545.JavaMail.zimbra@redhat.com> <54243024.5050109@redhat.com> <1795754452.11172633.1411680531876.JavaMail.zimbra@redhat.com> Message-ID: <54255285.6080406@redhat.com> Uff... Now you will hate me. I have changed my mind a bit, And i need we need to fix an ols parser a bit. At first inline Rest innline > > > itweb-settingsOptionParser-6.patch > > > diff -r 6d62f68fb037 launcher/launchers.in > --- a/launcher/launchers.in Mon Sep 22 17:10:07 2014 +0200 > +++ b/launcher/launchers.in Thu Sep 25 17:26:49 2014 -0400 > @@ -53,7 +53,7 @@ > *) > ARGS[$j]="$1" > j=$((j+1)) > - if [ "$1" = "-headless" ] ; then > + if [[ "$1" =~ -*headless ]] ; then > SPLASH="false" > fi > ;; Thsi is good. Please push as separate changeset (please let aazores/jie to check the changelog before push) > diff -r 6d62f68fb037 netx/net/sourceforge/jnlp/OptionsDefinitions.java > --- a/netx/net/sourceforge/jnlp/OptionsDefinitions.java Mon Sep 22 17:10:07 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/OptionsDefinitions.java Thu Sep 25 17:26:49 2014 -0400 > @@ -73,14 +73,14 @@ > TRUSTNONE("-Xtrustnone","BOTrustnone"), > JNLP("-jnlp","BOJnlp", NumberOfArguments.ONE), > //itweb settings > - NODASHHELP("help", "IBOHelp"), > - LIST("list", "IBOList"), > - GET("get", "name", "IBOGet"), > - INFO("info", "name", "IBOInfo"), > - SET("set", "name value", "IBOSet"), > - RESETALL("reset", "all", "IBOResetAll"), > - RESET("reset", "name", "IBOReset"), > - CHECK("check", "name", "IBOCheck"), > + NODASHHELP("-help", "IBOHelp"), we dont need this ;) This isnow duplication of HELP (maybe only the properties message needs tuning to suite both - if possible) otherwise wee need to go with some HELP2 (I prefer first) > + LIST("-list", "IBOList"), > + GET("-get", "name", "IBOGet", NumberOfArguments.ONE_OR_MORE), > + INFO("-info", "name", "IBOInfo", NumberOfArguments.ONE_OR_MORE), > + SET("-set", "name value", "IBOSet", NumberOfArguments.ONE_OR_MORE), > + RESETALL("-reset", "all", "IBOResetAll"), > + RESET("-reset", "name", "IBOReset", NumberOfArguments.ONE_OR_MORE), > + CHECK("-check", "name", "IBOCheck"), Otherwise this is good. > //policyeditor > //-help > FILE("-file", "policy_file", "PBOFile"), > @@ -160,8 +160,9 @@ > OPTIONS.GET, > OPTIONS.INFO, > OPTIONS.SET, > + OPTIONS.RESET, > OPTIONS.RESETALL, > - OPTIONS.RESET, > + OPTIONS.HEADLESS, > OPTIONS.CHECK > }); > } > diff -r 6d62f68fb037 netx/net/sourceforge/jnlp/controlpanel/CommandLine.java > --- a/netx/net/sourceforge/jnlp/controlpanel/CommandLine.java Mon Sep 22 17:10:07 2014 +0200 > +++ b/netx/net/sourceforge/jnlp/controlpanel/CommandLine.java Thu Sep 25 17:26:49 2014 -0400 > @@ -21,8 +21,6 @@ > import static net.sourceforge.jnlp.runtime.Translator.R; > > import java.io.IOException; > -import java.util.ArrayList; > -import java.util.Arrays; > import java.util.List; > import java.util.Map; > > @@ -37,16 +35,17 @@ > import net.sourceforge.jnlp.util.docprovider.TextsProvider; > import net.sourceforge.jnlp.util.docprovider.formatters.formatters.PlainTextFormatter; > import net.sourceforge.jnlp.util.logging.OutputController; > +import net.sourceforge.jnlp.util.optionparser.OptionParser; > > /** > * Encapsulates a command line interface to the deployment configuration. > *

    > - * The central method is {@link #handle(String[])}, which calls one of the > - * various 'handle' methods. The commands listed in {@link #allCommands} are > + * The central method is {@link #handle()}, which calls one of the > + * various 'handle' methods. The commands listed in OptionsDefinitions are > * supported. For each supported command, a method handleCOMMANDCommand exists. > * This method actually takes action based on the command. Generally, a > * printCOMMANDHelp method also exists, and prints out the help message for > - * that specific command. For example, see {@link #handleListCommand(List)} > + * that specific command. For example, see {@link #handleListCommand()} > * and {@link #printListHelp()}. > *

    > * Sample usage: > @@ -72,6 +71,7 @@ > > > DeploymentConfiguration config = null; > + private static OptionParser optionParser; > > /** > * Creates a new instance > @@ -125,11 +125,11 @@ > /** > * Handles the 'list' command > * > - * @param args the arguments to the list command > * @return result of handling the command. SUCCESS if no errors occurred. > */ > - public int handleListCommand(List args) { > - if (args.contains("help")) { > + public int handleListCommand() { > + List args = optionParser.getValues(OptionsDefinitions.OPTIONS.LIST); > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.NODASHHELP)) { > printListHelp(); > return SUCCESS; > } > @@ -169,33 +169,29 @@ > /** > * Handles the 'get' command. > * > - * @param args the arguments to the get command > * @return an integer representing success (SUCCESS) or error handling the > * get command. > */ > - public int handleGetCommand(List args) { > - if (args.contains("help")) { > + public int handleGetCommand() { > + List args = optionParser.getValues(OptionsDefinitions.OPTIONS.GET); > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.NODASHHELP)) { > printGetHelp(); > return SUCCESS; > } > > - if (args.size() != 1) { > - printGetHelp(); > - return ERROR; > - } > - > Map> all = config.getRaw(); > > - String key = args.get(0); > - String value = null; > - if (all.containsKey(key)) { > - value = all.get(key).getValue(); > - OutputController.getLogger().printOutLn(value); > - return SUCCESS; > - } else { > - OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownProperty", key)); > - return ERROR; > + for (String key : args) { > + String value = null; > + if (all.containsKey(key)) { > + value = all.get(key).getValue(); > + OutputController.getLogger().printOutLn(key+": "+value); > + } else { > + OutputController.getLogger().log(OutputController.Level.MESSAGE_ALL, R("CLUnknownProperty", key)); > + return ERROR; > + } > } > + return SUCCESS; > } > > /** > @@ -210,39 +206,46 @@ > /** > * Handles the 'set' command > * > - * @param args the arguments to the set command > * @return an integer indicating success (SUCCESS) or error in handling > * the command > */ > - public int handleSetCommand(List args) { > - if (args.contains("help")) { > + public int handleSetCommand() { > + List args = optionParser.getValues(OptionsDefinitions.OPTIONS.SET); > + args = OptionParser.splitListOnEquals(args); > + if (optionParser.hasOption(OptionsDefinitions.OPTIONS.NODASHHELP)) { > printSetHelp(); > return SUCCESS; > } > > - if (args.size() != 2) { > + if (args.size() % 2 != 0) { This is no go. This must be handeld by parser. on optionParser.getValues(OptionsDefinitions.OPTIONS.SET); parser must return you something "known" your choice if it is some special object of you,which contains key+value, or values separated by =, or always even numer of args (probably best). NBUt parser is who have to prepare it - and check it. (==die when non even result is at the end or whatever) > printSetHelp(); > return ERROR; > } > + String key = ""; > + String value; > > - String key = args.get(0); > - String value = args.get(1); > - > - if (config.getRaw().containsKey(key)) { > - Setting old = config.getRaw().get(key); > - if (old.getValidator() != null) { > - try { > - old.getValidator().validate(value); > - } catch (IllegalArgumentException e) { > - OutputController.getLogger().log(OutputController.Level.WARNING_ALL, R("CLIncorrectValue", old.getName(), value, old.getValidator().getPossibleValues())); > - OutputController.getLogger().log(e); > - return ERROR; > + for (String arg : args) { > + if (args.indexOf(arg) % 2 == 0) { same > + key = arg; > + } else { > + value = arg; > + if (config.getRaw().containsKey(key)) { > + Setting old = config.getRaw().get(key); ... snip. simialr issues. > + assertEquals("baseballbat", list.get(6)); > + } > + > } > \ No newline at end of file > Well what crossed my mind. at first - you must hanlde your set key=value in parser - that means new NUmberOfArguments value. Some EVEN_NUMBER_OR_WITHEQUALCHAR. ok? And then parser will figh tiwith it. Then I was thinking about the multiple options versus limited options. To introduce limited options, it really need new parameter into OPTIONS(String option, String helperString, String decriptionKey, NumberOfArguments numberOfArguments) { not instead NumberOfArguments, you got me wrong. *new*. So it will be OPTIONS(String option, String helperString, String decriptionKey, NumberOfArguments numberOfArguments, ArgumentOccurence oc) { where ArgumentOccurence is new enum with values like exactly one, one or more, unique.. or similar. Eg Xclearcahce is good candidate for NON_OR_UNIQUE (as it have no sensein other cases... And I'm still not sure with how to proceed with HELP - it clearly cannot be NONE_OR UNIQUE, but should be :D ) But his would need to be tuned as separate changeset *before* tthis patch (as it is independent patch toOptionPArser) However, as javaws have 99% of arguments asked like hasOption() (except -arg,-param -property", -update and -jnlp (and one null - the main arg) and those args are handled in main in order, and javaws is terinaed accordingly, and... well this sucks - only *first* of them have actually effect. The second one is silently ignored (?) - except mainarg - in this case javaws is terminated. On one side, it is really god to have so powerfull validation, on seconf, maybe it is to enforcing - thoughts? So I .. once javaws is so lenient to params, why not itweb-settings. And, with your original idea of allmighty interpreter - it will be even *simple* So my idea was. You have private final Map> parsedOptions; Lets change it to list! private final List where parsed option is NewClass contaiing OptionsDefinitions.OPTIONS, name and List params (dont forget about null mian param, and param-les soptions) - you may also move some(all?) verification (on number of params) logic to this class Now - you wil have to change hasOption method - but afaik it is all. In this parsedOptions you naow have all items, including the order. And of course validated values (both valid options only, and valid params only) So the itweb-stting cmd clinet, should do nothhing more, then iterate through this array, and evaluate each param.... Now - the best solution is probably *good* mixture of ArgumentOccurence and lanient list...I jsut can not see it. I'm on pto next week, please consult with jie/andrew/jacob/omair. Maybe in meantime you may adapt PolicyEditor to parser - it is much simple. But I would liek to verify tthe itweb-setting option parser before push. And of course you may discuse those list x ArgumentOccurence +/- Sorry for neverending itterations, but I'm still somehow unhappy about the state of this future. J. From bugzilla-daemon at icedtea.classpath.org Fri Sep 26 16:03:32 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 26 Sep 2014 16:03:32 +0000 Subject: [Bug 2006] Client queries too much data from vm-memory-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2006 Severin Gehwolf changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |2018 -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 26 16:03:32 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 26 Sep 2014 16:03:32 +0000 Subject: [Bug 2007] Client queries too much data from vm-cpu-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2007 Severin Gehwolf changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |2018 -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 26 16:14:05 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 26 Sep 2014 16:14:05 +0000 Subject: [Bug 2006] Client queries too much data from vm-memory-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2006 --- Comment #1 from Severin Gehwolf --- A reproducer is by applying the patch in the blocking bug, build thermostat, run thermostat web-storage-service and finally this: $ echo -e 'client-tester\ntester' | ./distribution/target/image/bin/thermostat vm-stat -a 0365d47b-206d-499b-92b8-cf8ff4b6ee14 -v d690d957-771f-4434-b841-626523414eb4 This throws IAE. java.lang.IllegalArgumentException: Refusing unbounded query! Query used Long.MIN_VALUE for 'since'! at com.redhat.thermostat.storage.core.VmLatestPojoListGetter.getLatest(VmLatestPojoListGetter.java:69) at com.redhat.thermostat.vm.cpu.common.internal.VmCpuStatDAOImpl.getLatestVmCpuStats(VmCpuStatDAOImpl.java:80) at com.redhat.thermostat.vm.cpu.client.cli.internal.VmCpuStatPrintDelegate.getLatestStats(VmCpuStatPrintDelegate.java:65) at com.redhat.thermostat.client.cli.internal.VMStatPrinter.printStats(VMStatPrinter.java:101) at com.redhat.thermostat.client.cli.internal.VMStatCommand.run(VMStatCommand.java:100) at com.redhat.thermostat.launcher.internal.LauncherImpl.parseArgsAndRunCommand(LauncherImpl.java:315) at com.redhat.thermostat.launcher.internal.LauncherImpl.runCommand(LauncherImpl.java:261) at com.redhat.thermostat.launcher.internal.LauncherImpl.runCommandFromArguments(LauncherImpl.java:250) at com.redhat.thermostat.launcher.internal.LauncherImpl.run(LauncherImpl.java:158) at com.redhat.thermostat.launcher.internal.LauncherImpl.run(LauncherImpl.java:138) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at com.redhat.thermostat.main.impl.FrameworkProvider.callVoidReflectedMethod(FrameworkProvider.java:276) at com.redhat.thermostat.main.impl.FrameworkProvider.runLauncher(FrameworkProvider.java:249) at com.redhat.thermostat.main.impl.FrameworkProvider.start(FrameworkProvider.java:101) at com.redhat.thermostat.main.Thermostat.start(Thermostat.java:85) at com.redhat.thermostat.main.Thermostat.main(Thermostat.java:57) -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 26 16:22:36 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 26 Sep 2014 16:22:36 +0000 Subject: [Bug 2007] Client queries too much data from vm-cpu-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2007 Severin Gehwolf changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |sgehwolf at redhat.com --- Comment #1 from Severin Gehwolf --- A reproducer is by applying the patch in the blocking bug, build thermostat, run thermostat web-storage-service, then thermostat gui and clicking on the "CPU" tab of a selected VM of a host. You'll see this stack trace in the terminal where you've started thermostat gui: java.lang.IllegalArgumentException: Refusing unbounded query! Query used Long.MIN_VALUE for 'since'! at com.redhat.thermostat.storage.core.VmLatestPojoListGetter.getLatest(VmLatestPojoListGetter.java:69) at com.redhat.thermostat.vm.cpu.common.internal.VmCpuStatDAOImpl.getLatestVmCpuStats(VmCpuStatDAOImpl.java:80) at com.redhat.thermostat.vm.cpu.client.core.internal.VmCpuController.doUpdateVmCpuCharts(VmCpuController.java:113) at com.redhat.thermostat.vm.cpu.client.core.internal.VmCpuController.access$000(VmCpuController.java:62) at com.redhat.thermostat.vm.cpu.client.core.internal.VmCpuController$1.run(VmCpuController.java:81) at com.redhat.thermostat.common.ThreadPoolTimerFactory$ExceptionPrintingRunnable.run(ThreadPoolTimerFactory.java:148) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 26 16:34:40 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 26 Sep 2014 16:34:40 +0000 Subject: [Bug 2020] Client queries too much data from vm-class-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2020 Severin Gehwolf changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 26 16:34:48 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 26 Sep 2014 16:34:48 +0000 Subject: [Bug 2019] Client queries too much data from vm-gc-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2019 Severin Gehwolf changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|omajid at redhat.com |unassigned at icedtea.classpat | |h.org -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 26 16:48:23 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 26 Sep 2014 16:48:23 +0000 Subject: [Bug 2021] New: Evolve storage cursor API Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2021 Bug ID: 2021 Summary: Evolve storage cursor API Product: Thermostat Version: hg Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: Thermostat Assignee: unassigned at icedtea.classpath.org Reporter: sgehwolf at redhat.com CC: thermostat at icedtea.classpath.org The current Cursor[1] storage API is insufficient. There is currently no way to use the current Cursor API and fetch results in a reasonable way. It's currently all-or-nothing (or at least implementation dependent). We should at least add the following API in order to be able to limit result sets and be able to skip over values: Cursor.limit(int); Cursor.skip(int); Preferably also add: Cursor.setBatchSize(int); [1] http://icedtea.classpath.org/thermostat/docs/1.0/javadocs/com/redhat/thermostat/storage/core/Cursor.html -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Fri Sep 26 18:16:27 2014 From: jkang at redhat.com (Jie Kang) Date: Fri, 26 Sep 2014 14:16:27 -0400 (EDT) Subject: [rfc][icedtea-web] Makefile New Whitelisted-Dist-Test option In-Reply-To: <5422E4AA.4020602@redhat.com> References: <1294941468.9304595.1411420667650.JavaMail.zimbra@redhat.com> <542162C3.1010400@redhat.com> <1201728781.9838431.1411496217760.JavaMail.zimbra@redhat.com> <5422E4AA.4020602@redhat.com> Message-ID: <450874635.11644392.1411755387742.JavaMail.zimbra@redhat.com> ----- Original Message ----- > On 09/23/2014 08:16 PM, Jie Kang wrote: > > ----- Original Message ----- > >> >On 09/22/2014 11:17 PM, Jie Kang wrote: > >>> > >Hello, > >>> > > > >>> > >This patch expands on the Makefile Reproducer Test patch [1]. > >>> > > > >>> > >[1] > >>> > >http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-September/029581.html > >>> > > > >>> > > > >>> > >There is now a new make rule: 'run-netx-whitelisted-dist-tests' > >>> > > > >>> > >This rule runs the reproducers similar to 'run-netx-dist-tests', > >>> > >except it > >>> > >only processes (compiles, etc.) the resources filtered by the > >>> > >whitelist. > >>> > > > >>> > >As well, the rule 'run-netx-dist-tests' has now reverted back to > >>> > >processing > >>> > >all resources (ie. what it used to do before the Makefile Reproducer > >>> > >Test > >>> > >patch [1]) > >>> > > > >>> > >Thoughts? > >>> > > > >>> > >Just a note, the purpose of the "stamps/whitelist-filter.stamp" rule > >>> > >having: > >>> > > echo ".*" ... > >>> > >is to maintain compatibility. Though the "all-whitelist" rule also > >>> > >contains > >>> > >duplicate code, there can be situations where neither "all-whitelist" > >>> > >or > >>> > >"filtered-whitelist" are not called. E.g. if user runs "make > >>> > >stamps/netx-dist-tests-prepare-reproducers.stamp". This is the > >>> > >solution I > >>> > >came up with to allow for all possible make commands to continue to > >>> > >work > >>> > >and for the user to be able to quickly switch between running "make > >>> > >run-netx-dist-tests" and "make run-netx-whitelisted-dist-tests" > >>> > >without > >>> > >always having to perform "make clean-netx-dist-tests". I guess a TLDR > >>> > >is > >>> > >that it's to prevent regressions. > >>> > > > >>> > >If this patch is accepted I will update the wiki and documentation for > >>> > >this > >>> > >feature. > >>> > > > >>> > > > >>> > >Regards, > >>> > > > >> > > >> >Hm. only hint to approach. Why not configure switch? This seems to me > >> >overcomplexed. What is > >> >advantage of this? > > Hello, > > > > I have attached a completely new patch that follows your hint. Thanks a > > lot, it is much better now, and more simple. > > New option for configure: --enable-whitelist-processing > > > > With the flag on, the Makefile generated will filter by whitelist for > > processing, otherwise, it will process all, just like before patch [1]. > > > > [1]http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2014-September/029581.html > > > >> >Once the new and old targets will be run in unpredicted order, the result > >> >can > >> >be unpredictible. > > The complexity was to make sure running new and old targets in random order > > still worked hahah. And you could run them and stop them whenever, and > > still work properly like before too! But now no longer needed so... > > > >> >Also I can not see the reverted part in patch. > > There wasn't really any reversion in code, just reversion in behaviour. > > Anyways, no longer relevant. > > > > > > Thanks a lot!! > > > > > > Regards, > > > >> > > >> >J. > >> > > > -- Jie Kang > > > > > > itw-make-configure-whitelist-1.patch > > > > > > diff --git a/Makefile.am b/Makefile.am > > --- a/Makefile.am > > +++ b/Makefile.am > > @@ -178,6 +178,12 @@ > > endif > > endif > > > > +if ENABLE_WHITELIST > > +WHITELIST=`cat $(REPRODUCERS_CLASS_WHITELIST)` > > +else > > +WHITELIST=.* > > +endif > > + > > if WITH_RHINO > > RHINO_TESTS=stamps/check-pac-functions.stamp > > else > > @@ -691,26 +697,23 @@ > > mkdir -p $(REPRODUCERS_BUILD_DIR) > > touch $@ > > > > -junit-jnlp-dist-custom.txt: $(REPRODUCERS_CLASS_WHITELIST) > > +junit-jnlp-dist-custom.txt: > > cd $(REPRODUCERS_TESTS_SRCDIR)/$(CUSTOM_REPRODUCERS)/ ; \ > > - whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ > > - for x in $$whiteListed ; do \ > > + for x in $(WHITELIST) ; do \ > > find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > > > $(abs_top_builddir)/$@ || true ; \ > > done > > > > -junit-jnlp-dist-simple.txt: $(REPRODUCERS_CLASS_WHITELIST) > > +junit-jnlp-dist-simple.txt: > > cd $(REPRODUCERS_TESTS_SRCDIR)/simple/ ; \ > > - whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ > > - for x in $$whiteListed ; do \ > > + for x in $(WHITELIST) ; do \ > > find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > > > $(abs_top_builddir)/$@ || true ; \ > > done > > > > -stamps/junit-jnlp-dist-signed.stamp: $(REPRODUCERS_CLASS_WHITELIST) > > +stamps/junit-jnlp-dist-signed.stamp: > > types=($(SIGNED_REPRODUCERS)) ; \ > > for which in "$${types[@]}" ; do \ > > pushd $(REPRODUCERS_TESTS_SRCDIR)/$$which/ ; \ > > - whiteListed=`cat $(REPRODUCERS_CLASS_WHITELIST)`; \ > > - for x in $$whiteListed ; do \ > > + for x in $(WHITELIST) ; do \ > > find . -maxdepth 1 -mindepth 1 | sed "s/.\/*//" | grep $$x > > > $(abs_top_builddir)/junit-jnlp-dist-$$which.txt ; \ > > done ; \ > > popd ; \ > > diff --git a/configure.ac b/configure.ac > > --- a/configure.ac > > +++ b/configure.ac > > @@ -28,6 +28,14 @@ > > AM_CONDITIONAL([ENABLE_DOCS], [test x$ENABLE_DOCS = xyes]) > > AC_MSG_RESULT(${ENABLE_DOCS}) > > > > +AC_MSG_CHECKING([whether to process reproducers using whitelist]) > > +AC_ARG_ENABLE([whitelist-processing], > > + [AS_HELP_STRING([--enable-whitelist-processing], > > + [Enable processing of reproducers using whitelist])], > > I would probably reflector those sentences. Even to me they are not much > describing. > Try to debug those sentences with somebody who never seen itw or our > testuite :) Once he understood > the help message, it is right. > > for ideas: > AC_MSG_CHECKING([whether to process reproducers using whitelist]) > - this will be nearly correct if you adapt my idea lower. No it imho is > not, and should be like > "whether to compile and deploy reproducers using filtering described > whitelist" > AC_ARG_ENABLE([whitelist-processing], > [AS_HELP_STRING([--enable-whitelist-processing], > [Enable processing of reproducers using whitelist])], > Same: > "Enable compilation and deploy of reproducers using filtering described > whitelist" > > In this or in (below) suggested approach, I would like to mention all three > targets (or more?) when > the whitelist is used - compile, deploy run (some more?) Hello, I've altered the messages to explain the purpose better. Does it look okay to you? +AC_MSG_CHECKING([whether to filter by whitelist when processing, compiling and running reproducers]) +AC_ARG_ENABLE([whitelist-processing], + [AS_HELP_STRING([--enable-whitelist-processing], + [Enable whitelist filter when processing, compiling and running reproducers])], > > + [ENABLE_WHITELIST="${enableval}"], [ENABLE_WHITELIST='no']) > > +AM_CONDITIONAL([ENABLE_WHITELIST], [test x$ENABLE_WHITELIST = xyes]) > > +AC_MSG_RESULT(${ENABLE_WHITELIST}) > > + > > AC_PATH_PROG([BIN_BASH], [bash],, [/bin]) > > if test x"$BIN_BASH" = x ; then > > AC_MSG_ERROR([/bin/bash is used in runtime and for about generation. > > Dying sooner rather then later]) > > > > > Except this, looks ok. > > Well - one general hint. > > Right now, if ENABLE_WHITELIST is true, then: > - only reprodcuers matching regeexes in list are compiled, deployed and run > if ENABLE_WHITELIST is false then: > - all reprodcuers are compiled and deployed, but only reprodcuers matching > regeexes in whitelist > are run. > > > I was thinking about to unifying it > - only reprodcuers matching regeexes in list are compiled, deployed and run > if ENABLE_WHITELIST is false then: > - all reprodcuers are compiled and deployed, and run > I think this is a good idea as well. The attached patch does this. Can you check to make sure it looks okay? (changes start at "-$(REPRODUCERS_CLASS_NAMES): $(REPRODUCERS_CLASS_WHITELIST)") Or should this be in another changeset? > > Well - this have question - what to do with current whitelist. To kept it in > repo enad ampty? As it > is? To rmeove? I probably incline to first one. I think keeping it as is fine. Having the ".*" is good. Making it empty might make it confusing as to why it is in repo..; If we want to remove it I think we'd need a patch to let user supply the whitelist file location since we can't guarantee it exists with the same name anymore.; Regards, > > J. > -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-make-configure-whitelist-2.patch Type: text/x-patch Size: 3585 bytes Desc: not available URL: From bugzilla-daemon at icedtea.classpath.org Fri Sep 26 19:14:45 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Fri, 26 Sep 2014 19:14:45 +0000 Subject: [Bug 2007] Client queries too much data from vm-cpu-stats In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2007 Omair Majid changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|unassigned at icedtea.classpat |omajid at redhat.com |h.org | --- Comment #2 from Omair Majid --- I am working on a gui-client fix for this. -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jkang at redhat.com Fri Sep 26 20:41:07 2014 From: jkang at redhat.com (Jie Kang) Date: Fri, 26 Sep 2014 16:41:07 -0400 (EDT) Subject: [rfc][icedtea-web] Cache Locking Tests : Potential Deadlock Fix In-Reply-To: <20140925162444.GA9482@redhat.com> References: <2103989617.9655152.1411481967464.JavaMail.zimbra@redhat.com> <1240968037.9688595.1411484857305.JavaMail.zimbra@redhat.com> <20140924170851.GB9537@redhat.com> <936247043.10480762.1411588303412.JavaMail.zimbra@redhat.com> <935547535.10521973.1411592146362.JavaMail.zimbra@redhat.com> <20140925162444.GA9482@redhat.com> Message-ID: <1588253831.11700001.1411764067242.JavaMail.zimbra@redhat.com> ----- Original Message ----- > * Jie Kang [2014-09-24 17:07]: > > After some more suggestions from Omair, here is a revised and > > hopefully decent patch ^^ > > > > A CountDownLatch has been used in place of previous 'countdown-like' > > implementation and timeouts have been added so the tests won't cause > > any problems (apart from failing) if they somehow run forever. > > > > > > Thanks for all the help! > > You are welcome! > > > > ----- Original Message ----- > > > [3] LockedFile.java > > > public void unlock() throws IOException { > > > if (JNLPRuntime.isWindows() || > > > !this.threadLock.isHeldByCurrentThread()) { > > > return; > > > } > > > ... > > > > > > Should this be changed? I am thinking of making all the void functions > > > return > > > booleans so callers can tell if locks/unlocks are successful, but the > > > original code was all void so I was reluctant. > > FWIW, I think it should be changed to throw an error if the lock is not > held. If a code implements methods from the Lock interface, it should > try and follow the semantics (where possible) closely too. If it does > not follow them, it should at least be documented. Hello, Right. I will document it for now and then look at altering it to throw an error in another changeset. Technically the Lock interface specifies that actions taken on invalid unlocks is up to the implementation [1] [1] http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/locks/Lock.html#unlock() > > > + //Check if input string contains only one instance of given substring > > + private boolean containsSingle(String in, String substr) { > > Call the method something like `stringContainsOnlySingleIntance(String > input, String substring)` and you wont need the comment :) > > > + int start = in.indexOf(substr); //first match > > Maybe call it `int firstMatch`, then? > > > + String restOfString = in.substring(start+substr.length()); > > + > > + return !substr.contains(restOfString ); > > } > > Another implementation might be: > > int firstIndex = in.indexOf(substr); > int lastIndex = in.lastIndexOf(substr); > boolean containsString = firstIndex != -1; > boolean onlyOneInstance = firstIndex == lastIndex; > return constainsString && onlyOneInstance; Changed. Thanks! > > > + //Wait for writers to be done; > > + try { > > + writerSignal.await(); > > The comment makes me think the latch should be named `writersDone`. Right. > > > + } catch (InterruptedException e) { > > + e.printStackTrace(); > > Can you make this fail the test? Yep. > > > + } > > long lastModified = entry.getLastModified(); > > - executorService.execute(new WriteRunnable(":read:" + > > lastModified)); > > + synchronized (out) { > > + out.println(":read:" + lastModified); > > + out.flush(); > > + } > > I am a little confused here. When you run this test, does the > `writerSignal.await()` mean that the writer is done and (possibly!) > unlocked the lock? What is this test testing in that case? Ah you are right, the functionality of the test was lost in all the changes. I have made changes so that this test actually causes the read to be attempted after the write, while the write still has the lock. > > > + //Let people know reading is done > > There's nothing that does what the comment says :( Right. It was removed with the addition of the CountDownLatches :( Sorry about that. > > > +++ b/tests/netx/unit/net/sourceforge/jnlp/cache/CacheLRUWrapperTest.java > > > @@ -99,36 +93,35 @@ > > > > final File cacheIndexFile = new File(clw.cacheDir + File.separator > > + cacheIndexFileName); > > cacheIndexFile.delete(); > > - try{ > > - > > - int noLoops = 1000; > > + try { > > + int noLoops = 1000; > > > > - long time[] = new long[noLoops]; > > + long time[] = new long[noLoops]; > > > > - clw.lock(); > > - clearCacheIndexFile(); > > + clw.lock(); > > + clearCacheIndexFile(); > > > > - fillCacheIndexFile(noEntriesCacheFile); > > - clw.store(); > > + fillCacheIndexFile(noEntriesCacheFile); > > + clw.store(); > > > > - // FIXME: wait a second, because of file modification timestamp > > only provides accuracy on seconds. > > - Thread.sleep(1000); > > + // FIXME: wait a second, because of file modification > > timestamp only provides accuracy on seconds. > > + Thread.sleep(1000); > > > > - long sum = 0; > > - for(int i=0; i < noLoops - 1; i++) { > > - time[i]= System.nanoTime(); > > - clw.load(); > > - time[i+1]= System.nanoTime(); > > - if(i==0) > > - continue; > > - sum = sum + time[i] - time[i-1]; > > - } > > - > > - double avg = sum / time.length; > > - ServerAccess.logErrorReprint("Average = " + avg + "ns"); > > + long sum = 0; > > + for(int i=0; i < noLoops - 1; i++) { > > + time[i]= System.nanoTime(); > > + clw.load(); > > + time[i+1]= System.nanoTime(); > > + if(i==0) > > + continue; > > + sum = sum + time[i] - time[i-1]; > > + } > > > > - // wait more than 100 microseconds for noLoops = 1000 and > > noEntries=1000 is bad > > - assertTrue("load() must not take longer than 100 ??s, but took in > > avg " + avg/1000 + "??s", avg < 100 * 1000); > > + double avg = sum / time.length; > > + ServerAccess.logErrorReprint("Average = " + avg + "ns"); > > + > > + // wait more than 100 microseconds for noLoops = 1000 and > > noEntries=1000 is bad > > + assertTrue("load() must not take longer than 100 ??s, but took > > in avg " + avg/1000 + "??s", avg < 100 * 1000); > > This is just an indentation change, right? I don't see code changes. Yes. > > > + //Check if input string contains only one instance of given substring > > + private boolean containsSingle(String in, String substr) { > > A duplicate method? Please put it in some shared code. Done. It's been placed in a class called CacheTestUtils. Thanks!! > > Thanks, > Omair > > -- > PGP Key: 66484681 (http://pgp.mit.edu/) > Fingerprint = F072 555B 0A17 3957 4E95 0056 F286 F14F 6648 4681 > -- Jie Kang -------------- next part -------------- A non-text attachment was scrubbed... Name: itw-cachelock-deadlock-6.patch Type: text/x-patch Size: 18942 bytes Desc: not available URL: From gitne at gmx.de Sat Sep 27 11:15:45 2014 From: gitne at gmx.de (Jacob Wisor) Date: Sat, 27 Sep 2014 13:15:45 +0200 Subject: [rfc][icedtea-web] IcedTea-Web for Windows In-Reply-To: <5416FBA6.2040908@guru.se> References: <5410FCF8.7040600@gmx.de> <5416FBA6.2040908@guru.se> Message-ID: <54269C61.5060209@gmx.de> On 09/15/2014 at 04:45 PM, Mattias Eliasson wrote: > Hi! > > I have previously discussed using FireBreath as a plugin abstraction layer for > icedtea-web. It provides a C++ abstraction layer on top of both NPAPI and IE:s > COM/OLE/ActiveX plugin API. I argued that it would make icedtea-web cleaner by > hiding all the NPAPI stuff, but it's oven more valid in this use case. We do not want to hide any NPAPI stuff. As I have already told you, hiding (do not confuse with encapsulation) and abstraction layers come always with loss of information and sometimes even loss of access to lower layers. This will definitely pose problems with FireBreath when trying to tie JVM ends with Windows specific ends. > As you are planning to use add the IE API you should consider using FireBreath > instead, and hopefully it will also solve your NPAPI worries. You do not > implement a IOleObject interface with FB, it generates one for you. Again, as I have already told you, I have looked at FireBreath and I am even more convinced today that it would be a bulky unnecessary dependency to the IcedTea-Web plug-in. It requires even Boost and Python to build. This is just unacceptable for having a slim code base with a simple build system. It is ridiculous to have 10+ other dependencies to build just one dependency which is of little to no use. The IcedTea-Web plug-in does not do anything complicated which would justify such an immense cost. This is like to use a sledgehammer to crack a nut. Oh btw, there are *no* problems with the NPAPI. The NPAPI is very simple and easy to implement. If you seem to have problems with the NPAPI or have found any bugs in the IcedTea-Web plug-in, why don't you simply report them (or fix them yourself) instead of childishly insisting on the IcedTea-Web developers to support some sort of your favorite library, in the delusional hope that /all/ problems would be solved then? > I totally agree with you on the need for a Windows/IE plugin and I wish I had > the time to work on this myself. You are free to implement your own version. ;-) With or without FireBreath. Jacob From bugzilla-daemon at icedtea.classpath.org Sun Sep 28 04:06:29 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Sun, 28 Sep 2014 04:06:29 +0000 Subject: [Bug 2022] New: SweetHome3d closes when Preferences is selected Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2022 Bug ID: 2022 Summary: SweetHome3d closes when Preferences is selected Product: IcedTea Version: unspecified Hardware: x86_64 OS: Linux Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: juant at verizon.net CC: unassigned at icedtea.classpath.org Created attachment 1181 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1181&action=edit his is the error file produced after closure of program 1. start SweetHome3d 2. select File 3. select Preferences 4. program closes no report unless the program is run from the terminal. Terminal report: Java 3D: implicit antialiasing enabled # # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007f39c37b45c9, pid=6115, tid=139886042572544 # # JRE version: OpenJDK Runtime Environment (7.0_65-b32) (build 1.7.0_65-b32) # Java VM: OpenJDK 64-Bit Server VM (24.65-b04 mixed mode linux-amd64 compressed oops) # Derivative: IcedTea 2.5.2 # Distribution: Ubuntu 14.04 LTS, package 7u65-2.5.2-3~14.04 # Problematic frame: # C [libGL.so.1+0x425c9] # # Core dump written. Default location: /usr/share/sweethome3d/core or core.6115 # # An error report file with more information is saved as: # /tmp/hs_err_pid6115.log # # If you would like to submit a bug report, please include # instructions on how to reproduce the bug and visit: # http://icedtea.classpath.org/bugzilla # The crash happened outside the Java Virtual Machine in native code. # See problematic frame for where to report the bug. # Aborted (core dumped) I will attach the error log -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 29 08:27:27 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 29 Sep 2014 08:27:27 +0000 Subject: [Bug 2023] New: JVM crash - seg fault Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2023 Bug ID: 2023 Summary: JVM crash - seg fault Product: IcedTea Version: 2.5.2 Hardware: x86_64 OS: Linux Status: NEW Severity: major Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: dbirch at perforce.com CC: unassigned at icedtea.classpath.org Created attachment 1182 --> http://icedtea.classpath.org/bugzilla/attachment.cgi?id=1182&action=edit Full crash log In normal operation of my code, I see one of the following three messages, there is normally no proper crash report, just one of these messages written to std out: *** Error in `/usr/lib/jvm/java-7-openjdk-amd64/bin/java': double free or corruption (!prev): 0x00007f0f0c2feaf0 *** *** Error in `/usr/lib/jvm/java-7-openjdk-amd64/bin/java': free(): invalid pointer: 0x00007fb988466f30 *** *** Error in `/usr/lib/jvm/java-7-openjdk-amd64/bin/java': free(): invalid size: 0x00007f57cc601de0 *** On trying to debug through and find out where in my code this fault was occurring, I managed to get it down to during the TestNG reporters running at the end of my test run, and actually managed to get eclipse to spit out a crash report: # # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007fd195a55ceb, pid=14757, tid=140537927476992 # # JRE version: OpenJDK Runtime Environment (7.0_65-b32) (build 1.7.0_65-b32) # Java VM: OpenJDK 64-Bit Server VM (24.65-b04 mixed mode linux-amd64 compressed oops) # Derivative: IcedTea 2.5.2 # Distribution: Ubuntu 14.04 LTS, package 7u65-2.5.2-3~14.04 # Problematic frame: # V [libjvm.so+0x7c9ceb] os::is_interrupted(Thread*, bool)+0xb # # Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again # # An error report file with more information is saved as: # /home/dbirch/Perforce/dbirch-linux-testforce/hs_err_pid14757.log [TestNG] Time taken by org.testng.reporters.SuiteHTMLReporter at 4b8899ad: 68 ms # I've attached the full log file to the bug, hope it helps with reproduction. >From my experience, I am running a number of tests around a remote NIO file system, using ssh & scp (provided by the sshj library). The code run is the first 5 tests I've written to test this, run individually the tests run with no issue, run together the JVM crashes 100% of the time with one of the above errors, so I'm wondering if it might be memory related. I recently changed the code slightly try to work around the issue, prior to the code changes I was seeing an addition error: *** Error in `/usr/lib/jvm/java-7-openjdk-amd64/bin/java': corrupted doubly-linked list (or very similar) Let me know if you need more info, a core dump or if I need to put some code together for you to reproduce the scenario. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 29 08:49:59 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 29 Sep 2014 08:49:59 +0000 Subject: [Bug 2023] JVM crash - seg fault In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2023 Dave Birch changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|major |normal -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Mon Sep 29 14:35:14 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 29 Sep 2014 14:35:14 +0000 Subject: [Bug 2022] SweetHome3d closes when Preferences is selected In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2022 Xerxes R?nby changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |xerxes at zafena.se Resolution|--- |INVALID --- Comment #1 from Xerxes R?nby --- I will close this bug as invalud because it happened in native code part of the mesa3d project thus this bug is not caused by any part of the IcedTea project. /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1 libGL originate from the Mesa 3D project [0] I reccomend that you to report this bug to your linux distribution that package this version of mesa, java3d and sweethome3d. The package you use are using and old versions java3d. /usr/share/java/j3dcore-1.5.2+dfsg.jar <- this version has not been updated since 2008 and is no longer maintained.[1] According to the readme in the latest version of sweethome3d [2] your linux distribution should package the community maintained version of java3d 1.6 Java 3D 1.6 libraries used for Java 7 are available at: http://jogamp.org/deployment/java3d/ and source code can be dosnwloaded at: http://github.com/hharrison/java3d-core/ http://github.com/hharrison/java3d-utils/ http://github.com/hharrison/vecmath/ [0] http://www.mesa3d.org/ [1] http://en.wikipedia.org/wiki/Java_3D [2] http://sourceforge.net/projects/sweethome3d -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew at icedtea.classpath.org Mon Sep 29 16:08:15 2014 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 29 Sep 2014 16:08:15 +0000 Subject: /hg/release/icedtea7-forest-2.5/jdk: 7122142: (ann) Race conditi... Message-ID: changeset 828993403102 in /hg/release/icedtea7-forest-2.5/jdk details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.5/jdk?cmd=changeset;node=828993403102 author: dmeetry date: Sat Mar 08 01:40:14 2014 +0400 7122142: (ann) Race condition between isAnnotationPresent and getAnnotations 7185456: (ann) Optimize Annotation handling in java/sun.reflect.* code for small number of annotations 8005232: (JEP-149) Class Instance size reduction 8022721: TEST_BUG: AnnotationTypeDeadlockTest.java throws java.lang.IllegalStateException: unexpected condition Reviewed-by: jfranck, plevart, robilad diffstat: src/share/classes/java/lang/Class.java | 242 ++++++--- src/share/classes/java/lang/System.java | 9 +- src/share/classes/sun/misc/JavaLangAccess.java | 12 +- src/share/classes/sun/reflect/annotation/AnnotationParser.java | 67 ++- src/share/classes/sun/reflect/annotation/AnnotationType.java | 69 +- test/java/lang/annotation/AnnotationType/AnnotationTypeDeadlockTest.java | 101 ++++ test/java/lang/annotation/AnnotationType/AnnotationTypeRuntimeAssumptionTest.java | 187 +++++++ 7 files changed, 552 insertions(+), 135 deletions(-) diffs (truncated from 1008 to 500 lines): diff -r 59ce33d99e27 -r 828993403102 src/share/classes/java/lang/Class.java --- a/src/share/classes/java/lang/Class.java Mon Sep 22 15:44:14 2014 +0100 +++ b/src/share/classes/java/lang/Class.java Sat Mar 08 01:40:14 2014 +0400 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1994, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1994, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2338,44 +2338,110 @@ } /** + * Atomic operations support. + */ + private static class Atomic { + // initialize Unsafe machinery here, since we need to call Class.class instance method + // and have to avoid calling it in the static initializer of the Class class... + private static final Unsafe unsafe = Unsafe.getUnsafe(); + // offset of Class.reflectionData instance field + private static final long reflectionDataOffset; + // offset of Class.annotationType instance field + private static final long annotationTypeOffset; + + static { + Field[] fields = Class.class.getDeclaredFields0(false); // bypass caches + reflectionDataOffset = objectFieldOffset(fields, "reflectionData"); + annotationTypeOffset = objectFieldOffset(fields, "annotationType"); + } + + private static long objectFieldOffset(Field[] fields, String fieldName) { + Field field = searchFields(fields, fieldName); + if (field == null) { + throw new Error("No " + fieldName + " field found in java.lang.Class"); + } + return unsafe.objectFieldOffset(field); + } + + static boolean casReflectionData(Class clazz, + SoftReference> oldData, + SoftReference> newData) { + return unsafe.compareAndSwapObject(clazz, reflectionDataOffset, oldData, newData); + } + + static boolean casAnnotationType(Class clazz, + AnnotationType oldType, + AnnotationType newType) { + return unsafe.compareAndSwapObject(clazz, annotationTypeOffset, oldType, newType); + } + } + + /** * Reflection support. */ // Caches for certain reflective results private static boolean useCaches = true; - private volatile transient SoftReference declaredFields; - private volatile transient SoftReference publicFields; - private volatile transient SoftReference declaredMethods; - private volatile transient SoftReference publicMethods; - private volatile transient SoftReference[]> declaredConstructors; - private volatile transient SoftReference[]> publicConstructors; - // Intermediate results for getFields and getMethods - private volatile transient SoftReference declaredPublicFields; - private volatile transient SoftReference declaredPublicMethods; + + // reflection data that might get invalidated when JVM TI RedefineClasses() is called + static class ReflectionData { + volatile Field[] declaredFields; + volatile Field[] publicFields; + volatile Method[] declaredMethods; + volatile Method[] publicMethods; + volatile Constructor[] declaredConstructors; + volatile Constructor[] publicConstructors; + // Intermediate results for getFields and getMethods + volatile Field[] declaredPublicFields; + volatile Method[] declaredPublicMethods; + // Value of classRedefinedCount when we created this ReflectionData instance + final int redefinedCount; + + ReflectionData(int redefinedCount) { + this.redefinedCount = redefinedCount; + } + } + + private volatile transient SoftReference> reflectionData; // Incremented by the VM on each call to JVM TI RedefineClasses() // that redefines this class or a superclass. private volatile transient int classRedefinedCount = 0; - // Value of classRedefinedCount when we last cleared the cached values - // that are sensitive to class redefinition. - private volatile transient int lastRedefinedCount = 0; + // Lazily create and cache ReflectionData + private ReflectionData reflectionData() { + SoftReference> reflectionData = this.reflectionData; + int classRedefinedCount = this.classRedefinedCount; + ReflectionData rd; + if (useCaches && + reflectionData != null && + (rd = reflectionData.get()) != null && + rd.redefinedCount == classRedefinedCount) { + return rd; + } + // else no SoftReference or cleared SoftReference or stale ReflectionData + // -> create and replace new instance + return newReflectionData(reflectionData, classRedefinedCount); + } - // Clears cached values that might possibly have been obsoleted by - // a class redefinition. - private void clearCachesOnClassRedefinition() { - if (lastRedefinedCount != classRedefinedCount) { - declaredFields = publicFields = declaredPublicFields = null; - declaredMethods = publicMethods = declaredPublicMethods = null; - declaredConstructors = publicConstructors = null; - annotations = declaredAnnotations = null; + private ReflectionData newReflectionData(SoftReference> oldReflectionData, + int classRedefinedCount) { + if (!useCaches) return null; - // Use of "volatile" (and synchronization by caller in the case - // of annotations) ensures that no thread sees the update to - // lastRedefinedCount before seeing the caches cleared. - // We do not guard against brief windows during which multiple - // threads might redundantly work to fill an empty cache. - lastRedefinedCount = classRedefinedCount; + while (true) { + ReflectionData rd = new ReflectionData<>(classRedefinedCount); + // try to CAS it... + if (Atomic.casReflectionData(this, oldReflectionData, new SoftReference<>(rd))) { + return rd; + } + // else retry + oldReflectionData = this.reflectionData; + classRedefinedCount = this.classRedefinedCount; + if (oldReflectionData != null && + (rd = oldReflectionData.get()) != null && + rd.redefinedCount == classRedefinedCount) { + return rd; + } } } @@ -2403,7 +2469,7 @@ } // Annotations handling - private native byte[] getRawAnnotations(); + native byte[] getRawAnnotations(); native ConstantPool getConstantPool(); @@ -2418,27 +2484,19 @@ // via ReflectionFactory.copyField. private Field[] privateGetDeclaredFields(boolean publicOnly) { checkInitted(); - Field[] res = null; - if (useCaches) { - clearCachesOnClassRedefinition(); - if (publicOnly) { - if (declaredPublicFields != null) { - res = declaredPublicFields.get(); - } - } else { - if (declaredFields != null) { - res = declaredFields.get(); - } - } + Field[] res; + ReflectionData rd = reflectionData(); + if (rd != null) { + res = publicOnly ? rd.declaredPublicFields : rd.declaredFields; if (res != null) return res; } // No cached value available; request value from VM res = Reflection.filterFields(this, getDeclaredFields0(publicOnly)); - if (useCaches) { + if (rd != null) { if (publicOnly) { - declaredPublicFields = new SoftReference<>(res); + rd.declaredPublicFields = res; } else { - declaredFields = new SoftReference<>(res); + rd.declaredFields = res; } } return res; @@ -2449,12 +2507,10 @@ // via ReflectionFactory.copyField. private Field[] privateGetPublicFields(Set> traversedInterfaces) { checkInitted(); - Field[] res = null; - if (useCaches) { - clearCachesOnClassRedefinition(); - if (publicFields != null) { - res = publicFields.get(); - } + Field[] res; + ReflectionData rd = reflectionData(); + if (rd != null) { + res = rd.publicFields; if (res != null) return res; } @@ -2487,8 +2543,8 @@ res = new Field[fields.size()]; fields.toArray(res); - if (useCaches) { - publicFields = new SoftReference<>(res); + if (rd != null) { + rd.publicFields = res; } return res; } @@ -2511,18 +2567,10 @@ // instead be copied via ReflectionFactory.copyConstructor. private Constructor[] privateGetDeclaredConstructors(boolean publicOnly) { checkInitted(); - Constructor[] res = null; - if (useCaches) { - clearCachesOnClassRedefinition(); - if (publicOnly) { - if (publicConstructors != null) { - res = publicConstructors.get(); - } - } else { - if (declaredConstructors != null) { - res = declaredConstructors.get(); - } - } + Constructor[] res; + ReflectionData rd = reflectionData(); + if (rd != null) { + res = publicOnly ? rd.publicConstructors : rd.declaredConstructors; if (res != null) return res; } // No cached value available; request value from VM @@ -2531,11 +2579,11 @@ } else { res = getDeclaredConstructors0(publicOnly); } - if (useCaches) { + if (rd != null) { if (publicOnly) { - publicConstructors = new SoftReference<>(res); + rd.publicConstructors = res; } else { - declaredConstructors = new SoftReference<>(res); + rd.declaredConstructors = res; } } return res; @@ -2552,27 +2600,19 @@ // via ReflectionFactory.copyMethod. private Method[] privateGetDeclaredMethods(boolean publicOnly) { checkInitted(); - Method[] res = null; - if (useCaches) { - clearCachesOnClassRedefinition(); - if (publicOnly) { - if (declaredPublicMethods != null) { - res = declaredPublicMethods.get(); - } - } else { - if (declaredMethods != null) { - res = declaredMethods.get(); - } - } + Method[] res; + ReflectionData rd = reflectionData(); + if (rd != null) { + res = publicOnly ? rd.declaredPublicMethods : rd.declaredMethods; if (res != null) return res; } // No cached value available; request value from VM res = Reflection.filterMethods(this, getDeclaredMethods0(publicOnly)); - if (useCaches) { + if (rd != null) { if (publicOnly) { - declaredPublicMethods = new SoftReference<>(res); + rd.declaredPublicMethods = res; } else { - declaredMethods = new SoftReference<>(res); + rd.declaredMethods = res; } } return res; @@ -2674,12 +2714,10 @@ // via ReflectionFactory.copyMethod. private Method[] privateGetPublicMethods() { checkInitted(); - Method[] res = null; - if (useCaches) { - clearCachesOnClassRedefinition(); - if (publicMethods != null) { - res = publicMethods.get(); - } + Method[] res; + ReflectionData rd = reflectionData(); + if (rd != null) { + res = rd.publicMethods; if (res != null) return res; } @@ -2727,8 +2765,8 @@ methods.addAllIfNotPresent(inheritedMethods); methods.compactAndTrim(); res = methods.getArray(); - if (useCaches) { - publicMethods = new SoftReference<>(res); + if (rd != null) { + rd.publicMethods = res; } return res; } @@ -2738,7 +2776,7 @@ // Helpers for fetchers of one field, method, or constructor // - private Field searchFields(Field[] fields, String name) { + private static Field searchFields(Field[] fields, String name) { String internedName = name.intern(); for (int i = 0; i < fields.length; i++) { if (fields[i].getName() == internedName) { @@ -2756,7 +2794,7 @@ // of Field objects which have to be created for the common // case where the field being requested is declared in the // class which is being queried. - Field res = null; + Field res; // Search declared public fields if ((res = searchFields(privateGetDeclaredFields(true), name)) != null) { return res; @@ -2808,7 +2846,7 @@ // number of Method objects which have to be created for the // common case where the method being requested is declared in // the class which is being queried. - Method res = null; + Method res; // Search declared public methods if ((res = searchMethods(privateGetDeclaredMethods(true), name, @@ -3209,9 +3247,20 @@ // Annotations cache private transient Map, Annotation> annotations; private transient Map, Annotation> declaredAnnotations; + // Value of classRedefinedCount when we last cleared the cached annotations and declaredAnnotations fields + private transient int lastAnnotationsRedefinedCount = 0; + + // Clears cached values that might possibly have been obsoleted by + // a class redefinition. + private void clearAnnotationCachesOnClassRedefinition() { + if (lastAnnotationsRedefinedCount != classRedefinedCount) { + annotations = declaredAnnotations = null; + lastAnnotationsRedefinedCount = classRedefinedCount; + } + } private synchronized void initAnnotationsIfNecessary() { - clearCachesOnClassRedefinition(); + clearAnnotationCachesOnClassRedefinition(); if (annotations != null) return; declaredAnnotations = AnnotationParser.parseAnnotations( @@ -3233,10 +3282,11 @@ // Annotation types cache their internal (AnnotationType) form - private AnnotationType annotationType; + @SuppressWarnings("UnusedDeclaration") + private volatile transient AnnotationType annotationType; - void setAnnotationType(AnnotationType type) { - annotationType = type; + boolean casAnnotationType(AnnotationType oldType, AnnotationType newType) { + return Atomic.casAnnotationType(this, oldType, newType); } AnnotationType getAnnotationType() { diff -r 59ce33d99e27 -r 828993403102 src/share/classes/java/lang/System.java --- a/src/share/classes/java/lang/System.java Mon Sep 22 15:44:14 2014 +0100 +++ b/src/share/classes/java/lang/System.java Sat Mar 08 01:40:14 2014 +0400 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1994, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1994, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1178,12 +1178,15 @@ public sun.reflect.ConstantPool getConstantPool(Class klass) { return klass.getConstantPool(); } - public void setAnnotationType(Class klass, AnnotationType type) { - klass.setAnnotationType(type); + public boolean casAnnotationType(Class klass, AnnotationType oldType, AnnotationType newType) { + return klass.casAnnotationType(oldType, newType); } public AnnotationType getAnnotationType(Class klass) { return klass.getAnnotationType(); } + public byte[] getRawClassAnnotations(Class klass) { + return klass.getRawAnnotations(); + } public > E[] getEnumConstantsShared(Class klass) { return klass.getEnumConstantsShared(); diff -r 59ce33d99e27 -r 828993403102 src/share/classes/sun/misc/JavaLangAccess.java --- a/src/share/classes/sun/misc/JavaLangAccess.java Mon Sep 22 15:44:14 2014 +0100 +++ b/src/share/classes/sun/misc/JavaLangAccess.java Sat Mar 08 01:40:14 2014 +0400 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -35,10 +35,10 @@ ConstantPool getConstantPool(Class klass); /** - * Set the AnnotationType instance corresponding to this class. + * Compare-And-Swap the AnnotationType instance corresponding to this class. * (This method only applies to annotation types.) */ - void setAnnotationType(Class klass, AnnotationType annotationType); + boolean casAnnotationType(Class klass, AnnotationType oldType, AnnotationType newType); /** * Get the AnnotationType instance corresponding to this class. @@ -47,6 +47,12 @@ AnnotationType getAnnotationType(Class klass); /** + * Get the array of bytes that is the class-file representation + * of this Class' annotations. + */ + byte[] getRawClassAnnotations(Class klass); + + /** * Returns the elements of an enum class or null if the * Class object does not represent an enum type; * the result is uncloned, cached, and shared by all callers. diff -r 59ce33d99e27 -r 828993403102 src/share/classes/sun/reflect/annotation/AnnotationParser.java --- a/src/share/classes/sun/reflect/annotation/AnnotationParser.java Mon Sep 22 15:44:14 2014 +0100 +++ b/src/share/classes/sun/reflect/annotation/AnnotationParser.java Sat Mar 08 01:40:14 2014 +0400 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -67,7 +67,35 @@ return Collections.emptyMap(); try { - return parseAnnotations2(rawAnnotations, constPool, container); + return parseAnnotations2(rawAnnotations, constPool, container, null); + } catch(BufferUnderflowException e) { + throw new AnnotationFormatError("Unexpected end of annotations."); + } catch(IllegalArgumentException e) { + // Type mismatch in constant pool + throw new AnnotationFormatError(e); + } + } + + /** + * Like {@link #parseAnnotations(byte[], sun.reflect.ConstantPool, Class)} + * with an additional parameter {@code selectAnnotationClasses} which selects the + * annotation types to parse (other than selected are quickly skipped).

    + * This method is only used to parse select meta annotations in the construction + * phase of {@link AnnotationType} instances to prevent infinite recursion. + * + * @param selectAnnotationClasses an array of annotation types to select when parsing + */ + @SafeVarargs + static Map, Annotation> parseSelectAnnotations( + byte[] rawAnnotations, + ConstantPool constPool, + Class container, + Class ... selectAnnotationClasses) { + if (rawAnnotations == null) + return Collections.emptyMap(); + + try { + return parseAnnotations2(rawAnnotations, constPool, container, selectAnnotationClasses); } catch(BufferUnderflowException e) { throw new AnnotationFormatError("Unexpected end of annotations."); } catch(IllegalArgumentException e) { @@ -79,22 +107,23 @@ private static Map, Annotation> parseAnnotations2( byte[] rawAnnotations, ConstantPool constPool, - Class container) { From bugzilla-daemon at icedtea.classpath.org Mon Sep 29 18:30:49 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 29 Sep 2014 18:30:49 +0000 Subject: [Bug 2022] SweetHome3d closes when Preferences is selected In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2022 --- Comment #2 from Juan Tyson --- I thank you for the help with this problem, it will be reported to Ubuntu. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 30 03:31:31 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 30 Sep 2014 03:31:31 +0000 Subject: [Bug 1750] Arduino-ide crashes with SIGSEGV in libpthread.so In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1750 himanshukr26 at gmail.com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |himanshukr26 at gmail.com --- Comment #1 from himanshukr26 at gmail.com --- I am also facing the same problemm but with Gmote server running the media files. PDF and images can be opened and controlled. But with video files this error come and server connection is disconnected. -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 30 08:59:41 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 30 Sep 2014 08:59:41 +0000 Subject: [Bug 2024] New: [STORY] Number of threads chart should not require turning on thread recording Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2024 Bug ID: 2024 Summary: [STORY] Number of threads chart should not require turning on thread recording Product: Thermostat Version: hg Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P5 Component: Thermostat Assignee: unassigned at icedtea.classpath.org Reporter: sgehwolf at redhat.com CC: thermostat at icedtea.classpath.org As a user I'd like to see the chart of currently running threads (thread count) and the number of daemon threads without turning on the thread recording feature. Implementation note: Relevant counters are exposed via jvm-stat counters. Thus by using this feature rather than JMX this should be possible without incurring too much overhead. The counter is called "java.threads.live" for live threads. See: https://bitbucket.org/jerboaa/thermostat-thread-events/src/ac8dff62d2e9073c4e73c3352cd2e07f134331ab/agent/src/main/java/com/redhat/thermostat/plugins/tutorial/thread/events/agent/internal/VmThreadLiveCountListener.java?at=default -- You are receiving this mail because: You are the assignee for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 30 21:34:06 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 30 Sep 2014 21:34:06 +0000 Subject: [Bug 2025] New: [IcedTea7] LCMS_CFLAGS & LCMS_LIBS should not be used unless SYSTEM_LCMS is enabled Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2025 Bug ID: 2025 Summary: [IcedTea7] LCMS_CFLAGS & LCMS_LIBS should not be used unless SYSTEM_LCMS is enabled Product: IcedTea Version: 7-hg Hardware: all OS: All Status: NEW Severity: normal Priority: P5 Component: IcedTea Assignee: gnu.andrew at redhat.com Reporter: gnu.andrew at redhat.com CC: unassigned at icedtea.classpath.org With LCMS_CFLAGS set to 'disabled' and SYSTEM_LCMS set to 'false': /usr/bin/gcc -O2 -fno-strict-aliasing -fPIC -W -Wall -Wno-unused -Wno-parentheses -fno-omit-frame-pointer -D_LITTLE_ENDIAN -g -DNDEBUG -DARCH='"i586"' -Di586 -DLINUX -DRELEASE='"1.7.0_65"' -D_LARGEFILE64_SOURCE -D_GNU_SOURCE -D_REENTRANT -DUSE_PTHREADS -I. -I/builddir/build/BUILD/java-1.7.0-openjdk/openjdk/build/linux-i586/tmp/sun/sun.java2d.cmm.lcms/javalcms/CClassHeaders -I../../../../src/solaris/javavm/export -I../../../../src/share/javavm/export -I../../../../src/share/native/common -I../../../../src/solaris/native/common -I../../../../src/share/native/sun/java2d/cmm/lcms -I../../../../src/solaris/native/sun/java2d/cmm/lcms -I../../../../src/share/native/sun/java2d -I../../../../src/share/native/sun/awt/debug disabled -c -o /builddir/build/BUILD/java-1.7.0-openjdk/openjdk/build/linux-i586/tmp/sun/sun.java2d.cmm.lcms/javalcms/obj/cmscam02.o ../../../../src/share/native/sun/java2d/cmm/lcms/cmscam02.c gcc: disabled: No such file or directory -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bugzilla-daemon at icedtea.classpath.org Tue Sep 30 21:34:22 2014 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 30 Sep 2014 21:34:22 +0000 Subject: [Bug 2025] [IcedTea7] LCMS_CFLAGS & LCMS_LIBS should not be used unless SYSTEM_LCMS is enabled In-Reply-To: References: Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=2025 Andrew John Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Target Milestone|--- |2.5.3 -- You are receiving this mail because: You are on the CC list for the bug. -------------- next part -------------- An HTML attachment was scrubbed... URL: