diff --git a/pkg/source/pubsub/pubsub_source.go b/pkg/source/pubsub/pubsub_source.go index 5481f48b..34f9a07a 100644 --- a/pkg/source/pubsub/pubsub_source.go +++ b/pkg/source/pubsub/pubsub_source.go @@ -33,8 +33,8 @@ type Configuration struct { ConcurrentWrites int `hcl:"concurrent_writes,optional"` MaxOutstandingMessages int `hcl:"max_outstanding_messages,optional"` MaxOutstandingBytes int `hcl:"max_outstanding_bytes,optional"` - minExtensionPeriodSeconds int `hcl:"min_extension_period_seconds"` - streamingPullGoRoutines int `hcl:"streaming_pull_goroutines"` + minExtensionPeriodSeconds int `hcl:"min_extension_period_seconds,optional"` + streamingPullGoRoutines int `hcl:"streaming_pull_goroutines,optional"` } // pubSubSource holds a new client for reading messages from PubSub diff --git a/pkg/source/pubsub/pubsub_source_test.go b/pkg/source/pubsub/pubsub_source_test.go index 60bdc08a..cc977ce9 100644 --- a/pkg/source/pubsub/pubsub_source_test.go +++ b/pkg/source/pubsub/pubsub_source_test.go @@ -13,6 +13,7 @@ package pubsubsource import ( "context" + "fmt" "os" "path/filepath" "sort" @@ -82,6 +83,9 @@ func TestPubSubSource_ReadAndReturnSuccessIntegration(t *testing.T) { assert.NotNil(pubsubSource) assert.Nil(err) + if err != nil { + fmt.Println(err.Error()) + } assert.Equal("projects/project-test/subscriptions/test-sub", pubsubSource.GetID()) output := testutil.ReadAndReturnMessages(pubsubSource, 5*time.Second, testutil.DefaultTestWriteBuilder, nil)