nicolaferraro commented on a change in pull request #235: Support for multiple 
integration definitions
URL: https://github.com/apache/camel-k/pull/235#discussion_r235686488
 
 

 ##########
 File path: pkg/trait/knative.go
 ##########
 @@ -214,6 +228,12 @@ func (t *knativeTrait) getConfiguredSourceChannels() 
[]string {
 }
 
 func (*knativeTrait) getSourceChannels(e *environment) []string {
-       meta := metadata.Extract(e.Integration.Spec.Source)
-       return knativeutil.ExtractChannelNames(meta.FromURIs)
+       channels := make([]string, 0)
+
+       for _, s := range e.Integration.Spec.Sources {
+               meta := metadata.Extract(s)
+               channels = append(channels, 
knativeutil.ExtractChannelNames(meta.FromURIs)...)
 
 Review comment:
   Maybe we should consider adding to the `meta` package some functions to 
inpect all sources without iterating on them each time.. For the future..

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to