Dispatch-policy using ejbgen

Hi,
          I need to specify <dispatch-policy> on MDB for highest throughput. But ejbgen is giving error while setting this property.
          I have specified ejbgen attributes for message driven beans as,
          /** @ejbgen:message-driven
          * ejb-name = com.netapp.asup.mdb.ParserMDBean
          * destination-type = javax.jms.Queue
          * max-beans-in-free-pool = ${max-beans-in-free-pool-Parser}
          * initial-beans-in-free-pool = ${initial-beans-in-free-pool-Parser}
          * dispatch-policy = "netapp.patnaik.asup.Parser"
          * destination-jndi-name = ${destination-jndi-name-Parser}
          * @ejbgen:foreign-jms-provider
          * connection-factory-jndi-name = ${connection-factory-jndi-name}
          * initial-context-factory = ${initial-context-factory}
          * provider-url = ${provider-url}
          It is giving error as,
          mdb/ParserMDBean.java:42: Error: Tag 'ejbgen:message-driven', unknown attribute: 'dispatch-policy'.
          My environment is, Weblogic 8.1 SP4 and ejbgen version is 2.16.
          I am getting this error even if I have changed ejbgen to 2.19.
          Please suggect me.
          Thanks,
          Murthy P

Thanks -
FYI - Known issue (CR190476). The patch support sent seems to work (ejbgen doesn't choke). I just don't see the MDB using the queue I specify - a thread dump shows onMessage executing in the default thread pool...
Cameron

Similar Messages

  • OSB: Proxy Service and Dispatch Policy

    Hi all,
    I'm trying to use OSB (10.3) proxy service with dispatch policy set to WebLogic (10.3) work manager to limit maximum number of threads allocated for request to this proxy service.
    It seems to me that whole dispatch policy setting is ignored in OSB. The situation is like this: I have simple Axis based web service with wait method that just waits for few seconds (based on request parameter). I use this service for testing (hm, so far just for trying to understand) OSB dispatch policy function.
    Using soapUI I created a simple load test which uses 10 threads to call wait(10) - it means "wait for 10 seconds". Time limit for the whole load test is set to 20 seconds. It is clear that the total execution count is 2 x 10 = 20. So far, so good.
    Then I created simple proxy service in OSB that just routes request to business service representing my Axis service with wait method. I set a dispatch policy for the proxy service to WorkManager-2threads (see below) and I expected that running the same load test with endpoint set to OSB would result in significant lower total execution count. I expected that because WebLogic should allocate 2 threads at most for all requests to this proxy service. However, that's not the case as the result is the same as in the first (Axis only) test. Just as there was no dispatch policy settings at all ...
    Where is the problem?
    This is the relevant part of my WebLogic configuration regarding work manager:
    <max-threads-constraint>
    <name>MaxThreadsConstraint-2</name>
    <target>AdminServer</target>
    <count>2</count>
    <connection-pool-name></connection-pool-name>
    </max-threads-constraint>
    <work-manager>
    <name>WorkManager-2threads</name>
    <target>AdminServer</target>
    <max-threads-constraint>MaxThreadsConstraint-2</max-threads-constraint>
    <capacity xsi:nil="true"></capacity>
    <ignore-stuck-threads>false</ignore-stuck-threads>
    </work-manager>

    It's same problem to me. I do pressure test by loadrunner,I deployed two separate proxy service,under same concurrent user,I get same TPS from the two proxy service.but when I add low priority concurrent user,low priority TPS up.
    I set the Route option as you say,but weblogic hanged immediately,and can't be accessed by the console.

  • Configure dispatch-policy in deployment plan, wls 9.2

    Hello,
    We are planning to use deployment plans to configure applications post-compile time, such as assigning it a particular work manager which is defined globally. The problem is that weblogic seems to ignore the dispatch-policy configured in the plan, at least there is no evidence that the ejb is actually using specified work manager, even though it merges the plan with the descriptor.
    The sections in my deployment plan looks as follows:
    <variable-definition>
    <variable>
    <name>dispatch-policy_0</name>
    <value>wm02</value>
    </variable>
    <variable-assignment>
    <name>dispatch-policy_0</name>
    <xpath>/weblogic-ejb-jar/weblogic-enterprise-bean/\[ejb-name="xx.xx.xx.myejb"\]/dispatch-policy</xpath>
    </variable-assignment>

    Hi,
    I ran a quick test where I removed the work manager i referenced in the deployment plan, and behold, the server whined about referring to a missing work manager, so it "worked" all the time, there was just no way to test it.
    Anyway, than you for the help, it was really appreciated. :)
    Another thing I'm wondering about is XPath functions, and whether weblogic supports them in deployment plans. If I for example would like to insert the dispatch policy for some ejb with a name partially matching a string, I thought the XPath */weblogic-ejb-jar/weblogic-enterprise-bean[ejb-name/dispatch-policy* would do the trick, however this is not liked by weblogic since it requires name value pairs. Is there another way to use the contains()-function according to this requirement?
    Regards
    Olov                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Async-dispatch-policy

    Hello,
    AS per BEA help
    [url http://edocs.bea.com/workshop/docs81/doc/en/workshop/reference/configfiles/con_wlw-config_xml_ConfigurationFile.html]
    <async-dispatch-policy>
    weblogic.wlw.async.dispatch
    </async-dispatch-policy>
    This fragment in wlw-config.xml will result in the following entry being generated into the weblogic-ejb-jar.xml
    configuration file for the project?s AysncDispatcher and AsyncErrorHandler message-driven beans:
    <dispatch-policy>weblogic.wlw.async.dispatch</dispatch-policy>
    I am using weblogic 8.1 sp3 .When I change the wlw-config.xml file and build I am getting warning
    WARNING: WARNING
    WARNING: DESCRIPTION: Webapp-level config file C:\m6prod\NEWORDER\NEWORDERWeb\WEB-INF\wlw-config.xml failed to validate against schema.
         SUGGESTION: Fix the config file so that it is valid, and redeploy the application.
    WARNING: WARNING
    WARNING: DESCRIPTION: Webapp-level config file C:\m6prod\NEWORDER\NEWORDERWeb\WEB-INF\wlw-config.xml error. Expected element hostname@http://www.bea.com/2003/03/wlw/config/ instead of async-dispatch-policy@http://www.bea.com/2003/03/wlw/config/ here in element wlw-config@http://www.bea.com/2003/03/wlw/config/. Line=-1 Col=-1while build and weblogic.ejb-jar.xml file is not updated
    Pls help

    More details on what we are seeing:
              When we look at the thread dump we see that the weblogic.ejb20.internal.JMSMessagePoller pool is filled up, and the custom thread pool MyMDBPool is partially used. It appears that first the JMSMessagePoller is used and then the custom thread pool specified in the dispatch policy of the MDB. Is that the design, or am I missing something ?
              Would'nt we normally want the custom thread pool to be used first and then the general thread pool ?

  • Setting dispatch-policy in weblogic-ejb-jar.xml

    We are using Weblogic 8.1 sp2.
    What are we trying to do-
    Use the dispatch policy feature to allocate a new execute queue to a stateless session bean. This is to throttle the usage of this bean.
    Problem(s) definition-
    1. When I deploy the application with compiled EJBs (i.e. after running ejbc) IT WORKS.
    If we deploy without compiling the EJBs IT DOES NOT WORK.
    To be very sure I have already tried removing the EJBCompilerCache every time I restart the server.
    I have made sure that we use the same weblogic.jar that the server uses during the compilation of the EJBs.
    2. In both the cases mentioned above the weblogic-ejb-jar.xml when viewwed from the console does not show the dispatch-policy element.
    Any help with regards to this would be highly appreciated.
    Rgds,
    Amresh

    We are using Weblogic 8.1 sp2.
    What are we trying to do-
    Use the dispatch policy feature to allocate a new execute queue to a stateless session bean. This is to throttle the usage of this bean.
    Problem(s) definition-
    1. When I deploy the application with compiled EJBs (i.e. after running ejbc) IT WORKS.
    If we deploy without compiling the EJBs IT DOES NOT WORK.
    To be very sure I have already tried removing the EJBCompilerCache every time I restart the server.
    I have made sure that we use the same weblogic.jar that the server uses during the compilation of the EJBs.
    2. In both the cases mentioned above the weblogic-ejb-jar.xml when viewwed from the console does not show the dispatch-policy element.
    Any help with regards to this would be highly appreciated.
    Rgds,
    Amresh

  • Using EJBGen

    Guys,
    I have a doubt regarding EJBGen and Workshop/WebLogic Server.
    I would like to generate automatically some EJBs.
    I have a DataSource working that points to a DataBase SQL Server. There are some Tables there that I would like to produce some EJBs.
    How can I do that?
    Is it possible to do by Eclipse Workshop? Or is it possible to do with a script? Maybe and ant script using ejbgen?
    Thanks,

    Hi,
    Internally Workshop provides you to use EjbGen option for EJB 2.1 so you can use those EJB option but not for EJB 3.0
    instead of using workshop use ant script which is more flexible and more efficient.
    Regards,
    Kal.

  • Adding security info in DD using EJBGen

    Hi,
    I need to insert security information like security-role, method permission, etc.
    in ejb-jar.xml and weblogic-ejb-jar.xml for the EJBs created using EJBGen. I tried
    searching on bea newsgroups and googling but couldn't find anything on that. Does
    EJBGen supports this or any new release of EJBGen is expected to do this ?
    As a work around, I keep the copy of the DDs which have this info and after EJBGen
    is finished, these DDs are copied over and the rest of the build process continues.
    This is very restrictive approach as any change in EJB apart from bug fixing requires
    some manual effort on these DDs.
    Is there any other solution possible?
    thx
    -deepak

    Oops.. I lied Deepak. I thought there wasn't
    a way to do this but I was wrong. I should've
    double checked before I replied
    @ejbgen:method-permission-pattern
    Where:Class
    Applicable on:All
    have a look at the docs for this tag. This will allow
    you to do what you're looking to do.
    -Michael
    Michael Kovacs wrote:
    deepak,
    There's no way to do wildcard method permission mapping with ejbgen
    currently. You have to explicitly map each method to a role.
    Michael Kovacs
    Senior Software Engineer
    BEA Systems
    "deepak" <[email protected]> wrote in message
    news:3f93b041$[email protected]..
    Falk <[email protected]> wrote:
    EJBGen supports this.
    Look into the tag reference.
    FalkI have already searched that but couldn't find anything useful.
    To be more precise I want to insert something like following inweblogic-ejb-jar.xml
    <security-role-assignment>
    <role-name>testRole</role-name>
    <principal-name>testUser</principal-name>
    </security-role-assignment>
    and following things in ejb-jar.xml
    <security-role>
    <role-name>testRole</role-name>
    </security-role>
    <method-permission>
    <role-name>testRole</role-name>
    <method>
    <ejb-name>myEJB</ejb-name>
    <method-name>*</method-name>
    </method>
    </method-permission>
    thx
    -deepak

  • Creating access policy using OIM 11g APIs

    Is there a way to create an access policy using API? I see that there is AccessPolicyService but it only supports evalutePoliciesForUser. I need a way to add and modify policies.
    I'm using OIM 11.1.1.5
    Edited by: DJ on May 21, 2012 11:53 AM

    FYI, I hope the following links might be helpful, if you did not come across them before:
    OIM API for Create Access Policy:
    http://otndnld.oracle.co.jp/document/products/id_mgmt/idm_904/doc_cd/javadocs/operations/Thor/API/Operations/tcAccessPolicyOperationsIntf.html
    Example Code for OIM API Creation of Access Policy
    http://learnidm.blogspot.co.uk/2011_08_01_archive.html
    Thanks,
    Krish.

  • How to create Authorization policy using OIM 11g API

    Hi,
    Could you please let me know how to create Authorization policy using OIM 11g API.
    Thanks

    Constructing A Policy Programmatically
    http://docs.oracle.com/cd/E27559_01/dev.1112/e27154/cons_policy_prog.htm#CHDHACBF
    api ref for PolicyStore
    http://docs.oracle.com/cd/E21764_01/apirefs.1111/e22649/oracle/security/jps/service/policystore/PolicyStore.html#createApplicationPolicy_java_lang_String_
    something like below code to start with
    try {
    JpsContextFactory ctxFact;
    ctxFact = JpsContextFactory.getContextFactory();
    JpsContext ctx;
    ctx = ctxFact.getContext();
    PolicyStore ps = ctx.getServiceInstance(PolicyStore.class);
    if (ps == null) {
    // if no policy store instance configured in jps-config.xml
    System.out.println("no policy store instance configured");
    return;
    ApplicationPolicy ap = ps.createApplicationPolicy("Trading", "Trading
    Application","Trading Application.");
    } catch (JpsException e) {
    }

  • Sjsws7 log rotation policy using CLI

    Is it possible to set the log rotation policy using CLI.
    We want to script the process of log rotation using CLI instead of configuring it from the console.

    Thanks for you interest in Web Server 7.
    Yes, Web Server 7 has a rich CLI and
    Log rotation like most administration tasks is configurable using the CLI.
    To schedule log rotation you need a create an "event" . The event as can be seen from the usage could be restart/reconfig/rotate-log/rotate-access-log etc.
    wadm> create-event
    Usage: create-event [--echo] [--no-prompt] [--verbose] [--no-enabled] config=name command=restart|reconfig|rotate-log|rotate-access-log|update-crl|commandline ( (--time=hh:mm [--month=1-12] [--day-of-week=sun/mon/tue/wed/thu/fri/sat] [--day-of-month=1-31]) | --interval=60-86400(seconds) )
    CLI014 config is a required option.
    I will walk thru the steps in the CLI starting from scratch..
    1. Create a config.
    2. Create an event
    3. Create an instance of the config
    4. Start the instance
    5. Deploy the config ( This is a workaround. You should not have to to do this in the upcoming Technology Preview Release 3).
    That's it.. The log should be rotated as per the parameters specified when you create the event.
    I am pasting below the actual result of following the above steps.
    In the example below the event scheduled is a rotate-log event. rotate-log rotates the error log. If you need to rotate the access logs use rotate-access-log instead.
    bash-3.00# ./wadm user admin port 18911
    Please enter admin-user-password>
    Sun Java System Web Server 7.0-Technology-Preview-2 B06/19/2006 17:16
    wadm> date
    Sat Sep 16 09:52:27 IST 2006
    wadm> create-config -- server-name servername http-port 18923 test
    CLI201 Command 'create-config' ran successfully
    wadm> create-event config=test command=rotate-log --time=09:55
    CLI201 Command 'create-event' ran successfully
    wadm> list-events config=test verbose --all
    command time interval
    rotate-log {09:55}
    wadm> create-instance --config=test wspqes032
    CLI201 Command 'create-instance' ran successfully
    wadm> start-instance --config=test
    CLI204 Successfully started the server instance.
    wadm> deploy-config test
    CLI201 Command 'deploy-config' ran successfully
    wadm> date
    Sat Sep 16 09:53:22 IST 2006
    wadm> pwd
    /space/hari/ws7/tpv2/bin
    wadm> cd ../https-test/logs
    wadm> date
    Sat Sep 16 09:53:37 IST 2006
    wadm> ls -al
    total 8
    drwxr-xr-x 2 root root 512 Sep 16 09:53 .
    drwxr-xr-x 10 root root 512 Sep 16 09:53 ..
    -rw-r--r-- 1 root root 143 Sep 16 09:53 access
    -rw-r--r-- 1 root root 683 Sep 16 09:53 errors
    wadm> date
    Sat Sep 16 09:55:18 IST 2006
    wadm> ls -al
    total 8
    drwxr-xr-x 2 root root 512 Sep 16 09:55 .
    drwxr-xr-x 10 root root 512 Sep 16 09:53 ..
    -rw-r--r-- 1 root root 143 Sep 16 09:53 access
    -rw-r--r-- 1 root root 0 Sep 16 09:55 errors
    -rw-r--r-- 1 root root 869 Sep 16 09:55 errors.200609160955
    wadm>
    In this example we have configures the log to be rotated at 09:55 am and as can be seen this has been done.
    We appreciate your valuable feedback. Please do mail us at [email protected]
    Hope that helps,
    Hari.
    Message was edited by:
    hari19

  • Error while creating authorisation policy using OIM 11g API

    Hi,
    We have a requirement to create ‘Authorization Policies’ (assign Data Constraints, Permissions & Assignments) using OIM 11g API’s.  I am using ‘oracle.iam.authzpolicydefn.api.PolicyDefinitionService & oracle.iam.authzpolicydefn.vo.AuthzPolicy’.  But when I am trying to attach Entity/Feature (User Management) to authorisation policy, it is throwing exception.  Below is the code snippet which I am trying to implement.
    Line1: PolicyDefinitionService policyService = oimClient.getService(PolicyDefinitionService.class);
    Line2: AuthzPolicy authPolicy = new AuthzPolicy();
    Line3: authPolicy.setName("Test Authz Policy");
    Line4: authPolicy.setDisplayName("Test Authz Policy Dsp Name");
    Line5: authPolicy.setDescription("Test Authz Policy Description");
    Line6: Feature feature = oimClient.getService(Feature.class);
    Line7: Action featureAction = feature.getAction(FeatureManagerConstants.Features.USER_MGMT.getId());
    Line8: List<Action> actions = new ArrayList<Action>();
    Line9: actions.add(featureAction);
    Line10: authPolicy.setActions(actions);
    Line11: policyService.createPolicy(authPolicy);
    Exception: oracle.iam.platform.utils.NoSuchServiceException: java.lang.ClassNotFoundException: oracle.iam.authzpolicydefn.api.FeatureDelegate
    The above exception is throwing at Line6.
    Let me know if anyone implemented.
    - Kalyan Mutya

    If you are using JDeveloper , can you able to get class after giving "." .If yes no than it is the problem with the jar file you are using .Check whether you can able to import oracle.iam.authzpolicydefn.api.Feature.
    Thanks ,
    Animesh anand

  • Sub-Organization's Network control Policy used by a vNIC Template causes Warning

    Hi,
    using UCSM 1.4.(1i) if a Network Control Policy defined in a Sub-Origaniziation is used by a vNIC Template the following warning shows up:
    * Description:
    ** Policy reference nwCtrlPolicyName does not resolve to named policy.
    * ID: 792882
    * Cause: named-policy-unresolved
    * Code: F4526851
    This does not happen if the network control policy has been defined in the "root" organization.
    Any ideas on how to get rid of that warning?
    Ralph

    Ralph,
    I have had the same problem in my environment for awhile. I have been ignoring it because even though the warning says the policy can't be found when I check the NIC Templates in the server OS they are able to see the CDP information so the settings have been working. I found that if I just go ahead and create another policy in root with the same name the warnings all clear. I figure this is some buggy alert. I know the change in setting was getting recognized and if the vNIC Template can't find it then why would it be an option in the drop down right? Either way taking advantage of the fact that if it can't find it in the sub-org the UCS automatically searches for the same named item in the root org, I didn't need to change vNIC Templates I just had to let it find the new one in root.
    I also find it interesting that no VNIC has this problem just VNIC Templates.

  • Nested request dispatches when using RequestDispatcher in a Button action

    Hi all,
    I am new to JSF so I am probably missing something very simple, please help:
    The test case is simple: I created one visual web page with one button and one normal JSP file(named test.jsp) using Netbeans 5.5 with visual web pack on Sun Application Server 9 PE. The code action for the button is as follows:
    public String button1_action() throws Exception
            ExternalContext context = FacesContext.getCurrentInstance().getExternalContext();
            HttpServletRequest request = (HttpServletRequest) context.getRequest();
            HttpServletResponse response = (HttpServletResponse) context.getResponse();
            RequestDispatcher dispatcher = request.getRequestDispatcher("test.jsp");
            dispatcher.forward(request,response);
            return null;
        }Once the JSF page is loaded and the button is clicked, this exception occurs:
    ApplicationDispatcher[WebApplication1] Servlet.service() for servlet Faces Servlet threw exception
    javax.servlet.ServletException: WEB2651: Exceeded maximum depth for nested request dispatches: 20
    at org.apache.catalina.core.ApplicationDispatcher.doInvoke(ApplicationDispatcher.java:837)
    at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:697)
    at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:532)
    at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:465)
    at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:353)
    at webapplication1.Page1.button1_action(Page1.java:242)
    Can anyone provide any advice on how to resolve this issue?

    Hi Rachel,
    As per the Servlet2.3 Javadoc:
    The pathname must begin with a "/" and is interpreted as relative to the current context root.
    If you make that change and include the complete path, then it would work fine.
    Ex:
    If your context looks like http://my.company.com/webapp1/ and if you were to have your forwardPortlet.jsp in a directory like:
    webapp1
      |
      |-> htdocs
             |
             |-> forwardPortlet.jsp
    then, your code would look like;
    RequestDiscpatcher d = request.getRequestDispatcher("/htdocs/forwardPortlet.jsp");
    HTH,
    thanks,
    harsha

  • Dispatch Capacity using Product Allocations

    Looking for a bit of guidance on an issue. Have a scenario where we get heavy demand on dispatching requirements. Strangely enough, SAP doesn't have any capacity planning around Logisitcs Execution from what I have seen - it assumes unconstrained capacity to dispatch stock. So I am looking to use Product Allocation based on a total volume (key figure) per site (Characteristic) basis.
    My issue is around the Planning Period indicator. I want to use the Allocation model on a daily basis - i.e. fill up the Dispatch 'bucket' daily and once filled, it will look to the next available planning period. I need to do this daily - not weekly or monthly. Period indicator 'T' (Daily) is available but the planning parameter doesn't seem to like this.
    Anyone manage to get this working on a daily basis? Other than that I may have to go down the custom path, which will be sub-optimal, as the standard functionality works sensationally at a weekly or monthly basis.
    Cheers,
    Paul...

    As per usual, I solve the issue just after I log a question in the forum!
    It appears that within MC7F, that the Planning Period indicator is also controlled via table T445A, which is maintainable. I updated the table, checked the planning parameters associated with my Info Structure, which showed up as 'T', then assigned the entry to my transport. I recreated my Plan via MC93 (after deleting the old one), and the daily planning buckets have come through.

  • AuthZ Policy using specific Endpoint Identity Groups

    I am trying to create an AuthZ policy that will identify if a device is in specific Endpoint Identity Group.  See policy below.
    I used the IdentityGroup:Name attribute Equals the Identity Group MAB_Devices.  Please note that there are NO Identity groups listed in the dropdown options, so I typed in the name.   Alas, the rule is not working.   Anyone have advise on what I am doing wrong?  Thx

    Bransomar, your screenshot is an Authentication policy rule but you should do it in Authorization policy. Authentication policy sorts out requests by request method and origin and assigns an identity store to each.

Maybe you are looking for