// UpdateSubjectCompatibilityLevel modifies a specific subject(schema)'s compatibility level.
UpdateSubjectCompatibilityLevel modifies a specific subject(schema)'s compatibility level.
// UpdateSubjectCompatibilityLevel modifies a specific subject ( schema ) ' s compatibility level .
func (c *Client) UpdateSubjectCompatibilityLevel(subject string, level CompatibilityLevel) error {
	if subject == "" {
		return errRequired("subject")
	}
	if string(level) == "" {
		return errRequired("level")
	}
	lv := compatibilityPutOnlyJSON{
		Compatibility: string(level),
	}
	send, err := json.Marshal(lv)
	if err != nil {
		return err
	}
	path := fmt.Sprintf(subjectCompatibilityLevelPath, subject)
	resp, err := c.Do(http.MethodPut, path, contentTypeSchemaJSON, send, schemaAPIOption)
	if err != nil {
		return err
	}
	return resp.Body.Close()
}
func ( c * Client ) UpdateSubjectCompatibilityLevel ( subject string , level CompatibilityLevel ) error { if subject == " " { return errRequired ( " " ) } if string ( level ) == " " { return errRequired ( " " ) } lv := compatibilityPutOnlyJSON { Compatibility : string ( level ) , } send , err := json . Marshal ( lv ) if err != nil { return err } path := fmt . Sprintf ( subjectCompatibilityLevelPath , subject ) resp , err := c . Do ( http . MethodPut , path , contentTypeSchemaJSON , send , schemaAPIOption ) if err != nil { return err } return resp . Body . Close ( ) }
UpdateSubjectCompatibilityLevel modifies a specific subject(schema)'s compatibility level.
UpdateSubjectCompatibilityLevel modifies a specific subject ( schema ) ' s compatibility level .
// # Change compatibility level of a subject // PUT /api/proxy-sr/config/(string: subject)