Package com.webobjects.appserver.xml

Examples of com.webobjects.appserver.xml._JavaMonitorDecoder


    private NSDictionary[] generateResponseDictionaries(WOResponse[] responses) {
        NSDictionary[] responseDicts = new NSDictionary[responses.length];
        for (int i = 0; i < responses.length; i++) {
            if ((responses[i] != null) && (responses[i].content() != null)) {
                try {
                    responseDicts[i] = (NSDictionary) (new _JavaMonitorDecoder()).decodeRootObject(responses[i]
                            .content());
                } catch (WOXMLException wxe) {
                    responseDicts[i] = responseParsingFailed;
                }
            } else {
View Full Code Here


            for (int i = 0; i < responses.length; i++) {
                if ((responses[i] == null) || (responses[i].content() == null)) {
                    responseDictionary = emptyResponse;
                } else {
                    try {
                        responseDictionary = (NSDictionary) new _JavaMonitorDecoder().decodeRootObject(responses[i]
                                .content());
                    } catch (WOXMLException wxe) {
                        NSLog.err.appendln("MonitorComponent pageWithName(AppDetailPage) Error decoding response: "
                                + responses[i].contentString());
                        responseDictionary = responseParsingFailed;
View Full Code Here

            if ((responses[i] == null) || (responses[i].content() == null)) {
                responseDict = emptyResponse;
            } else {
                try {
                    responseDict = (NSDictionary) new _JavaMonitorDecoder().decodeRootObject(responses[i].content());
                } catch (WOXMLException wxe) {
                    NSLog.err.appendln("MonitorComponent pageWithName(HostsPage) Error decoding response: "
                            + responses[i].contentString());
                    responseDict = responseParsingFailed;
                }
View Full Code Here

        for (int i = 0; i < responses.length; i++) {
            if ((responses[i] == null) || (responses[i].content() == null)) {
                queryResponseDictionary = emptyResponse;
            } else {
                try {
                    queryResponseDictionary = (NSDictionary) new _JavaMonitorDecoder().decodeRootObject(responses[i]
                            .content());
                } catch (WOXMLException wxe) {
                    NSLog.err.appendln("MonitorComponent pageWithName(ApplicationsPage) Error decoding response: "
                            + responses[i].contentString());
                    queryResponseDictionary = responseParsingFailed;
View Full Code Here

      if (responseContentString.startsWith("ERROR")) {
        throw new MonitorException("Path " + thePath + " does not exist");
      }

      _JavaMonitorDecoder aDecoder = new _JavaMonitorDecoder();
      try {
        byte[] evilHackCombined = new byte[responseContentBytes.length + evilHack.length];
        // System.arraycopy(src, src_pos, dst, dst_pos, length);
        System.arraycopy(evilHack, 0, evilHackCombined, 0, evilHack.length);
        System.arraycopy(responseContentBytes, 0, evilHackCombined, evilHack.length,
            responseContentBytes.length);
        anArray = (NSArray) aDecoder.decodeRootObject(new NSData(evilHackCombined));
      } catch (WOXMLException wxe) {
        NSLog.err.appendln("RemoteBrowseClient _getFileListOutOfResponse Error decoding response: "
            + responseContentString);
        throw new MonitorException("Host returned bad response for path " + thePath);
      }
View Full Code Here

            theApplication._lock.endReading();
        }

        NSDictionary requestDict;
        try {
            requestDict = (NSDictionary) new _JavaMonitorDecoder().decodeRootObject(aRequest.content());
        } catch (WOXMLException wxe) {
            NSLog.err.appendln("Wotaskd monitorRequestAction: Error parsing request");
            if (NSLog.debugLoggingAllowedForLevelAndGroups(NSLog.DebugLevelInformational, NSLog.DebugGroupDeployment))
                NSLog.debug.appendln("Wotaskd monitorRequestAction: " + aRequest.contentString());
            aResponse.appendContentString(_invalidXML);
View Full Code Here

                }

                NSDictionary instanceResponse = null;
                NSData responseContent = aResponse.content();
                try {
                    instanceResponse = (NSDictionary) new _JavaMonitorDecoder().decodeRootObject(responseContent);
                } catch (WOXMLException wxe) {
                    try {
                        Object o = NSPropertyListSerialization.propertyListFromString(new String(responseContent.bytes()));
                        errorResponse.addObject(anInstance.displayName() + " is probably an older application that doesn't conform to the current Monitor Protocol. Please update and restart the instance.");
                        NSLog.err.appendln("Got old-style response from instance: " + anInstance.displayName());
View Full Code Here

        }

        NSDictionary xmlDict = NSDictionary.EmptyDictionary;
        if (aResponse != null) {
            try {
                xmlDict = (NSDictionary) new _JavaMonitorDecoder().decodeRootObject(aResponse.content());
            } catch (WOXMLException wxe) {
                log.error("Got non-parsable data from Host: " + configHostName + " + and Port: " + aPort + ". Data received was: " + aResponse.contentString() + ". It is possible that the Wotaskd on the remote host is of the wrong version");
                throw new MonitorException("Got non-parsable data from Host: " + configHostName + " + and Port: " + aPort + ". Data received was: " +aResponse.contentString() + ". It is possible that the Wotaskd on the remote host is of the wrong version");
            }
        }
View Full Code Here

        // now, the file should exist, or we have an error.
        //
        if (fileForSiteConfig().exists()) {
            if (fileForSiteConfig().canRead()) {
                try {
                    NSDictionary siteDict = (NSDictionary) (new _JavaMonitorDecoder().decodeRootObject(pathForSiteConfig()));
                    aConfig = new MSiteConfig(siteDict);
                    if (NSLog.debugLoggingAllowedForLevelAndGroups(NSLog.DebugLevelDetailed, NSLog.DebugGroupDeployment))
                        NSLog.debug.appendln("the SiteConfig is \n" + aConfig.generateSiteConfigXML());
                } catch (Throwable ex) {
                    if (isWotaskd) {
View Full Code Here

TOP

Related Classes of com.webobjects.appserver.xml._JavaMonitorDecoder

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.