• kottegron
  • NEWBIE
  • 10 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 2
    Replies

Hi Salesforce Developers

I have a problem reaching limits "Streaming API events, last 24 hours". 
In a few hours we will reach the limits which will cause business flows to stop. 

What I want to know is if there is a way to view which operations cause all these events. I have to clues. 
1. Salesforce for Outlook 
2. a Call Center Integration

Does anyone know any tools which can monitor what is reponsible for all these push topics
pushTopicId sum(numEvents)
0IFb0000000CbJ9 796144
0IFb00000008OS2 215551
0IFb00000008OS5 3535
0IFb00000008OS1 1927
0IFb00000008OS4 45

Thanks!!

Hi everyone!

I'm trying to validate a Event field with a trigger. I'm using a trigger because it's dependent on values in the Account object. I want to show the user an error with sObject.addError() method. The test scenarios in the Salesforce GUI for 1 record at a time is working fine however the test class is failing. I'm creating 200 event records and inserting them at the same time. 

/*test class*/
try{
insert eventList;
 }
catch (Exception e) {
System.assert(e.getMessage().contains('The error message that should be shown'), e.getMessage());
 }

/*Event handler method*/
public void displayErrorMessage(List<Account> accountList){
      for (Account acc : accountList){
             if(acc.Type == 'Agency')
                eventMap.get(acc.Id).WhatID.addError('The error message that should be shown', false);
      }
}

/*Trigger*

trigger EventBefore on Event (before insert, before update) {
      if(Trigger.isInsert || Trigger.isUpdate){
          Event_TypeOfMeetingHandler handler = new Event_TypeOfMeetingHandler( trigger.new );
      }
}

THIS IS THE ERROR MESSAGE I'M GETTING:

 
Insert failed. First exception on row 0; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, Too many retries of batch save in the presence of Apex triggers with failures: when triggers are present partial save requires that some subset of rows save without any errors in order to avoid inconsistent side effects from those triggers. Number of retries: 2: []

THE TEST WORKS FINE FOR THE FOLLOWING TRIGGER CODE. INSERT ONLY THOUGH.  
trigger EventBefore on Event (before insert) {
      if(Trigger.isInsert){
          Event_TypeOfMeetingHandler handler = new Event_TypeOfMeetingHandler( trigger.new );
      }
}

What am I doing wrong in the Trigger handler alternative what can I do in the test class to make this work for multiple insert and updates on  Event records? 

Thanks!

I'm setting up a Salesforce regression test environment and using Selenium IDE for firefox.

When Logged in to my Salesforce Org using Firefox I first create an Account Record and than I delete the same record without and complications.

However when I start the Selenium IDE recording and performing the same test use case, then there is a problem when trying to delete the account record. The creation of the account record works but the deletion of the same record is not working. So the Button "Delete" in the UI in Firefox is not responding to me clicking.

The console output in Firefox is giving me this error: Error: Permission denied to access property "apply"

Why is Selenium IDE preventing me from performing this simple test scenario, and what could I do for this to work?

Also I've tried to perform the same test Scenario using PhantomJS instead of firefox and it's still just a problem deleting the Record. So it should be Selenium related error? Thanks in advance

Hi everyone!

I'm trying to validate a Event field with a trigger. I'm using a trigger because it's dependent on values in the Account object. I want to show the user an error with sObject.addError() method. The test scenarios in the Salesforce GUI for 1 record at a time is working fine however the test class is failing. I'm creating 200 event records and inserting them at the same time. 

/*test class*/
try{
insert eventList;
 }
catch (Exception e) {
System.assert(e.getMessage().contains('The error message that should be shown'), e.getMessage());
 }

/*Event handler method*/
public void displayErrorMessage(List<Account> accountList){
      for (Account acc : accountList){
             if(acc.Type == 'Agency')
                eventMap.get(acc.Id).WhatID.addError('The error message that should be shown', false);
      }
}

/*Trigger*

trigger EventBefore on Event (before insert, before update) {
      if(Trigger.isInsert || Trigger.isUpdate){
          Event_TypeOfMeetingHandler handler = new Event_TypeOfMeetingHandler( trigger.new );
      }
}

THIS IS THE ERROR MESSAGE I'M GETTING:

 
Insert failed. First exception on row 0; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, Too many retries of batch save in the presence of Apex triggers with failures: when triggers are present partial save requires that some subset of rows save without any errors in order to avoid inconsistent side effects from those triggers. Number of retries: 2: []

THE TEST WORKS FINE FOR THE FOLLOWING TRIGGER CODE. INSERT ONLY THOUGH.  
trigger EventBefore on Event (before insert) {
      if(Trigger.isInsert){
          Event_TypeOfMeetingHandler handler = new Event_TypeOfMeetingHandler( trigger.new );
      }
}

What am I doing wrong in the Trigger handler alternative what can I do in the test class to make this work for multiple insert and updates on  Event records? 

Thanks!

Hi everyone!

I'm trying to validate a Event field with a trigger. I'm using a trigger because it's dependent on values in the Account object. I want to show the user an error with sObject.addError() method. The test scenarios in the Salesforce GUI for 1 record at a time is working fine however the test class is failing. I'm creating 200 event records and inserting them at the same time. 

/*test class*/
try{
insert eventList;
 }
catch (Exception e) {
System.assert(e.getMessage().contains('The error message that should be shown'), e.getMessage());
 }

/*Event handler method*/
public void displayErrorMessage(List<Account> accountList){
      for (Account acc : accountList){
             if(acc.Type == 'Agency')
                eventMap.get(acc.Id).WhatID.addError('The error message that should be shown', false);
      }
}

/*Trigger*

trigger EventBefore on Event (before insert, before update) {
      if(Trigger.isInsert || Trigger.isUpdate){
          Event_TypeOfMeetingHandler handler = new Event_TypeOfMeetingHandler( trigger.new );
      }
}

THIS IS THE ERROR MESSAGE I'M GETTING:

 
Insert failed. First exception on row 0; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, Too many retries of batch save in the presence of Apex triggers with failures: when triggers are present partial save requires that some subset of rows save without any errors in order to avoid inconsistent side effects from those triggers. Number of retries: 2: []

THE TEST WORKS FINE FOR THE FOLLOWING TRIGGER CODE. INSERT ONLY THOUGH.  
trigger EventBefore on Event (before insert) {
      if(Trigger.isInsert){
          Event_TypeOfMeetingHandler handler = new Event_TypeOfMeetingHandler( trigger.new );
      }
}

What am I doing wrong in the Trigger handler alternative what can I do in the test class to make this work for multiple insert and updates on  Event records? 

Thanks!

I'm setting up a Salesforce regression test environment and using Selenium IDE for firefox.

When Logged in to my Salesforce Org using Firefox I first create an Account Record and than I delete the same record without and complications.

However when I start the Selenium IDE recording and performing the same test use case, then there is a problem when trying to delete the account record. The creation of the account record works but the deletion of the same record is not working. So the Button "Delete" in the UI in Firefox is not responding to me clicking.

The console output in Firefox is giving me this error: Error: Permission denied to access property "apply"

Why is Selenium IDE preventing me from performing this simple test scenario, and what could I do for this to work?

Also I've tried to perform the same test Scenario using PhantomJS instead of firefox and it's still just a problem deleting the Record. So it should be Selenium related error? Thanks in advance