Skip to content

Commit

Permalink
set hard coded collector app endpoint (#1836)
Browse files Browse the repository at this point in the history
  • Loading branch information
shirmoran authored Jan 26, 2024
1 parent ffe37b4 commit 2d7f1bd
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 14 deletions.
1 change: 0 additions & 1 deletion cnf-certification-test/tnf_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ servicesignorelist:
- "hazelcast-platform-webhook-service"
- "new-pro-controller-manager-metrics-service"
- "mysql"
collectorAppEndPoint: ""
executedBy: ""
partnerName: ""
collectorAppPassword: ""
3 changes: 0 additions & 3 deletions cnf-certification-test/webserver/webserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -390,9 +390,6 @@ func updateTnf(tnfConfig []byte, data *RequestedData) []byte {

config.ServicesIgnoreList = data.Servicesignorelist
config.ValidProtocolNames = data.ValidProtocolNames
if len(data.CollectorAppEndPoint) > 0 {
config.CollectorAppEndPoint = data.CollectorAppEndPoint[0]
}
if len(data.CollectorAppPassword) > 0 {
config.CollectorAppPassword = data.CollectorAppPassword[0]
}
Expand Down
5 changes: 0 additions & 5 deletions pkg/autodiscover/autodiscover.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ type DiscoveredTestData struct {
StorageClasses []storagev1.StorageClass
ServicesIgnoreList []string
ScaleCrUnderTest []ScaleObject
CollectorAppEndPoint string
ExecutedBy string
PartnerName string
CollectorAppPassword string
Expand Down Expand Up @@ -245,10 +244,6 @@ func DoAutoDiscover(config *configuration.TestConfiguration) DiscoveredTestData
os.Exit(1)
}

if config.CollectorAppEndPoint == "" {
config.CollectorAppEndPoint = "http://localhost:8080"
}
data.CollectorAppEndPoint = config.CollectorAppEndPoint
data.ExecutedBy = config.ExecutedBy
data.PartnerName = config.PartnerName
data.CollectorAppPassword = config.CollectorAppPassword
Expand Down
5 changes: 3 additions & 2 deletions pkg/certsuite/certsuite.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ func LoadChecksDB(labelsExpr string) {
}

const (
junitXMLOutputFile = "cnf-certification-tests_junit.xml"
junitXMLOutputFile = "cnf-certification-tests_junit.xml"
collectorAppEndPoint = "http://44.195.143.94"
)

func getK8sClientsConfigFileNames() []string {
Expand Down Expand Up @@ -150,7 +151,7 @@ func Run(labelsFilter, outputFolder string) error {

// Send claim file to the collector if specified by env var
if configuration.GetTestParameters().EnableDataCollection {
err = collector.SendClaimFileToCollector(env.CollectorAppEndPoint, claimOutputFile, env.ExecutedBy, env.PartnerName, env.CollectorAppPassword)
err = collector.SendClaimFileToCollector(collectorAppEndPoint, claimOutputFile, env.ExecutedBy, env.PartnerName, env.CollectorAppPassword)
if err != nil {
log.Error("Failed to send post request to the collector: %v", err)
}
Expand Down
1 change: 0 additions & 1 deletion pkg/configuration/configuration.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ type TestConfiguration struct {
ServicesIgnoreList []string `yaml:"servicesignorelist,omitempty" json:"servicesignorelist,omitempty"`
DebugDaemonSetNamespace string `yaml:"debugDaemonSetNamespace,omitempty" json:"debugDaemonSetNamespace,omitempty"`
// Collector's parameters
CollectorAppEndPoint string `yaml:"collectorAppEndPoint,omitempty" json:"collectorAppEndPoint,omitempty"`
ExecutedBy string `yaml:"executedBy,omitempty" json:"executedBy,omitempty"`
PartnerName string `yaml:"partnerName,omitempty" json:"partnerName,omitempty"`
CollectorAppPassword string `yaml:"collectorAppPassword,omitempty" json:"collectorAppPassword,omitempty"`
Expand Down
2 changes: 0 additions & 2 deletions pkg/provider/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ type TestEnvironment struct { // rename this with testTarget
DaemonsetFailedToSpawn bool
ScaleCrUnderTest []ScaleObject
StorageClassList []storagev1.StorageClass
CollectorAppEndPoint string
ExecutedBy string
PartnerName string
CollectorAppPassword string
Expand Down Expand Up @@ -295,7 +294,6 @@ func buildTestEnvironment() { //nolint:funlen
env.HorizontalScaler = data.Hpas
env.StorageClassList = data.StorageClasses

env.CollectorAppEndPoint = data.CollectorAppEndPoint
env.ExecutedBy = data.ExecutedBy
env.PartnerName = data.PartnerName
env.CollectorAppPassword = data.CollectorAppPassword
Expand Down

0 comments on commit 2d7f1bd

Please sign in to comment.