Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom Domain Patch #66

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

adasgupta
Copy link

@adasgupta adasgupta commented Feb 10, 2017

  1. Modified the parse_instance() method inside SalesforecBulkApi Module to accommodate domain names that start with 2 alphabets and are followed by digits.

If the domain name is something like 'ab12cdef' and the salesforce instance url is 'ab12cdef.my.salesforce.com'.
The original code would evaluate the instance to ab12.salesforce.com
That would result in "Failed to open TCP connection to ab12.salesforce.com:443 (getaddrinfo: Name or service not known)" error as the host could not be resolved.

I have changed the evaluation of the @instance as follows:

@instance = @server_url.match(/https://[a-z]{2}[0-9]{1,2}./).to_s.gsub("https://","").split(".")[0]
@instance = @server_url.split(".salesforce.com")[0].split("://")[1] if @instance.nil? || @instance.empty?

  1. Added instructions to the README to show OAuth2 mode of authentication and the mandatory options to pass to restforce client while using client.authenticate!

Modified the parse instance method inside SalesforecBulkApi Module to accommodate domain names that start with 2 alphabets and are followed by digits
Added instructions to the README to show oauth mode of authentication and the mandatory options to pass to restforce client while using authenticate method
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant