class RubyAem::Resources::ReverseReplicationAgent
ReverseReplicationAgent
class contains API calls related to managing an AEM reverse replication agent.
Public Class Methods
Initialise a reverse replication agent.
@param client RubyAem::Client
@param run_mode AEM run mode: author or publish @param name the reverse replication agent's name, e.g. some-replication-agent @return new RubyAem::Resources::ReverseReplicationAgent
instance
# File lib/ruby_aem/resources/reverse_replication_agent.rb, line 25 def initialize(client, run_mode, name) @client = client @call_params = { run_mode: run_mode, name: name } end
Public Instance Methods
Create or update a reverse replication agent.
@param title reverse replication agent title @param description reverse replication agent description @param dest_base_url base URL of the agent target destination, e.g. somepublisher:4503 @param opts optional parameters:
-
transport_user: username for transport user, default is admin
-
transport_password: password for transport user, default is admin
-
log_level: error, info, debug, default is error
-
retry_delay: in milliseconds, default is 30_000
@return RubyAem::Result
# File lib/ruby_aem/resources/reverse_replication_agent.rb, line 44 def create_update( title, description, dest_base_url, opts = { transport_user: 'admin', transport_password: 'admin', log_level: 'error', retry_delay: 30_000 } ) @call_params[:title] = title @call_params[:description] = description @call_params[:dest_base_url] = dest_base_url @call_params = @call_params.merge(opts) @client.call(self.class, __callee__.to_s, @call_params) end
Delete the reverse replication agent.
@return RubyAem::Result
# File lib/ruby_aem/resources/reverse_replication_agent.rb, line 65 def delete @client.call(self.class, __callee__.to_s, @call_params) end
Check whether the reverse replication agent exists or not. If the reverse replication agent exists, this method returns a true result data, false otherwise.
@return RubyAem::Result
# File lib/ruby_aem/resources/reverse_replication_agent.rb, line 74 def exists @client.call(self.class, __callee__.to_s, @call_params) end