11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12 * version 2 for more details (a copy is included in the LICENSE file that 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 */ 23 24 /* @test 25 * @bug 4504153 26 * @summary RMI implementation should not log to two loggers where one is 27 * an ancestor of the other, to avoid unintended or duplicate logging 28 * @author Peter Jones 29 * 30 * @library ../../../../../java/rmi/testlibrary 31 * @build JavaVM 32 * @run main/othervm Test4504153 33 */ 34 35 import java.io.ByteArrayOutputStream; 36 import java.rmi.registry.LocateRegistry; 37 import java.rmi.server.RemoteServer; 38 39 public class Test4504153 { 40 41 private final static String DONE = "Done!"; 42 43 public static void main(String[] args) throws Exception { 44 45 System.err.println("\nRegression test for bug 4504153\n"); 46 47 ByteArrayOutputStream out = new ByteArrayOutputStream(); 48 ByteArrayOutputStream err = new ByteArrayOutputStream(); 49 JavaVM vm = new JavaVM(StartRegistry.class.getName(), 50 "-Dsun.rmi.transport.logLevel=v", "", out, err); | 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12 * version 2 for more details (a copy is included in the LICENSE file that 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 */ 23 24 /* @test 25 * @bug 4504153 26 * @summary RMI implementation should not log to two loggers where one is 27 * an ancestor of the other, to avoid unintended or duplicate logging 28 * @author Peter Jones 29 * 30 * @library ../../../../../java/rmi/testlibrary 31 * @modules java.rmi/sun.rmi.registry 32 * java.rmi/sun.rmi.server 33 * java.rmi/sun.rmi.transport 34 * java.rmi/sun.rmi.transport.tcp 35 * @build JavaVM 36 * @run main/othervm Test4504153 37 */ 38 39 import java.io.ByteArrayOutputStream; 40 import java.rmi.registry.LocateRegistry; 41 import java.rmi.server.RemoteServer; 42 43 public class Test4504153 { 44 45 private final static String DONE = "Done!"; 46 47 public static void main(String[] args) throws Exception { 48 49 System.err.println("\nRegression test for bug 4504153\n"); 50 51 ByteArrayOutputStream out = new ByteArrayOutputStream(); 52 ByteArrayOutputStream err = new ByteArrayOutputStream(); 53 JavaVM vm = new JavaVM(StartRegistry.class.getName(), 54 "-Dsun.rmi.transport.logLevel=v", "", out, err); |