Groovy Script extended of two Topologies in a rule

Hi all

I am trying to create rules, where I can reach to the memory of the physical hosts of special services.

Here's what I have in theory up to now, by themselves, they work, but I would like to know how I can put the two together.

It works to follow
(Memory: host.hostType.name = 'Physical')

the following books
(Where the host $object in (((FSMService_where_name_like_"Foglight_%").definition_where_$object_instanceof_FSMChildService).definition where $object instanceof FSMDynamicManagedComponent) .components))

I have not an FMS works now, so here it is (no pun intended) memory and not tested:

Memory where ((host.hostType.name = «Physique») and (in the host (((FSMService_where_name_like_"Foglight_%").definition_where_host_instanceof_FSMChildService).definition where host instanceof FSMDynamicManagedComponent) .components)))

You combine the 2 where clauses, the $object (in the 2nd scope query) must be replaced by the host memory object as $object would be otherwise reference memory, no host.  (I hope that this somewhat laconic explanation is logical).

Tags: Dell Tech

Similar Questions

  • Groovy script

    Hello

    I found here (to communities.quest.com) script that gives you all your alarms information, when you run administration-> tools-> script console.

    Now, for this script, I want to create a rule that runs this script every 2 minutes.

    In the rule of Action, there is an option for Action script, but I don't know how to add my script to this list.

    Is there an option for this? or y at - it another option?

    I don't want to control action that runs my groovy script from outside the foglight.

    Furthermore, I won't build script agent (in the agent script generator).

    These two requirements because of the requirements of the customer.

    Best regards

    Victor

    Create a simple rule with no scope query, put on engine driven time or schedule and then simply paste your groovy code into the home.

  • Groovy Script error - launch of workload dynamically

    Hi all

    I'm trying to plan kickoff to load dynamically to help after the groovy script

    com of the packaging. LoadPlan.OdiTool;

    Import oracle.odi.core.OdiInstance;

    Import oracle.odi.core.config.MasterRepositoryDbInfo;

    Import oracle.odi.core.config.OdiInstanceConfig;

    Import oracle.odi.core.config.PoolingAttributes;

    Import oracle.odi.core.config.WorkRepositoryDbInfo;

    Import oracle.odi.core.persistence.transaction.ITransactionStatus;

    Import oracle.odi.core.persistence.transaction.support.DefaultTransactionDefinition;

    Import oracle.odi.core.security.Authentication;

    Import oracle.odi.runtime.agent.invocation.RemoteRuntimeAgentInvoker;

    Import oracle.odi.domain.runtime.loadplan.OdiLoadPlan;

    Oracle.odi.domain.runtime.loadplan.OdiLoadPlan import. *;

    Import oracle.odi.domain.runtime.loadplan.OdiLoadPlanStep;

    Import oracle.odi.domain.runtime.loadplan.OdiLoadPlanStepContainer;

    Import oracle.odi.domain.runtime.loadplan.OdiLoadPlanStepSerial;

    Import oracle.odi.domain.runtime.loadplan.finder.IOdiLoadPlanFinder;

    Import oracle.odi.domain.runtime.loadplan.OdiLoadPlanSchedule;

    Oracle.odi.runtime.agent.invocation import. *;

    Oracle.odi.runtime.agent.invocation.StartupParams import. *;

    Import oracle.odi.runtime.agent.invocation.LoadPlanStartupParams;

    import java.util.HashMap;

    import java.util.Map;

    public class CustomLoadPlan {}

    Public Shared Sub main (String [] args) {}

    String Master_User = 'Master_User;

    String Master_Pass = "Master_Pass";

    String WorkRep = "WORKREP";

    String Odi_User = "myuser";

    String Odi_Pass = 'mypass ';

    MasterRepositoryDbInfo masterInfo = new MasterRepositoryDbInfo (Url, driver, Master_User, Master_Pass.toCharArray (), PoolingAttributes()) new;

    WorkInfo WorkRepositoryDbInfo = new WorkRepositoryDbInfo (WorkRep, new PoolingAttributes());

    OdiInstance odiInstance is OdiInstance.createInstance (new OdiInstanceConfig(masterInfo,workInfo));.

    Authentication auth = odiInstance.getSecurityManager () .createAuthentication (Odi_User, Odi_Pass.toCharArray ());

    odiInstance.getSecurityManager () .setCurrentThreadAuthentication (auth);

    ITransactionStatus trans = odiInstance.getTransactionManager () .getTransaction (new DefaultTransactionDefinition());

    Officer of RemoteRuntimeAgentInvoker = new RemoteRuntimeAgentInvoker ("http://localhost", "myuser", "mypassword".toCharArray ());

    Map paramsValues = new HashMap();

    LpProps properties = new Properties ();

    LoadPlanStartupParams startupParams = new LoadPlanStartupParams (paramsValues);

             

    LoadPlan research

    OdiLoadPlan odiLoadPlan = (odiInstance.getTransactionalEntityManager () .getFinder (OdiLoadPlan.class)) .findByName (planName) (IOdiLoadPlanFinder);

    Implementation of the Plan of care

    ExecutionInfo res = agent.invokeStartLoadPlan (planName, 'GLOBAL', startupParams, "," WORKREP", lpProps, 1);

    }

    And get the following error

    org.codehaus.groovy.runtime.InvokerInvocationException: oracle.odi.runtime.agent.invocation.InvocationException: http://host.com:port/OracleDIAgent:org.apache.commons.httpclient.ProtocolException: The Host of the server.com has not responded to a valid HTTP response

    at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:95)

    at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:233)

    at groovy.lang.MetaClassImpl.invokeStaticMethod(MetaClassImpl.java:1302)

    at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:759)

    at groovy.lang.GroovyShell.runScriptOrMainOrTestOrRunnable(GroovyShell.java:271)

    at groovy.lang.GroovyShell.run(GroovyShell.java:513)

    at groovy.lang.GroovyShell.run(GroovyShell.java:170)

    at oracle.odi.ui.groovy.GroovyScriptRunInstance.run(GroovyScriptRunInstance.java:228)

    Caused by: oracle.odi.runtime.agent.invocation.InvocationException: http://host:port2/OracleDIAgent:org.apache.commons.httpclient.ProtocolException: The Host of the server.com has not responded to a valid HTTP response

    Any idea a pointer what is wrong in the script. Please note that my Agent is up and running, I am able to launch the studio ODi LoadPlan. I am also able to join annex to load the plan through the groovy script. So looks like something wrong in the script.

    Any help is greatly appreciated.

    Thanks and greetings

    I was able to solve the issue myself. It was two minor problems.

    (1) agent was running over HTTPS not http like I was trying in the script.

    (2) the name of the agent must be column of the Web Application context, rather than the column name set Agent screen.

    After the correction of these two options, I was able to launch the Plan of loading of the groovy script.

    7 regards thanks

  • Interface is not changed after Groovy Script executed successfully

    Hi all

    I tried to add a filter to interface (temporary) source.

    There is only one set of data (the default) and the source data store has alias T001. This data store is also associated with other data warehouse.

    The script seems to be run successfully, but I don't see any change in the Interface. I've included a few prints debug to check.

    Am I missing something?

    Thank you

    My groovy script output is the following:

    Found SAP_FDM_GLBALANCES_NEW

    Found GL_BALANCES_NEW_1_CUSTOM

    Found by default

    Helper Created

    Fact

    Script was released.

    Groovy script

    Created by Studio ODI

    package odi_sdk;

    Utils

    to import java.util.Collection;

    Import java.util.Iterator;

    Basic libraries

    import oracle.odi.core.OdiInstance

    import oracle.odi.core.config.OdiInstanceConfig

    import oracle.odi.core.config.MasterRepositoryDbInfo

    import oracle.odi.core.config.WorkRepositoryDbInfo

    import oracle.odi.core.security.Authentication

    import oracle.odi.core.config.PoolingAttributes

    Context operators:

    import oracle.odi.domain.topology.OdiContext

    import oracle.odi.domain.topology.finder.IOdiContextFinder

    Folder operators:

    import oracle.odi.domain.project.OdiFolder

    import oracle.odi.domain.project.finder.IOdiFolderFinder

    User interface:

    import oracle.odi.domain.project.OdiInterface

    import oracle.odi.domain.project.finder.IOdiInterfaceFinder

    Project managers:

    import oracle.odi.domain.project.OdiProject

    import oracle.odi.domain.project.finder.IOdiProjectFinder

    Assistants of the interface:

    import oracle.odi.interfaces.interactive.support.InteractiveInterfaceHelperWithActions

    import oracle.odi.interfaces.interactive.support.targetkeychoosers.TargetKeyChooserPrimaryKey

    import oracle.odi.interfaces.interactive.support.mapping.automap.AutoMappingComputerLazy

    import oracle.odi.interfaces.interactive.support.mapping.matchpolicy.MappingMatchPolicyLazy

    import oracle.odi.interfaces.interactive.support.actions.InterfaceActionSetTargetDataStore

    import oracle.odi.interfaces.interactive.support.aliascomputers.AliasComputerDoubleChecker

    import oracle.odi.interfaces.interactive.support.clauseimporters.ClauseImporterLazy

    import oracle.odi.interfaces.interactive.support.actions.InterfaceActionAddSourceDataStore

    Import oracle.odi.interfaces.interactive.support.actions.InterfaceActionOnTargetDataStoreComputeAutoMapping;

    import oracle.odi.interfaces.interactive.support.actions.InterfaceActionAddFilter

    Operators of transaction:

    Import oracle.odi.core.persistence.transaction.support.DefaultTransactionDefinition;

    Import oracle.odi.core.persistence.transaction.ITransactionDefinition;

    Import oracle.odi.core.persistence.transaction.ITransactionManager;

    Import oracle.odi.core.persistence.transaction.ITransactionStatus;

    Data set:

    Import oracle.odi.domain.project.interfaces.DataSet;

    Data Bank:

    Import oracle.odi.domain.model.OdiDataStore;

    Import oracle.odi.domain.model.finder.IOdiDataStoreFinder;

    Variables

    def Url = "jdbc:oracle:thin:@EPM11123:1521:FUSION";

    def Driver = "oracle.jdbc.OracleDriver";

    def Master_User = "XXXXX";

    def Master_Pass = "XXXXX";

    def WorkRep = "XXXXX";

    def Odi_User = 'SUPERVISOR ';

    def Odi_Pass = "SUNOPSIS ';

    def Project_Code = "AIF_SAP";

    def folder_name = "SAP_FDM_GLBALANCES_NEW";

    def Interface_Name = "GL_BALANCES_NEW_1_CUSTOM."

    def file

    INTF def

    def ds

    filter def = new String ("T001. BUKRS = 1000 ")

    Connection

    def masterInfo = new MasterRepositoryDbInfo (Url, driver, Master_User, Master_Pass.toCharArray (), PoolingAttributes()) new;

    def workInfo = new WorkRepositoryDbInfo (WorkRep, new PoolingAttributes());

    def odiInstance is OdiInstance.createInstance (new OdiInstanceConfig (masterInfo, workInfo));.

    def auth = odiInstance.getSecurityManager () .createAuthentication (Odi_User, Odi_Pass.toCharArray ());

    odiInstance.getSecurityManager () .setCurrentThreadAuthentication (auth);

    def trans = odiInstance.getTransactionManager () .getTransaction (new DefaultTransactionDefinition());

    Find the folder

    Fold collection = (odiInstance.getTransactionalEntityManager () .getFinder (OdiFolder.class)) (Folder_Name, Project_Code) .findByName (IOdiFolderFinder);

    for (Iterator < OdiFolder > it = fold.iterator (); it.hasNext ();) {

    record = it.next ((OdiFolder));

    println ("Found" + folder.getName ())

    }

    Find Interface

    Collection intfcol = ((IOdiInterfaceFinder) odiInstance.getTransactionalEntityManager () .getFinder (OdiInterface.class)) .findByName (Interface_Name, Project_Code);

    for (Iterator < OdiInterface > it = intfcol.iterator (); it.hasNext ();) {

    INTF = it.next ((OdiInterface));

    println ("Found" + intf.getName ())

    }

    Get the Dataset

    DS = intf.getDataSets () .get (0) (DataSet);

    println ("Found" + ds.getName ())

    Create support

    def = new InteractiveInterfaceHelperWithActions helper (intf, odiInstance, odiInstance.getTransactionalEntityManager ());

    println ('creation of assistance')

    Add the filter

    helper.performAction (new InterfaceActionAddFilter (ds, filter, OdiInterface.ExecutionLocation.SOURCE));

    println ("Done")

    I don't see you commit the transaction. This is probably the reason that the changes do not come.

    Chantal

    http://dwteam.in

  • How to enable and disable, copy or rename the rules via the groovy script?

    A client, we received this question:

    How to enable and disable, copy or rename the rules via the groovy script?

    Foglight 5.7.5

    Hello

    There is this example of support KB

    support.Software.Dell.com/.../99059

    and there is also documentation of Service layer of the administration on the RuleService console.

    Best regards

    Golan

  • Determine whether the host is virtual in the groovy script

    Hello

    I am writing a groovy script to extract data from our monitored SQL Server instances.  I would like to be able to differentiate between the n & b physical and virtual hosts.  I know that this should be possible since the database dashboard displays a different icon for both.  However, I can find what data item or property I'd look for his determination.

    I use the following code:

    dataSrv = server. DataService

    querySvc = server. QueryService

    topologyQuery = «!» DBSS_Instance ".

    objects = querySvc.queryTopologyObjects (topologyQuery)

    Need a way to determine whether each object is located on a physical or virtual host

    //...........

    Thank you.

    Thank you.  That pointed me in the right direction.  For those looking for the code, I use:

    ...

    topologyQuery = «!» DBSS_Instance ".

    objects = querySvc.queryTopologyObjects (topologyQuery)

    Objects.each {object->

    instance_name = object.name

    instance_host_name = object.real_mon_instance_name

    VM = 'physical '.

    vmQuery = «!» «VMWVirtualMachine where $host.name = ' "+ instance_host_name +»»»

    VM = querySvc.queryTopologyObjects (, vmQuery)

    If (vms.size () > 0) {}

    VM = "VM".

    }

    ...

  • Want to learn the basic Groovy script

    Want to learn how Groovy script of all reference documents database

    You might find many documents, some of them for you

    http://docs.Oracle.com/CD/E23943_01/integrate.1111/e12643/appendix_c.htm#ODIDG1443

    http://www.Ateam-Oracle.com/getting-groovy-with-ODI-upgrades-and-OWB-migrations/

    https://Java.NET/projects/oracledi/pages/ODISDKSamples/text

    Kind regards

    Deker P.

  • can we have more than one type of topology for a rule?

    Hello

    5.6.4 can we have more than one type of topology for a rule? How insert and separate?

    Thank you.

    Try something like this, but be very careful that you understand the implications of the scope of the rule to a very large number of objects:

    $objectsbytype(/Host|) VMWVirtualMachine | VMWESXServer | VMWCluster | VMWDatastore /) If you do not need to check each type separately

    or

    the ((hôte où name like 'a%') Union (VMWVirtualMachine where name like would be %')) If you need condition the type of each object separately, and then join the results)

  • How to extend to two monitors?

    I have a Macbook Pro that I bought this year. I want to connect it to my KVM DVI switch for two monitors. It will work with a bolt of lightning for two adapters to DVI ports? If so, any recommendations on what card? If option 1 is not possible, I guess I need two crush on DVI adapters. However, without worrying that we I get, I need to work in extended mode and not just mirroring. Is this possible with the MacBook Pro?

    I'm looking at present one this one on Amazon. Any recommendation is also appreciated.

    with the exception of the Apple ThunderBolt display NO display use ThunderBolt directly. They all pick up a subset of the ThunderBolt signals off the same connector, called Mini DisplayPort. Mini DisplayPort and its twin full size are "next generation" display interfaces.

    DisplayPort family attribute this and display-decision makers interface wanted to for a long time. Refresh 'heartbeat', 60 to 100 times per second is GONE. Only changes are sent in most of the time. The display must have an internal display buffer. Talk about framerate for DisplayPort has no meaning.

    The signal levels are very low, but use differential driver (or push-pull) circuits to very good noise protection.

    If you choose to convert to "legacy" display protocols, you can do it on a limited basis, with constraints. Long cables or more than TWO screens "legacy" will lose the signal strength and must be stimulated with ACTIVE DVI adapters, usually around US$ 40, who re-pilots to signal them upward.

    Using DVI screens larger than worms 1920 wide requires a Dual-Link, much more complicated and expensive adapter.

  • can a wifi with an airport extreme network be extended with two Airport express wireless?

    I have developed successfully the range of my wifi network by connecting an older brick of Airport express to a new airport extreme. Unfortunately, there is a room more than I would like to achieve, so I'm trying to add a second (newer) to bring in this room to get full coverage. When I try to set up in the airport utility it hits an "unexpected error" message continually or breaks down the network. should I change in the settings? the express environment be on something else (like a relay?) in order to allow the new express to join the network? I have reset the factory default final express and tried to let the wizard implemented to extend my existing network.

    I understand that I will sacrifice speed, but there is no way to connect them at the present time. worst case, I should better results if I break through the floor and the extreme of wire in the Middle express?

    Thank you

    David

    Sorry, but Apple will allow you only to wireless "extend" the network once, not two.

    In other words, just about any device that "extends" the network must connect directly to the 'main' router... not to another router that is already expanding the network.

    Another way of saying the same thing... both your need for extensions at about the same distance from the 'main' router and two extensions should be closer to the main router they are to each other.

    You want to continue trying to implement the 2nd AirPort Express Terminal?

    "I should better results if I break through the floor and the extreme of wire in the Middle express?


    Yes, that would allow you to do what you want, assuming that the 'remote' Express can pick up a good signal of the Middle Express wireless.

  • Script that export two separate PDF files of paper with two pages AND change the name of the file, the number two of the PDF

    OBS: Script InDesign CS3:

    I have a document with two pages but a file name!

    I need a script which

    1 export the two pages in format PDF separated two - so NOT a single PDF file with two pages but two PDF files

    2. the first PDF file must have the same name as the document - for example .indd13ESW110020216TC0-> ESW110020216TC013.pdf

    3. the second PDF file will be added to the last number - so .indd14ESW110020216TC0-> ESW110020216TC014.pdf

    Is it possible to integrate this script:

    var doc = app.activeDocument;  
    var _PDFfile = new File('\\\\testserver\\' + app.activeDocument.name.replace (/\.indd$/, '.pdf'));  
      
    var _PDFExportPreset = app.pdfExportPresets.item('MyPdfSetting');   
    if (_PDFExportPreset == null){  
       alert('PDF Export Presets not found');  
       exit();  
        }    
        app.pdfExportPreferences.pageRange = PageRange.ALL_PAGES;                      
        doc.exportFile(ExportFormat.pdfType, _PDFfile, false,_PDFExportPreset);  
    

    Hello

    Try this...

  • How can I script to group two frames?

    I want to be able, from a script, to harness together a frame image and his label so that they move together. The context is that I am trying to automate the process of loading the images and add labels, leaving them paired together so I can then move/resize together to form my final layout. I think I just need to know how to set up a link between two images, since I know how to place the image and establish a framework text for the label. Suggestions welcomed and thanks in advance.

    var myGroup = myDoc.groups.add ([myImageFrame, myLabel])

  • Can someone provide me with a groovy script to make a simple alert for anythin

    Can someone provide me with a script simple roovy which can be used to craete an alert for a threshold of data... I just need a simple script that I could use to define my own script.
    down the line.

    I do not know groovy and I'm NOT a person of java. So learning groovy is really hard for me.

    Deploying the dir fixed link:
    {JBOSS_HOME}/server/default/deploy/hq.ear/hq.war/hqu

  • Install Photoshop CS6 extended on two computers?

    Hello

    Is it possible to install Photoshop CS6 extended on my two computers (Mac pro and a Macbook pro)?

    I already have Photoshop CS6 extended running on my Mac Pro, but I would also like to install it on my Macbook pro.

    Best regards.

    Sébastien.

    Yes. You can activate the software to be used on up to two computers at the same time.

  • Extend the two-dimensional array

    Hi all

    How can I extend both the axis of a two-dimensional array?
    DECLARE
      TYPE num_array IS TABLE OF VARCHAR2(100);
      TYPE bidim_num_array IS TABLE OF num_array;
      l_array bidim_num_array;
    BEGIN
      ...
    END;
    in order to fill the two-dimensional table as a matrix:
    l_array(1)(1) := ...
    l_array(1)(2) := ...
    l_array(1)(3) := ...
    l_array(2)(1) := ...
    l_array(2)(2) := ...
    l_array(2)(3) := ...
    l_array(3)(1) := ...
    l_array(3)(2) := ...
    l_array(3)(3) := ...
    I don't know the size of the MxN matrix.

    Thanks in advance.

    Manuel Vidigal wrote:

    How can I extend both the axis of a two-dimensional array?

    Just as you would with one-dimensional, just twice - one for each dimension. You will also need to initialize second dimension table whenever you extend first dimension:

    SQL> DECLARE
      2    TYPE num_array IS TABLE OF VARCHAR2(100);
      3    TYPE bidim_num_array IS TABLE OF num_array;
      4    l_array bidim_num_array := bidim_num_array(); -- initialize two-dimensional array (this initializes first dimension only)
      5  BEGIN
      6    l_array.extend; -- extend two-dimensional array
      7    l_array(1) := num_array(); -- initialize second dimention array
      8    l_array(1).extend; -- extend second dimension array (this extends first dimension only)
      9    l_array(1)(1) := 'Row 1, Column1';
     10    l_array(1).extend; -- extend second dimension array
     11    l_array(1)(2) := 'Row 1, Column2';
     12    l_array.extend; -- extend two-dimensional array (this extends first dimension only)
     13    l_array(2) := num_array(); -- initialize second dimention array
     14    l_array(2).extend; -- extend second dimension array
     15    l_array(2)(1) := 'Row 2, Column1';
     16    l_array(2).extend; -- extend second dimension array
     17    l_array(2)(2) := 'Row 2, Column2';
     18    for i in 1..l_array.count loop
     19      for j in 1..l_array(i).count loop
     20        dbms_output.put_line(l_array(i)(j));
     21      end loop;
     22    end loop;
     23  END;
     24  /
    Row 1, Column1
    Row 1, Column2
    Row 2, Column1
    Row 2, Column2
    
    PL/SQL procedure successfully completed.
    
    SQL>  
    

    SY.

Maybe you are looking for

  • iPhone 5 cracked during loading

    Recently received an iPhone handed to nine 5 eBay. I got two days and I was recharged during the night, it the morning I got up and took the phone to see a crack right next to the home button. I'm positive, I didn't damage myself and have read it cou

  • iTunes menu bar

    My iTunes does not ikon menu or menu bar. What measures are needed to restore these features?

  • XP users are always welcome here?

    A question for the moderators please. Since April 8, 2014 are always welcome XP users here? I am looking at this option, when I click on 'ask a Question ': * Windows * Windows XP * Updated Windows

  • This disc is should downloads to solve the problem of the device are not installed. (Code 28)

    This disc is should downloads to fix the drivers for this device are not installed. (Code 28)  There is no driver selected for the device information set or element.my pc works on windows 8.1 pro 64 bit model whose id is 15-e017AU. 

  • processor a6763w

    I saw in the forums that the phenom 9650 has been updated with the a6763w, but I was wondering if there is a way to increase it to 3.0 ghz?