Unexpected end of ZLIB input stream.

Hello everyone.
I have a problem which I was unable to solve so far. Any suggestion is very welcome.
The scenario.
My process worked on a previously installed default install 10.1.3.1 platform.
I installed the SOA Suite (same, very default set with olite) on a different computer and copied all files of the project dir. Modified file paths and URLs in all files in the folder and deployed the process with jdeveloper.
Symptoms.
Flow viewer gets stuck at Loading audit trail. Messages from a java call get to manual recovery, and will not recover.
I start the process with a java call:
Locator locator = new Locator("default","bpel");
IDeliveryService deliveryService = (IDeliveryService)locator.lookupService(IDeliveryService.SERVICE_NAME);
NormalizedMessage nm = new NormalizedMessage( );
nm.addPart("payload", xml );
deliveryService.post("OrderFlow", "initiate", nm);
it starts without any problems and runs until a callback (receive) activity, where it is waiting for a message using the same java api calls as above.
This runs well on the previous system, however the new system will not deliver the message.
Log output.
After trying to access the flow viewer:
<2008-03-19 20:13:12,120> <ERROR> <default.collaxa.cube> <BaseCubeSessionBean::logError> Error while invoking bean "instance manager": Cannot uncompress data stream.
Cannot uncompress data stream with GZIP algorithm; exception is Unexpected end of ZLIB input stream.
ORABPEL-02018
Cannot uncompress data stream.
Cannot uncompress data stream with GZIP algorithm; exception is Unexpected end of ZLIB input stream.
     at com.collaxa.cube.engine.util.CompressUtils.uncompressStream(CompressUtils.java:184)
     at com.collaxa.cube.engine.util.DBUtils.getUncompressedBLOB(DBUtils.java:358)
     at com.collaxa.cube.engine.util.DBUtils.getUncompressedBLOB(DBUtils.java:310)
     at com.collaxa.cube.engine.adaptors.common.BaseCubeInstancePersistenceAdaptor$BaseScopeHandler.load(BaseCubeInstancePersistenceAdaptor.java:1268)
     at com.collaxa.cube.engine.adaptors.common.BaseCubeInstancePersistenceAdaptor.load(BaseCubeInstancePersistenceAdaptor.java:348)
     at com.collaxa.cube.engine.adaptors.common.BaseCubeInstancePersistenceAdaptor.load(BaseCubeInstancePersistenceAdaptor.java:251)
     at com.collaxa.cube.engine.data.CubeInstancePersistenceMgr.__load(CubeInstancePersistenceMgr.java:252)
     at com.collaxa.cube.engine.data.CubeInstancePersistenceMgr.load(CubeInstancePersistenceMgr.java:136)
     at com.collaxa.cube.engine.CubeEngine.load(CubeEngine.java:4859)
     at com.collaxa.cube.engine.CubeEngine.getInstanceTrace(CubeEngine.java:2415)
     at com.collaxa.cube.ejb.impl.InstanceManagerBean.getInstanceTrace(InstanceManagerBean.java:168)
     at sun.reflect.GeneratedMethodAccessor275.invoke(Unknown Source)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:585)
     at com.evermind.server.ejb.interceptor.joinpoint.EJBJoinPointImpl.invoke(EJBJoinPointImpl.java:35)
     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
     at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
     at com.evermind.server.ejb.interceptor.system.JAASInterceptor$1.run(JAASInterceptor.java:31)
     at com.evermind.server.ThreadState.runAs(ThreadState.java:620)
     at com.evermind.server.ejb.interceptor.system.JAASInterceptor.invoke(JAASInterceptor.java:34)
     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
     at com.evermind.server.ejb.interceptor.system.TxNotSupportedInterceptor.invoke(TxNotSupportedInterceptor.java:43)
     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
     at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
     at com.evermind.server.ejb.InvocationContextPool.invoke(InvocationContextPool.java:55)
     at com.evermind.server.ejb.StatelessSessionEJBObject.OC4J_invokeMethod(StatelessSessionEJBObject.java:87)
     at InstanceManagerBean_RemoteProxy_4bin6i8.getInstanceTrace(Unknown Source)
     at com.oracle.bpel.client.InstanceHandle.getInstanceTrace(InstanceHandle.java:267)
     at xmlGetInstanceTrace.jspService(_xmlGetInstanceTrace.java:56)
     at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:59)
     at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:453)
     at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:591)
     at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:515)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
     at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
     at oracle.security.jazn.oc4j.JAZNFilter$1.run(JAZNFilter.java:396)
     at java.security.AccessController.doPrivileged(Native Method)
     at javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
     at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java:410)
     at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
     at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:368)
     at com.evermind.server.http.ServletRequestDispatcher.unprivileged_forward(ServletRequestDispatcher.java:259)
     at com.evermind.server.http.ServletRequestDispatcher.access$100(ServletRequestDispatcher.java:50)
     at com.evermind.server.http.ServletRequestDispatcher$2.oc4jRun(ServletRequestDispatcher.java:193)
     at oracle.oc4j.security.OC4JSecurity.doPrivileged(OC4JSecurity.java:283)
     at com.evermind.server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:198)
     at com.collaxa.cube.fe.DomainFilter.doFilter(DomainFilter.java:131)
     at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:15)
     at oracle.security.jazn.oc4j.JAZNFilter$1.run(JAZNFilter.java:396)
     at java.security.AccessController.doPrivileged(Native Method)
     at javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
     at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java:410)
     at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:619)
     at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:368)
     at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:866)
     at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:448)
     at com.evermind.server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:216)
     at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:117)
     at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:110)
     at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
     at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
     at java.lang.Thread.run(Thread.java:595)
After sending the message
<2008-03-19 15:20:58,984> <ERROR> <default.collaxa.cube.engine.dispatch> <DispatchHelper::handleMessage> failed to handle message
ORABPEL-02018
Cannot uncompress data stream.
Cannot uncompress data stream with GZIP algorithm; exception is Unexpected end of ZLIB input stream.
... and ...
<2008-03-19 15:20:58,994> <ERROR> <default.collaxa.cube.engine> Attempt (1/2): caught non-fatal connection exception ... retry
<2008-03-19 15:21:00,075> <ERROR> <default.collaxa.cube> <BaseCubeSessionBean::logError> Error while invoking bean "cube delivery": Cannot uncompress data stream.
Cannot uncompress data stream with GZIP algorithm; exception is Unexpected end of ZLIB input stream.
ORABPEL-02018
Cannot uncompress data stream.
Cannot uncompress data stream with GZIP algorithm; exception is Unexpected end of ZLIB input stream.
===================
THANK YOU

Some update on the issue.
I have a quite complicated BPEL process, which has this symptom.
I figured out however, that if I dont use the TaskService, it does run well.
So I just created a test bpel process with nothing but a human task.
It failed with the same unexpected end of zlib ... problem.
What I also noticed is that the task appears in the worklist app, but the reply gets into the callback manual recovery pool. there must be some kind of communication failure from the taskservice in the direction of the bpel process.
Any advice is welcome,
thx,
tg

Similar Messages

  • ExecTask - java.io.EOFException: Unexpected end of ZLIB input stream

    BOXI 3.1 FP 7 deployed on AIX environment with all the lang packs. Trying to install SP2 on AIX, when it comes to deploying the war files, AnalyticalReporting, the install encounters error. This error appears to be with size of the war file.  Anyone came across this issue?
    2010-03-30 10:10:00,633   Target - Target "expand_and_package" started.
    2010-03-30 10:10:00,634   Delete - Deleting directory /export/home/Business_Objects/global/deployment/workdir/tomcat55/resources/web/AnalyticalReporting
    2010-03-30 10:10:00,798    Mkdir - Created dir: /export/home/Business_Objects/global/deployment/workdir/tomcat55/resources/web/AnalyticalReporting
    2010-03-30 10:10:00,828    Mkdir - Created dir: /export/home/Business_Objects/global/deployment/workdir/tomcat55/resources/AnalyticalReporting
    2010-03-30 10:19:32,016 *ExecTask - java.io.EOFException: Unexpected end of ZLIB input stream
    2010-03-30 10:19:32,016 ExecTask -      at java.util.zip.InflaterInputStream.fill(InflaterInputStream.java(Compiled Code))
    2010-03-30 10:19:32,017 ExecTask -      at java.util.zip.InflaterInputStream.read(InflaterInputStream.java(Compiled Code))
    2010-03-30 10:19:32,017 ExecTask -      at java.util.zip.ZipInputStream.read(ZipInputStream.java(Compiled Code))
    2010-03-30 10:19:32,017 ExecTask -      at sun.tools.jar.Main.extractFile(Main.java(Compiled Code))
    2010-03-30 10:19:32,017 ExecTask -      at sun.tools.jar.Main.extract(Main.java(Compiled Code))
    2010-03-30 10:19:32,025 ExecTask -      at sun.tools.jar.Main.run(Main.java:228)
    2010-03-30 10:19:32,025 ExecTask -      at sun.tools.jar.Main.main(Main.java:944)
    2010-03-30 10:19:32,051 ExecTask - Result: 1
    2010-03-30 10:19:32,162     Echo - Adding 'webiApplet/**' to the content to bundle with AnalyticalReporting's war file
    2010-03-30 10:19:32,302      Jar - error while reading original manifest: Error opening zip file /export/home/Business_Objects/global/deployment/workdir/tomc
    at55/application/AnalyticalReporting.war
    2010-03-30 10:19:35,354      Jar - Building jar: /export/home/Business_Objects/global/deployment/workdir/tomcat55/application/AnalyticalReporting.war
    2010-03-30 10:20:29,036      Zip - Building zip: /export/home/Business_Objects/global/deployment/workdir/tomcat55/resources/AnalyticalReporting.zip
    2010-03-30 10:23:58,561    Mkdir - Created dir: /export/home/Business_Objects/global/deployment/workdir/tomcat55/resources/web/AnalyticalReporting/WEB-INF
    2010-03-30 10:23:58,564     Copy - Copying 1 file to /export/home/Business_Objects/global/deployment/workdir/tomcat55/resources/web/AnalyticalReporting/WEB-I
    NF
    2010-03-30 10:23:58,597   Delete - Deleting directory /export/home/Business_Objects/global/deployment/workdir/tomcat55/resources/AnalyticalReporting
    2010-03-30 10:35:00,636   Target - Target "expand_and_package" finished.

    Hi,
    Don't know which of this factors solved the problem:
    1. Error server:
    AIX 5.2
    jdk 1.3.17 (minimum from docu: 1.3.11)
    $ORACLE_HOME wasn't in the begining of $PATH
    2. success server:
    AIX 5.3
    jdk 1.4.02
    $ORACLE_HOME is now in the begining of $PATH
    cheers Lao De

  • Java.io.EOFException: Unexpected end of ZLIB input stream

    Hi,
    I am reading .gz file in servlet and writing it in output stream. It works fine for smaller files. For larger file when I reading file and writing output I am getting exceptions as below in order.
    8/6/09 9:52:28:953 CDT] 00000029 ServletWrappe E SRVE0068E: Could not invoke the service() method on servlet /WEB-INF/pages/TilesTemplate/layouttemplate.jsp. Exception thrown : java.lang.IllegalStateException: SRVE0199E: OutputStream already obtained
         at com.ibm.ws.webcontainer.srt.SRTServletResponse.getWriter(SRTServletResponse.java:489)
         at org.apache.jasper.runtime.JspWriterImpl.initOut(JspWriterImpl.java:170)
         at org.apache.jasper.runtime.JspWriterImpl.flushBuffer(JspWriterImpl.java:163)
         at org.apache.jasper.runtime.PageContextImpl.release(PageContextImpl.java:227)
    ---- Begin backtrace for Nested Throwables
    java.lang.IllegalStateException: SRVE0199E: OutputStream already obtained
         at com.ibm.ws.webcontainer.srt.SRTServletResponse.getWriter(SRTServletResponse.java:489)
         at org.apache.jasper.runtime.JspWriterImpl.initOut(JspWriterImpl.java:170)
         at org.apache.jasper.runtime.JspWriterImpl.flushBuffer(JspWriterImpl.java:163)
    *[8/6/09 9:52:28:625 CDT] 00000029 SystemErr R java.io.EOFException: Unexpected end of ZLIB input stream*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at java.util.zip.InflaterInputStream.fill(InflaterInputStream.java:238)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:157)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at java.util.zip.GZIPInputStream.read(GZIPInputStream.java:109)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at java.io.FilterInputStream.read(FilterInputStream.java:110)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at sun.nio.cs.StreamDecoder$ConverterSD.implRead(StreamDecoder.java:325)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:223)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at java.io.InputStreamReader.read(InputStreamReader.java:208)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at java.io.BufferedReader.fill(BufferedReader.java:153)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at java.io.BufferedReader.readLine(BufferedReader.java:316)*
    *[8/6/09 9:52:28:656 CDT] 00000029 SystemErr R      at java.io.BufferedReader.readLine(BufferedReader.java:379)*
    *[8/*

    My suggestion would be to run your code as a plain old Java application. Why use a servlet environment to test the problem? There's just too many things going on. So first see if it works the same way in a Java application. If it does, or if it doesn't, you then know where to go next.

  • Unexpected end of ZLIB input stream - While Importing SAP_BUILDT

    Hello All,
    We are trying to import the SAP_BUILDT file into the CMS track. But encounter the following error when we try to import in the "Development" tab. All the three steps: "Repository-Import", "CBS-make", "SDM-Deploy" have the same error message in the log.
    May 14, 2008 8:28:45 AM  Error  : error during loading of propagation request Exc=com.sap.cms.tcs.interfaces.exceptions.TCSFileLoadException: cannot load file: /usr/sap/trans/CMS/archives/sap.comSAP_BUILDTSAP AG20071117141300.sca Error: Could not extract file BUILDARCHIVES/sap.comtcbijlincbs_compdcia.zip from archive /usr/sap/trans/CMS/archives/sap.comSAP_BUILDTSAP AG~20071117141300.scaAdditional error message is:Unexpected end of ZLIB input stream
    May 14, 2008 8:28:45 AM  Error  : stack trace:
    [EXCEPTION]
    com.sap.cms.tcs.interfaces.exceptions.TCSFileLoadException: cannot load file: /usr/sap/trans/CMS/archives/sap.comSAP_BUILDTSAP AG20071117141300.sca Error: Could not extract file BUILDARCHIVES/sap.comtcbijlincbs_compdcia.zip from archive /usr/sap/trans/CMS/archives/sap.comSAP_BUILDTSAP AG~20071117141300.scaAdditional error message is:Unexpected end of ZLIB input stream
         at com.sap.cms.tcs.core.PropagationRequest.PropagationRequestData.load(PropagationRequestData.java:2464)
         at com.sap.cms.tcs.core.TCSManager.importPropagationRequests(TCSManager.java:355)
    The sp level we are trying to import is 7.00 SP14.
    We found some posts which said that the file may be corrupted. So we downloaded a couple of times from the service market place and tried. But still the same error.
    The following is the file that we downloaded from SMP:
      SAPBUILDT14_0-10003479.SCA   SP14 for DI BUILD TOOL 7.00
    Could anyone tell us what the problem could be?
    Thanks and Regards,
    Reena
    Edited by: Reena Prabhakar on May 21, 2008 11:51 AM

    Hi Purush,
    We used the same files as the ones we had used in the "Inbox" folder and copied them to the "archives" folder as well. These files we downloaded from the SAP service Marketplace. I am sure you would be aware of the right location in SMP for your files.
    However, you could also do one more thing. Make sure that you delete all the files similar to the ones that are giving an error in the "Archives" folder. I mean, if there is more than one version of the file that is giving the error, delete all these files from the archives folder. Then, do a check-in and an import again. This will copy the right version of the file to the archives folder automatically. This way, you won't have to copy paste the files manually to the archives folder.
    To explain this in more detail... here is the response I got from SAP regarding this issue:
    The "archives" folder is normally only used internally by the CMS to store a backup copy of the imported files.
    After you place a file in the "inbox" and check it in, CMS first extracts the SCA name, vendor and version and checks if it is already contained in the archive. If the file is new, it is copied from "inbox" to the "archives" folder. Already existing files are not copied. Later, during import, the import file is read from the "archives" folder. In your case I assume that the fixed SCA file had the same version, so just by comparing the SCA name, vendor and version, the CMS did not realize that it has to update the file in "archives".
    Usually you don't have to care about the "archives" folder.
    Hope this helps.
    Thanks and Regards,
    Reena

  • Unexpected end of ZLIB input stream error while compiling

    Hello
    I am getting errors when i run RMIC and JAR apps in the same window, i've tried to close and open the input stream in between, tried delaying between the two , tried /I paramaeter, any one ?
    Rmic stage pass OK
    but i get Unexpected end of ZLIB input stream exception i some of the file on the jar stage :
    Main batch :
    start /B %SWIFT_LOCAL_HOME%\scripts\rmicAll.bat
    start /B %SWIFT_LOCAL_HOME%\scripts\create_jar.bat
    Jar exception :
    adding: CVS/(in = 0) (out= 0)(stored 0%)
    adding: CVS/Entries(in = 383) (out= 168)(deflated 56%)
    adding: CVS/Repository(in = 13) (out= 15)(deflated -15%)
    adding: CVS/Root(in = 60) (out= 60)(deflated 0%)
    java.io.EOFException: Unexpected end of ZLIB input stream
    at java.util.zip.InflaterInputStream.fill(InflaterInputStream.java:223)
    at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:141)
    at java.util.zip.ZipInputStream.read(ZipInputStream.java:146)
    at sun.tools.jar.Main.update(Main.java:508)
    at sun.tools.jar.Main.run(Main.java:184)
    at sun.tools.jar.Main.main(Main.java:1022)
    C:\Eclipse_Workspace\Swift\scripts>date /T 1>>C:\Eclipse_Workspace\Swift\swift_build.txt
    C:\Eclipse_Workspace\Swift\scripts>time /T 1>>C:\Eclipse_Workspace\Swift\swift_build.txt
    C:\Eclipse_Workspace\Swift\scripts>echo Swift.jar Build Time : 1>C:\Eclipse_Workspace\Swift\swift_build.txt
    C:\Eclipse_Workspace\Swift\scripts>"C:\Program Files\Java\jdk1.6.0_02\bin\jar" -uvf C:\Eclipse_Workspace\Swift\jars\swift.jar -C C:\Eclipse_Workspace\Swift swift_build.txt
    java.io.EOFException: Unexpected end of ZLIB input stream
    at java.util.zip.InflaterInputStream.fill(InflaterInputStream.java:223)
    at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:141)
    at java.util.zip.ZipInputStream.read(ZipInputStream.java:146)
    at sun.tools.jar.Main.update(Main.java:508)
    at sun.tools.jar.Main.run(Main.java:184)
    at sun.tools.jar.Main.main(Main.java:1022)

    You seem to be adding the contents of CVS directories to the jar file. CVS directories contain internal information used by CVS. This suggests to me that you are either deliberately doing something really really strange, or you are doing something stupid out of ignorance.
    The CVS directories suggest you are making a jar from your source code. Generally you compile the source code 'tree' and place the output (.class files etc) in another tree and create the jar from that second tree.
    And PaulMiner is correct, you'll definitely need to change 'start' to 'call'. Do that first, then take a look at what is source code, and what it is that you want in your jar file and make sure it is all sensible, I suspect it isn't.

  • Mac OS X MySQL Connect throws Unexpected end of input stream

    With java version 1.4.2_05 I'm attempting to run an application which retrieves information from a MySQL database version 4.1 on Mac OS X Panther 10.3.6 The application operates without error on Windows and Linux using MySQL v4.0. Relevant Code appears below..
              private static final String DRIVER = "com.mysql.jdbc.Driver";
         private static final String URL = "jdbc:mysql://localhost:3306";
         boolean openConnection() throws SQLException, DatabaseException {
              try {
                   if (con == null) {
                        StringBuffer sb = new StringBuffer(URL);
                        sb.append("/").append(getDatabase());
                        Class.forName(DRIVER);
                        /* Failure occurs here while calling getConnection on the
                        DriverManager class. */
                        con = DriverManager.getConnection(sb.toString(), getUser(), getPassword());
              } catch(SQLException sle) {
                   sle.printStackTrace();
         } But on Mac X I'm seeing an exception thrown.
    java.sql.SQLException: Communication link failure: java.io.IOException, underlying cause:
    Unexpected end of input stream
    ** BEGIN NESTED EXCEPTION **
    java.io.IOException
    MESSAGE: Unexpected end of input stream
    STACKTRACE:
    java.io.IOException: Unexpected end of input stream
            at com.mysql.jdbc.MysqlIO.readPacket(MysqlIO.java:1096)
            at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:626)
            at com.mysql.jdbc.Connection.createNewIO(Connection.java:1562)
            at com.mysql.jdbc.Connection.<init>(Connection.java:491)
            at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:346)
            at java.sql.DriverManager.getConnection(DriverManager.java:512)
            at java.sql.DriverManager.getConnection(DriverManager.java:171)I have checked to see that the proper permissions are established in the database. I've used the GRANT statement etc. It's unclear to me why I am having difficulty with the newer MySQL on Mac OS X. Any feedback is appreciated thanks.

    I managed to solve this by having the MySQL server run as a service rather than attempting to start it via the application. So now the application can retrieve from the database without error.

  • SQL Server 2012 Management Studio:Importing XML file to new Table of new Database-XML parsing: unexpected end of input???

    Hi all,
    In the Notepad, I created an xml file (ZenQroducts.xml) :
    <Qroducts>
    <Qroduct>
    <SKU>1</SKU>
    <Desc>Book</Desc>
    </Qroduct>
    <Qroduct>
    <SKU>2</SKU>
    <Desc>DVD</Desc>
    </Qroduct>
    <Qroduct>
    <SKU>3</SKU>
    <Desc>Video</Desc>
    </Qroduct>
    In my SQL Server 2012 Management Studio, I executed the following code:
    --to create a new object Qroducts in a new database OPENXMLtesting
    CREATE DATABASE OPENXMLtesting
    GO
    CREATE TABLE Qroducts(
    sku INT Primary KEY,
    qroduct_desc VARCHAR(30));
    INSERT INTO Qroducts (sku, qroduct_desc)
    SELECT X.qroduct.query('SKU').value('.', 'INT'),
    X.qroduct.query('Desc').value('.', 'VARCHAR(30)')
    FROM (
    SELECT CAST(x AS XML)
    FROM OPENROWSET(
    BULK 'H:\ZenQroducts.xml',
    SINGLE_BLOB) AS T(x)
    ) AS T(x)
    CROSS APPLY x.nodes('Qroducts/Qroduct') AS X(qroduct);
    SELECT sku, qroduct_desc
    FROM Qroducts;
    I got the following message:
    Msg 9400, Level 16, State 1, Line 6
    XML parsing: line 13, character 12, unexpected end of input
    I have no ideas why I got this "XML parsing:line 13, character12, unexpected end of input" message. Please kindly help, advise me on where I made mistake and how I can resolve this problem, and respond in this Forum.
    Thanks in advance,
    Scott Chang
     

    Hi Manish, Thanks for your response.
    Yes, it is a duplicate with Qroducts/Qroduct instead of Products/Product. I did it, because I don't know how to remove the existing "Products" database.
    Again, I got the existing "Qroducts" database in this second trial!!??  I am comletely lost in doing "Importing XML file to SQL Table" now!!  I think that I have not touched T-SQL and XML programming, since 2008. I
    did not catch the new features of T-SQL 2008, XML, SQL/XML, XQuery, etc. for long time. Recently, I did not know what DECLARE, @x, SET,...were, and dived into the SQL/XML and XQuery programming. I knew the SQL Basics (SELECT, FROM, WHERE,..), creating
    the names of databases and tables in SQL Server 2008/2012 Management Studio (Express) before. This morning, I found an old T-SQL 2008 Prgrammer's Guide that has the new features of SQL Server 2008 for T-SQL, XML, XQuery, etc. I just starting reading
    it to know what DECLARE, @x, SET,... are. But, I still don't know where the existing databases "Products" and "Qroducts" (created by me) are - they are not in the Databases of SQL Server 2012 Management Studio I am using!!??  Could
    you please kindly point out where the "Products" and "Qroducts" databases are?
    Prashanth responded to my posted question too and he asked to to try his code: DECLARE @xml XML, SELECT @xml =' <Qroducts>.....SELECT product.value.....FROM @XML.nodes.....AS.... I just learned that his code is doing the thing we
    want to do and print the results below the SQL Query. This is not what I need in doing my SQL/XML programming. I am reading/studying the new (2008) features of T-SQL, XQuery 1.0: An XML Query Language (Second Edition), and Microsoft XQuery Language Reference
    (SQL Server 2012 Books Online) closely now. I hope that I can resume the T-SQL, XML Query, SQL/XML, XQuery in my SQL Server 2012 Management Studio soon.
    Please tell me  where the existing databases "Products" and "Qroducts" I created in my previous trials in my SQL Server 2012 Management Studio.  This is what I need to know and to delete them, before I do this kind of "Importing
    XML file to Table of SQL Server 2012 Management Studio"  programming again.
    Please kindly help, advise and respond again.
    Many Thanks,
    Scott Chang

  • End of input stream

    Hi,
    I want to read though an input stream using the read method. The javadoc says that read method returns -1 when it has reached the end of stream.
    But the problem is that my data also has -1 s. So my while loop breaks in the middle of stream. This is what I have done.
    //is - InputStream
    //c - int
    while((c=is.read()) != -1)
    System.out.println(c);
    Best regards,
    Chamal.

    From the AIP...
    The value byte is returned as an int in the range 0 to 255
    So -1 will never be returned other than at end if stream

  • Parsing input stream into named value pairs

    Hi everyone. I figured I would post this scenario, and hope to get some 'expert' opinions on what the best way to handle this would be.
    I have an input stream being returned to me and I need to separate them into name/value pairs. I receive this as two lines of strings. The first line is the variable names, and the second line is the values. This is the format:
    "Variable1","Variable2","Variable3","Variable4"
    "Value1","Value2","Value3","Value4"
    I need to separate this out into:
    Variable1 = "Value1"
    Variable2 = "Value2"
    What I was thinking of doing is to create a hashtable, read the first line in and assign those as the keys, then read the second line in and assign those as the values. I'm not quite sure if this is even possible as of yet, but thats my original game plan. My primary goals are:
    1. Seperate each variable name and match it with its appropriate value
    2. Be able to retrieve each value by calling the appropriate variable name.
    Any advice/opinion on this is greatly appreciated!!! Thanks!

    You could choose to feed the String through an InputStream and use a StreamTokenizer, which is substantially more powerful than StringTokenizer. I would personally, however, choose to parse it myself, as antequated as that might seem. ;)
    Presume that s1 is equal to
    "Var1", "Var2", "MoreVars", "EvenMoreVars" , "LastVar"
    And that s2 is equal to
    "Hello","9900", ":)", "He said \"hi\".", "Hi, there."
    These would make good sample data, but aren't necessarily the case.
    String s1 = ...;
    String s2 = ...;
    HashMap map = null;
    String[] keys = parseQuotedByCommas(s1);
    String[] values = parseQuotedByCommas(s2);
    if (keys.length==values.length)
        map = new HashMap();
        for (int i=0;i<keys.length;i++)
            map.put(keys, values[i]);
    } else
    // Error!
    // throws IllegalArgumentException for improperly formatted strings
    public static String[] parseQuotedByCommas(String s)
         ArrayList acc = new ArrayList();
         char[] ch = s.toCharArray();
         int i = 0;
         try
              while (i < ch.length)
                   while (ch[i] == ' ') i++;
                   if (i < ch.length)
                        if (ch[i] != '"')
                             throw new IllegalArgumentException(
                             "Expected '\"', receieved '" + ch[i] + "'");
                        i++;
                        StringBuffer sb = new StringBuffer();
                        boolean stop = false;
                        while (!stop)
                             switch (ch[i])
                                  case '"':
                                       if (ch[i - 1] == '\\')
                                            sb.append('"');
                                       else
                                            stop = true;
                                       break;
                                  case '\\':
                                       int j = i;
                                       boolean write = true;
                                       while ((j >= 0) && (ch[j] == '\\'))
                                            write = !write;
                                            j--;
                                       if (write) sb.append('\\');
                                       break;
                                  default:
                                       sb.append(ch[i]);
                             i++;
                        acc.add(sb.toString());
                   if (i < ch.length)
                        while (ch[i] == ' ') i++;
                        if (i < ch.length)
                             if ((ch[i] != ',') && (ch[i] != '"'))
                                  throw new IllegalArgumentException(
                                  "Expected ',' or '\"', received '" + ch[i] + "'");
                             i++;
         } catch (IndexOutOfBoundsException oob)
              throw new IllegalArgumentException("Unexpected end of string.");
         return (String[]) (acc.toArray(new String[0]));
    That should work for anything formatted as
    <String> ::= [<WhiteSpace>] <Stmt> [ [<WhiteSpace>] , [<WhiteSpace>] <Stmt> ] *
    <Stmt> ::= " <Characters> "
    <Characters> ::= \" | \\ | <AnyCharacterExceptQuoteOrBackslash>
    <WhiteSpace> ::= <Space>*
    Any questions?
    Oh, BTW, that was all blue 'cause the code tag doesn't take well to '"'.

  • How do I return an input stream from a text file

    Suppose there's a class with methods..
    one of the methods is something like..
    public int value() and has a return statement at the end obviously for returning an int value..
    Another method reads a text file and creates an input stream..
    Scanner data  = new Scanner(new File(input.next()));
    I want to return the data when I do a call to this method, but I'm not sure what the method heading would look like..

    flounder wrote:
    Are we supposed to magically know what those errors are? Do you think that copying and pasting the exact error messages and indicating the lines they occur on would be useful to us?Sorry about that..
    I've replicated the same code below; and put the number of the line where the error is.
    +cannot find symbol variable read     [line 21]+
    +cannot find symbol variable read     [line 23]+
    +cannot find symbol variable read     [line 29]+
    +cannot find symbol variable read     [line 31]+
    +cannot find symbol variable inputStream     [line 44]+
    +calculate() in textInput cannot be applied to (java.util.Scanner)     [line 57]+
    the reason I have the _______ for the createInputStream() method is because I'm not really sure what the heading type should be to return the input stream.
    import java.io.*;
    import java.util.*;
    public class textInput
              public void requestFileName()
                   Scanner input = new Scanner(System.in);
                   System.out.print("Enter file name: ");
              public _______ createInputStream() throws FileNotFoundException
                   Scanner input = new Scanner(System.in);
                   Scanner read = new Scanner(new File(input.next()));
                   return read;
              public void calculate() throws IOException
    21           double max;
                   double min;
    23            int count = 0;
                   double total = 0;
                   if (read.hasNextDouble())
                        double temp = read.nextDouble();
    29                 max = temp;
                        min = temp;
    31                 count++
                        total += temp;
                        while (read.hasNextDouble())
                             double current = read.nextDouble();
                             count++;
                             min = Math.min(current, min);
                             max = Math.max(current, max);
                             total += current;
                   System.out.println("Max of: " + max);
                   System.out.println("Min of: " + min);
    44            System.out.println("Average of " + total/count);
              public void close() throws IOException
                   inputStream.close();
              public static void main(String[] args)
                   textInput run = new textInput();
                   try
    57                 run.requestFileName();
                        run.createInputStream();
                        run.calculate();
                        run.close();
                   catch(FileNotFoundException e)
                        System.out.println("File not found.");
                        System.exit(0);
                   catch(IOException e)
                        System.out.prinln("File not found.");
                        System.exit(0);
    }

  • Error while executing SSIS package - Error: 4014, Severity:20, State: 11. A fatal error occurred while reading the input stream from the network. The session will be terminated (input error: 109, output error: 0)

    Hi,
    We are getting the following error when running our SSIS packages on Microsoft SQL Server 2012 R2 on Windows Server 2008 R2 SP1:
    Error: 4014, Severity:20, State: 11.   A fatal error occurred while reading the input stream from the network. The session will be terminated (input error: 109, output error: 0)
    SQL Server Data Tools and SQL Server Database Engine reside on the same server.
    We tried the following:
    Disabling TCP Chimney Offload
    Installed Windows Server 2008 SP1
    Splitting our SSIS code into multiple steps so it is not all one large continuous operation
    The error occurs during a BulkDataLoad task.
    Other options we are investigating with the engineering team (out-sourced, so delayed responses):
    Firewall configurations (everything is local, so this should not make a difference)
    Disabling the anti-virus scanner
    Are there other things we can try?
    Any insight is greatly appreciated.
    Thanks!

    Hi HenryKwan,
    Based on the current information, the issue can be caused by many reasons. Please refer to the following tips:
    Install the latest hotfix based on your SQL Server version. Ps: there is no SQL Server 2012 R2 version.
    Change the MaxConcurrentExecutables property from -1 to another one based on the MAXDOP. For example, 8.
    Set "RetainSameConnection" Property to FALSE on the all the connection managers.
    Reference:
    https://connect.microsoft.com/SQLServer/feedback/details/774370/ssis-packages-abort-with-unexpected-termination-message
    If the issue is still existed, as Jakub suggested, please provide us more information about this issue.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Fast Formula Error APP-FF-33629 (Unexpected End of Entry_Value)

    Hi,
    My formula successfully verified. I am getting following error message when application is trying to invoke the same formula. Error message says that:
    Error: “Unexpected End of ENTRY_VALUE(T)=:control entry_value line (trigger for Ded_Amt2)”.
    Cause: A formula was invoked via application Foundation. It was invoked using a #USR trigger step. One of the INPUT= or UDCOL= or OUTPUT= lines appears to have been truncated.
    Action: Please refer to your local support.
    I did not find any document on metalink for the same error.
    Please help me to resolve this error.
    Thanks in Advance.
    Regard.

    Are you still the getting the same error?
    there might be something missing while creating an element.
    What is the input value for the element?
    Is the name of your formula XX_TEST?
    And are you getting this error while verifying the formula?
    Try with following.
    INPUTS are HOURS_WORKED
    DEFAULT FOR XX_TRAVEL_RATE IS 0
    Inputs are HOURS_WORKED
    If (HOURS_WORKED  > 0) then
    L_WAGE = HOURS_WORKED * XX_TRAVEL_RATE
    Else
    L_WAGE =  1  *  XX_TRAVEL_RATE
    RETURN L_WAGE

  • Sending Control-Z to Input Stream

    Hi everyone,
    I'm writing an interface to a command line program, and
    one of it's features is that it will accept "forms" through
    standard input. The default is that notepad will open
    when the command is typed, and you can edit the form
    through there.
    To accept the form through standard input, you have to
    send it the form, and then tell it the form is complete.
    This is done using the CTRL-Z keypress, at least when
    typing the form in with the keyboard.
    I need to do this with Java.
    There is another post which poses the same question at
    http://forum.java.sun.com/thread.jsp?forum=1&thread=3050
    so I attempted that solution.. and that didn't work.
    I had the system print out the form as it was being written,
    and the form displayed properly, followed by what was
    supposed to be a CTRL-Z character, which appeared
    on screen (DOS Window) as an arrow pointing right.
    Here is the code constructing the form and adding what i've been told is "ctrl-z":
    new StringBuffer(form+System.getProperty("line.separator")).append(CTRL_Z).append(System.getProperty("line.separator")))CTRL_Z is defined as:
    public static final char CTRL_Z = 26;Does anyone have any other suggestions that might be able to help me?
    If you need more information/code provided, I can do so.
    Thanks for any help!
    Kefka.

    You can't actually send anything to an input stream. But let's suppose you have an output stream somewhere that is connected to the standard input of this command line program. Try sending a byte, not a character, that contains 26 to it (yes, ctrl-z is indeed 26). This has a better chance of working than the character idea, because Java is going to translate your character-26 from Unicode to bytes using your system's default encoding. And I can't predict what that might end up as. But it will leave the byte 26 alone and just send it... I hope. Can't guarantee this.

  • Bulk Insert Failure: Unexpected end of file

    Hi all,
    I have a Bulk Insert task which pulls data from a .csv file to SQL server table.
    It works fine 99 out of 100 times, but sometimes it throws the following error in production.
    "System exception: An error occurred with the following error message: "Cannot fetch a row from OLE DB provider "BULK" for linked server "(null)".The OLE DB provider "BULK" for linked server "(null)" reported an error. The provider did not give any information
    about the error.Bulk load: An unexpected end of file was encountered in the data file.".  "
    My Client says that there was no change to the file and it runs fine the next time.Its a error which I could not reproduce in development.
    I have an interface prior to this bulk insert interface to check whether the file is completely available(i.e i try to open the file and check whether its used by any other process).
    I'm supposed to give an answer for why it fails sometimes. Your thoughts on this?
    Rajkumar

    The Bulk insert task is used in SSIS package. The error Posted in my first post is what I got from SSIS..
    Why don't you use Data Flow task? BULK INSERT is fast, but not much error control.
    BOL quote ( http://msdn.microsoft.com/en-us/library/ms141679.aspx ) : "Error Handling in Data
    When a data flow component applies a transformation to column data, extracts data from sources, or loads data into destinations, errors can occur. Errors frequently occur because of unexpected data values. For example, a data conversion fails because a column
    contains a string instead of a number, an insertion into a database column fails because the data is a date and the column has a numeric data type, or an expression fails to evaluate because a column value is zero, resulting in a mathematical operation that
    is not valid.
    Errors typically fall into one the following categories:
    Data conversion errors, which occur if a conversion results in loss of significant digits, the loss of insignificant digits, and the truncation of strings. Data conversion errors also occur if the requested conversion is not supported.
    Expression evaluation errors, which occur if expressions that are evaluated at run time perform invalid operations or become syntactically incorrect because of missing or incorrect data values.
    Lookup errors, which occur if a lookup operation fails to locate a match in the lookup table.
    Many data flow components support error outputs, which let you control how the component handles row-level errors in both incoming and outgoing data. You specify how the component behaves when truncation or an error occurs by setting options on individual
    columns in the input or output. For example, you can specify that the component should fail if customer name data is truncated, but ignore errors on another column that contains less important data."
    http://msdn.microsoft.com/en-us/library/ms141679.aspx
    Kalman Toth SQL SERVER & BI TRAINING

  • Playing input stream audio in j2me

    want to make a text-to-speech synthesizer for mobile phones.
    for that i am using FreeTTS (text-to-speech synthesizer written in java)
    so i have made a client-server model where i have a midp client which is sending text to the FreeTTS acting as a server.... for this i am using socket...
    so basically -- client is sending text to server -- server processes the text and sends the audio stream back to client
    the problem is i dont know how to play the audio stream received on client side
    i tried to copy it in a buffer but its not working..
    do i need to save the file in some format before playing it?
    or can the player play the audio stream directly?
    this is how i am copying the contents in the buffer
    try
    InputStream is = socketConnection.openInputStream();
    byte[] buff = new byte[1024];
    int bytesIn = is.read(buff, 0, 1024);
    ByteArrayInputStream bis = new ByteArrayInputStream(buff);
    player = Manager.createPlayer(bis, "audio/x-wav" );
    player.start();
    but it gives an error saying
    javax.microedition.media.MediaException: Malformed wave media
    i tried to display the contents of bis on console it reads
    java.io.ByteArrayInputStream@d590dbc
    i tried the same with the Free TTS client and got the same output.
    so i think client socket is even receiving the audio stream properly...however, im not sure.
    is the whole client-server using socket idea correct?
    if yes, please tell me how to play this audio stream in j2me (the client)
    if it is wrong then please tell me a correct way to do this.
    can the input stream be stored as a WAV file and then played? if yes, then how can i store it as a WAV file? Can this be achieved by appending a WAV header?

    I once tried the similar thing, I ended up buffer all the content locally (from bluetooth), then play the wave file.
    Maybe someone else has better idea.

Maybe you are looking for