+ Reply to Thread
Results 1 to 6 of 6
This is a discussion on Objects not created in SalesForce (sporadically) within the Salesforce Coding Discussions forums, part of the Salesforce category; Every now and then, when sending objects to SalesForce via the API
  1. #1
    benbac is offline Junior Member
    Join Date
    Aug 2009
    Posts
    11

    Objects not created in SalesForce (sporadically)

    Every now and then, when sending objects to SalesForce via the API (phptoolkit), the create() call fails and the object does not get created (sporadically).

    We have a "Project" object in our web app and SF (custom). When a user submits a project in our app, it creates the sObject and sends it to SF in real time.

    I have a Util class that persists my php objects into my SF objects and sends it to SF. My way around it, for now, is to email myself the objects that are not created and have it manually inserted into SF.

    I was wondering if anyone else was having similar issues when creating/sending objects to SF on the fly and how you resolved it?

    Is there some sort of salesforce api timeout (in the partner wsdl?)?
    When the create() call fails do you retry several times?
    Do you store your objects in your db and set a CRON to send it? (i do this for other objects)

    I'm trying to get 100% of the projects that are submitted to be successfully created in SalesForce. A CRON is not the most favorable option due to the fact we need the "Projects" in real time.

    Any info would be appreciated.
    -Ben
    Last edited by benbac; 06-11-2010 at 05:00 PM.

  2. #2
    mike's Avatar
    mike is offline Administrator
    Join Date
    May 2007
    Location
    Wylie, Texas
    Posts
    607
    Blog Entries
    16
    Ben,

    When you say they are failing, and this may seems like a stupid response, but are you getting any sort of error back. I have only seen creates fail when something on the record fails.

    So if I am running a batch script to update products or accounts in Salesforce, there is a failure code that is returned in the object in the API

    Are these failures happening when creating only objects? or records

    Are you using the meta API to do this?

    Sorry for all the questions

    ~Mike

  3. #3
    benbac is offline Junior Member
    Join Date
    Aug 2009
    Posts
    11
    As of now I'm not getting any error codes back (specific error codes are not currently logged) just that the create() failed, the SforcePartnerClient() object returned success = false.

    Sorry, the failures are occurring when creating "records" (not objects) and i've only been seeing it fail with a specific object, then again, i'm not checking the other objects, since the other records are stored and added via crons (and are retried if it fails every few min). So i can't really say whether it's happening for other objects.

    As far as the newer metadata api, no, i'm using the core api calls.

    I'll be updating the code to log the errors from the create().
    So far, all objects have been created successfully the last 5 days

    - Ben

  4. #4
    mike's Avatar
    mike is offline Administrator
    Join Date
    May 2007
    Location
    Wylie, Texas
    Posts
    607
    Blog Entries
    16
    Keep me updated man, I would like to know if this persists! So if I understand this correctly, you are creating objects via CRON ? or records within an custom object within your Org ?

    Good news on the last 5 days!

    ~Mike

  5. #5
    benbac is offline Junior Member
    Join Date
    Aug 2009
    Posts
    11
    i'm creating records within a custom object in my org

  6. #6
    mike's Avatar
    mike is offline Administrator
    Join Date
    May 2007
    Location
    Wylie, Texas
    Posts
    607
    Blog Entries
    16
    That is what I thought... Just wanted to make sure

    Let me know if it fails dude, I would really like to keep up with this

    ~Mike

+ Reply to Thread

Similar Threads

  1. Upsert Record(s) related to other Objects
    By quantentunnel in forum Salesforce Coding Discussions
    Replies: 4
    Last Post: 04-09-2011, 05:46 AM
  2. how to search on multiple objects
    By jlowtek in forum Salesforce PHP Tutorials
    Replies: 3
    Last Post: 08-04-2009, 08:01 AM
  3. Salesforce PHP script which lists all Objects and Fields
    By mike in forum Salesforce PHP Tutorials
    Replies: 2
    Last Post: 03-27-2009, 01:14 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

SEO by vBSEO 3.5.2