Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Galasa Resources Apply fails if properties are given an empty value, even though ETCD accepts properties that are empty #2115

Closed
Tom-Slattery opened this issue Jan 22, 2025 · 1 comment
Assignees
Labels
4-customer-enhancement Enhancements requested by a customer defect Something isn't working

Comments

@Tom-Slattery
Copy link
Member

Describe the bug

Galasa Resources Apply fails if properties are given an empty value, even though ETCD accepts properties that are empty. The capabilities of Galasactl and the backend Etcd should match.

Steps to reproduce

  1. Create this file as "resources.yaml"
apiVersion: galasa-dev/v1alpha1
kind: GalasaProperty
metadata:
    namespace: demo
    name: empty.prop.demo
data:
    value: ""
  1. Run this command:
galasactl resources apply -f resources.yaml
  1. You will receive this error:
Error: GAL1113E: Failure reported by the Galasa Ecosystem. The Ecosystem believes there is a problem with this client program or the user input. Errors returned: 'GAL5024E: Error occurred because the Galasa Property is invalid. 'The 'value' field cannot be empty. The field 'value' is mandatory for the type GalasaProperty.''
  1. Note that in Galasactl version 0.40.0 you can apply empty CPS properties:
galasactl properties set --namespace demo --name empty.prop.demo --value ""  
galasactl properties get --namespace demo --name empty.prop.demo           
namespace name           value
demo      empty.prop.demo 

Total:1
galasactl properties get --namespace demo --name mike.prop.demo --format yaml
apiVersion: galasa-dev/v1alpha1
kind: GalasaProperty
metadata:
    namespace: demo
    name: empty.prop.demo
data:
    value: ""

Expected behavior

The behaviour of resources apply and proeprties set should be consistent, and should match the allowed actions in etcd.

@techcobweb techcobweb added defect Something isn't working 4-customer-enhancement Enhancements requested by a customer labels Jan 22, 2025
@techcobweb techcobweb moved this from 🆕 New to 4 Release backlog in galasa-dev team Jan 22, 2025
@techcobweb techcobweb self-assigned this Feb 3, 2025
@techcobweb techcobweb moved this from 4 Release backlog to 🔖 3 Iteration Backlog in galasa-dev team Feb 3, 2025
@techcobweb techcobweb moved this from 🔖 3 Iteration Backlog to 🏗 2 In progress in galasa-dev team Feb 4, 2025
@techcobweb
Copy link
Contributor

fixed

@techcobweb techcobweb moved this from 🏗 2 In progress to ✅ Done - in iteration in galasa-dev team Feb 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4-customer-enhancement Enhancements requested by a customer defect Something isn't working
Projects
Status: Done - in iteration
Development

No branches or pull requests

2 participants