components/ruby/puppet/files/solaris/lib/puppet/provider/evs_properties/solaris.rb
changeset 4801 c249904bb056
parent 4794 be62c55aa235
equal deleted inserted replaced
4796:df74c4f80d70 4801:c249904bb056
    95                 when "vxlan-range"
    95                 when "vxlan-range"
    96                     control_props[:vxlan_range] = value
    96                     control_props[:vxlan_range] = value
    97                 end
    97                 end
    98             end
    98             end
    99         rescue Puppet::ExecutionFailure => e
    99         rescue Puppet::ExecutionFailure => e
   100             # EVS controller is not set or valid
   100             # EVS controller is not set or invalid
   101             # Handle the exception at upper level
   101             # Handle the exception at upper level
   102             raise
   102             raise
   103         end
   103         end
   104         control_props[:name] = "controller_property"
   104         control_props[:name] = "controller_property"
   105         control_props[:uplink_port] = uplink_ports
   105         control_props[:uplink_port] = uplink_ports
   194 
   194 
   195     def flush
   195     def flush
   196         case @resource[:name]
   196         case @resource[:name]
   197         when "controller_property"
   197         when "controller_property"
   198             if @property_flush.has_key?(:controller)
   198             if @property_flush.has_key?(:controller)
   199                 puts "foo"
       
   200                 raise Puppet::Error, "controller_property does not have "\
   199                 raise Puppet::Error, "controller_property does not have "\
   201                     "'controller' property. Try client_property"
   200                     "'controller' property. Try client_property"
   202                 puts "bar"
       
   203             end
   201             end
   204             
   202             
   205             props = []
   203             props = []
   206             @property_flush.each do |key, value|
   204             @property_flush.each do |key, value|
   207                 # Change symbol to string
   205                 # Change symbol to string