Fix import of stream analytics jobs that have been created via Azure Portal #5522
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hey,
i found out that importing an existing Stream Analytics job that was created via the Portal didn't work. The reason was that a
transformation
object has a name property. It's used to read & update the transformation. Unfortunately it was calledTransformation
in this provider but Azure calls itmain
when you create the job in the portal.In this PR i changed the name to be also
main
. In order to keep backward compatibility i'm reading the name of the transformation before updating it.I tested the following:
All tests completed without any error.
I also ran all acc tests for this resource successfully.
If you want me to add any further tests pls let me know.