Automic Workload Automation

 View Only
  • 1.  SetAgentProperties Does Not Show All Methods in 12.0

    Posted Jun 12, 2018 01:43 PM
      |   view attached

    I've been trying to set maxResourceJobs and maxResourceFileTransfers to throttle agents down for v10 to v12 agent upgrades (automated agent upgrades not available until we are on 12). This code block is what i'm using:

     

    UC4HostName host = new UC4HostName(uc4Server);
    AgentList clientAgents = new AgentList();
    uc4.sendRequestAndWait(clientAgents);

    Iterator it = clientAgents.iterator();
    while (it.hasNext()){
        AgentListItem tempAgent = (AgentListItem) it.next();
        UC4HostName hostName = tempAgent.getName();
        if (hostName.equals(host)){
            GetAgentProperties getAgentProperties = new GetAgentProperties(host);
            uc4.sendRequestAndWait(getAgentProperties);

            getAgentProperties.getMaxJobs();
            getAgentProperties.getMaxFileTransfer();

            SetAgentProperties setAgentProperties = new SetAgentProperties(getAgentProperties);
            setAgentProperties.setMaxJobs(throttleCount);
            setAgentProperties.setMaxFileTransfer(throttleCount);
           

        }

    The two methods I'm trying to call (setAgentProperties.setMaxJobs and setMaxFileTransfers are methods not found. I'm using the v12.0 jar and these were introduced in v11. Any ideas if it's a bug or perhaps I'm not getting to the methods?

     

    The docs show there are 5 methods for SetAgentProperties and I'm only seeing isDirty() and setHostTraceOptions().

    I tried this without the iterator as well to pull the agent details directly but have the same result.

    Any help greatly appreciated!



  • 2.  Re: SetAgentProperties Does Not Show All Methods in 12.0
    Best Answer

    Posted Jun 12, 2018 02:01 PM

    It appears the 12.1 jar fixes this issue, just a heads up for anyone else who stumbles on this one.