Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion test/c3/appframework/appframework_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -709,7 +709,7 @@ var _ = Describe("c3appfw test", func() {
// Create Single site Cluster and SHC, with App Framework enabled on SHC Deployer
// Deploy the CM
testenvInstance.Log.Info("Deploy Cluster manager in single site configuration")
_, err = deployment.DeployClusterMaster(deployment.GetName(), "", "")
_, err = deployment.DeployClusterMaster(deployment.GetName(), "", "", "")
Expect(err).To(Succeed(), "Unable to deploy Cluster Manager")

// Deploy the indexer cluster
Expand Down
49 changes: 37 additions & 12 deletions test/custom_resource_crud/custom_resource_crud_c3_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,11 @@ var _ = Describe("Crcrud test for SVA C3", func() {
})

Context("Clustered deployment (C3 - clustered indexer, search head cluster)", func() {
It("crcrud: can deploy indexer and search head cluster, change their CR, update the instances", func() {
It("crcrud, integration, c3: can deploy indexer and search head cluster, change their CR, update the instances", func() {

// Deploy Single site Cluster and Search Head Clusters
err := deployment.DeploySingleSiteCluster(deployment.GetName(), 3, true /*shc*/)
mcRef := deployment.GetName()
err := deployment.DeploySingleSiteCluster(deployment.GetName(), 3, true /*shc*/, mcRef)
Expect(err).To(Succeed(), "Unable to deploy cluster")

// Ensure that the Cluster Manager goes to Ready phase
Expand All @@ -68,8 +69,12 @@ var _ = Describe("Crcrud test for SVA C3", func() {
// Ensure Search Head Cluster go to Ready phase
testenv.SearchHeadClusterReady(deployment, testenvInstance)

// Verify MC Pod is Ready
// testenv.MCPodReady(testenvInstance.GetName(), deployment)
// Deploy Monitoring Console CRD
mc, err := deployment.DeployMonitoringConsole(mcRef, "")
Expect(err).To(Succeed(), "Unable to deploy Monitoring Console One instance")

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify RF SF is met
testenv.VerifyRFSFMet(deployment, testenvInstance)
Expand Down Expand Up @@ -130,6 +135,9 @@ var _ = Describe("Crcrud test for SVA C3", func() {
// Verify Search Head go to ready state
testenv.SearchHeadClusterReady(deployment, testenvInstance)

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify CPU limits on Search Heads after updating the CR
for i := 0; i < searchHeadCount; i++ {
SearchHeadPodName := fmt.Sprintf(testenv.SearchHeadPod, deployment.GetName(), i)
Expand All @@ -139,10 +147,11 @@ var _ = Describe("Crcrud test for SVA C3", func() {
})

Context("Clustered deployment (C3 - clustered indexer, search head cluster)", func() {
It("crcrud, integration: can verify IDXC, CM and SHC PVCs are correctly deleted after the CRs deletion", func() {
It("crcrud, integration, c3: can verify IDXC, CM and SHC PVCs are correctly deleted after the CRs deletion", func() {

// Deploy Single site Cluster and Search Head Clusters
err := deployment.DeploySingleSiteCluster(deployment.GetName(), 3, true /*shc*/)
mcRef := deployment.GetName()
err := deployment.DeploySingleSiteCluster(deployment.GetName(), 3, true /*shc*/, mcRef)
Expect(err).To(Succeed(), "Unable to deploy cluster")

// Ensure that the Cluster Manager goes to Ready phase
Expand All @@ -154,8 +163,12 @@ var _ = Describe("Crcrud test for SVA C3", func() {
// Ensure Search Head Cluster go to Ready phase
testenv.SearchHeadClusterReady(deployment, testenvInstance)

// Verify MC Pod is Ready
// testenv.MCPodReady(testenvInstance.GetName(), deployment)
// Deploy Monitoring Console CRD
mc, err := deployment.DeployMonitoringConsole(mcRef, "")
Expect(err).To(Succeed(), "Unable to deploy Monitoring Console One instance")

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify RF SF is met
testenv.VerifyRFSFMet(deployment, testenvInstance)
Expand All @@ -174,21 +187,30 @@ var _ = Describe("Crcrud test for SVA C3", func() {

// Delete the Search Head Cluster
shc := &enterpriseApi.SearchHeadCluster{}
deployment.GetInstance(deployment.GetName()+"-shc", shc)
err = deployment.GetInstance(deployment.GetName()+"-shc", shc)
Expect(err).To(Succeed(), "Unable to GET SHC instance", "SHC Name", shc)
err = deployment.DeleteCR(shc)
Expect(err).To(Succeed(), "Unable to delete SHC instance", "SHC Name", shc)

// Delete the Indexer Cluster
idxc := &enterpriseApi.IndexerCluster{}
deployment.GetInstance(deployment.GetName()+"-idxc", idxc)
err = deployment.GetInstance(deployment.GetName()+"-idxc", idxc)
Expect(err).To(Succeed(), "Unable to GET IDXC instance", "IDXC Name", idxc)
err = deployment.DeleteCR(idxc)
Expect(err).To(Succeed(), "Unable to delete IDXC instance", "IDXC Name", idxc)

// Delete the Cluster Manager
cm := &enterpriseApi.ClusterMaster{}
deployment.GetInstance(deployment.GetName(), cm)
err = deployment.GetInstance(deployment.GetName(), cm)
Expect(err).To(Succeed(), "Unable to GET Cluster Manager instance", "Cluster Manager Name", cm)
err = deployment.DeleteCR(cm)
Expect(err).To(Succeed(), "Unable to delete CM instance", "CM Name", cm)
Expect(err).To(Succeed(), "Unable to delete Cluster Manager instance", "Cluster Manger Name", cm)

// Delete Monitoring Console
err = deployment.GetInstance(mcRef, mc)
Expect(err).To(Succeed(), "Unable to GET Monitoring Console instance", "Monitoring Console Name", mcRef)
err = deployment.DeleteCR(mc)
Expect(err).To(Succeed(), "Unable to delete Monitoring Console instance", "Monitoring Console Name", mcRef)

// Verify Search Heads PVCs (etc and var) have been deleted
testenv.VerifyPVCsPerDeployment(deployment, testenvInstance, "shc-search-head", 3, false, verificationTimeout)
Expand All @@ -201,6 +223,9 @@ var _ = Describe("Crcrud test for SVA C3", func() {

// Verify Cluster Manager PVCs (etc and var) have been deleted
testenv.VerifyPVCsPerDeployment(deployment, testenvInstance, splcommon.ClusterManager, 1, false, verificationTimeout)

// Verify Monitoring Console PVCs (etc and var) have been deleted
testenv.VerifyPVCsPerDeployment(deployment, testenvInstance, "monitoring-console", 1, false, verificationTimeout)
})
})
})
19 changes: 15 additions & 4 deletions test/custom_resource_crud/custom_resource_crud_m4_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,12 @@ var _ = Describe("Crcrud test for SVA M4", func() {
})

Context("Multisite cluster deployment (M4 - Multisite indexer cluster, Search head cluster)", func() {
It("crcrud, integration : can deploy can deploy multisite indexer and search head clusters, change their CR, update the instances", func() {
It("crcrud, integration, m4: can deploy can deploy multisite indexer and search head clusters, change their CR, update the instances", func() {

// Deploy Multisite Cluster and Search Head Clusters
mcRef := deployment.GetName()
siteCount := 3
err := deployment.DeployMultisiteClusterWithSearchHead(deployment.GetName(), 1, siteCount)
err := deployment.DeployMultisiteClusterWithSearchHead(deployment.GetName(), 1, siteCount, mcRef)
Expect(err).To(Succeed(), "Unable to deploy cluster")

// Ensure that the cluster-manager goes to Ready phase
Expand All @@ -69,8 +70,12 @@ var _ = Describe("Crcrud test for SVA M4", func() {
// Ensure search head cluster go to Ready phase
testenv.SearchHeadClusterReady(deployment, testenvInstance)

// Verify MC Pod is Ready
// testenv.MCPodReady(testenvInstance.GetName(), deployment)
// Deploy Monitoring Console CRD
mc, err := deployment.DeployMonitoringConsole(mcRef, "")
Expect(err).To(Succeed(), "Unable to deploy Monitoring Console One instance")

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify RF SF is met
testenv.VerifyRFSFMet(deployment, testenvInstance)
Expand Down Expand Up @@ -102,6 +107,12 @@ var _ = Describe("Crcrud test for SVA M4", func() {
// Verify Indexers go to ready state
testenv.IndexersReady(deployment, testenvInstance, siteCount)

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify RF SF is met
testenv.VerifyRFSFMet(deployment, testenvInstance)

// Verify CPU limits after updating the CR
for i := 1; i <= siteCount; i++ {
podName := fmt.Sprintf(testenv.MultiSiteIndexerPod, deployment.GetName(), i, 0)
Expand Down
15 changes: 13 additions & 2 deletions test/custom_resource_crud/custom_resource_crud_s1_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,23 @@ var _ = Describe("Crcrud test for SVA S1", func() {
})

Context("Standalone deployment (S1)", func() {
It("crcrud, integration: can deploy a standalone instance, change its CR, update the instance", func() {
It("crcrud, integration, s1: can deploy a standalone instance, change its CR, update the instance", func() {

// Deploy Standalone
standalone, err := deployment.DeployStandalone(deployment.GetName())
mcRef := deployment.GetName()
standalone, err := deployment.DeployStandalone(deployment.GetName(), mcRef, "")
Expect(err).To(Succeed(), "Unable to deploy standalone instance")

// Verify Standalone goes to ready state
testenv.StandaloneReady(deployment, deployment.GetName(), standalone, testenvInstance)

// Deploy Monitoring Console CRD
mc, err := deployment.DeployMonitoringConsole(deployment.GetName(), "")
Expect(err).To(Succeed(), "Unable to deploy Monitoring Console One instance")

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify CPU limits before updating the CR
standalonePodName := fmt.Sprintf(testenv.StandalonePod, deployment.GetName(), 0)
testenv.VerifyCPULimits(deployment, testenvInstance.GetName(), standalonePodName, defaultCPULimits)
Expand All @@ -75,6 +83,9 @@ var _ = Describe("Crcrud test for SVA S1", func() {
// Verify Standalone goes to ready state
testenv.VerifyStandalonePhase(deployment, testenvInstance, deployment.GetName(), splcommon.PhaseReady)

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify CPU limits after updating the CR
testenv.VerifyCPULimits(deployment, testenvInstance.GetName(), standalonePodName, newCPULimits)
})
Expand Down
2 changes: 1 addition & 1 deletion test/delete_cr/deletecr_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ var _ = Describe("DeleteCR test", func() {
Context("Multisite cluster deployment (M13 - Multisite indexer cluster, Search head cluster)", func() {
It("deletecr: can deploy indexers and search head cluster", func() {

err := deployment.DeploySingleSiteCluster(deployment.GetName(), 3, true /*shc*/)
err := deployment.DeploySingleSiteCluster(deployment.GetName(), 3, true /*shc*/, "")
Expect(err).To(Succeed(), "Unable to deploy cluster")

// Ensure that the cluster-manager goes to Ready phase
Expand Down
8 changes: 4 additions & 4 deletions test/ingest_search/ingest_search_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ var _ = Describe("Ingest and Search Test", func() {
})

Context("Standalone deployment (S1)", func() {
It("ingest_search, integration: can search internal logs for standalone instance", func() {
It("ingest_search, integration, s1: can search internal logs for standalone instance", func() {

standalone, err := deployment.DeployStandalone(deployment.GetName())
standalone, err := deployment.DeployStandalone(deployment.GetName(), "", "")
Expect(err).To(Succeed(), "Unable to deploy standalone instance ")

// Wait for standalone to be in READY Status
Expand Down Expand Up @@ -127,9 +127,9 @@ var _ = Describe("Ingest and Search Test", func() {
})

Context("Standalone deployment (S1)", func() {
It("ingest_search, integration: can ingest custom data to new index and search", func() {
It("ingest_search, integration, s1: can ingest custom data to new index and search", func() {

standalone, err := deployment.DeployStandalone(deployment.GetName())
standalone, err := deployment.DeployStandalone(deployment.GetName(), "", "")
Expect(err).To(Succeed(), "Unable to deploy standalone instance ")

// Wait for standalone to be in READY Status
Expand Down
17 changes: 13 additions & 4 deletions test/licensemanager/lm_c3_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ var _ = Describe("Licensemanager test", func() {
})

Context("Clustered deployment (C3 - clustered indexer, search head cluster)", func() {
It("licensemanager, integration: Splunk Operator can configure License Manager with Indexers and Search Heads in C3 SVA", func() {
It("licensemanager, integration, c3: Splunk Operator can configure License Manager with Indexers and Search Heads in C3 SVA", func() {

// Download License File
licenseFilePath, err := testenv.DownloadLicenseFromS3Bucket()
Expand All @@ -58,7 +58,8 @@ var _ = Describe("Licensemanager test", func() {
// Create License Config Map
testenvInstance.CreateLicenseConfigMap(licenseFilePath)

err = deployment.DeploySingleSiteCluster(deployment.GetName(), 3, true /*shc*/)
mcRef := deployment.GetName()
err = deployment.DeploySingleSiteCluster(deployment.GetName(), 3, true /*shc*/, mcRef)
Expect(err).To(Succeed(), "Unable to deploy cluster")

// Ensure that the cluster-manager goes to Ready phase
Expand All @@ -70,8 +71,12 @@ var _ = Describe("Licensemanager test", func() {
// Ensure search head cluster go to Ready phase
testenv.SearchHeadClusterReady(deployment, testenvInstance)

// Verify MC Pod is Ready
// testenv.MCPodReady(testenvInstance.GetName(), deployment)
// Deploy Monitoring Console CRD
mc, err := deployment.DeployMonitoringConsole(mcRef, deployment.GetName())
Expect(err).To(Succeed(), "Unable to deploy Monitoring Console One instance")

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify RF SF is met
testenv.VerifyRFSFMet(deployment, testenvInstance)
Expand All @@ -91,6 +96,10 @@ var _ = Describe("Licensemanager test", func() {
testenv.VerifyLMConfiguredOnPod(deployment, searchHeadPodName)
searchHeadPodName = fmt.Sprintf(testenv.SearchHeadPod, deployment.GetName(), 2)
testenv.VerifyLMConfiguredOnPod(deployment, searchHeadPodName)

// Verify LM Configured on Monitoring Console
monitoringConsolePodName := fmt.Sprintf(testenv.MonitoringConsolePod, deployment.GetName(), 0)
testenv.VerifyLMConfiguredOnPod(deployment, monitoringConsolePodName)
})
})

Expand Down
17 changes: 13 additions & 4 deletions test/licensemanager/lm_m4_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ var _ = Describe("Licensemanager test", func() {
})

Context("Multisite cluster deployment (M4 - Multisite indexer cluster, Search head cluster)", func() {
It("licensemanager: Splunk Operator can configure license manager with indexers and search head in M4 SVA", func() {
It("licensemanager, integration, m4: Splunk Operator can configure license manager with indexers and search head in M4 SVA", func() {

// Download License File
licenseFilePath, err := testenv.DownloadLicenseFromS3Bucket()
Expand All @@ -53,7 +53,8 @@ var _ = Describe("Licensemanager test", func() {
testenvInstance.CreateLicenseConfigMap(licenseFilePath)

siteCount := 3
err = deployment.DeployMultisiteClusterWithSearchHead(deployment.GetName(), 1, siteCount)
mcRef := deployment.GetName()
err = deployment.DeployMultisiteClusterWithSearchHead(deployment.GetName(), 1, siteCount, mcRef)
Expect(err).To(Succeed(), "Unable to deploy cluster")

// Ensure that the cluster-manager goes to Ready phase
Expand All @@ -68,8 +69,12 @@ var _ = Describe("Licensemanager test", func() {
// Ensure search head cluster go to Ready phase
testenv.SearchHeadClusterReady(deployment, testenvInstance)

// Verify MC Pod is Ready
// testenv.MCPodReady(testenvInstance.GetName(), deployment)
// Deploy Monitoring Console CRD
mc, err := deployment.DeployMonitoringConsole(mcRef, deployment.GetName())
Expect(err).To(Succeed(), "Unable to deploy Monitoring Console One instance")

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify RF SF is met
testenv.VerifyRFSFMet(deployment, testenvInstance)
Expand All @@ -89,6 +94,10 @@ var _ = Describe("Licensemanager test", func() {
testenv.VerifyLMConfiguredOnPod(deployment, searchHeadPodName)
searchHeadPodName = fmt.Sprintf(testenv.SearchHeadPod, deployment.GetName(), 2)
testenv.VerifyLMConfiguredOnPod(deployment, searchHeadPodName)

// Verify LM Configured on Monitoring Console
monitoringConsolePodName := fmt.Sprintf(testenv.MonitoringConsolePod, deployment.GetName(), 0)
testenv.VerifyLMConfiguredOnPod(deployment, monitoringConsolePodName)
})
})

Expand Down
17 changes: 13 additions & 4 deletions test/licensemanager/lm_s1_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ var _ = Describe("Licensemanager test", func() {
})

Context("Standalone deployment (S1) with LM", func() {
It("licensemanager: Splunk Operator can configure License Manager with Standalone in S1 SVA", func() {
It("licensemanager, integration, s1: Splunk Operator can configure License Manager with Standalone in S1 SVA", func() {

// Download License File
licenseFilePath, err := testenv.DownloadLicenseFromS3Bucket()
Expand All @@ -53,7 +53,8 @@ var _ = Describe("Licensemanager test", func() {
testenvInstance.CreateLicenseConfigMap(licenseFilePath)

// Create standalone Deployment with License Manager
standalone, err := deployment.DeployStandaloneWithLM(deployment.GetName())
mcRef := deployment.GetName()
standalone, err := deployment.DeployStandaloneWithLM(deployment.GetName(), mcRef)
Expect(err).To(Succeed(), "Unable to deploy standalone instance with LM")

// Wait for License Manager to be in READY status
Expand All @@ -62,12 +63,20 @@ var _ = Describe("Licensemanager test", func() {
// Wait for Standalone to be in READY status
testenv.StandaloneReady(deployment, deployment.GetName(), standalone, testenvInstance)

// Verify MC Pod is Ready
// testenv.MCPodReady(testenvInstance.GetName(), deployment)
// Deploy Monitoring Console
mc, err := deployment.DeployMonitoringConsole(mcRef, deployment.GetName())
Expect(err).To(Succeed(), "Unable to deploy Monitoring Console One instance")

// Verify Monitoring Console is Ready and stays in ready state
testenv.VerifyMonitoringConsoleReady(deployment, deployment.GetName(), mc, testenvInstance)

// Verify LM is configured on standalone instance
standalonePodName := fmt.Sprintf(testenv.StandalonePod, deployment.GetName(), 0)
testenv.VerifyLMConfiguredOnPod(deployment, standalonePodName)

// Verify LM Configured on Monitoring Console
monitoringConsolePodName := fmt.Sprintf(testenv.MonitoringConsolePod, deployment.GetName(), 0)
testenv.VerifyLMConfiguredOnPod(deployment, monitoringConsolePodName)
})
})
})
Loading