Basic question: what to provide EJB client

Weblogic 6.1, SP1, on Red Hat Linux and Windows 2000
I have been developing an application for a few months now, but all EJBs have
only had local interfaces. My team now needs to expose a few remote interfaces
to another division of my company that's using WLS on another server. I understand
the changes that I need to make on the server side. I have searched the documentation
several times for help, but I can't seem to find a "Start here" page on how to
create the client Jar.
My understanding is this so far. For the server that will contain and run the
beans, I still bundle up the MyServiceBean, MyServiceRemote, and MyServiceHome
class files into a jar and run ejbc to perform the EJB compiling. My Manifest's
Class-Path element references some helper Jars like exceptions and value objects.
Once that's done, I then create a separate jar for the client. I must modify
my ejb-jar.xml file to add an ejb-client-jar element with MyServiceClient.jar
(or whatever the final file name will be) as its value. The client jar should
otherwise contain the same classes as the server jar, but without the bean class.
And then I also just provide the helper jars as well.
I'm sure I don't have this right yet, and I'd really appreciate some insight.
But then I have a more fundamental question: how does the client know which server
contains my EJBs? I haven't found this info in any deployment descriptor. The
only guess I have so far is that when the client creates an InitialContext to
fetch the home interface, they have to specify a ProviderUrl with my server's
IP address when they create an Environment.
Any help would be greatly appreciated. Thanks so much.
Andy

You don't really need to put an entry for ejb-client-jar element in the
ejb-jar.xml. You can still create your client and run it. Only thing is that
you need to put ur client jar in the classpath of your java client.
Hey Seth, where exactly is the ejb-client-jar entry is used ? I mean without
this also you can run ur client. Where does this help?
Rupesh.
Andrew Byala <[email protected]> wrote in message
news:[email protected]...
>
Hey, thanks for the rapid reply, Seth. But I'm wondering about theejb-client-jar
element of the ejb-jar.xml file. It seems a bit silly to use the xml filein
one version to generate my server-side Jar, and then have to make anotherversion
to generate the client-side Jar. Is there a simple way to do this withoutwriting
custom Ant tasks or anything like that?
Seth White <[email protected]> wrote:
Andrew Byala wrote:
Weblogic 6.1, SP1, on Red Hat Linux and Windows 2000
I have been developing an application for a few months now, but allEJBs have
only had local interfaces. My team now needs to expose a few remoteinterfaces
to another division of my company that's using WLS on another server.I understand
the changes that I need to make on the server side. I have searchedthe documentation
several times for help, but I can't seem to find a "Start here" pageon how to
create the client Jar.
My understanding is this so far. For the server that will containand run the
beans, I still bundle up the MyServiceBean, MyServiceRemote, and
MyServiceHome
class files into a jar and run ejbc to perform the EJB compiling.My Manifest's
Class-Path element references some helper Jars like exceptions andvalue objects.
Once that's done, I then create a separate jar for the client. I mustmodify
my ejb-jar.xml file to add an ejb-client-jar element with
MyServiceClient.jar
(or whatever the final file name will be) as its value. The clientjar should
otherwise contain the same classes as the server jar, but without thebean class.
And then I also just provide the helper jars as well.
I'm sure I don't have this right yet, and I'd really appreciate someinsight.
Sounds like you've got it, actually. The client just needs to have the
remote interface
classes
for the bean + helper classes in its classpath. Any generated RMIclasses
will be loaded
over the network, if needed.
But then I have a more fundamental question: how does the client knowwhich server
contains my EJBs? I haven't found this info in any deployment
descriptor.
The
only guess I have so far is that when the client creates an
InitialContext
to
fetch the home interface, they have to specify a ProviderUrl with myserver's
IP address when they create an Environment.To the best of my knowledge, this is correct as well.
Any help would be greatly appreciated. Thanks so much.
Andy

Similar Messages

  • Basic questions regarding installing Forefront EP Client 2010 on Windows 2012 R2

    Hi,
    We have a handful of servers and client machines (although these always seem to be expanding) and as such have previously just installed the Forefront Endpoint 2010 Client manually onto the various endpoints with updates being pushed via WSUS from a Windows
    2008R2 machine, without running to a full installation of SCCM or the Forefront Endpoint Server. However, trying to install the FEP 2010 client directly onto new Windows 2012R2 servers result in a "This OS is not supported" error.
    After checking some articles it appears that FEP 2010 might well be supported on Win 2012R2 (and Windows 8), but only if installed via SCCM. Is this correct?
    We do have access to SCCM 2012, but again I have shied away from this. I had hoped that maybe the SCCM Endpoint client could also be installed manually once more, but trying to install this on a Windows 2012R2 machine results in a "Windows compatibility
    mode is not supported by this program" error.
    Am I barking up the wrong tree and will I now have to finally learn and install SCCM? If so I take it that I can update my 2008R2 WSUS server to firstly Win 2012RS WSUS, then add SCCM 2012?
    Cheers
    Chris

    Hi Joyce,
    Thanks for the feedback.
    Hi,
    >>After checking some articles it appears that FEP 2010 might well be supported on Win 2012R2 (and Windows 8), but only if installed via SCCM. Is this correct?
    According to the blog below, Forefront Endpoint Protection 2010 with Update Rollup 1
    is supported on Windows Server 2012 R2.
    http://blogs.technet.com/b/configmgrteam/archive/2013/09/16/support-questions-about-win-8.1-and-winsvr-2012-r2-for-configmgr-and-endpoint-protection.aspx
    Please make sure you are running FEP 2010 update rollup 1. You could get it from the following link.
    http://support2.microsoft.com/kb/2907566/en-us
    Thanks for the feedback. I should have said that I have indeed tried this. From the initial link you posted I found the "Update Rollup 1 for Forefront Endpoint Protection 2010" (http://support2.microsoft.com/kb/2551095/en-us), however, this update
    itself apparently requires a prerequisite. Whist I have tried to install the prerequisite (http://support2.microsoft.com/kb/2554364/en-us) and the Forefront Update Rollup 1 directly onto a a Windows 2012 R2 machine, I end up with errors:
    Installing the Prerequisite result in a "Error code: 1642" in the log file. Have have tried to chase this error, but have not spent too much time digging as yet, but this appears to be more to do with the FEP server than the client.
    Installing with the FEP Update Rollup (obviously without the prerequisite), give us three folders (FepExt, FepReport and FepUx), none of which seem to be the client per se
    >>Ah, the later problem of trying to install a client from SCCM 2012 onto Windows 2012R2 maybe because I have been using SCCM 2012 SP1, and not SCCM 2012R2??
    In SCCM 2012, Endpoint Protection 2012 is integrated so you cannot install FEP 2010 in it.
    Best Regards,
    Joyce
    No no, What I meant was that I had hoped that I could install the client contained within SCCM 2012 R2 installation material manually onto a vanilla Windows 2012 R2 box (which is what I'm trying to do), in the same way that I could install the FEP 2010 on
    previous Windows OS. The ISO that I have currently from our systems team is that of SCCM 2012 SP1, not SCCM 2012 R2, and the client within the SP1 package does not install in Windows 2012 R2. I'm tyring to get hold of the SCCM 2012 R2 ISO now, which (from
    what I read) should allow me to manually install the client.
    I may well play with SCCM later, but is a little over kill for our estate (read 10's of servers and clients, rather than 1000's), however, we should have a campus licence for SCCM.
    Regards
    Chris

  • What is an EJB client?

    From EJB tutorial http://java.sun.com/j2ee/tutorial/1_3-fcs/doc/EJBConcepts2.html#62895
    Second, because the beans--and not the clients--contain the application's business logic, the client developer can focus on the presentation of the client. The client developer does not have to code the routines that implement business rules or access databases. As a result, the clients are thinner, a benefit that is particularly important for clients that run on small devices.
    What does it mean by 'client' in the above paragraph?

    I agree and I understand what's the point with
    separation of the layers, Kumar.
    But how does it help small devices?
    Is the EJB tutorial wrong? Are you agree/disagree
    with the paragraph from the tutorial re it helps
    small devices, and why?If you are developing an application for small devices certainly you cannot do much processing as the recources are limited, so place a request to your server which does it for you. Also if you have any idea of developing enterprise application for multiple clients (Swing, Jsps, Mobile etc) only your presentation needs to be implemented but not the business.

  • Basic question - what is Java Studio Creator?

    What is the difference between Java Studio Enterprise and Java Studio Creator? I've been using JSE but have never used Java Studio Creator.
    Looking at the info about it, it appears to be another IDE to create Java applications, but I'm wondering what exactly is the difference between the two. Why would someone use one over the other?

    - If you are learning java, you may want to check out:
    http://java.sun.com/new2java/index.jsp
    New to Java Programming Center
    Making Sense Out of Java Technology
    Tutorials, articles, and other learning tools for new developers.
    - As for the IDE, Java Studio Enterprise is based on an older version of NetBeans.
    You should check out the latest version of NetBeans, 6.0:
    http://www.netbeans.org/
    Documentation: http://www.netbeans.org/kb/index.html
    Community: http://www.netbeans.org/community/index.html
    Register to Join the NetBeans Community
    Once registered you have the opportunity to submit bugs and feature requests in IssueZilla, submit news for the NetBeans Community, and contribute code or even create a project of your own. Welcome to the team!
    You can also joint the mailing lists (http://www.netbeans.org/community/lists/top.html), especially [email protected] , to discuss issues and get community help on NetBeans related questions.

  • [BASIC question] what is the component I should use to fix an AC voltage and its current (in the same component)

    I need urgently to know how use a component which allows me to fix an AC voltage and its current.
    I can't use a resistance and an AC current in parallele for my application..
    Thanks a lot you will be very helpful !

    In general the way to fix both voltage and current requires a source and an impedance, but you say you do not want that solution.
    Please tell us exactly what your application is and why a current source in parallel with a resistance is unacceptable.
    Lynn

  • Basic Question: What is MASTERING exactly?

    and can one do it successfully in GB2?
    Thanks
    G5   Mac OS X (10.4.5)  

    If I understand it correctly, mastering is the process of making sure all songs on a CD flow together. All songs need to be roughly in the same dynamic level or the listener will have to turn the volume up and down. The order of the songs is also considered as well as spacing between songs and possible fade in and outs.
    Garageband is a little weak at Mastering.
    First of all GB loses quality on each export. For Mastering, 24 bit is recommended so there is little loss when reimporting the file into a new session. GB exports to 16 bit. Each export/import/export process results in lost quality.
    If you are limited to Garageband then you would create a new session with each song on a separate track. Volume levels, order of the songs and fade ins/outs can then be done easily. Slight compression can be added as well to try and even out any volume differences.
    Once you get the whole mix the way you want it export one track at a time by soloing the track and selecting only that section using the loop playback feature.
    Kurt

  • EJB client session

    What is an EJB client session? How many are there? When does it start and when does it end? Who controls that?
    Thank you.

    You may be thinking of a Stateful Session Bean. Each stateful session bean has state that is tied to a
    particular client. In EJB 3.0, the stateful session bean is created when the client does a naming
    lookup or has the stateful session bean injected. The client can remove the stateful session bean at
    any time by calling a method annotated with the @Remove annotation.
    The container can also choose to remove a stateful session bean. Typically, the container vendor
    provides configuration options that specify the stateful session bean timeout parameters.
    --ken                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Is JMF a failed concept ? basic question

    I have been researching to embed a JMF app on an applet for nearly 2 months. i have also read most questions on this forums thats related to this topic.
    Almost every one says to use java web start than using an applet. and most of the people in the forum has not got a solution to there problem, that is to add audio/video chat to an applet.
    I too have a issue in adding a audio/video chat to an applet. but still almost every one encouraged me to use java webstart.
    Further more there are no successful example in the net where you can add a audio/video chat into an applet. Most of the sample code given don't even work.
    My problem is that, Why doesn't jmf work on applets ?? have some one tried using this method, and has it worked ?? and why does people in this forum encourage others to use java web start instead of applets ? and finally does sun want to turn down the concept of using applets ???
    note: I might had asked a stupid question, if so my apologies._

    The cross-platform version of JMF works just fine in embedded applets(1), it is the Performance Pack that can be a hassle to get working. The JMF PP would need to be installed on the users computer, to get the natives in a place they can be used.
    Having said that, the "This computer needs to reboot" message at the end of the JMF installer puts a bit of a damper on that. Who wants to use an applet that requires them to reboot the PC before use?
    Also, I've heard that even after that, many users visit the JMF test applet to have it report that the JMF classes are not found. Since I have little interest in deploying the PP to end users, I have never looked into it that closely.
    localpott wrote:
    ..Almost every one says to use java web start than using an applet. Humour me. Why do your users want a browser window wrapped around the applet?
    It seems logical to me, that the end user should just be able to click the maximize icon in a free floating app., rather than have the screen acreage of the GUI limited by a conventional applet.
    My problem is that, Why doesn't jmf work on applets ??Please fix that sticky '?' key.
    Reasons mentioned above. To contrast that with a webstart launch, it is trivially easy to add natives to the run-time class-path of a webstart app.
    .. have some one tried using this method, and has it worked ??.. I've not tried it for the reasons mentioned above.
    ..and why does people in this forum encourage others to use java web start instead of applets ? (My) reasons mentioned above.
    ..and finally does sun want to turn down the concept of using applets ???Given the effort Sun is pouring into the jnlp2 architecture, which allows webstart services to be used even in embedded applets, I think not.
    It should be noted though, that Sun has abandoned JMF a long time ago (though they have never issued an announcement to that effect). :(
    As such:
    a) It is lacking in the more advanced compression codecs, which it seems would be a killer for network/internet based media transfer.
    b) Nobody is updating the (32 bit) natives, so I guess they will work on less and less PCs as time goes on.
    Those two things aside, I feel that JMF is a relatively well engineered & comprehensive media solution. The reason so many people have trouble getting up to speed in JMF is largely because 'media handling' is a lot more complex than most people realise. I probably should have asked those people who complained about JMF, if they had ever dealt with the intricacies of media handling in another API for anything beyond 'throw a media file into the system player and play it'. Playing a media file would probably be trivially easy in VB.
    And finally:
    Sub: Is JMF a failed concept ? *<basic question>*
    What is the meaning of life? Is a simple or basic question, it is the answer that is more complicated!

  • VERY Basic Questions about Oracle eBusiness - what "languages" are used?

    Please forgive the very basic nature of this post- (I have been in systems (IT) for over 20 years, so I do have lots of systems experience, but no exposure to this particular software.)
    So here are the basic questions - I assume that much of the data base logic is written in PL/SQL, but what other tools / languages are the applications written in?
    (Oracle Forms, Oracle Reports, Java, C, something else?)
    With over 20 years and experience with a number of other packages, I can learn a great deal about an application by 1. Looking at the DB structures (charts), 2. looking into DB code (Packages, triggers, procedure, functions) and 3. Seeing the screen shots.
    None of my customers have had Oracle eBusiness - that have had home grown applications or other COTS/packages.
    can anyone suggest a place where an independent person can inexpensively get some exposure?
    My sincere thanks for any answers/suggestions. 

    Hi,
    Please refer to the following links for details about the different database releases and Oracle tools.
    Oracle Timeline
    http://www.oracle.com/timeline/index.html
    http://www.oracle.com/oramag/profit/07-may/p27anniv_timeline.pdf
    Oracle Corporation - Oracle FAQ
    http://www.orafaq.com/wiki/Oracle_Corporation
    Oracle E-Business Suite consists of Application/Database/Client tiers, you can find more details in [Oracle Applications Concepts|http://www.oracle.com/technology/documentation/applications.html] manual.
    Oracle Forms
    http://en.wikipedia.org/wiki/Oracle_Forms
    Regards,
    Hussein

  • Hello, for a multilingual catalog project I would have to know how and with what tool I can place text from Excel or a database in text frames / tables. The basic idea is to provide the text box with an ID (eg text_eng_art_nr_987654 ) and above to ma

    Hello, for a multilingual catalog project I would have to know how and with what tool I can place text from Excel or a database in text frames / tables. The basic idea is to provide the text box with an ID (eg << text_eng_art_nr_987654>>) and above to make the connection. Does anyone have a tip. Thanks in advance !!!
    Bernd

    Data merge is really useful in many circumstances, but my first question would be about the size of the project. A really large catalog might be better handled by processing an IDML in some kind of translation memory tool.
    If all of your multilingual content is already in Excel, then it's probably best handled with a Data Merge. Note that you can't save Unicode CSV out of Excel for the merge, so for many languages you'll need to save "Unicode Text" out of Excel and tweak your import settings when you select a Data Source for encoding (Unicode) and delimiter (tab instead of comma).

  • I recently upgraded by iMac iOS to Yosemite, and I find that my best buy provided Trend Micro stopped working. Question, what security software is recommended, if any for an iMac. Thanks

    I recently upgraded by iMac iOS to Yosemite, and I find that my best buy provided Trend Micro stopped working. Question, what security software is recommended, if any for an iMac. Thanks

    Uninstall Trend Micro software. It is not needed and could prevent your computer from operating properly. If there is no uninstaller for the software, then see the following:
    Uninstalling Software: The Basics
    Most OS X applications are completely self-contained "packages" that can be uninstalled by simply dragging the application to the Trash.  Applications may create preference files that are stored in the /Home/Library/Preferences/ folder.  Although they do nothing once you delete the associated application, they do take up some disk space.  If you want you can look for them in the above location and delete them, too.
    Some applications may install an uninstaller program that can be used to remove the application.  In some cases the uninstaller may be part of the application's installer, and is invoked by clicking on a Customize button that will appear during the install process.
    Some applications may install components in the /Home/Library/Applications Support/ folder.  You can also check there to see if the application has created a folder.  You can also delete the folder that's in the Applications Support folder.  Again, they don't do anything but take up disk space once the application is trashed.
    Some applications may install a startupitem or a Log In item.  Startupitems are usually installed in the /Library/StartupItems/ folder and less often in the /Home/Library/StartupItems/ folder.  Log In Items are set in the Accounts preferences.  Open System Preferences, click on the Accounts icon, then click on the LogIn Items tab.  Locate the item in the list for the application you want to remove and click on the "-" button to delete it from the list.
    Some software use startup daemons or agents that are a new feature of the OS.  Look for them in /Library/LaunchAgents/ and /Library/LaunchDaemons/ or in /Home/Library/LaunchAgents/.
    If an application installs any other files the best way to track them down is to do a Finder search using the application name or the developer name as the search term.  Unfortunately Spotlight will not look in certain folders by default.  You can modify Spotlight's behavior or use a third-party search utility, EasyFind, instead.
    Some applications install a receipt in the /Library/Receipts/ folder.  Usually with the same name as the program or the developer.  The item generally has a ".pkg" extension.  Be sure you also delete this item as some programs use it to determine if it's already installed.
    There are many utilities that can uninstall applications.  Here is a selection:
        1. AppZapper
        2. AppDelete
        3. Automaton
        4. Hazel
        5. AppCleaner
        6. CleanApp
        7. iTrash
        8. Amnesia
        9. Uninstaller
      10. Spring Cleaning
    For more information visit The XLab FAQs and read the FAQ on removing software.

  • EJB Client Code Question

    Hi ,
    I am learning the basic EJB and trying to write my first piece of code.
    I wrote a HelloWorld.jar(EJB) and deployed it in Websphere server.
    Then I wrote a standalone java program with main method to access the EJB client. As per the tutorial..
    public void callEJB()
              try
                   java.util.Properties env = new java.util.Properties();
                   env.put(javax.naming.Context.INITIAL_CONTEXT_FACTORY,"com.ibm.websphere.naming.WsnInitialContextFactory");
                   env.put(javax.naming.Context.PROVIDER_URL,"iiop://localhost:2809/");               
                   javax.naming.Context initial = new javax.naming.InitialContext(env);
                   //Object objref =(javax.naming.Context)initial.lookup("java:comp/env/HelloWorld");                              
                   Object objref =initial.lookup("ejb/ejb/demo/HelloWorldHome");     
                   System.out.println(objref.getClass());
                   HelloWorldComponent helloRef = (HelloWorldRemote)PortableRemoteObject.narrow(objref, HelloWorldComponent.class);
              }catch(Exception e){e.printStackTrace();}
    How will my code compile???? Because HelloWorldComponent is on the application server, but my client is on a different server. It cannot find the HelloWorldComponent class right??
    What should I do now?
    Thanks.

    What you need is the interface (if you're using EJB3) or home interface class within your client. When you perform a lookup on Websphere it will return a proxy to your remote home interface, so in order to resolve it your client must have it in the classpath.
    You don't need to package the actual EJB within your client, just the interface(s) you are using, remembering that the interfaces need to be remote.
    Message was edited by:
    mtedone

  • EJB Facade basic question

    Hi All,
    I have a basic question on EJB Session Facade design pattern.
    What is the extra code we write in normal Session Bean, to make it as Session Facade.
    I never involve in EJB coding, but i know the coding and bit curious to know about it. I see Normal Session Bean coding and also seen Session Facade coding, i dont find any difference in implementation, then y do we call it as a Session Facade design pattern. Are all session beans are by default called Session Facade or do we need to write any extra code in a normal Session bean to make it as SF.
    Requesting to clarify.
    Thanks & Regards,
    Ravi Kumar

    There's a nice explanation on http://java.sun.com/blueprints/patterns/SessionFacade.html.
    The way I read it, my session beans are really session facades already, so why not yours too? However, that page also gives an example of a session bean that wouldn't count as session facade.

  • What todo with those who keep on answering basic questions - Your thoughts?

    Hi Experts,
    I have been active in ABAP Development Forum and usually hit the abuse button around 50 times a day.
    And most of the cases is for posting queries which are very basic and can be searched in SCN or in any Search engine.
    Example: The specified item was not found.
    Subject : BAPI
    Question :
    >
    muralireddy manyam wrote:
    > whats the  difference between normal function module and bapi function module?
    Although this is the mistake of the poster, i can see around 5 - 10 replies for such posts in a few seconds. Most of the replies are posted with Copy + paste content from SAP documentation/ other sites, some link farms etc.
    What i feel is this type of replies only encourages other people to post such basic questions again and again.
    So i think a little amendment need to be added to the Forum guidelines prompting members not to post replies/links to basic questions which can be easily searched.
    What you people think of it? Your thoughts are welcome and i hope some moderator would be in a better position to answer this.
    Regards
    Karthik D

    Hi Karthik,
    Your BAPI example took a whack together with all it's answers and the other questions by the same lazy bones fresher.
    There is no real answer to your question, because more usable expert forums and keeping the quality up to standard is a constant thing. Each new batch of freshers brings new challenges with them, and new types of points-gaming, etc. So it is the journey which counts
    At other times some tollerance is also appropriate - for example when the person has language problems and is using a translator.
    But for the lazy bones who don't even have common sense, there is no SDN medication available. No amount of waiving the rules at them helps. The only think which can be done is to delete it on sight and try to catch them as early as possible.
    For this the folks who use the Abuse Reports button are the true heros of the forums, as it is impossible for moderators to be everywhere all the time.
    Cheers and thank again!
    Julius

  • What are the best third-party Internet marketing companies that provide advertising clients to websites?

    What are the best third-party Internet marketing companies that provide advertising clients to websites? Say if I have a million views/month on my webpage, what are the companies I should look for to provide me clients to advertise on my website? I am talking about service provdiers such as AdSense. Thanks a bunch.

    Hi,
    We have seen that. Thanks.
    Now, how could we add multiple tiems to ATG's shopping cart before redirecting the user to ATG's home?
    The scenario we see is:
    User navigates on a Marketing website, spots items he/she is interested in and add them to the LOCAL shopping cart (without leaving the current website), after adding many items he/she decides to buy these items buy clicking FINISH, at this moment we add the N items to ATG shopping cart (how??) and redirect the user to ATG's home.
    Is that possible?
    Thanks

Maybe you are looking for