• zbeckman
  • NEWBIE
  • 0 Points
  • Member since 2006

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 6
    Replies
Yesterday our Salesforce integration apparently went sour. Our systems have been offline (they are completely powered by Salesforce) and I've been trying to diagnose what's wrong ever since.

I have upgraded to the latest PHP library (1.1.1) and the latest WSDL files (which were bundled with it, version 9.0). Now I'm trying to execute this simple test, bundled with the samples in the PHP kit. I can't even get a login to work:

require_once ('../soapclient/SforcePartnerClient.php');

try {
$mySforceConnection = new SforcePartnerClient();
$mySoapClient = $mySforceConnection->createConnection("partner.wsdl.xml");
$mylogin = $mySforceConnection->login("zbeckman@xyz.com", "xyz");

$userResult = $mylogin->userInfo;
echo $userResult->userFullName.', your session id is '.$mylogin->sessionId;
} catch (Exception $e) {
echo $e->faultstring;
}

The output of this is:

Could not connect to host

Obviously I've changed the login credentials, but otherwise, nothing. I have verified that I can login to Salesforce.com (using Firefox) with the credentials, so it's not a matter of the account having issues.

Any help would be appreciated. As I said, our systems are down -- and the best we can tell on this end, it looks like Salesforce.com has stopped allowing logins. Nothing on our site changed, so by all means it looked like a regular maintenance outage... but now it has been over 24 hours.
Today, apparently spontaneously, our PHP front end to Salesforce started spewing the following errors:

[Mon Jun 18 17:22:24 2007] [error] PHP Fatal error: SoapClient::SoapClient() [function.SoapClient-SoapClient]: 'uri' option is requred in nonWSDL mode in /Library/WebServer/STI/soapclient/SforceBaseClient.php on line 57

The error corresponds to a line in the Salesforce PHP kit shown below, note the line with an asterisk:

public function createConnection($wsdl) {
$_SERVER['HTTP_USER_AGENT'] = 'Salesforce/PHPToolkit/1.0';

// Bug #36283 SOAPClient Compression Broken. Fix will be in the release after 5.1.2
// $this->sforce = new SoapClient($wsdl, array('compression' => SOAP_COMPRESSION_ACCEPT | SOAP_COMPRESSION_GZIP));
* $this->sforce = new SoapClient($wsdl, array('trace' => 1, 'encoding' => 'utf-8'));
return $this->sforce;
}

Not only has the code not changed, but it's not even ours (part of the PHP API kit from Salesforce). It's been running fine for over a year... can anyone offer pointers as to why our site is now suddently disfunctional?

As it's taken down our production system, this is a critical issue. I'd really appreciate any assistance.
I haven't found much evidence of Python support in the APIs. I've done PHP integration using the older (version 5) API and we are now moving to Python. Any pointers would be appreciated... I'm hoping it's not a "build it from scratch" situation (although, how hard could it be really)?
I'm trying to update an SFDC_Enrollment__c custom object. There are no errors showing up in the logs and it seems like it should have worked, but the database isn't updating. The code:

syslog(LOG_ERR, "Updating record for " . $enrollmentId . ".");
$enrollmentQueryResults = sforceQuery($connection, 1, "SELECT Id, Payment_Status__c, Payment_Amount__c from SFDC_Enrollment__c where Name = '" . $enrollmentId . "'");
if ($enrollmentQueryResults->records[0]) {
$enrollment = new SObject($enrollmentQueryResults->records[0]);
$enrollment->fields->Payment_Status__c = "Paid";
$result = $connection->update(array($enrollment));
syslog(LOG_ERR, "Order " . $enrollmentId . " received and status updated: " . $result . ".");
}

Generates this log message:

Jun 9 10:09:14 server /usr/sbin/httpd: Enrollment update for 200606-0062 received.
Jun 9 10:09:14 server /usr/sbin/httpd: Updating record for 200606-0062.
Jun 9 10:09:14 server /usr/sbin/httpd: Order 200606-0062 received and status updated: Object id #11.

No PHP errors, etc, but the database is unchanged. Any ideas?
Hi Everyone
 
I am getting the following error sometimes. I am using the PHP toolkit

SoapFault exception: [Client] SoapClient::__construct() [<a href='function.SoapClient---construct'>function.SoapClient---construct</a>]: 'uri' option is requred in nonWSDL mode in /home/clients/websites/w_angel/public_html/epifany/soapclient/SforceBaseClient.php:59

Stack trace:

#0 /home/clients/websites/w_angel/public_html/epifany/soapclient/SforceBaseClient.php(59): SoapClient->__construct(NULL, Array)

#1 /home/clients/websites/w_angel/public_html/epifany/selfserviceuser/SelfServiceUserUtility.php(152): SforceBaseClient->createConnection(NULL)

#2 /home/clients/websites/w_angel/public_html/epifany/ssp/hangup.php(8): SelfServiceUserUtility->__construct(NULL, NULL, NULL)

This happens sometimes, It was happening yesterday around 11.45 AM EST and last night at around 10.45 PM EST.

What can be the issue here, I don't understand. I have not changed the code at all.

 

DG

  • October 11, 2007
  • Like
  • 0
Yesterday our Salesforce integration apparently went sour. Our systems have been offline (they are completely powered by Salesforce) and I've been trying to diagnose what's wrong ever since.

I have upgraded to the latest PHP library (1.1.1) and the latest WSDL files (which were bundled with it, version 9.0). Now I'm trying to execute this simple test, bundled with the samples in the PHP kit. I can't even get a login to work:

require_once ('../soapclient/SforcePartnerClient.php');

try {
$mySforceConnection = new SforcePartnerClient();
$mySoapClient = $mySforceConnection->createConnection("partner.wsdl.xml");
$mylogin = $mySforceConnection->login("zbeckman@xyz.com", "xyz");

$userResult = $mylogin->userInfo;
echo $userResult->userFullName.', your session id is '.$mylogin->sessionId;
} catch (Exception $e) {
echo $e->faultstring;
}

The output of this is:

Could not connect to host

Obviously I've changed the login credentials, but otherwise, nothing. I have verified that I can login to Salesforce.com (using Firefox) with the credentials, so it's not a matter of the account having issues.

Any help would be appreciated. As I said, our systems are down -- and the best we can tell on this end, it looks like Salesforce.com has stopped allowing logins. Nothing on our site changed, so by all means it looked like a regular maintenance outage... but now it has been over 24 hours.
Today, apparently spontaneously, our PHP front end to Salesforce started spewing the following errors:

[Mon Jun 18 17:22:24 2007] [error] PHP Fatal error: SoapClient::SoapClient() [function.SoapClient-SoapClient]: 'uri' option is requred in nonWSDL mode in /Library/WebServer/STI/soapclient/SforceBaseClient.php on line 57

The error corresponds to a line in the Salesforce PHP kit shown below, note the line with an asterisk:

public function createConnection($wsdl) {
$_SERVER['HTTP_USER_AGENT'] = 'Salesforce/PHPToolkit/1.0';

// Bug #36283 SOAPClient Compression Broken. Fix will be in the release after 5.1.2
// $this->sforce = new SoapClient($wsdl, array('compression' => SOAP_COMPRESSION_ACCEPT | SOAP_COMPRESSION_GZIP));
* $this->sforce = new SoapClient($wsdl, array('trace' => 1, 'encoding' => 'utf-8'));
return $this->sforce;
}

Not only has the code not changed, but it's not even ours (part of the PHP API kit from Salesforce). It's been running fine for over a year... can anyone offer pointers as to why our site is now suddently disfunctional?

As it's taken down our production system, this is a critical issue. I'd really appreciate any assistance.