How to reference an External Library (Server Side) in a DC-EJB Module ?

Hi:
I start working with hibernate in a DC component, so I create my DC project and EJB module inside. I Make an external library following this
Thanks a lot for your time on this thread.
Rocío.

Hi Rocío!
  Umm, I don't usually use DC's... I don't know if this will work... you can make an EAR (New Proyect -> J2EE -> Enterpise Application Module), add your EJB Module to the EAR (right click on EJB Project and choose Add to EAR proyect), and you'll find a j2ee-engine file on it, and you can add the reference there.Then deploy the EAR.
  I normally do something similar to your issue, I make a EJB calling XI via Java Proxys, and the reference to the XI libs are allocated on the EAR, not on the EJB. This is only for runtime, for compilation you must reference the hibernate jar with an external jar file, as always.
  A dirty solution could be this one: open your generated EAR with de-compressor, and copy your hibernate jar on it (at root). This way you'll load hibernate classes at runtime (I know this is an horrible solution, this is only for testing).
  As I said before, I'm not used to DCs, so this could be wrong, and be a waste of time... I don't know further...
  Good luck
  Eneko.

Similar Messages

  • How to make html file on server side from the data entered in text area

    Hi!
    I want to know how to make .html file on server side. Like if i enter the data in text area ( or like we normaly see when we write mail that editor) and we can use html tages in it and when user submit form all the data in that field will be saved on server side as an html formate. Is it possible to do so??? or any ruff idea how to design it???

    Erm ...
    Whats the problem with that?!
    Ok, here the code ...
    String myparameter = request.getParameter("paramname");
    String htmltemplate = "<html>\n"
                         +"<head><title>demo</title></head>\n";
                         +"<body>@parametertag@</body>\n";
                         +"<html>";
    String htmlpage = htmltemplate.replaceAll("@parametertag@",myparameter);
    File yourHTMLfile = new File("wheredoyouwannagotoday.html");
    FileOutputStream fos = new FileOutputStream(yourHTMLfile);
    fos.write(htmlpage.getBytes());
    fos.close();You're done.
    Happy Coding! :-) &copy;

  • How to refer to J2EE library server component from a web service?

    Hi,
    I need help!  I created a web service and it worked fine.  However, I started having problems when I tried to use java classes from my deployable J2EE library server component.  I got the NoClassDefFound error.
    I tried to include the library DC in the Used DC list and put the reference of it in the web service deployment descriptor xml (application.xml and application-j2ee-engine.xml), but it did not work.
    How do I refer and use java classes from my deployable J2EE library at run time from my web service application?  What should I do?
    Thanks,
    Giavinh Pham

    I would like to clarify more about the web service project.  I created a Java DC project and converted it into a web service as the SAP manual instructions.  It worked fine by itself, but I now want to use some of my classes that I deployed as a J2EE library server component. 
    It was compiled and built when I refer to my J2EE library server component DC in the UsedDC.  It was deployed fine as well.  However, it broke when I tested the web service calls.  The class declarations and usage from the J2EE server component could not be found (NoClassDefFound error.) 
    I thought it was because I did not have an application-j2ee-engine.xml in my META-INF folder so I created one and referred to the library in xml as type library and reference 'strong'.  I built and deployed again.  It still did not work. 
    I examined the EAR and noticed that there were two parts of the EAR.  One is the WSAR archive file that contains the META-INF folder from my project and other web service assemblies.  The other part is the META-INF folder generated by the SAP NetWeaver IDE. 
    The strange thing was that SAP NetWeaver IDE generated an application-j2ee-engine.xml without any reference to my J2EE library server component.  However, the nested application-j2ee-engine.xml in the WSAR archive file did contain the info. 
    Since I cannot control the application-j2ee-engine.xml generated by SAP NetWeaver IDE, what should I do?  Is it the cause for my problem?
    Please advice, anyone?
    Giavinh

  • How to use mathscript node in server side with the parameter from the client side

    I tried to develop a server/client system with some algorithms written in matlab. So I included a mathscript node on the server side. The client will send the parameter to the server. According to these parameters, the sever will call the matlab functions to do some computings and then send the results back to the client. The server has to wait for all parameters received before the computings. How do I know this since I only connect the parameter variables to the inputs of mathscript node on the server. The sever cannot know whethere these parameters are the new ones or old ones since the client may send parameters multiple times?

    It seems to me you have two perfectly good options to start with. You could send all possible parameters in a single packet from the client to the server. This could be in the form of a cluster or an array of values. If by server/client you mean you are sending data over the network, then you could flatten this data to string before sending and unflatten it on the other side. Since all parameters come in one packet, you know all the data is valid every time you send data.
    The other option is to send the parameters individually, but include some extra information such as a timestamp or iteration count. The server keeps reading and storing parameter values until a packet arrives with the next timestamp. Alternatively, you could include some information such as an end-of-parameter-list boolean that is sent with every parameter. It would be false until the last parameter packet.
    Give it a thought. There are lots of solutions.
    Jarrod S.
    National Instruments

  • How to send Subtopic Message From Server-Side to Client ?

    I’m new at flex and i have a new question about Flex
    Message Service.
    How to send messages from Server-Side Java Code with
    Subtopic?
    For example.
    I customed a Flex Message Adapter in Tomcat Server , with
    this Adapter , i can send message to Client with following code .
    ---------------------Send message to Client------------
    MessageBroker msgBroker =
    MessageBroker.getMessageBroker(null);
    String clientID = UUIDUtils.createUUID(false);
    AsyncMessage msg = new AsyncMessage();
    msg.setDestination("CustomMsgServiceDes");
    msg.setClientId(clientID);
    msg.setMessageId(UUIDUtils.createUUID(false));
    msg.setTimestamp(System.currentTimeMillis());
    msg.setBody(clientID + "this is my message from server! \n");
    msgBroker.routeMessageToService(msg, null);
    ---------------------Send message to Client------------
    But i want send a message that have Subtopic to the Client ,
    How to do ?
    Thank you for reply.

    There's a white paper that talks about this subject -
    http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=8f1eb6ea

  • How can I deliver to custom server-side LoginModule additional options?

    I need to deliver additional options to sever-side custom LoginModule when I use Weblogic Security Framework (Weblogic 9.2). How can I do it?

    So I'm guessing you want to take into account other factors in the auth decision? The sample authentication provider does show some additional context api's I believe, I haven't looked at it in awhile.
    I recommend that you concisely write your requirements with a detailed example and post the question in the WLS - Security forum which will have a more specialized focus on the security sub-system.
    WebLogic Server - Security

  • Need to know how to calculate and allocate the server side bandwidth between two exchange sites for DAG replication

    Hi All,
    Please have a look in to the below mentioned environment.
    primary site :SITE 1
    server 1 
    server 2 
    secondary site :SITE 2
    server 3
    Note : All the above three servers are in single DAG .All the database are mounted on the server (server 1) which is located in the primary site (I.E SITE 1).
    On that 5 databases we are having 3500 users .Based on the user designation we have allocated the mailbox size.
    Query : Each and every day we are having the large no copy queue length for all the five databases to the server located in SITE 2.
    Please help me out on this and also tell me is there any tool available to exactly get the required bandwidth for the exchange servers located between the active directory sites.
    Thanks & Regards S.Nithyanandham

    I don't know of any tool that can calculate things for you but latency is the biggest thing you have to worry about. The other issues is looking at the network gear between the 2 sites. I have seen many times were switches get maxed out if they are set to
    1 GB or even ports getting maxed out and need to bonded for more throughput. Test your latency from the edge of each site then test it within to see if there is a difference. 
    Regardless of their geographic location relative to other DAG members, each member of the DAG must have round trip network latency no greater than 500 milliseconds between each other member.
    As the round trip latency between two Mailbox servers hosting copies of a database increases, the potential for replication not being up to date also increases. Regardless of the latency of the solution, customers should validate that the networks between
    all DAG members is capable of satisfying the data protection and availability goals of the deployment. Configurations with higher latency values may require special tuning of DAG, replication, and network parameters, such as increasing the number of databases
    or decreasing the number of mailboxes per database, to achieve the desired goals.
    Round trip latency requirements may not be the most stringent network bandwidth and latency requirement for a multi-datacenter configuration. You must evaluate the total network load, which
    includes client access, Active Directory, transport, continuous replication, and other application traffic, to determine the necessary network requirements for your environment.
    http://technet.microsoft.com/en-us/library/dd638104(v=exchg.150).aspx
    DJ Grijalva | MCITP: EMA 2007/2010 SPA 2010 | www.persistentcerebro.com

  • How JMS client operate on JMS server side objects?

    For example, JMS client got an instance of ConnecitonFactory by JNDI call from a remote side JMS server. Thereafter, the client uses this object to set upconnections. My question is that what kind of remote tech this is? Is it RMI or CORBA or something?

    I suspect it boils down to who your JMS Provider is.

  • How to use a jar from a external library DC Project?

    I followed the steps of how to create DC, External Library Project, which contains the jar I want.
    I understood that this type of project can't be deployed so I build and deployed other DC Project from the type J2EE server component Library and added it to it's public part. What do I do next, to actually use the jar and it's imports?
    Thank you,
    Meytal.

    Hi,
    Check this:
    Making a JAR file publicly available
    http://help.sap.com/saphelp_nw70/helpdata/en/9f/2ade3fc6c6ec06e10000000a1550b0/frameset.htm
    Greetings,
    Praveen Gudapati
    [Points are welcome for helpful answers]

  • How to delete server side cookie

    Hy ppl.
    i would like to know how i can get rid of server side cookies which date is in the past?
    I've trie it with
    call method cl_bsp_server_side_cookie=>DELETE_SERVER_COOKIE
    but the there was no result

    hi
    good
    Class CL_BSP_SERVER_SIDE_COOKIE provides methods for setting, getting, deleting, and managing cookies on the server.
    Server-side cookies are persistent data, similar to the usual client-side cookies. However, while on the client-side, there are restrictions that limit the size of cookies to around 4 kilobytes per cookie, the number of cookies to 300 in total and 20 per server or domain, server-side cookies are subject to no such restrictions. A server-side cookie is stored on the database.
    For technical reasons, each individual cookie can be stored in one of the following ways:
    as a field or
    as a structure or
    as an internal table
    http://help.sap.com/saphelp_nw2004s/helpdata/en/2a/31b97b35a111d5992100508b6b8b11/content.htm
    thanks
    mrutyun^

  • How to send XML packet from external socket server to OSB

    Hi folks,
    How do I use external Socket Server(tcp) to send payload to OSB ?
    I have configured the socket protocol in my OSB. I am also able to send and receive responses by testing my proxy services from OSB itself.
    But now, we want to use some external socket (tcp)server to be able to fire some xml file and then receive response on OSB.
    Please help
    salil

    You need to use a socket client application to send a message to a socket where your proxy is listening. For receiving a message at a socket, configure business service at OSB.
    Regards,
    Anuj

  • How to get the publish method with server side actionscript?

    We publish this way at client side:
    ns.publish(name, howToPublish);
    How to get this howToPublish at server side?
    application.onPublish = function(){
        //how to know whether the stream's publishing method(live,record,append) here?

    I am not sure whether you can know mode of publish via SSAS, best way would be to use Authorisation Plug-in which can intercept you publish request and get the information which you need - in this case mode of publishing.

  • How to involve the external XA resource in the WL global transaction

    I wanted to know, if anybody has any knowledge of using external XAResource with
    Weblogic transaction, at the client end. For example:
    I create a Oracle Datasource and create a XAResource using unique xid. And would
    like register with Weblogic Transaction service, to use in the global transaction
    from client end.
    Is it possible? if yes how. What are APIs.

    The server-side connection obtained from the DataSource will enlist in
    and be part of the global transaction. Client operations on the
    connection will be performed on the server from which it was obtained.
    WLS will register the Oracle XAConnection and enlist it in the global
    transaction transparently.
    Alex
    Malli wrote:
    Alex,
    Thanks on your response.
    The JNDI lookup for DataSource and get a connection from that datasource works
    ok. But I want to make the external XAResource to participate in the WLS transaction.
    Malli
    Alex <[email protected]> wrote:
    Registering a resource on a client VM is not supported by WLS. It is
    possible for a client to look up a remote DataSource from a server and
    have connection operations participate in global transactions. However,
    there are some limitations with this approach, such as result sets not
    being available on the client.
    Alex
    Malli wrote:
    I wanted to know, if anybody has any knowledge of using external XAResource
    with
    Weblogic transaction, at the client end. For example:
    I create a Oracle Datasource and create a XAResource using unique xid.
    And would
    like register with Weblogic Transaction service, to use in the global
    transaction
    from client end.
    Is it possible? if yes how. What are APIs.

  • Problem with External Library

    Hi Everybody
    I'm using NW04s (7.0) sp 11 and I'm having problem using an <a href="http://sourceforge.net/projects/jexcelapi/">external jar</a>
    for reading and writing to excel files. (I already used this jar with a regluar WD project and now I want to use it in a Web Dynpro DC project).
    I tried using <a href="/people/valery.silaev/blog/2005/09/14/a-bit-of-impractical-scripting-for-web-dynpro blog</a> and <a href="/people/bala.krishnan2/blog/2006/09/25/bid-adieu-to-bots--using-captchas Blog</a>.
    I tryed following both step by step, but when I tryed to use my project I get Class Not Found Error. The library is being created but it doesn't contain any jars.
    I'll will give ten points for anyone who will guide me step by step how to deploy an external library in NW04s
    Maybe something changed in this version??? Or this Jar isn't suitable for SAP J2ee server
    Regards
                Omer

    I tried this blog and had 2 problems.
    1.)
    I didn't understand this part from the blog
    "Caveat confector:
    One should always remember this significant and valid point: 'Use ONLY DC Builds to create the deployable archive if you work with assembly public parts."
    What should  I 'DC Build' the  'Web Dynpro DC' or the 'external library DC'?
    It isn't clear.
    2.)
    When I tried now to do it, I followed the blog and I get this warning when trying to build External Library DC.
    "17/06/2007 10:02:09 /userOut/Development Component (com.sap.ide.eclipse.component.provider.listener.DevConfListener) [Thread[ModalContext,5,main]] WARNING: jexecel_lib: Compute DC build order: skipping DC that could not be loaded: MyComponents:sap.com/jexecel_lib. Exception: Failed to read component definition from local file MyComponents:sap.com/jexecel_lib : Cannot read component definition. File does not exist: D:\Documents and Settings\omers\.dtc\LocalDevelopment\DCs\sap.com\jexecel_lib\_comp\.dcdef (Cannot read component definition. File does not exist: D:\Documents and Settings\omers\.dtc\LocalDevelopment\DCs\sap.com\jexecel_lib\_comp\.dcdef)"
    what is the reason, for this warning?

  • Reading .txt file Server side

    How do you read a file server side and send it to the client. I am getting confused with FileReader and the fact that you have to wrap a socket with PrintWriter, BufferedWriter and OutputStreamWriter i.e.
    BufferedReader in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
    Any ideas

    Assuming you want to read from a file on the server and write to a client socket:
    FileReader fi= new FileReader("reading.txt");
    BufferedReader br= new BufferedReader(fi);
    String il=br.readLine();
    ServerSocket sock= new ServerSocket(port,mcons);
    PrintStream dout=
    new PrintStream (sock.getOutputStream());
    dout.println(il);
    dout.flush();...
    Hope this helps.

Maybe you are looking for

  • Application not accessible over VPN

    I have written a windows service application that opens a TCPIP port (and posts a listen) on a server. A matching client application can connect and works perfectly when the client computer is on the local network. When I am connected to the server u

  • Need help!  Adobe Acrobat 9 Standard will not print to printer, only want to print to prn file.

    I have done a repair on the file,  I have installed the lastest updates, and nothing works.  My next step would be to uninstall and reinstall the program.  Does anyone have a fix for this?  I have always been able to print PDF files and this just sta

  • VB with Oracle Database as Backend

    Hi, I was trying to do some work in VB with Oracle Database as backend. i got the connection. but the arabic data in the database is not showing properly in VB form. the current values in the table is showing junk characters. if i'm updating a field

  • Selected iPhoto 6 technical notes (NO Library merging abilities)

    A query on iPhoto 6 SOMETIMES displays up to 250 tech notes for the release on Apple's support site. Sometimes it shows nothing. I suspect their servers are still updating. These caught me eye. Specific links are on my blog, a paste of the comments a

  • Change default security settings for new Discoverer users? How?

    Hello, using Discoverer 10g with SSO integration. I've created two roles and create in advance users in the DB user, granting them one of the two roles. The two roles privileges for Discoverer are already configured. This way, when I create the user