Retrieving EmailService/EmailServicesFunction

99 views
Skip to first unread message

Chris S

unread,
May 20, 2021, 2:51:47 PM5/20/21
to Illuminated Cloud Q&A
Scott,


Email Services have me confused. When I retrieve using IC2, email service metadata is retrieved into:

/force-app/main/default/emailservices

However, trying to actually deploy this doesnt work, either from IC2 (it failed to queue up the deployment) or from the CLI directly running:

PS C:\git\student-support> sfdx force:source:deploy -m "EmailService"
ERROR running force:source:deploy:  The specified metadata type is unsupported: [EmailService]

...however, I noted that the metadata is actually EmailServicesFunction, so I tried again:

PS C:\git\student-support> sfdx force:source:deploy -m "EmailServicesFunction"
=== Deployed Source
No results found

...still no good. I renamed the folder that the file resides in to /emailservicesfunction/ and tried again, and this time it worked! Great Success!

The same thing was true with running the retrieve command directly from the CLI:

PS C:\git\student-support> sfdx force:source:retrieve -m "EmailServices"
ERROR running force:source:retrieve:  The specified metadata type is unsupported: [EmailServices]
PS C:\git\student-support> sfdx force:source:retrieve -m "EmailServicesFunction"
(success)

It seems like running the CLI for this metadata type puts the file in the right location to push/pull, but the behavior I see in IC2's retrieve/deploy does not work the same way (it wants to use /emailservices/ and fails).

Long story short - Is this a SF bug? A CLI bug? An IC2 bug? I'm not sure where to go from here and it seemed like something to report.

Thanks in advance for any info you might have!

Scott

unread,
May 20, 2021, 3:02:47 PM5/20/21
to Illuminated Cloud Q&A, Chris S
I'm honestly not 100% sure what's going on, but I'm sure we can figure it out. For the most part IC2 uses the metadata information available via the API to determine how to map that metadata to local files. In this case I don't know whether it was the CLI that placed the initial retrieved file under "emailservices" or if IC2 did something itself. My guess is that it's the former, but either way something incorrect seems to have happened.

Do you mind logging this as a bug in the public issue tracker so that it's more concretely on my working radar vs. here in the public groups? I'll try to reproduce the behavior myself locally, but if I'm unable to do so I'll request additional diagnostic information from you via the logged bug.

Regards,
Scott Wells

Chris S

unread,
May 20, 2021, 3:34:08 PM5/20/21
to Illuminated Cloud Q&A, Scott, Chris S
Reply all
Reply to author
Forward
0 new messages