Geting Version Information within a Java Custom Component

Is there a way to retrieve the data from the 'version=' keyword that is in a component.hda file. I want to do it within my java component so that it can be writting to a trace log.
Thanks

Give this a try:
intradoc.shared.SharedObjects.getEnvironmentValue("IDC_Name")

Similar Messages

  • Java custom component for image generation

    I want to create a custom service for image generation. I want to send the image in response stream.
    I want to service like below :
    <img src="http://localhost/ucm/idcplg?IdcService=getImageService"/>
    Thanks in advance!!

    Hi ,
    Thank you os much for reply . really appreciate.
    I want to create a Captcha component that will generate Captcha image in reponse. I do not want to generate image in file system. Just want to use Image Stream.
    I want achieve something like below in java servlet code :
    ServletOutputStream out = httpServletResponse.getOutputStream();
    ImageIO.write(bi, "jpg", out);
    Thanks

  • HtmlCommandLink generation within custom component

    Hey everybody, I had a previous post similar to this, but after solving the one problem I was having another one arose that I'm not sure how to fix either. I've been scouring google and the forums for a definite answer on this to no avail. So, here's my problem again:
    I've created a menuBar component that consists of images, tomahawk swap images, and command links. I use the component this way in my pages:
    <or:menuBar pageClass="#{menuBarBean.PAGECLASS_HOME}" msg="foo!" />In my renderer for this component, I have set up HtmlCommandLinks which are supposed to invoke navigation methods in my MenuBarBean. However, when you click on one of the links, it seems as if the MethodBinding is never invoked, because the page just refreshes and never goes into the corresponding backing bean method. Strangely enough, if you provide an erroneous method name for the method binding such as "#{menuBarBean.FakeMethod}", faces doesn't even give a warning.
    All the piping seems to be working for the tag and the component.. meaning the "pageClass" and "msg" attributes get set and rendered properly on the menuBar. Also the thing renders correctly, but I have a feeling that I'm not setting the MethodBinding correctly for the "Action" property of the CommandLink, or I'm not setting it in the right place. Here's an abbreviated version of the code behind the component:
    In my 'MenuBar.java' class:
    public void setHomeBinding(MethodBinding mb)
    { homeBinding = mb; }
    public MethodBinding getHomeBinding()
    { return homeBinding; }There is also code in this class for stat management that saves and restores the values of the menuBar. I found that if I didn't do this, the "msg" attribute was cleared on refresh.
    In the 'setProperties' method of my 'MenuBarTag.java' class:
    MethodBinding mb = getFacesContext().getApplication().createMethodBinding("#{menuBarBean.gotoHome}", null);
    menuBar.setHomeBinding(mb);In the 'encodeEnd' method of 'MenuBarRenderer.java' (Here's where I create the link and set the Action to the MethodBinding)
    // If is this class, show a selected tab
    if(menuBar.getPageClass().equals(MenuBarBean.PAGECLASS_HOME))
         HtmlGraphicImage homeButton = (HtmlGraphicImage)application.createComponent(HtmlGraphicImage.COMPONENT_TYPE);
         homeButton.setUrl(IMG_HOME_SRC_SELECTED);
         menuBar.getChildren().add(homeButton);
    // else Render the button
    else
         HtmlSwapImage homeSwapImg = (HtmlSwapImage)application.createComponent(HtmlSwapImage.COMPONENT_TYPE);
         homeSwapImg.setUrl(IMG_HOME_SRC_IDLE);
         homeSwapImg.setSwapImageUrl(IMG_HOME_SRC_OVER);
         homeSwapImg.setStyleClass("menuBarButton");
         HtmlCommandLink homeButton = (HtmlCommandLink)application.createComponent(HtmlCommandLink.COMPONENT_TYPE);
         homeButton.setAction(menuBar.getHomeBinding());
         homeButton.setId("homeButton");
         homeButton.getChildren().add(homeSwapImg);
         menuBar.getChildren().add(homeButton);
    menuBar.getChildren().add(spacer);
    RendererUtils.renderChildren(facesContext, menuBar);
    menuBar.getChildren().removeAll(menuBar.getChildren());And finally, in my MenuBar backing bean 'MenuBarBean.java'
    public String gotoHome()
    { return("goto-home"); }
    public String getPAGECLASS_HOME()
    { return PAGECLASS_HOME; }So that's pretty much it. Like I said, the thing appears to be rendered correctly and looks like I want it to look. Unfortunately, the buttons don't do anything because I guess I'm not creating the HtmlCommandLinks properly, or I'm just leaving something out. Does anybody have any idea as to why the links aren't working based the on the above code? There are no exceptions being thrown or any warnings coming up in the console at all, so unfortunately there's no more information I can give you of what's happening within the framework.

    I really don't know what the problem is, but I'm willing to take a few wild guesses. At least this post should give you a few things to try...
    I found funny things start happening with CommandLinks when they are attached as children to any component except UIViewRoot. I don't know why. I would suggest you do not add the commandLink as a child of menuBar. Try just adding it to UIViewRoot. Maybe it'll work. Another option might be to try and find a creative way to use outputLink.
    When I ran into problems with my CommandLink, I eventually found a way to do it with outputLink instead. However, that was far from an ideal solution.
    Another guess would be to make sure you menuBarBean is in Session scope.
    Try surrounding everything in the encodeEnd method in a try-catch block and see if you are throwing any exceptions.
    Also, maybe moving the code from encodeEnd to encodeBegin might make a difference. It's worth a try.
    And lastly, always make sure you have an h:messages tag on your JSP. There may be messages there that can shed some light on the situation.
    Sorry I can't give you a more definitive answer! Hope this helps though.
    CowKing

  • Add & use custom jars in "Java embedding" component

    I need to generate pdf file in process.
    So I included "Java embedding" component, and write my code. For clarity example:
    com.itextpdf.text.Document document = new com.itextpdf.text.Document( 
                        com.itextpdf.text.PageSize.A4, 50, 50, 50, 50); 
              try { 
                   com.itextpdf.text.pdf.PdfWriter pdf = com.itextpdf.text.pdf.PdfWriter 
                             .getInstance(document, new java.io.FileOutputStream("c:\\text.pdf")); 
                   document.open(); 
                   document.add(new com.itextpdf.text.Paragraph("This is test message")); 
                   catch (com.itextpdf.text.DocumentException de) { System.err.println(de.getMessage());  }
                   catch (Exception de) { System.err.println(de.getMessage());}
              document.close();Im using external jar file, of course I add it to classpath (right click soa project -> properties -> libraries and classpath ->add jar).
    But I get folowing error (no during compilation, but during deploying):
    Failed to compile bpel generated classes.
    failure to compile the generated BPEL classes for BPEL process "SimpleProcess" of composite "default/SOAProject!1.0*soa_9f8e80a4-346d-424e-9e12-1b69e2024e58"
    The class path setting is incorrect.
    Ensure that the class path is set correctly. If this happens on the server side, verify that the custom classes or jars which this BPEL process is depending on are deployed correctly. Also verify that the run time is using the same release/version.
    [04:35:23 PM] Check server log for more details.
    [04:35:23 PM] Error deploying archive sca_SOAProject_rev1.0.jar to soa_server1 [[fe80:0:0:0:5968:cb45:2001:f6ce]:8001] 
    [04:35:23 PM] ####  Deployment incomplete.  ####
    [04:35:23 PM] Error deploying archive file:/C:/Projects/SOAProject/deploy/sca_SOAProject_rev1.0.jar
    (oracle.tip.tools.ide.fabric.deploy.common.SOARemoteDeployer)where ist the problem???
    Edited by: user1175491 on Nov 2, 2010 4:39 PM

    Ajaykumar, can u please write me what exactly append to bpel:exec part (which classes include?)? it looks now:
    <bpelx:exec name="GeneratePDF" version="1.5" language="java">
    <![CDATA[
                  com.itextpdf.text.Document document = new com.itextpdf.text.Document(  
                        com.itextpdf.text.PageSize.A4, 50, 50, 50, 50);  
              try {  
                   com.itextpdf.text.pdf.PdfWriter pdf = com.itextpdf.text.pdf.PdfWriter  
                             .getInstance(document, new java.io.FileOutputStream("c:\\text.pdf"));  
                   document.open();  
                   document.add(new com.itextpdf.text.Paragraph("This is test message"));  
                   catch (com.itextpdf.text.DocumentException de) {System.err.println(de.getMessage());}
                   catch (java.lang.Exception de) {System.err.println(de.getMessage());}  
              document.close();]]>
    </bpelx:exec>Edited by: user1175491 on Nov 2, 2010 5:07 PM
    Edited by: user1175491 on Nov 2, 2010 5:08 PM

  • Custom component  - how to store java Properties object in ucm environment

    Hi Experts,
    I am developing a custom component.
    my custom component code is reading a properties file and load in Properties object. Everytime this custom Service is called, properties file is read from file system and new Properties Object is created.
    Is there any way to load the Properties object once and store somewhere in UCM context ? (just like we do in JSP using application object"
    thanks!!
    Edited by: user4884609 on Jul 12, 2010 3:01 PM

    I'd say there are quite a few ways how to do it, but many of them have nothing in common with UCM.
    - I'd opt for the only "UCM" way I' aware of: as a part of custom component you can create your own properties file (it's also called environment variables) as a part of your custom component. You can, then, easily read (and write?) properties from/to the file.
    - The first option could have disadvantage, if there are too many properties. In this case you could use Java serialization - it should be UCM independent
    - Another option is to create your properties in the database - it is a bit similar to the first option, but it's more robust. Plus, you may use features of the database if you want to have some additional logic in you properties.
    - Note that you can also create a static object, which could be initialized e.g during class load

  • Changing state of application from within a custom component

    Hello, I have several custom components all of which are included in the parent application.
    When I try to change state from a custom component, I get an error  saying "undefined state: state name". How do I change the state of the  application from within a custom component ? All the states are defined in the parent application.

    @linrsvp,
    If you are using Flex3 try Application.application.currentState = "somestate";
    If you are using Flex4 try FlexGlobas.topLevelApplication.currentState = "somestate";
    Don't forget to import the corresponding namespaces for the above.
    Thanks,
    Bhasker

  • In HCP Cockpit, is there a way to provide version information for the deployed java applications?

    We have a Java Application which is deployed on HCP. When we make fixes and redeploy it again, is there a way that we can provide version information that could be useful to identify which version is currently deployed. Please advice if there is an alternate way to achieve this.

    Unfortunately there is no way to do that current stage , you would need to add the tags manually.
    Thanks,
    Sanjit

  • ALERT: java/lang/ClassFormatError: Bad version information.

    Hi all,
    I'm developing a mobile application but I got this error: ALERT: java/lang/ClassFormatError: Bad version information.
    I've read all the posts in the forum and searched for other ones with google, but still no luck :-( pls help.
    The situation is the following:
    IDE: netBeans 6.5
    MIDP2.1
    CLDC1.1
    javac.source=1.3
    javac.target=1.3
    J2ME web services 1.0 loaded.
    The application retrieves tracking data from a .net web service: I've created the stub with the sun official tool included in the WTK (Stub Generator).
    When I run the jar with the sun device emulator, the splash screen is loaded but, when I retrieve data from the web service, the application crashes with the error ALERT: java/lang/ClassFormatError: Bad version information. No problem if there's no data to fetch.
    Where am I wrong? pls help, thx,
    have a i nica day,
    Michela

    Have you tried JSR172Demo application that is supplied with Netbeans? if yes, did it work?
    Instructions on how to obtain this demo app are provided in [Netbeans help|http://i39.tinypic.com/k2h8og.jpg], section Importing Java ME Projects -> Sun Java Wireless Toolkit project

  • Customer component java.lang.OutOfMemoryError: Java heap space

    I have a custom component, the tag class is
    public class CalendarTag extends UIComponentELTag {
        private static final Logger log = Logger.getLogger(CalendarTag.class);
        @Override
        public String getComponentType() {
            return "HtmlCalendar";
        @Override
        public String getRendererType() {
            return "Calendar";
        @Override
        public void release() {
            super.release();
            this.pattern = null;
            this.year = null;
            this.month = null;
            this.firstDayOfWeek = null;
        @Override
        protected void setProperties(UIComponent component) {
            super.setProperties(component);
            CalendarComponent comp = (CalendarComponent) component;
            if (pattern != null) {
                comp.setValueExpression("pattern", pattern);
            if (year != null) {
                comp.setValueExpression("year", year);
    //        if (month != null) {
    //            component.setValueExpression("month", month);
    //        if (firstDayOfWeek != null) {
    //            component.setValueExpression("firstDayOfWeek", firstDayOfWeek);
        protected ValueExpression pattern;
         * Get the value of pattern
         * @return the value of pattern
        public ValueExpression getPattern() {
            return pattern;
         * Set the value of pattern
         * @param pattern new value of pattern
        public void setPattern(ValueExpression pattern) {
            this.pattern = pattern;
        protected ValueExpression year;
         * Get the value of year
         * @return the value of year
        public ValueExpression getYear() {
            return year;
         * Set the value of year
         * @param year new value of year
        public void setYear(ValueExpression year) {
            this.year = year;
        protected ValueExpression month;
         * Get the value of month
         * @return the value of month
        public ValueExpression getMonth() {
            return month;
         * Set the value of month
         * @param month new value of month
        public void setMonth(ValueExpression month) {
            this.month = month;
        protected ValueExpression firstDayOfWeek;
         * Get the value of firstDayOfWeek
         * @return the value of firstDayOfWeek
        public ValueExpression getFirstDayOfWeek() {
            return firstDayOfWeek;
         * Set the value of firstDayOfWeek
         * @param firstDayOfWeek new value of firstDayOfWeek
        public void setFirstDayOfWeek(ValueExpression firstDayOfWeek) {
            this.firstDayOfWeek = firstDayOfWeek;
    public class CalendarComponent extends UICommand {
        private static final Logger log = Logger.getLogger(CalendarComponent.class);
        public CalendarComponent() {
            super();
            setRendererType("Calendar");
        @Override
        public String getFamily() {
            return "Calendar";
        @Override
        public void encodeBegin(FacesContext context) throws IOException {
            log.debug("encodeBegin");
            super.encodeBegin(context);
        @Override
        public void encodeChildren(FacesContext context) throws IOException {
            log.debug("encodeChildren");
        protected String calendarType;
         * Get the value of calendarType
         * @return the value of calendarType
        public String getCalendarType() {
            if(calendarType != null) {
                return calendarType;
            ValueExpression ve = getValueExpression("pattern");
            if(ve != null) {
                if(!ve.isLiteralText()) {
                    return (String) ve.getValue(FacesContext.getCurrentInstance().getELContext());
                } else {
                    return ve.getExpressionString();
            } else {
                return (String) getAttributes().get("pattern");
         * Set the value of calendarType
         * @param calendarType new value of calendarType
        public void setCalendarType(String calendarType) {
            this.calendarType = calendarType;
        public int getYear() {
            ValueExpression ve = getValueExpression("year");
            if(ve != null) {
                if(!ve.isLiteralText()) {
                    return ((Integer) ve.getValue(FacesContext.getCurrentInstance().getELContext())).intValue();
                } else {
                    log.debug("a=" + ve.getExpressionString());
                    return 2009;//(Integer.getInteger(ve.getExpressionString())).intValue();
            } else {
                log.debug("size=" + this.getAttributes().size());
                log.debug("year=" + this.getAttributes().get("year"));
                return 2009;//((Integer) getAttributes().get("year")).intValue();
    //        return 2009;
    }Some code has been omitted.
    where I use this component, I got the following exception
    {font:&#65325;&#65331; &#65328;&#12468;&#12471;&#12483;&#12463;, monospace}{size:2}Caused by: java.lang.OutOfMemoryError: Java heap space
    From the log, I found {size}{font}this.getAttributes().get("year") is called recursively. But I don't know why, can anyone help me?

    the log is added to find my stackover problem,
    I am new to JSF, can you point out why it will call it recursively. thank you very much
    public int getYear() {
            ValueExpression ve = getValueExpression("year");
            if(ve != null) {
                if(!ve.isLiteralText()) {
                    return ((Integer) ve.getValue(FacesContext.getCurrentInstance().getELContext())).intValue();
                } else {
                    log.debug("a=" + ve.getExpressionString());
                    return (Integer.getInteger(ve.getExpressionString())).intValue();   /// here is the problem
            } else {
                return ((Integer) getAttributes().get("year")).intValue();
        }

  • Java/lang/ClassFormatError: Bad version information.

    Hi
    When running the midlet in wireless tool kit the following
    error is occuring
    java/lang/ClassFormatError: Bad version information.
    can any body suggest me wat the problem is

    Hi,
    answer is at http://forum.java.sun.com/thread.jspa?threadID=569449&tstart=0

  • Navigation from within a custom component ???

    Hi All
    I am working on a new project in Flex 4 and i have a Viewstack on my main page.  Then i have 6 custom components in the viewstack, the first being the home page.  In this homepage custom component i have linkbuttons which i want the user to click on to navigate the viewstack ..
    So what would be the best way to do this ?
                             <fx:Script>
                                  <![CDATA[
                                       ]]>
                             </fx:Script>
                   <mx:ViewStack id="vs" width="800" height="1000">
                        <s:NavigatorContent width="100%">
                             <v:VHome id="vHome" />
                                            <v:VHome id="vAbout" />
                                            <v:VHome id="vShop" />
                                            <v:VHome id="vProducts" />
                                            <v:VHome id="vSupport" />
                                            <v:VHome id="vContact" />
                             </s:NavigatorContent>
                   </mx:ViewStack>
    <s:Group xmlns:fx="http://ns.adobe.com/mxml/2009"
               xmlns:s="library://ns.adobe.com/flex/spark"
               xmlns:mx="library://ns.adobe.com/flex/mx"
               width="100%">
         <s:layout>
              <s:VerticalLayout />
         </s:layout>
         <fx:Declarations>
              <!-- Place non-visual elements (e.g., services, value objects) here -->
         </fx:Declarations>
              <mx:Spacer height="10" />
              <s:Panel title="Welcome" width="100%">
              </s:Panel>
              <s:HGroup>
                   <s:Panel width="397" height="200">
                        <MX:LinkButton />
                   </s:Panel>
                   <s:Panel width="397" height="200">
                        <MX:LinkButton />
                   </s:Panel>               
              </s:HGroup>
              <s:HGroup>
                   <s:Panel width="397" height="200">
                        <MX:LinkButton />
                   </s:Panel>
                   <s:Panel width="397" height="200">
                        <MX:LinkButton />
                   </s:Panel>               
              </s:HGroup>
              <s:HGroup>
                   <s:Panel width="397" height="200">
                        <MX:LinkButton />
                   </s:Panel>
                   <s:Panel width="397" height="200" >
                        <MX:LinkButton />
                   </s:Panel>               
              </s:HGroup>
    </s:Group>
    Many Thanks

    If I am understanding this correctly, you have three choices.
    1. Do something like ViewStack.selectedIndex(id of tab in viewstack), but not sure if selectedIndex is correct but whatever the method name is.
    2. Fire an event and set up listeners
    3. Go with a framework and use its notifications or event system
    If this is a production app I suggest fighting the urge to go the easy route and use a framework as before you know it you will in the middle of spaghetti code.

  • Version information for java  resource adaptor

    Hi,
    Iam developing a resource adaptor(RAR). I have deployed my RAR on app server. My problem is that i want to provide version information of my RAR. One way is that i do the same in log files which iam doing presently. Problem is that logging is disabled in most production environment due to performance reasons.
    Otherway is, instead of usual .log file, i write the version information in some .config file which I can create when my adaptor is loaded. Problem with this approach is that i can have mutiple RAR deployed on same app server connected to different instances of EIS. If app server has only single class loader, then this will be a problem as the RAR which is loaded later will override the previous info as only one copy of the file is created.
    Can anyone suggest me a possible way.
    Ashish

    There is noy way for you to write a simple message to the app server log file when the RAR is inited stating the version of the RAR? You also mentioned dumping the RAR version to a file. Why can't you simply write the RAR version to a unique file name by adding a date stamp or some other unique identifier so you don't overwrite the previous file? Maybe I'm missing something.

  • Dispatching & listening for custom events from custom component [Flex 4.1]

    I'm giving this a try for the first time and I'm not sure I have the recipe correct!
    I have a custom component - it contains a data grid where I want to double click a row and dispatch an event that a row has been chosen.
    I created a custom event
    package oss
        import flash.events.Event;
        public class PersonChosenEvent extends Event
            public function PersonChosenEvent(type:String, bubbles:Boolean=false, cancelable:Boolean=false)
                super(type, bubbles, cancelable);
            // Define static constant.
            public static const PERSON_CHOSEN:String = "personChosen";
            // Define a public variable to hold the state of the enable property.
            public var isEnabled:Boolean;
            // Override the inherited clone() method.
            override public function clone():Event {
                return new PersonChosenEvent(type);
    Then I try to dispatch the event within the component when the datagrid is doubleclicked:
    import oss.PersonChosenEvent
    dispatchEvent(new PersonChosenEvent(PersonChosenEvent.PERSON_CHOSEN, true, false));
    And in the parent application containing the component I do on creationComplete
    addEventListener(PersonChosenEvent.PERSON_CHOSEN,addPersonToList);
    The event does not seem to fire though. And if I try to evaluate the "new PersonChosenEvent(..." code it tells me "no such variable".
    What am I doing wrong?
    (It was so easy in VisualAge for Java, what have we done in the last 10 years?? )
    Martin

    I've done this kind of thing routinely, when I want to add information to the event.  I never code the "clone" method at all.
    Be sure that you are listening to the event on a parent of the dispatching component.
    You can also have the dispatching component listen for the event too, and use trace() to get a debug message.
    I doubt if it has anything to to with "bubbles" since the default is true.
    Sample code
    In a child (BorderContainer)
    dispatchEvent(new ActivationEvent(ActivationEvent.CREATION_COMPLETE,null,window));
    In the container parent (BorderContainer)
    activation.addEventListener(ActivationEvent.CREATION_COMPLETE,activationEvent);
    package components.events
        import components.containers.SemanticWindow;
        import components.triples.SemanticActivation;
        import flash.events.Event;
        public class ActivationEvent extends Event
            public static const LOADED:String = "ActivationEvent: loaded";
            public static const CREATION_COMPLETE:String = "ActivationEvent: creation complete";
            public static const RELOADED:String = "ActivationEvent: reloaded";
            public static const LEFT_SIDE:String = "ActivationEvent: left side";
            public static const RIGHT_SIDE:String = "ActivationEvent: right side";
            private var _activation:SemanticActivation;
            private var _window:SemanticWindow;
            public function ActivationEvent(type:String, activation:SemanticActivation, window:SemanticWindow)
                super(type);
                _activation = activation;
                _window = window
            public function get activation():SemanticActivation {
                return _activation;
            public function get window():SemanticWindow{
                return _window;

  • How Do I Link to Custom Component States From Scrolling Content Buttons?

    Hi there, I'm in need of some help as i've got a deadline to meet within the next few weeks and im stuck!
    Basically what I've done is i've made a scrolling content lists, containing about 10 products in each one, my plan was to turn each product into a button so that users could click on that product, and take them to a new page containing more detailed information on that product; when they've finished looking at that product they can click a button to return them to the list they were on previously. However I can't just make a brand new state for each product as there is a limit to 20 states, and I will need around 50 of them.
    So, from what i've read I will need to create custom components. the only trouble with doing this is that I can't link to the custom component on a different main timeline state (I dont get the option to link to the states of the custom component).
    If i put the image of the detailed product into the scroll panel I am able to link to it, however, it's inside the scrolling content and it just scrolls around and stuff which isn't what I want; as it makes it look messy.
    - Basically I just need to link from the buttons in the scrolling list, to a more detailed page for that product. Then be able to return to the list using a button.
    If anybody has any input on how to achieve this, please help me out. Starting to panic now as this needs to be finished before september :s
    Btw i'm happy to share my .fxp file it that helps.
    Thanks alot, Hoping for some helpful replies on this topic
    - Tom

    Hi Tom,
    Adding this back here to share my wireframe with the community.
    Have put a quick .fxp together based on the 'product' section of your project.
    Take a look at how the product lists are linking into the product detail pages within their custom components. 
    Using this model you should be able to expand out to infinite product detail states.  If a particular product area has more than the maximum allowed states, just start a new custom component (part 2 for that product section).
    Let me know if you have any questions. Hope this sets you on a path to getting your project complete.  It's looking nice.
    Tanya

  • I am not able to create a JMS connection from a custom component in UCM

    I am trying to create a custom component which makes a JMS connection and inserts messages in JMS Queue.
    THe JMS server is hosted on Weblogic Application Server.
    When the code runs I am getting the factory object and the queue object.
    But when I try to get a connection it throws an error as pasted below.
    WHen I googled the same error It has shown a simliar problem in TOmcat in sun thread
    It said two jar files xerces.jar and xml-apis.jar are obsolete.
    I replaced with the new version.
    still the same problem occurred
    Please help
    Pasting the code and exception here
    Code __________________________________________
    import java.util.Date;
    import java.util.Hashtable;
    import javax.jms.*;
    import javax.naming.*;
    import weblogic.jms.client.WLConnectionImpl;
    import weblogic.jms.extensions.*;
    import javax.rmi.PortableRemoteObject;
    public class SimpleProducer {
    public static void drive() {
    final int NUM_MSGS;
         NUM_MSGS = 93;
    Context jndiContext = null;
    Hashtable<String, String> ht;
              ht = new Hashtable<String, String>();
              ht.put(Context.INITIAL_CONTEXT_FACTORY,
                        "weblogic.jndi.WLInitialContextFactory");
              ht.put(Context.PROVIDER_URL, "t3://punitp52975d:7001");
    try {
         jndiContext = new InitialContext(ht);
    } catch (NamingException e) {
    System.out.println("Could not create JNDI API context: " +
    e.toString());
    System.exit(1);
    ConnectionFactory connectionFactory = null;
    Destination dest = null;
    try {
                   Object home = jndiContext.lookup("CNFT"); // where iiopTestDS is jndi name for my DataSource.
    connectionFactory =(ConnectionFactory)PortableRemoteObject.narrow(home , ConnectionFactory.class);
         Object home1 = jndiContext.lookup("QUEUE2"); // where iiopTestDS is jndi name for my DataSource.
    dest =(Destination)PortableRemoteObject.narrow(home1 , Destination.class);
         /*connectionFactory = (ConnectionFactory) jndiContext.lookup(
    "CNFT");
    dest = (Destination) jndiContext.lookup("QUEUE2");
    System.out.println("connectionFactory,dest "+connectionFactory+dest);*/
    } catch (Exception e) {
    System.out.println("JNDI API lookup failed: " + e.toString());
    e.printStackTrace();
    System.exit(1);
    //WLConnectionImpl connection = null;
    WLConnection connection = null;
    WLMessageProducer producer = null;
    try {
                   System.out.println("Getting Connection "+(WLConnection) connectionFactory.createConnection());
    //connection = (WLConnection) connectionFactory.createConnection();
                   System.out.println("Connection created");
    WLSession session =
    (WLSession) connection.createSession(false, Session.CLIENT_ACKNOWLEDGE);
    producer = (WLMessageProducer) session.createProducer(dest);
    WLMessage message = (WLMessage) session.createTextMessage();
    //TextMessage message = session.createTextMessage();
    for (int i = 91; i < NUM_MSGS; i++) {
    ((TextMessage) message).setText("This is message " + (i + 1));
    Long l = new Date().getTime();
    message.setLongProperty("ReleasedDate",l );
    System.out.println("Sending message: " + ((TextMessage) message).getText());
    producer.send(message);
    producer.send(session.createMessage());
    } catch (Exception e) {
    System.out.println("Exception occurred: " + e.toString());
    } catch (Throwable et) {
    System.out.println("Exception occurred: " + et.toString());
    et.printStackTrace();
    finally {
    if (connection != null) {
    try {
    connection.close();
    } catch (Exception e) {
                             System.out.println("*************Instantiating Producer***************");
    Exception_________________________________________________________________
    Exception occurred: java.lang.NoSuchMethodError: javax.xml.parsers.SAXParserFactory.getSchema()Ljavax/xml/validation/Schema;
    java.lang.NoSuchMethodError: javax.xml.parsers.SAXParserFactory.getSchema()Ljavax/xml/validation/Schema;
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.<init>(SAXParserImpl.java:124)
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl.newSAXParserImpl(SAXParserFactoryImpl.java:115)
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl.setFeature(SAXParserFactoryImpl.java:143)
    at weblogic.xml.jaxp.WebLogicSAXParserFactory.<init>(WebLogicSAXParserFactory.java:62)
    at weblogic.rmi.internal.wls.WLSRMIEnvironment.getSAXParser(WLSRMIEnvironment.java:136)
    at weblogic.rmi.internal.DescriptorManager.getDescriptorAsMap(DescriptorManager.java:170)
    at weblogic.rmi.internal.DescriptorManager.getDescriptorAsMap(DescriptorManager.java:159)
    at weblogic.rmi.internal.DescriptorManager.createRuntimeDescriptor(DescriptorManager.java:104)
    at weblogic.rmi.internal.DescriptorManager.getBasicRuntimeDescriptor(DescriptorManager.java:85)
    at weblogic.rmi.internal.DescriptorManager.getDescriptor(DescriptorManager.java:51)
    at weblogic.rmi.internal.DescriptorManager.getDescriptor(DescriptorManager.java:37)
    at weblogic.rmi.internal.OIDManager.makeServerReference(OIDManager.java:194)
    at weblogic.rmi.internal.OIDManager.getReplacement(OIDManager.java:175)
    at weblogic.rmi.utils.io.RemoteObjectReplacer.replaceRemote(RemoteObjectReplacer.java:120)
    at weblogic.rmi.utils.io.RemoteObjectReplacer.replaceObject(RemoteObjectReplacer.java:103)
    at weblogic.rmi.extensions.server.ServerHelper.exportObject(ServerHelper.java:223)
    at weblogic.rmi.internal.OIDManager.initializeDGCServer(OIDManager.java:231)
    at weblogic.rmi.internal.OIDManager.getReplacement(OIDManager.java:144)
    at weblogic.rmi.utils.io.RemoteObjectReplacer.replaceRemote(RemoteObjectReplacer.java:120)
    at weblogic.rmi.utils.io.RemoteObjectReplacer.replaceObject(RemoteObjectReplacer.java:103)
    at weblogic.rmi.extensions.server.ServerHelper.exportObject(ServerHelper.java:223)
    at weblogic.corba.server.naming.ReferenceHelperImpl.exportObject(ReferenceHelperImpl.java:233)
    at weblogic.rmi.extensions.PortableRemoteObject.exportObject(PortableRemoteObject.java:34)
    at weblogic.messaging.dispatcher.DispatcherImpl.export(DispatcherImpl.java:85)

    This is probably related to this other issue http://www.adobeforums.com/webx/.59b7fbab/0.
    Jasmin

Maybe you are looking for