SCA from an EAR file

Hello!
I have a simple question about the sapmake utility. I have used to create an SCA from various archives and am familiar with its workings.
What I want to know is that is it possible to create an SCA from an EAR file. I have created an SCA from an EPA and an EAR file but I want to create an SCA from an EAR.
Theoritically this should be possible because an EAR is considered to be an SDA. Since an SCA is used to pack multiple or a single SDA(s), it should be possible to create a valid SCA out of an EAR.
But when I tried it, the SCA build process went perfectly and I did get an SCA. The JSPM however, does not recognize this SCA at all! It says the inbox is completely empty. However, when I pack in the EAR with an EPA coverted to SDA and create an SCA, this SCA is immediately recognised.
So why cant I create a valid SCA from only an EAR file?
Thanks for looking into it!
Sameer

Hello Praveen!
The EAR file is considered to be an SDA by NetWeaver. This is the reason that you can add an EAR file when deploying from the SDM tool even though the button in the deployment says "Add SDA/SCA for deployment".
Bye!
Sameer.
P.S - Here is the link to one weblog which explains it - <u>Software Deployment/Component Archive Basics>.
Added the link.
Message was edited by:
        Sameer Jagirdar

Similar Messages

  • Reading Java files from a EAR file

    I want to read all Java files from a EAR file and from inner (inside EAR) EAR or WAR file with out unpacking.
    suppose "Demo.ear" contaions the following files:
    abc.java
    programs / a.java
    programs / b.java
    src / index.java
    src / com / myFolder / main.java
    src.war
    and suppose "src.war" again contains some java files inside differenet folders.
    The main problem is that i can read all java files from "Demo.ear" but unable to reading from "src.war" b'coz my program is using JarFile class constructor which needs a archive file path, So only top level archive having the path but not the inner archives.
    So, pls help me out to this problems
    Thanks in advance

    Maybe you can use java.util.zip.ZipInputStream to
    open the Ear and recursively to open the files in
    it; I'm not sure whether this will result in a full
    unpacking of the file in some temporary directory,
    though.
    Please let me know if it worked the way you wanted,
    I'm curious about it.This jerk just created the third thread about the same topic, because he didn't understand your suggestion, which I already provided earlier.
    http://forum.java.sun.com/thread.jspa?threadID=790015

  • Java files from a EAR file and from inner (inside EAR)

    I want to read all Java files from a EAR file and from inner (inside EAR) EAR or WAR file with out unpacking.
    suppose "Demo.ear" contaions the following files:
    abc.java
    programs / a.java
    programs / b.java
    src / index.java
    src / com / myFolder / main.java
    src.war
    and suppose "src.war" again contains some java files inside differenet folders.
    The main problem is that i can read all java files from "Demo.ear" but unable to reading from "src.war" b'coz my program is using JarFile class constructor which needs a archive file path, So only top level archive having the path but not the inner archives.
    So, pls help me out to this problems
    Thanks in advance

    Firstly Sorry to writing long letter. but i was unable to express my problem.
    see my code==============================
    JarFile jarFile = new JarFile("Demo.ear");
    Enumeration e=jarFile.entries();
    while (e.hasMoreElements())
    JarEntry entry=(JarEntry)e.nextElement();
    if (entry.getName().endsWith(".war"))
    // Then what Next to do...........
    ===========================================
    you have mentioned "theFile" , What is this?...............
    InputStream in = theFile.getInputStream(theEntryOfTheWAR);
    This line is not a compatible type casting in Java..........
    ZipOutputStream theWar = new ZipInputStream(in);

  • Java files from a EAR file

    I want to read all Java files from a EAR file and from inner (inside EAR) EAR or WAR file with out unpacking.
    suppose "Demo.ear" contaions the following files:
    abc.java
    programs / a.java
    programs / b.java
    src / index.java
    src / com / myFolder / main.java
    src.war
    and suppose "src.war" again contains some java files inside differenet folders.
    The main problem is that i can read all java files from "Demo.ear" but unable to reading from "src.war" b'coz my program is using JarFile class constructor which needs a archive file path, So only top level archive having the path but not the inner archives.
    So, pls help me out to this problems
    Thanks in advance

    please help me
    I am waiting for ur response
    thanking you

  • Retrieve the jdev project from the ear file

    I have an ear file, but I've lost the original jdev project.
    How can I retrieve the project from the ear file?
    I would know if there's a function in jdev or with another tool to convert an ear file to the original project in jdeveloper.
    Thanks.

    Try the File->Import menu option.

  • Can not lookup EJB from another EAR file, the ClassCastException returned

    Hi,
         I try to call EJB module in A.ear from Servlet in another EAR file(B.ear) the ClassCastException returned on the context.lookup() code . So when i create a Dynamic Web Project(With the same code as Servlet in B.ear) and pack it in A.ear(The same EAR file with EJB module), it work fine. I have no idea. Could you please suggest me.
    The ClassCastException : incompatible with interface ..... return on
    HelloManBeanLocalHome home=(HelloManBeanLocalHome) ctx.lookup("localejbs/sap.com/HelloMan_EAR/HelloManBean");
    The entire code is below :
              try {               
                   InitialContext ctx=new InitialContext();
                   HelloManBeanLocalHome home=(HelloManBeanLocalHome) ctx.lookup("localejbs/sap.com/HelloMan_EAR/HelloManBean");
                   HelloManBeanLocal remote=home.create();
                   lookupText=remote.helloMan("Test");
              } catch (Exception e) {
                   // TODO: handle exception
                   e.printStackTrace(out);
    Many Thanks

    Hi Saleem Mohammad.
               Thank a lot for your post. I got this idea from your link. The below code work fine.
              try {               
                   InitialContext ctx=new InitialContext();
                   Object obj= ctx.lookup("localejbs/sap.com/HelloMan_EAR/HelloManBean");
                    ClassLoader homeCl = obj.getClass().getClassLoader();
                    Class<?> localHome = homeCl.loadClass(HelloManBeanLocalHome.class.getCanonicalName());
                    java.lang.reflect.Method method = localHome.getMethod("create");               
                    Object homeObj = (Object)method.invoke(obj);
                    ClassLoader localCl=homeObj.getClass().getClassLoader();
                    Class<?> local = localCl.loadClass(HelloManBeanLocal.class.getCanonicalName());
                    Class  args[] = {String.class};
                    java.lang.reflect.Method localMethod=local.getMethod("helloMan",args);               
                    Object params[]={"Thongie"};
                    Object localObj = (Object)localMethod.invoke(homeObj,params);
                    lookupText=(String)localObj;               
              } catch (Exception e) {
                   // TODO: handle exception
                   e.printStackTrace(out);

  • How to build project in NWDS from ear file?

    I do know that it maynot be possible to build a project from a .ear file but I am sure there must be a way out. I am sure someone else would have faced the same problem that I am facing.
    This is what happened. We had a consultant working on our ESS/MSS appplications in the studio. He made changes to a few ESS/MSS applications. However, while deploying, he did not use NWDI even though we do have NWDI available. He simply imported the .ear files in all the development, quality and production portals. Because of this, the changed source code is not available on NWDI and when I import the configuration from NWDI, I only get the old source code.
    I do have al the .ear files he deployed. So, my question is, is there anyway for me to build the project from the .ear file? I do know how to decompile the CLASS files on the ear file and look at the code but I was hoping for a way to build the entire project with the changed source code in NWDS. Or Is there anyway to synchronize the NWDI source code with the deployed source code. Please respond ONLY if you have actually managed to resolve this problem.

    Hi Santosh,
    This is hardly possible even if you have Java decompiler -- WD has a lot compile(design)-time only artifcats that are not exist in generated EAR.
    Regards,
    Vipin.

  • How to extract XML from EAR file?

    how to Extract weblogic-application.xml file from StellentPortlets.ear file ???

    http://en.wikipedia.org/wiki/EAR_(file_format)
    An EAR file is a standard JAR file (and therefore a Zip file) with a .ear extension, with one or more entries representing the modules of the application, and a metadata directory called META-INF which contains one or more deployment descriptors.
    7zip is a nice tool for me but most any should be usable.

  • Extracting from EAR file

    Hello Experts,
    Right now we are on EP6 upgraded to EP7
    I have a modified sap.comessus.ear file from EP6.
    But, we lost  the source code on the track and track itself during upgrade to NWDI.
    Is there anyway to get the source code from this EAR file. Or any way we can deploy this ear file on different J2ee engine. So, we can run it on our new portal.
    your help is greatly appreciated.
    Thanks,
    James

    Hi James,
    the developer chose to keep or not the source class into .ear file.
    So you can unzip the .ear  file (using WinRar), in this way you will be able to see the folder structure and various files, you will see a lot of .class file that are binary class and if you are lucky you can find a lot of .java files. Open the .java files with a txt editor like notepad, this is the source code.
    Hope this help you.
    Regars,
    Vito

  • Reading Ear file and inner ear or war file

    Actually My problem is to read and store the all java files and its path from a Ear file or War file. If a archive contains inner archive as well then the process will be the same for inner jar.
    pls give me a sample code so that i can develop my solution
    Thanks

    reply me soon

  • Deploy given EAR file having application.xml and change context-root

    hi
    Please consider deploying a given EAR file on WebLogic Server 10.3.5 (part of JDeveloper 11.1.1.6.0) and changing the context-root for its web-module.
    For example an EAR file with only a web-module (ReviewContextRootFirstApp.ear [1]) or an EAR file with a web-module and an ejb-module (ReviewContextRootSecondApp.ear [2]).
    Given documentation appendix B section "context-root" [3] saying
    "... A context-root setting in application.xml takes precedence over context-root setting in weblogic.xml. ..."
    and documentation section "Typical Deployment Configuration Workflows" [4] saying
    "Oracle does not support using a deployment plan to change the context-root in an application.xml file. However, if an application is deployed as a library, you can either change the context-root through an weblogic-application.xml file or use the deployment plan to change the context-root in an weblogic-application.xml file. "
    Some observed behaviour:
    - scenario (sc1) : deploy ReviewContextRootFirstApp.ear without deployment plan, results in context-root "/rcrfaweb" (as in application.xml)
    - scenario (sc2) : deploy ReviewContextRootFirstApp.ear with deployment plan fa-plan.xml (tries to configure "/rcrfaweb11"), results in context-root "/rcrfaweb" (as in application.xml)
    - scenario (sc3) : deploy ReviewContextRootSecondApp.ear without deployment plan, results in context-root "/rcrsaweb" (as in application.xml)
    - scenario (sc4) : deploy ReviewContextRootSecondApp.ear with deployment plan sa-plan.xml (tries to configure "/rcrsaweb21"), results in context-root "/rcrsaweb" (as in application.xml)
    The blog post "Defining the context root of a web application in Oracle WebLogic server" [5] by Silviu Leahu in its section "Defining the context root in deployment plan" suggests to
    "Remove the META-INF/application.xml DD from the EAR"
    - scenario (sc5) : remove application.xml from ReviewContextRootFirstApp.ear (e.g. using Ant target "remove.application.xml.from.ear") and deploy with deployment plan fa-plan.xml, results in context-root "/rcrfaweb11" (as in fa-plan.xml)
    - scenario (sc6) : remove application.xml from ReviewContextRootSecondApp.ear (e.g. using Ant target "remove.application.xml.from.ear") and deploy with deployment plan sa-plan.xml, results in context-root "/rcrsaweb21" (as in sa-plan.xml)
    One could expect that using a deployment plan (like in scenario's (sc2) and (sc4)) would allow to configure/change the context-root, whithout having to make changes to the EAR file to make this possible. (Somewhat like "Figure 4-2 Single Deployment Plan Workflow")
    Only in scenario's (sc5) and (sc6) I see something close to what I would like to achieve, but there the application.xml file has been removed from the EAR file.
    So ...
    - (q1) Is it impossible to change the context-root at deploy-time for a web-module in a given EAR file that includes an application.xml file, without changing the EAR file?
    - (q2) Is working with EAR files that don't have an application.xml file a supported approach (to change the context-root at deploy-time)?
    Seems like a simple goal, but I must be missing something that is required to achieve it.
    - [1] ReviewContextRootFirstApp/deploy/ReviewContextRootFirstApp.ear in the ZIP file
    at http://www.consideringred.com/files/oracle/2012/ReviewContextRootApps-v0.01.zip
    - [2] ReviewContextRootSecondApp/deploy/ReviewContextRootSecondApp.ear in the (same) ZIP file
    at http://www.consideringred.com/files/oracle/2012/ReviewContextRootApps-v0.01.zip
    - [3] http://docs.oracle.com/cd/E21764_01/web.1111/e13712/weblogic_xml.htm#WBAPP623
    - [4] http://docs.oracle.com/cd/E21764_01/web.1111/e13702/config.htm#DEPGD172
    - [5] http://blog.leahu.net/it/2011/01/04/defining-the-context-root-of-a-web-application-in-oracle-weblogic-server/
    many thanks
    Jan Vervecken

    Thanks for your reply René van Wijk.
    René van Wijk wrote:
    You can use deployment plans in order to change the context-root ...That is what I tried and describe in scenario's (sc2), (sc4), (sc5) and (sc6) in this forum thread.
    Because the application.xml file (in the "given EAR file"), added by JDeveloper 11.1.1.6.0 when deploying to an EAR file, doesn't have id attributes on its application/module elements, I first tried a different XPath expression:
    "/application/module/web[web-uri/text()="WebProject.war"]/context-root"
    But, that didn't work.
    Although the "given EAR file" does not have the suggested id attributes, I tried adding a deployment descriptor application.xml file that does have such id attributes [2], allowing an XPath expression like the one suggested:
    "/application/module[id="WebProject"]/web/context-root"
    - scenario (sc7) : deploy ReviewContextRootFirstApp.ear (in ReviewContextRootApps-v0.02.zip) with deployment plan fa-plan-application-xml-with-id.xml (tries to configure "/rcrfaweb14"), results in context-root "/rcrfaweb" (as in application.xml)
    - scenario (sc8) : deploy ReviewContextRootSecondApp.ear (in ReviewContextRootApps-v0.02.zip) with deployment plan sa-plan-application-xml-with-id.xml (tries to configure "/rcrsaweb24"), results in context-root "/rcrsaweb" (as in application.xml)
    So, it does not seem to work.
    ... you have to use a variable assignment in the right part of the deployment plan (in this case the application.xml) ...My observations I describe above (that it does not seem to work) seem to confirm the Oracle documentation [1] I referred to in this forum thread before:
    "Oracle does not support using a deployment plan to change the context-root in an application.xml file. ... "
    ... By using an xpath expression, you can define which part of the xml has to be changed. ...The values for the deployment-plan xpath elements seem to be "peculiar".
    Although it should not be a problem in an XPath expression, using single quotes (like module[id='WebProject'] ) instead of double quotes (like module[id="WebProject"] ) results in:
    "java.lang.AssertionError: Attributes must be defined as name value pairs, eg, name="value" -- [id='WebProject']"
    Because an XPath predicate expression would use an "@" to refer to an attribute, I also tried to replace what you suggested module[id="Web"] with something like module[@id="Web"] but that also did not make a difference.
    - [1] http://docs.oracle.com/cd/E21764_01/web.1111/e13702/config.htm#DEPGD172
    - [2] http://www.consideringred.com/files/oracle/2012/ReviewContextRootApps-v0.02.zip
    regards
    Jan Vervecken

  • J2EE cluster error while deploying "EAR" file from SDM tool

    Hi all,
    I am new to CRM ISA development side. I am learning how to build b2c ear file base on b2c.ear and then how to deploy through SDM. Everything is working fine till build tool. Successfully build my own b2c_ashish.ear file. then I started SDM GUI and try to deploy it. In SAP MMC all process are running. J2EE engine is also running fine. I have describe below which step I took.
    PL. go through it an let me know about my mistake.
    I am just pasting that portion of error which I am getting when I am accessing "/b2c_kce/b2c/init.do"
    ===================
    A runtime error occurred
    Contact the administrator
    Start application
    ==================
    do you have any idea in which log file it writes error so I can open that file and . I tried to access log file from "Admin" page.
    If I am trying to access "/b2c_kce/admin/index.jsp" I am able to access those pages without problem only "/b2c_kce/b2c/init.do" I am getting problem like above "run time error Occured"
    When I click on "Start Application" it is opening new window and showing same text.
    I checked SAP MMC. it is showing all node Green "dgntisa", "dgntisa1" and "dgntisa0" Also All process like under "dgntisa0" process "jcontrol.exe" and "igswd.exe "  are green.
    I build "b2c_ashish" new by using build tool. It was also successful.
    I start SDM server by "StartServer.bat" and after that I start SDM remote GUI.
    I select "Deployment" tab and add "crm.b2c_ashish" for deployment then I click on Start button and I got below error for "J2EE Cluster" that "SDM could not start J2EE cluster on the host dgntisa"
    Pl. if you have any idea then pl. let me know how to solve this error.
    Deployment started Sun May 14 14:24:50 PDT 2006
    ===========================================================================
    Starting Deployment of crm.b2c_ashish
    Aborted: development component 'crm.b2c_ashish'/'sap.com'/'SAP AG'/'400.200605141307':
    SDM could not start the J2EE cluster on the host dgntisa! The online deployment is terminated. JStartup Framework is not able to deliver an information about the cluster control instances! Please check the status of the J2EE Engine
    (message ID: com.sap.sdm.serverext.servertype.inqmy.extern.EngineApplOnlineDeployerImpl.performAction(DeploymentActionTypes).STARTUP_CLUSTER)
    Deployment of crm.b2c_ashish finished with Error (Duration 3250 ms)
    ===========================================================================
    Above error start ater restarting "WAS" server. Now You can not deploy or undeploy any SDA or SCA component.
    I follow above mentioned steps 2 time after restarting "WAS" server. but it seems that one service for J2EE cluster is not started.  I also chekced the running mode of SDM and SAP J2EE version. SDM Runing mode is "integrated" and SAP J2EE version is " 6.30" While using a build file it is showing J2EE engin version.
    =======================================================

    Would you post the same thread under SAP Netweaver or WAS?

  • Extracting EAR files from Server

    Hi All,
    Can any one help me in extracting  the ear files deployed on to the server...??
    Thanks.
    Venkat.

    Michael,
    Let me fulfill your Interest... We don't have NWDI environment and we just need to Deploy the applications accessing from a Repository. In building up SCA file instead of  taking from the applications I want to access the Updated EAR files form the server so that version will not conflict and I could get the updated versions .
    Too many applications of the same name in the repository is driving to confusion in extracting the EAR files of the Latest version.
    Hope you got the business requirement.
    Thanks.
    Venkat.

  • Error while deploying ear file generated from weblogic to ocj4

    Hi All,
    I have an .ear file which has been generated from weblogic server.I tried to deploy it on ocj4 aby created a new project in eclipse and deploying it on ocj4.
    When I try to run my project it gives me an error:
    2008-12-15 19:13:54.811 NOTIFICATION J2EE JSP-0008 Unable to dispatch JSP Page : Exception:oracle.classloader.util.AnnotatedLinkageError: duplicate class definition: javax/xml/rpc/Service
         Invalid class: javax.xml.rpc.Service
         Loader: Test.web.TSOptyQGateWeb:0.0.0
         Code-Source: /C:/OC4J_10.1.3.4/j2ee/home/applications/Test/TSOptyQGateWeb/WEB-INF/lib/jaxrpc.jar
         Configuration: WEB-INF/lib/ directory in C:\OC4J_10.1.3.4\j2ee\home\applications\Test\TSOptyQGateWeb\WEB-INF\lib
         Dependent class: oracle.jsp.runtimev2.JspPageInstFacade$DeclaredAction
         Loader: oc4j:10.1.3
         Code-Source: /C:/OC4J_10.1.3.4/j2ee/home/lib/ojsp.jar
         Configuration: <code-source> in META-INF/boot.xml in C:\OC4J_10.1.3.4\j2ee\home\oc4j.jar
         The original class instance was defined in the shared-library oracle.ws.jaxrpc:1.1, and oc4j:10.1.3 does import that loader. This may be a search-order problem.
    Can anyone help??

    Hi,
    I checked the log-files, but there are no helpful informations, but:
    07/04/23 12:08:04 -  Start updating EAR file...
    07/04/23 12:08:04 -  start-up mode is lazy
    07/04/23 12:08:20 -  com.sap.engine.deploy.manager.DeployManagerException: com.sap.engine.services.deploy.container.DeploymentException: Cannot update archive file Docsndownloads.war
                         com.sap.engine.services.deploy.ear.exceptions.BaseIOException: Error during replacement of substitution values. Reason:
                          java.io.IOException: Stream closed
    and
    Apr 23, 2007 12:08:20... Error: Aborted: development component 'Dokusunddownloads'/'sap.com'/'localhost'/'2007.04.23.12.07.47'/'0':
    Caught exception during application deployment from SAP J2EE Engine's deploy API:
    com.sap.engine.deploy.manager.DeployManagerException: com.sap.engine.services.deploy.container.DeploymentException: Cannot update archive file Docsndownloads.war
    com.sap.engine.services.deploy.ear.exceptions.BaseIOException: Error during replacement of substitution values. Reason:
    java.io.IOException: Stream closed
    thanks,
    Lu

  • How to create a PAR file from EAR file

    Hi,
       I have created an Web Dynpro Application . When i deploy it in Remote J2EE Engine, it will deploy as EAR file. It then runs as normal Web Application in Web browser. My requirement is to create an iView for my Web dynpro appn in EP. That is possible only by creating a PAR file. so How to create an PAR file from EAR in NWDS(NetWeaver Developer Studio).
    How to access the EAR file in NWDS or J2EE ?
    Thanks in Advance ,
    By
    Saravanan

    Hi,
    To create a iview,
    log on to portal, New iView and select SAP webdynpro iview.
    It will ask for namespace which is usually , local/Project Name
    and application name is the name of the application.
    We dont have to create par file for this requirement

Maybe you are looking for

  • Firefox is not working after upgade to vesion 4

    I have Windows XP installed on my PC toshiba satelit 200 serie, I use french version firefox, After instalation of the new fiefox 4 it's not working (but Googole Chrome and IE are O.K.)

  • Download error with pages

    I am trying to download Pages and it gets to approx 10 MBs downloaded and then shows sero downloaded. Starts over several times - I finally get the messagePages failed to download Pages failed to download: Use the Purchases page to try again. I've tr

  • How can I get back $400 deposit? check or bank?

    I'm an international student and my brother and me using family share plan. We know we can get refund our deposit after using 12 months but we wanna know is it check or bank. We are going to visit our country during the summer vacation, about 4 month

  • Does anyone know if Adobe Photoshop CS5.1 is compatible with Snow Leopard?

    Does anyone know if Adobe Photoshop CS5.1 is compatible with Snow Leopard?

  • ODi Generates random name at HFM load log.

    Hi Gurus, I am using ODI 11.1.1.3 to load data into HFM. I Want the data load log to be attached in an email. The problem is that a random log name is generated. I've opened the IKM and a function generates the random log name (<?=java.lang.System.ge