JDK-6477297 : com.sun.xml.internal.ws.streaming does not exist
  • Type: Bug
  • Component: tools
  • Sub-Component: javac
  • Affected Version: 6
  • Priority: P2
  • Status: Closed
  • Resolution: Not an Issue
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2006-10-02
  • Updated: 2010-04-26
  • Resolved: 2006-10-02
Related Reports
Relates :  
The attched simple sample can not compile with javac. There is no problems with eclipse, and in the rt.jar and the file XMLStreamReaderFactory.class is on the correct place.

Command line:    %JAVA_HOME6%\bin\javac CompilerSample.java
OS:              Windows 2000 and Windows XP
java version "1.6.0-rc"
Java(TM) SE Runtime Environment (build 1.6.0-rc-b100)
Java HotSpot(TM) Client VM (build 1.6.0-rc-b100, mixed mode, sharing)
Compiler Output:
CompilerSample.java:1: package com.sun.xml.internal.ws.streaming does not exist
import com.sun.xml.internal.ws.streaming.XMLStreamReaderFactory;
CompilerSample.java:8: cannot find symbol
symbol  : variable XMLStreamReaderFactory
location: class CompilerSample
                XMLStreamReaderFactory.createXMLStreamReader(new StringReader(""), false);
2 errors

import com.sun.xml.internal.ws.streaming.*;
import java.io.StringReader;

public class CompilerSample{

    void test(){
        XMLStreamReaderFactory.createXMLStreamReader(new StringReader(""), false);


EVALUATION The package com.sun.xml.internal.ws.streaming is a proprietary implementation detail of Sun's JRE. This is why the package has "internal" in its name. Furthermore, the package is not documented. In JDK 6, the compiler cannot see such implementation details. For more details including the motivation for this change, see RFE 6476630 and my blog (http://blogs.sun.com/ahe/entry/b86_compiler_fixes and http://blogs.sun.com/ahe/entry/b92_b96_compiler_fixes).