Removes the ERRONEOUS state from a component and retries a validation

        :param properties_update: A dictionary to update component properties
        :return: The new state of the component
974872
def retry_erroneous(self, properties_update):
        # type: (dict) -> int
        
        with self._lock:
            if self.state != StoredInstance.ERRONEOUS:
                # Not in erroneous state: ignore
                return self.state

            # Update properties
            if properties_update:
                self.context.properties.update(properties_update)

            # Reset state
            self.state = StoredInstance.INVALID
            self.error_trace = None

            # Retry
            self.check_lifecycle()

            # Check if the component is still erroneous
            return self.state
1120100
protected void dirtyUpdated() {
		boolean dirty = isDirty();
		if (hasChanged(oldDirty, dirty)) {
			oldDirty = dirty;
			firePropertyChange(DIRTY_PROPERTY, !dirty, dirty);
		}
	}
641256
def update_properties_cache(sender, instance, action, reverse, model, pk_set, **kwargs):
    ""
    if action == 'post_add':
        instance.save_properties_cache()
528865
def old_properties_names_to_new(self):
        
        old_properties = getattr(self.__class__, "old_properties", {})
        for old_name, new_name in list(old_properties.items()):
            # Ok, if we got old_name and NO new name,
            # we switch the name
            if hasattr(self, old_name) and not hasattr(self, new_name):
                value = getattr(self, old_name)
                setattr(self, new_name, value)
                delattr(self, old_name)
29499
def validate_properties(props, required):
    

    props = set(props)
    required = set(required or _supported_props)

    if len(required.intersection(props)) < len(required):
        missing = required - props
        raise ValidationError(
            'Missing property names: {props}', props=','.join(missing), missing=missing
        )
1238562
def update_property(property, value, raw = false)
      property = property.to_s
      property = validate_property(property, raw)
      value = validate_value(property, value, raw)
      properties[property] = value
    end
714066
public void configPropertiesUpdated(Dictionary<String, String> properties)
    {
        if (HttpServiceTracker.propertiesEqual(properties, configProperties))
            return;
        configProperties = properties;
        ServiceReference reference = context.getServiceReference(HttpService.class.getName());
        if (reference == null)
            return;
        HttpService httpService = (HttpService) context.getService(reference);

        String oldAlias = this.getAlias();
        this.changeServletProperties(servlet, properties);
        String alias = properties.get(BaseWebappServlet.ALIAS);
        boolean restartRequired = false;
        if (!oldAlias.equals(alias))
            restartRequired = true;
        else if (servlet instanceof WebappServlet)
            restartRequired = ((WebappServlet)servlet).restartRequired();
        if (!restartRequired)
            return;
        try {
            httpService.unregister(oldAlias);
        } catch (Exception e) {
            e.printStackTrace();    // Should not happen
        }
        this.properties.put(BaseWebappServlet.ALIAS, alias);
        
        if (servlet instanceof WebappServlet)
            if (((WebappServlet)servlet).restartRequired())
        {
            ((WebappServlet)servlet).free();
            servlet = null;
        }

        this.addingService(reference); // Start it back up
    }
257033
def _validate_props(self):
        """"""
        for key, prop in iteritems(self._props):
            try:
                value = self._get(key)
                err_msg = 'Invalid value for property {}: {}'.format(key, value)
                if value is not None:
                    change = dict(name=key, previous=value, value=value,
                                  mode='validate')
                    self._notify(change)
                    if not prop.equal(value, change['value']):
                        raise utils.ValidationError(err_msg, 'invalid',
                                                    prop.name, self)
                if not prop.assert_valid(self):
                    raise utils.ValidationError(err_msg, 'invalid',
                                                prop.name, self)
            except utils.ValidationError as val_err:
                if getattr(self, '_validation_error_tuples', None) is not None:
                    self._validation_error_tuples += val_err.error_tuples
                else:
                    raise
        return True
489727
def dict_update_overwrite_check(base, fresh):
    

    result = [
        (key, base[key], fresh[key])
        for key in set(base.keys()) & set(fresh.keys())
        if base[key] != fresh[key]
    ]
    base.update(fresh)
    return result
1195459
def delete(self, for_update=False):
        
        hash_key = self.get_hash_id()
        try:
            original_instance = self.load(hash_key, convert_key=False)
        except KeyError:
            return

        # Remove from the `all` index.
        all_index = self._query.all_index()
        all_index.remove(hash_key)

        # Remove from the secondary indexes.
        for field in self._indexes:
            for index in field.get_indexes():
                index.remove(original_instance)

        if not for_update:
            for field in self._fields.values():
                if isinstance(field, _ContainerField):
                    field._delete(self)

        # Remove the object itself.
        self.__database__.delete(hash_key)
381852
def update_property(old, new):
    """"""
    update_generic(old.fdel, new.fdel)
    update_generic(old.fget, new.fget)
    update_generic(old.fset, new.fset)
850713
protected void updatePropertiesInternal(
        Iterable<Property> properties,
        Iterable<PropertyDeleteMutation> propertyDeleteMutations,
        Iterable<PropertySoftDeleteMutation> propertySoftDeleteMutations
    ) {
        if (propertyDeleteMutations != null) {
            this.propertyDeleteMutations = new ConcurrentSkipListSet<>();
            for (PropertyDeleteMutation propertyDeleteMutation : propertyDeleteMutations) {
                removePropertyInternal(
                    propertyDeleteMutation.getKey(),
                    propertyDeleteMutation.getName(),
                    propertyDeleteMutation.getVisibility()
                );
                this.propertyDeleteMutations.add(propertyDeleteMutation);
            }
        }
        if (propertySoftDeleteMutations != null) {
            this.propertySoftDeleteMutations = new ConcurrentSkipListSet<>();
            for (PropertySoftDeleteMutation propertySoftDeleteMutation : propertySoftDeleteMutations) {
                removePropertyInternal(
                    propertySoftDeleteMutation.getKey(),
                    propertySoftDeleteMutation.getName(),
                    propertySoftDeleteMutation.getVisibility()
                );
                this.propertySoftDeleteMutations.add(propertySoftDeleteMutation);
            }
        }

        for (Property property : properties) {
            addPropertyInternal(property);
        }
    }
1287122
def update_properties(self, new_properties):
        
        [self._update_property_from_dict(section, option, new_properties)
         for section in self.sections() for option in self.options(section)]
459927
def update(self):
        
        con = self.subpars.pars.control
        self(con.eqd1*con.tind)
161332
def update(self, **values):
        
        if not values:
            return

        nulled_columns = set()
        us = UpdateStatement(self.column_family_name, where=self._where, ttl=self._ttl,
                             timestamp=self._timestamp, transactions=self._transaction)
        for name, val in values.items():
            col_name, col_op = self._parse_filter_arg(name)
            col = self.model._columns.get(col_name)
            # check for nonexistant columns
            if col is None:
                raise ValidationError("{}.{} has no column named: {}".format(self.__module__, self.model.__name__, col_name))
            # check for primary key update attempts
            if col.is_primary_key:
                raise ValidationError("Cannot apply update to primary key '{}' for {}.{}".format(col_name, self.__module__, self.model.__name__))

            # we should not provide default values in this use case.
            val = col.validate(val)
            
            if val is None:
                nulled_columns.add(col_name)
                continue

            # add the update statements
            if isinstance(col, Counter):
                # TODO: implement counter updates
                raise NotImplementedError
            elif isinstance(col, (List, Set, Map)):
                if isinstance(col, List):
                    klass = ListUpdateClause
                elif isinstance(col, Set):
                    klass = SetUpdateClause
                elif isinstance(col, Map):
                    klass = MapUpdateClause
                else:
                    raise RuntimeError
                us.add_assignment_clause(klass(col_name, col.to_database(val), operation=col_op))
            else:
                us.add_assignment_clause(AssignmentClause(
                    col_name, col.to_database(val)))

        if us.assignments:
            self._execute(us)

        if nulled_columns:
            ds = DeleteStatement(self.column_family_name, fields=nulled_columns, where=self._where)
            self._execute(ds)
291780
def update_bindings(self):
        # type: () -> bool
        
        with self._lock:
            all_valid = True
            for handler in self.get_handlers(handlers_const.KIND_DEPENDENCY):
                # Try to bind
                self.__safe_handler_callback(handler, "try_binding")

                # Update the validity flag
                all_valid &= self.__safe_handler_callback(
                    handler, "is_valid", only_boolean=True, none_as_true=True
                )
            return all_valid
354691
def execute
      return :locked if @resource.locked_to_user? @headers

      # The `propertyupdate` tag contains the request to alter properties
      # on a resource.
      xml = xml_for body: body, node: 'propertyupdate'
      return :bad_request if xml == :bad_request

      actions = @resource.proppatch xml

      builder = xml_builder
      xml_res = builder.proppatch_response(@resource.full_request_path,
                                           actions)

      set_xml_content_type

      [:multi_status, xml_res]
    end