Problems generating multiple services from the same EAR using servicegen

I have a single EJB JAR that contains multiple stateless session beans. I
want to expose each of these individually as a service. So I have defined
the following in my build file:
<servicegen destEar="${ear.file}" warName="${war.file.name}"
contextURI="web_services">
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="AService"
serviceURI="/AService" includeEJBs="AService" generateTypes="True"
expandMethods="True"/>
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="BService"
serviceURI="/BService" includeEJBs="BService" generateTypes="True"
expandMethods="True"/>
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="CService"
serviceURI="/CService" includeEJBs="CService" generateTypes="True"
expandMethods="True"/>
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="DService"
serviceURI="/DService" includeEJBs="DService" generateTypes="True"
expandMethods="True"/>
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="EService"
serviceURI="/EService" includeEJBs="EService" generateTypes="True"
expandMethods="True"/>
</servicegen>
I execute the task and it runs without issue. However, when I attempt to
deploy the EAR I get some odd results (there are multiple jars listed all
with my original name and then a number appended, for example MyApp.ear2).
The deployment fails because each of these JARs contains the same session
beans.
So, I'm wondering if my only option is to package each session bean in a
separate EJB JAR or if there is another way I could get this to work.
Thanks,
Rob

Thanks, Neal. I'll do as you suggest.
Just a little feature enhancement request, as well. It would be nice if the
option existed to break out the webservices for all the session beans in a
ejb rather than creating one all-encompassing interface of all the methods.
I think this would be a useful feature.
Thanks, again,
Rob
"Neal Yin" <[email protected]> wrote in message
news:[email protected]...
I am not sure what can cause this. But I will make servicegen check for
duplicate.
For now, in order to make sure your automatic build process, you can use
ant's build in task "jar" to update your application.xml with a correctone
after servicegen.
-Neal
"Rob Moore" <[email protected]> wrote in message
news:[email protected]...
Neal,
After discussing this issue with a coworker, I found that when he buildsthe
ear on his machine using the servicegen entries I specified previously,the
application.xml is generated correctly. Mine, as you guessed, puts in
multiple module entries all containing references to the same jar. I'm
puzzled because we are apparently running in the same environment. Anyidea
what might be causing it?
Thanks,
Rob
"Neal Yin" <[email protected]> wrote in message
news:[email protected]...
Hi Rob,
There is something wrong during generating application.xml for the
ear.
After servicegen, if you open generated application.xml, you probablycan
see duplicate entries for one module. Please go ahead delete thoseredundant
entries. Let me know if this works.
-Neal
"Rob Moore" <[email protected]> wrote in message
news:[email protected]...
I have a single EJB JAR that contains multiple stateless session
beans.
I
want to expose each of these individually as a service. So I havedefined
the following in my build file:
<servicegen destEar="${ear.file}" warName="${war.file.name}"
contextURI="web_services">
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="AService"
serviceURI="/AService" includeEJBs="AService" generateTypes="True"
expandMethods="True"/>
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="BService"
serviceURI="/BService" includeEJBs="BService" generateTypes="True"
expandMethods="True"/>
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="CService"
serviceURI="/CService" includeEJBs="CService" generateTypes="True"
expandMethods="True"/>
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="DService"
serviceURI="/DService" includeEJBs="DService" generateTypes="True"
expandMethods="True"/>
<service ejbJar="${ejbc.jar.file}"
targetNamespace="http://www.acme.com/xauto" serviceName="EService"
serviceURI="/EService" includeEJBs="EService" generateTypes="True"
expandMethods="True"/>
</servicegen>
I execute the task and it runs without issue. However, when I
attempt
to
deploy the EAR I get some odd results (there are multiple jars
listed
all
with my original name and then a number appended, for exampleMyApp.ear2).
The deployment fails because each of these JARs contains the samesession
beans.
So, I'm wondering if my only option is to package each session bean
in
a
separate EJB JAR or if there is another way I could get this to
work.
>>>>
Thanks,
Rob

Similar Messages

  • Problems sorting multiple releases from the same year

    Hello,
    I have just discovered how to arrange my iTunes library in chronological order by artist using 'Album by Year', i.e. All an artists albums are in order of release, Artist > Year > Disc # > Track #
    However,
    I have now encountered a new (minor) problem where there are several releases from the same year.
    For example, I have some artists who have released several singles, EPs and albums all in the same year (those busy people) and so all releases from any one year are filed alphabetically, not technically in chronological order, but close.
    It would require an exact release date in the 'Year'/'File Info' fields. Is this possible?
    Am I just being too picky?
    Thanks people. My head hurts.

    Hello,
    I have just discovered how to arrange my iTunes library in chronological order by artist using 'Album by Year', i.e. All an artists albums are in order of release, Artist > Year > Disc # > Track #
    However,
    I have now encountered a new (minor) problem where there are several releases from the same year.
    For example, I have some artists who have released several singles, EPs and albums all in the same year (those busy people) and so all releases from any one year are filed alphabetically, not technically in chronological order, but close.
    It would require an exact release date in the 'Year'/'File Info' fields. Is this possible?
    Am I just being too picky?
    Thanks people. My head hurts.

  • How do I receive multiple texts from the same sender, each individually?

    How do I receive multiple texts from the same sender, each individually?

    So I receive automated reminders from my job &amp; I want them to come individually. For example, one text -- time stamped 10:14 pm, then another 11:12 am, coming as separate msgs.

  • Connecting to multiple clusters from the same client

    We have a scenario where our cache client (extend client) should be able to connect to multiple clusters. All the clusters use the exact same configuration (same caches, same services etc) but running in different geographical locations. I know that the <remote-addresses> can be used to add multiple addresses but I'm assuming this is provided solely for fault tolerance. So, does the client actually support connecting to multiple clusters at the same time?
    Thanks
    Sijo Mathew

    Hi Sijo,
    Normally to connect a client to multiple clusters you would just define multiple <proxy-scheme> settings in your client configuration file, each one having a different name and pointing to a different cluster. You then map caches to the proxy-scheme for the cluster those caches live on.
    What may confuse things in your case is that you say the different clusters are identical and contain the same caches and services so you may have problems mapping caches on the client to different clusters.
    What are you trying to achieve by doing this if the clusters are all identical?
    JK

  • How Can I delete multiple messages from the same address in Mac Mail

    Hope this is in the correct Community.  Hope someone can help me to delete multiple email messages from the same email address.
    At the moment I can do it by holding down the Command key and highlighting each email, but that can be difficult with many messages
    to delete.  Is there a quicker way?
    Thanks for any help on this.

    Thanks for the reply, appreciate your input.  I did find another way of doing it and that is to highlight the first e-mail, hold down the shift key and click on the last one.  That highlights them all and then they can all be deleted.  Your ideas also work of course and I thank you for that.  Cheers.

  • *** Receiving multiple emails from the same person

    This is a new issue that started happening today and I'm wondering if someone can help.
    When receiving emails today, they are duplicating as they are coming into my inbox. The wierd thing is, the amount of duplicate emails is inconsistent. All emails are coming in as duplicates, but some messages duplicate up to 7 times for each sender. Other times, the message is in my inbox 4 times. Same message from the same sender.
    Is there a way I can tell my MacMail to stop this from happening???
    Thanks in advance.

    People keep reporting this problem from time to time, and almost always it is some sort of Yahoo account and there is nothing the user can do to fix it. The problem usually fixes itself after some time for no apparent reason, just as it started.
    Try using a different mail client, such as Thunderbird, and see whether the problem happens there as well. If so, then you know Mail has no bearing on it and there is nothing you can do other than complaining to your ISP or whoever is responsible for that account.

  • Multiple Contacts From The Same Company

    Is there a way to "clone" a contact entry to avoid re-entering all of the information for a new contact from the same company?

        Let's figure this out mrucci! I want to ensure I fully understand so I may assist accordingly. Are you creating several contacts with different numbers from the same company and want to know if there is a quick option to auto generate the company contact details? Please confirm so I may further assist. Thank you.
    TominqueBo_VZW
    Please follow us on Twitter @VZWSupport   

  • Multiple ResultSets from the same connection occuring at the same time

    Is it possible to have the following code? The issue is that you are iterating through two result sets created from the same connection at the same time.
    try {
    Connection conn=createConnection();
    Statement s=conn.createStatement();
    ResultSet rs=s.executeQuery(someSQL);
    while (rs.next()) {
         Statement s2=conn.createStatement();
          ResultSet rs2=s2.executeQuery(someOtherSQL);
          while (rs2.next()) {
               //do something
    } catch (SQLException sqle) {
    } finally {
    freeConnection(conn);

    Joel,
    The code compiles, but I have not tried running it. It is a question I need to know, designing a program.
    The question is whether some error would come up or the first ResultSet would be corrupted because a second were created before the first one was closed.
    --Gabe                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Can I combine multiple threads from the same contact in iMessage?

    iMessage displays multiple threads for the same contact.  Its very confusing and has resulted in lost messages.  I've tried changing a number of settings but to no avail.  Seems to require everyone in my contact list to eliminate all their email addresses in iMessage.
    Begs the question why does iMessage even need this information?  Worse, why does it suck it into its settings by default.  The directory server should only require a valid Apple ID (associated with the users' devices)  in order to direct an iMessage between two contacts.

    Thanks for the reply, appreciate your input.  I did find another way of doing it and that is to highlight the first e-mail, hold down the shift key and click on the last one.  That highlights them all and then they can all be deleted.  Your ideas also work of course and I thank you for that.  Cheers.

  • Connect one JAVA ADS instance to multiple clients from the same ABAP system

    Hi,
    Does anyone know whether it is possible to connect multplie clients from the same ABAP system to a JAVA instance running ADS?
    If so how do you setup the java destinations in Visual Admin and SM59 RFC connections?
    Any help is appreciated,
    Sander

    Dear Sander,
    this is always the case if you arrange the ADS connection.
    You have to set up the RFC connection 'ADS' in ABAP side and this connection/destination is client independent. So you can use this from all clients of your abap system.
    On Java side you have to arrange the already mentioned FP_ICF_DATA_<SID> destination. On the ABAP system and client (you specify in this destination) you have to maintain the user ADS_AGENT and your templates should also exist on this client. If there is no client defined, the default client will be used.
    Regards
    Istvan

  • Multiple edits from the same clip.

    Hi guys,
    I have a project which requires a lot of different edits from the same clip.
    Is there any way to do this without having to duplicate the same clip each time and then making my new edit?
    For instance -
    Clip 1 is 20 minutes long.
    My first edit is from 1:10 to 1:35.
    I then duplicate Clip 1 and make another edit from 2:40 to 3:55.
    I'm using Premier CS5.
    Thanks,
    Dave.

    Sub clips are not a general edit way of doing things efficiently.
    They are more of a way of creating a bin full of "selects" ( selected clips in a Selects Folder for easy and quick access and review). That is a time consuming process but works  well in some situations.
    Standard general  edit practice is to edit from Source Monitor.
    drop Clip into Source Monitor
    Mark In and Out point and drop that to the Time line. (many ways to do that Insert/ overlay/ shortcuts etc..)
    Next...Move thru and create new In and Out and do the same
    continue thru the Source Clip till complete...
    Then on the Timeline ( sequence) Tim and work the clips.
    Now ...some "learners" edit the source clip in the timeline  using Razor Tool...hacking and chopping and deleting and dragging bits of stuff all over the show.   Thats in efficient and clunky .

  • Generating Web Service from PL/SLQL procedures using ODSI

    1) Is there a way for us to generate REST based web services from PL/SQL procedures using Oracle data services Integrator? If Yes, Can you please point me to any available documentation
    2) I am trying to create a phyiscal data source based on PL/SQL procedures in the hope of turning these data sources into web services. I created a JDBC connection in web logic server console and am trying to view the packages under APPS but ODSI always crashes after selecting APPS. Is there a way to resolve this?
    Thanks
    Bhanu

    Hi..
    We came accross this problem a while back (I think it was us that the patch was created for). The patch was released under CR369707.
    Additionally it took us a while to figure out how to use it correctly.. Here's the info for it from a mail i receievd from our support contact..
    Here is more information from engineering on the patch:
    This is patch for filtering Stored Procedures in the New Physical Data Service Wizard. It is a partial fix to the problem. It just does filtering - it still retrieves all the jdbc metadata for everything that matches the filter. Ideally, the wizard would let you explore the stored procedures - retrieving the name only - and once you selected a stored procedure, it would retrieve the argument types (which is the expensive part).
    Copy these two files to a safe place
    <bea_home>\<aldsp_home>\eclipse-plugins\dsp\eclipse\plugins\com.bea.dsp.ide.external_10.3.0\dsp-ide-ldshredder.jar
    <bea_home>\<aldsp_home>\eclipse-plugins\dsp\eclipse\plugins\com.bea.dsp.ide.import_metadata_10.3.0.jar
    Replace the files with the ones provided in the patch (which I sent you be eMail recently).
    Creating Relational Database Physical Data Services -> Stored Procedures will be affected as follows :
    The Search field used to represent a pattern for the stored procedures only, and this patterns were applied against every schema visible to ALDSP. The patch allows you to also specify a list of catalogue patterns (useful only when applicable), a list of schema patterns and a list of procedure name patterns. These lists are separated by the pipe symbol, and the lists themselves are command-separated. The catalogue and schema patterns are regular expressions, the procedure pattern is for a database 'like' clause. For, Oracle, the catalogue patterns are not applicable.
    Example:
    |ODM1,ODM2|B% // look in schemas containing the strings ODM1 or ODM2 for procedures that start with B
    // possible results would be MY_ODM1.BUILDER, ODM2.BOTTOM
    |^ODM$|B%D // look in the ODM schema for procedures that start with B and end with D.
    Also - if there is a search string in the Search box, that search string will be applied to the schema when you click on the + to expand it in the Tree.
    Note that once a schema has been 'explored' - either by a search, or by expanding it in the tree, further searches will not update it's children. You would need to quit the wizard and restart.
    Once you get the patch if you have issues let me know..

  • Are there any conflicts or problems having 2 browsers on the same computer using windows 7

    I have no experience with having different browsers on the same computer and want to know if there are any conflicts or problems before I download a second browser.

    There are no conflicts if you install multiple browsers to the same computer. You can do that just fine.

  • How to read the hierarchy data from the same table using loop in AMDP method

    Hi All,
    We have a requirement to get the top partner from BUT050 table.
    Here the Top parent is nothing but the top most in the hierarchy of the partners from BUT050.
    Example:
    For partner 1234 (BUT050-PARTNER1) there is partner 3523(BUT050-PARTNER2) one level above
    For partner 3523(BUT050-PARTNER1)  there is partner 4544 (BUT050-PARTNER2) last level .
    so in this case for the partner 1234 the Top parent is 4544 .
    I have created AMDP Procedure method to get the top-parnet and below given is the logic implemented in AMDP method.
    Here i have implemented a recursive logic with the WHILE loop to get the top most hierarchy partner from the same table BUT050
    IV_Parent is the input partner and ev_top_parent is the output value.
    AMDP Procedure Method:
        DECLARE lv_date VARCHAR(8) := TO_VARCHAR (current_date, 'YYYYMMDD');
        DECLARE found INT := 1;
              iv_partner1 =  SELECT partner1 FROM but050
                              WHERE partner2 = iv_partner
                              AND reltyp = :iv_hierarchy
                              AND date_to >=  :lv_date
                              AND date_from <= :lv_date;
         WHILE found <> 0  do
           select partner1 into ev_top_parent from :iv_partner1;
                           iv_partner1 =  SELECT partner1 FROM but050
                           WHERE partner2 in ( select partner1 from :iv_partner1 where partner1 is not null)
                           AND reltyp = 'ZBP004'
                           AND date_to >= :lv_date
                           AND date_from <= :lv_date;
           select COUNT ( partner1 ) INTO found FROM :IV_PARTNER1;
        END WHILE;
    This method is working fine, but here it is only taking one single partner and getting the top parent as output.
    Now i would like to convert this mehtod so as to accept n number of partners (not one single partner) as input and should process each partner to get the top parent.
    Could anyone guide me how can i handle the given AMDP method further so as to work some how it is within another loop from other AMDP method.
    Thanks.
    Regards,
    Laxman.P

    Hi
    Go to SE11 and enter the hierarchy table name.
    /BIC/H....(infoobject name)...and execute the table and select table entry and delete all....
    Thanks
    TG

  • Send a message to multiple receivers from the same service

    Hi all,
    I registered on SAP community several months ago, I found many good hints and solutions to some of the problems encountered in XI and for which I thank you, but this is the first time I address a question to a common issue, written already about.
    I have a scenario with 1 File FTP sender adapter and 2 Receiver adapters:1 FTP adapter and 1 MAIL adapter. The input message is sent to one of these receiver adapters based on the value taken by a specific field from the input message.The receiver adapters are using the same party and service.
    The requirement is to solve this without using BPM.
    I have read "multiple receiver" issue related blogs and tried to use the standard receiver determination. Thus, I have 1 Sender Agreement, 2 Receiver agreements (one for FTP and one for MAIL), 1 Interface Determinations (with the 2 inbound interfaces and interface mappings corresponding to FTP and MAIL output) and 1 standard Receiver Determination where I added the party and service twice and specified for both the condition. The condition is based on XPath, is correct.
    In sxmb_moni, I get the error: "No receiver could be determined". If I remove one of the conditions, then the output is sent on both receiver adapters, instead of only the one that fulfills the condition.
    Can you please give me some feedback on how to solve this problem? It is rather urgent.
    I have also tried to create 2 Interface Determinations and have 2 Receiver Determinations, each one with the right condition. But I get the same error message.
    Is the problem due to the fact that I don't use 2 different services ?
    If you know how this can be solved without using BPM, please reply.
    Thanks a lot,
    Alina hudea

    > In sxmb_moni, I get the error: "No receiver could be determined". If I remove one of the conditions, then the output is sent on both receiver adapters, instead of only the one that fulfills the condition.
    Hi,
    I think the problem in Receive Determination. As you mentioned when you remove one of the condition then it works..
    What I concluded is, I think while creating your Receiver Determination for multiple receivers you added the receivers by pressing the plus sign and that means you are using mulitiple receivers with "AND" condition, so in this condition when both the condition will be true then only you will get success.
    What you can do is, Just remove one of the receivers and then add it by pressing the "OR" symbol i.e. by pressing this ( [ ] ) symbol and put your conditions as you like.
    I hope what I have concluded is correct.. 
    Regards,
    Sarvesh

Maybe you are looking for