Skip to content

Commit

Permalink
Merge pull request #31 from rog-golang-buddies/feature/apispec_external
Browse files Browse the repository at this point in the history
Switch to external API spec document dependency.
  • Loading branch information
ldmi3i authored Aug 24, 2022
2 parents 36a91a5 + 73f0012 commit 508025a
Show file tree
Hide file tree
Showing 23 changed files with 109 additions and 408 deletions.
1 change: 1 addition & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ require (
github.com/golang/mock v1.6.0
github.com/kelseyhightower/envconfig v1.4.0
github.com/rabbitmq/amqp091-go v1.4.0
github.com/rog-golang-buddies/api_hub_common v0.0.3
github.com/stretchr/testify v1.8.0
github.com/wagslane/go-rabbitmq v0.10.0
go.uber.org/zap v1.22.0
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/rabbitmq/amqp091-go v1.4.0 h1:T2G+J9W9OY4p64Di23J6yH7tOkMocgnESvYeBjuG9cY=
github.com/rabbitmq/amqp091-go v1.4.0/go.mod h1:JsV0ofX5f1nwOGafb8L5rBItt9GyhfQfcJj+oyz0dGg=
github.com/rog-golang-buddies/api_hub_common v0.0.3 h1:ABg+GOuVfhjL5x3yjqBZRVvWnJ9izs/yS1iARqVi7s0=
github.com/rog-golang-buddies/api_hub_common v0.0.3/go.mod h1:9qNVWp7RgAcS7xVtPbALrWIYXh0DWKZakw7tWo2sE6k=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
Expand Down
2 changes: 1 addition & 1 deletion internal/config/logger.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package config

//LoggerConfig represents configuration of the logger
// LoggerConfig represents configuration of the logger
type LoggerConfig struct {
Level LoggerLevel `default:"info"` //Level of minimum logging
}
2 changes: 1 addition & 1 deletion internal/config/queue.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package config

//QueueConfig queue configuration
// QueueConfig queue configuration
type QueueConfig struct {
//UrlRequestQueue name to listen to the new events
UrlRequestQueue string `default:"data-scraping-asd" envconfig:"URL_REQUEST_QUEUE"`
Expand Down
4 changes: 2 additions & 2 deletions internal/config/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ package config

import "go.uber.org/zap/zapcore"

//Environment defines the application environment to adjust settings to it.
// Environment defines the application environment to adjust settings to it.
type Environment string

const (
Dev Environment = "dev"
Prod Environment = "prod"
)

//LoggerLevel defines the minimum logging level to process
// LoggerLevel defines the minimum logging level to process
type LoggerLevel string

const (
Expand Down
229 changes: 0 additions & 229 deletions internal/dto/apiSpecDoc/apiSpecDoc.go

This file was deleted.

75 changes: 0 additions & 75 deletions internal/dto/apiSpecDoc/types.go

This file was deleted.

4 changes: 2 additions & 2 deletions internal/dto/scrapingResult.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package dto

import "github.com/rog-golang-buddies/api-hub_data-scraping-service/internal/dto/apiSpecDoc"
import "github.com/rog-golang-buddies/api_hub_common/apispecdoc"

type ScrapingResult struct {
IsNotifyUser bool

ApiSpecDoc *apiSpecDoc.ApiSpecDoc
ApiSpecDoc *apispecdoc.ApiSpecDoc
}
3 changes: 2 additions & 1 deletion internal/logger/logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ import (
"github.com/rog-golang-buddies/api-hub_data-scraping-service/internal/config"
)

//Logger represents common logger interface
// Logger represents common logger interface
//
//go:generate mockgen -source=logger.go -destination=./mocks/logger.go
type Logger interface {
Fatal(args ...interface{})
Expand Down
Loading

0 comments on commit 508025a

Please sign in to comment.