Classloading in scoped memory

Hello,
currently I am trying to figure out how classloading in scoped memory can be done.
I tried the following code which is executed by a RealtimeThread:
public void run() {
// allocation context is: heap
final ScopedMemory scopeA = new LTMemory(50000);
final ScopedMemory scopeB = new LTMemory(50000);
// RtjTestClassloader simply loads a class from a .class-file that
// exists somewhere in the filesystem
final ClassLoader cloader = new RtjTestClassloader();
try {
    // loading a class in scoped memory fails if no class was loaded
    // using that classloader before entering the scope
    Class<?> c = cloader.loadClass(OTHER_CLASS);
} catch (ClassNotFoundException e) {
    System.exit(1);
scopeA.enter(new Runnable() {
    public void run() {
        try {
            System.err.println("scopeA entered");
            Class<?> clazz = cloader.loadClass(CLASS);
            TestClass tc = (TestClass)clazz.newInstance();
            System.err.println("scopeA memory consumed: " + scopeA.memoryConsumed());
        } catch (Exception e) {
            e.printStackTrace();
scopeB.enter(new Runnable() {
    public void run() {
        try {
            System.err.println("scopeB entered");
            System.err.println("scopeA memory consumed: " + scopeA.memoryConsumed());
            Class<?> clazz = cloader.loadClass(CLASS);
            TestClass tc = (TestClass)clazz.newInstance();
            System.err.println("scopeB memory consumed: " + scopeB.memoryConsumed());
        } catch (Exception e) {
            e.printStackTrace();
}the output is:
scopeA entered
scopeA memory consumed: 16240
scopeB entered
scopeA memory consumed: 0
scopeB memory consumed: 1896
If the Class object would be allocated in scopeA it would not be possible to
use that Class object in scopeB since classes can only be loaded once per
classloader (the high memory consumption of scopeA is probably because of
opening a file). That implies that classes must be allocated on the heap or in
immortal memory. Is that the case in the Sun Java RTS?
Furthermore the above code fails when run in TimeSys JVM. Trying to load the
class in scopeA causes an IllegalAsignmentError when defineClass(...) is called.
I suspect that is due to the storing of the reference to the loaded class for
later use. Which would again imply that TimeSys really allocates memory for
Class objects inside the scope.
The same Error happened when I tried to load a class with a classloader that was
instanciated in scoped memory (using Sun Java RTS).
Another interesting notice is that the loading of the class in scopeA only works
if the classloader was used to load a class in heap or immortal memory before
entering the scope.
What happens when a class is being loaded and scopes are involved? Is there an
approach that should be used when having multiple classloaders and scopes?
And is there anything in the RTSJ Spec on that? I wasn't able to find anything.
Thank you,
Matthias
Edited by: user13696541 on 11.01.2011 13:46

Hello,
I have to push this topic, because it addresses a common question about the scenario of (user-defined) class loading in Real-Time Java, especially when mixed up with Scope usage.
I'm wondering if user-defined Class Loading has been addressed yet in the RTSJ?
Because of the absence of any statement about it within the RTSJ specification (or any of the well-known books about RTSJ),
we assumed the problem is implementation-specific.
Therefore we decided to do some tests, which Matthias has presented here in his previous post.
The cited code above exemplifies a simple class loading scenario executed by a Real-Time JVM:
A RealTimeThread enters a scope A and uses a Class Loader instance "cloader" residing on the Heap in order to load a certain class "CLASS" within that scope.
On success, I would expect that the entire control structures defining the class "CLASS" are situated within the scope A.
As you can see the program output, after the class loading procedure Class<?> clazz = cloader.loadClass(CLASS),
there are about 16 Kbytes of scope A in use (e.g. something happened on class loading within that scope).
Afterwards, the RT-Thread leaves the scope A, and according to it's memory usage (= 0) the latter seems to be already freed (e.g. no active threads therein anymore).
This would impose, that the definition structures (or parts of them) of the class "CLASS" that were placed within the scope A are lost now, wouldn't it?
However, this seems not to be the case.
The RT-Thread enters a new scope B and tries to reload the same class "CLASS" with the same "cloader" instance residing on the heap.
I would expect, that the "CLASS" is either redefined in some way within scope B, or that the JVM throws a kind of error since the definition for "CLASS" has been already lost with scope A.
Nevertheless, "cloader" simply returns a valid Class object for the "CLASS" which can be further instantiated and used without any problems.
But, the memory usage of scope B is much lower (= 1896 bytes) than that of scope A after defining the "CLASS".
This raises a common question:
1. Where does the JRTS JVM place Class Objects of newly defined classes (in terms of the Java "Class" object and the corresponding JVM-internal definition structures)?
a) The current allocation scope of the Thread actually defining a class?
b) Some other scope (e.g. a class cache) ?
2. What happens in the scenario above? What is allocated on class loading within scope A, and how is it possible to have a valid class definition of "CLASS" since scope A has been freed?
We've tried another use case, having a separate class loader object "rtcl" instantiated within a scope C, which again loads the class "CLASS" within the same scope C:
mc.enter(new Runnable() {
                public void run() {
                    try {
                        ClassLoader rtcl = new RtjTestClassloader();
                        Class c = rtcl.loadClass(CLASS3);
                        TestClass cl3 = (TestClass) c.newInstance();
                    } catch (Exception e) { e.printStackTrace(); }
Output:
Exception in thread "RealtimeThread-0" javax.realtime.IllegalAssignmentError
     at java.util.HashMap$Entry.<init>(HashMap.java:730)
     at java.util.HashMap.addEntry(HashMap.java:797)
     at java.util.HashMap.put(HashMap.java:431)
     at java.util.HashSet.add(HashSet.java:194)
     at java.lang.ClassLoader.checkPackageAccess(ClassLoader.java:346)
     at java.lang.ClassLoader.defineClass1(Native Method)
     at java.lang.ClassLoader.defineClass(ClassLoader.java:630)
     at java.lang.ClassLoader.defineClass(ClassLoader.java:475)
     at rtjtests.classloader.RtjTestClassloader.loadClass(RtjTestClassloader.java:35)
     at rtjtests.classloader.ClassLoadingInScopeTest$3.run(ClassLoadingInScopeTest.java:138)
     at javax.realtime.MemoryArea.enter0(Native Method)
     at javax.realtime.MemoryArea.enter(MemoryArea.java:190)
     at javax.realtime.ScopedMemory.enter(ScopedMemory.java:191)
     at rtjtests.classloader.ClassLoadingInScopeTest.run(ClassLoadingInScopeTest.java:114)3. If I interpret the programs output right,
- Class Loaders in JRTS seem to use traditional java.util.HashMap objects for storing references to their loaded classes
- The class loading procedure really placed something on the scope (i.e. the class's Class object?)
- For some reasons the class loader cannot store a reference to that object on the scope within its HashMap.
Could anyone give us a short explaination of the internal representation of class objects and their corresponding class loaders?
What are the reasons the RT-JVM behavior described above during our tests?
Is there any intended or standardized way for the usage of extended class loading within RTSJ scopes?
We would appreciate any help !
Sincerely,
Vladimir
Edited by: vladimir.nikolov on Jan 17, 2011 5:05 AM
Edited by: vladimir.nikolov on Jan 17, 2011 5:06 AM
Edited by: vladimir.nikolov on Jan 17, 2011 5:07 AM

Similar Messages

  • Scoped Memory Allocation

    Hi,
    I am working with RTS on eclipse, I have written a simple program where i construct a LTMemory object and i print its memoryRemaining() method once before entering the scope and once after exiting the scope.(Inside the scope i allocated two Integer objects) The memory doesn't seem to be reclaimed. Furthermore i get the same number of bytes from the first call of the memoryRemaining() (16384) irrelative to the number i pass at the constructor of the LTMemory object.What is wrong with these cases?
    Thanks

    Hi,
    gn_164 wrote:
    I am working with RTS on eclipse, I have written a simple program where i construct a LTMemory object and i print its memoryRemaining() method once before entering the scope and once after exiting the scope.(Inside the scope i allocated two Integer objects) The memory doesn't seem to be reclaimed. This is a known bug with the memory counters. Logically the scope is reclaimed when the last thread leaves, but in practice actual reclaiming is deferred until the next thread enters. The memory counters should have been adjusted when the thread left, but they weren't. If you check the available memory each time you enter the scope you will see that the full amount is available each time.
    Furthermore i get the same number of bytes from the first call of the memoryRemaining() (16384) irrelative to the number i pass at the constructor of the LTMemory object.The VM has a default minimum scope size of 16KB. You can change this by using the -XX:ScopedMemoryAllocGrain=n flag where n is the number of bytes: 512, 1K, 1M. Only use a power-of-2 because the actual size will be rounded down to the closest power of 2.
    I see this flag is missing from our command-line options documentation.
    David Holmes
    >
    Thanks

  • Related to RealtimeThread creation and memory issue

    I wrote a sample program
    public static void main(String args[]) {
    try{
    System.out.println("Creating mainScopedMem scoped memory ");
    LTMemory mainScopedMem = new LTMemory(10240);
    System.out.println("Setup, in memory Area "+ RealtimeThread.getCurrentMemoryArea().size());
    new RealtimeThread( null, null, null, mainScopedMem, null,
    new Runnable () {
    public void run() {
    final ScopedMemory orderManagerScope = new LTMemory(240960);
    try{
    orderManagerScope.enter( new OrderManagerListener() );
    }catch( OutOfMemoryError err){
    System.out.println("OutOfMemoryError inner Runnable");
    err.printStackTrace();
    }).start();
    }catch( OutOfMemoryError err){
    System.out.println("OutOfMemoryError Outer Runnable");
    err.printStackTrace();
    and executed this code from netbeans, linux in virtual box
    -Xms512m -Xmx1024m -Xss1000 -XX:ThreadStackSize=0 -XX:ScopedSize=440960
    ulimit -s in linux gave me 10240
    I monitored memory via system monitor. I found that my memory started to grow from 786MB to 1.8G
    I tried creating a thread pool for 3000 Realtime thread.... My Single CPU got utilized 100% and its used 3.1GB for memory out of 3.3 and code started to hang..
    My question is. How much memory does a normal realtimeThread consumes... Is there any limit in creating Realtime thread... and Why does is consumes a lot of memory. If i need to do any fine tuning please do let me know.
    Hardware is not an issue in my case....
    Right now i am using viritual box. We are running our code in seperate RTLinux box.
    - Lemuria

    Hi Ashok ,
    Cost Component Structure Applies for both Plan and Actuals ...hence mentioning admin o/h as not relevant for inventory will not serve your purpose.
    Only workaround i see it to use a negligible quantity as Admin overhead is routing . Like (0.00001) Hour .
    Standard  Cost will have a negligible Admin overhead and in actual you will book actual hours will be be part of actual cost
    This will solve your Issue..
    Regards
    Sarada

  • AspectJ load time weaving AnnotatedNoClassDefFoundError

    I am trying to use AspectJ load time weaving on an application running on OC4J 10.1 on JRE 1.5. I get AnnotatedNoClassDefFoundError with Missing class: org.aspectj.runtime.internal.AroundClosure message.
    Here is what I am doing:
    1. Starting the server with JVM argument -javaagent:aspectjweaver.jar to enable AspectJ load time weaving.
    2. I put an AspectJ library MaintainJAspect.jar under j2ee\home\applib folder.
    3. I put the aspect defined in aop.xml at j2ee\home\applib\META-INF\aop.xml .
    The aspect defined in aop.xml is properly weaved into the application class (I can see in the dumped source). But when the application is running, it fails with the message pasted below.
    My question is, while it says that the missing class is available in oc4j classloader, which is parent of system and application class loaders, why is it not available to my application?
    Thanks in advance,
    Choudary Kothapalli.
    oracle.classloader.util.AnnotatedNoClassDefFoundError:
         Missing class: org.aspectj.runtime.internal.AroundClosure
         Dependent class: com.maintainj.aspect.ExecutionAspect
         Loader: global.libraries:1.0
         Code-Source: /C:/Programs/oc4j10/j2ee/home/applib/MaintainJAspect.jar
         Configuration: <code-source> in /c:/Programs/oc4j10/j2ee/home/config/server.xml
    The missing class is available from the following locations:
         1. Code-Source: /C:/Programs/oc4j10/j2ee/home/maintainj/aspectjweaver.jar (from system property java.class.path)
         This code-source is available in loader oc4j:10.1.3.
         at oracle.classloader.PolicyClassLoader.handleClassNotFound (PolicyClassLoader.java:2068) [C:/Programs/oc4j10/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@9627532]
         at oracle.classloader.PolicyClassLoader.internalLoadClass (PolicyClassLoader.java:1679) [C:/Programs/oc4j10/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@9627532]
         at oracle.classloader.PolicyClassLoader.loadClass (PolicyClassLoader.java:1635) [C:/Programs/oc4j10/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@9627532]
         at oracle.classloader.PolicyClassLoader.loadClass (PolicyClassLoader.java:1620) [C:/Programs/oc4j10/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@9627532]
         at java.lang.ClassLoader.loadClassInternal (ClassLoader.java:319) [jre bootstrap, by jre.bootstrap:1.5.0_08]
         at com.maintainj.aspect.ExecutionAspect.ajc$around$com_maintainj_aspect_ExecutionAspect$1$133697c9proceed (ExecutionAspect.aj:1) [C:/Programs/oc4j10/j2ee/home/applib/MaintainJAspect.jar (from <code-source> in /c:/Programs/oc4j10/j2ee/home/config/server.xml), by global.libraries:1.0]
         at com.maintainj.aspect.ExecutionAspect.ajc$around$com_maintainj_aspect_ExecutionAspect$1$133697c9 (ExecutionAspect.aj:42) [C:/Programs/oc4j10/j2ee/home/applib/MaintainJAspect.jar (from <code-source> in /c:/Programs/oc4j10/j2ee/home/config/server.xml), by global.libraries:1.0]
         at simple.SimpleServlet.<init> (SimpleServlet.java:12) [C:/Programs/oc4j10/j2ee/home/applications/SimpleWeb/SimpleWeb/WEB-INF/classes/ (from WEB-INF/classes/ in C:\Programs\oc4j10\j2ee\home\applications\SimpleWeb\SimpleWeb\WEB-INF\classes), by SimpleWeb.web.SimpleWeb:0.0.0]

    Not sure what you mean by "support". AspectJ rewrites bytecodes so the VM will just execute them. You'll probably encounter increased memory usage with load-time weaving as class loading/initialization occurs in Immortal memory. Also load-time weaving won't be compatible with Java RTS's Initialization Time Compilation (ITC) feature ... or at least not the pre-initialization part. It's likely that no-heap threads won't work well running weaved code if there are any references back to heap-allocated AspectJ runtime objects, and similarly (like most libraries) it's not likely to work from scoped memory.
    HTH.
    David Holmes

  • AspectJ with real time java

    Hi
    Does real time java supports aspectJ with Load-time weaving ( LTW ) ? ( compile time weaving )

    Not sure what you mean by "support". AspectJ rewrites bytecodes so the VM will just execute them. You'll probably encounter increased memory usage with load-time weaving as class loading/initialization occurs in Immortal memory. Also load-time weaving won't be compatible with Java RTS's Initialization Time Compilation (ITC) feature ... or at least not the pre-initialization part. It's likely that no-heap threads won't work well running weaved code if there are any references back to heap-allocated AspectJ runtime objects, and similarly (like most libraries) it's not likely to work from scoped memory.
    HTH.
    David Holmes

  • About ISAC packet size

    Hi,all
    Learning CCIE Collarboration course, I notice that one of the ISAC feature is that, its packet size is adaptive from 30 to 60 ms.
    Then here is the question, Why we measure packet size in millisecond?
    Thanks!

    Hi,
    Please have a look at the scoped memory related section in the technical information document:
    http://java.sun.com/javase/technologies/realtime/reference/doc_2.2u1/release/JavaRTSTechInfo.html#scoped-mem
    For your specific question, search for ScopedMemoryAllocGrain.
    Regards,
    Bertrand.

  • When exactly are request-scoped beans evicted from memory?

    Hi,
    I have a question about request-scoped JSF-managed beans and request-scoped HibernateFilter. It seems to me that request-scoped JSF beans actually outlive an HTTP request. Here's what I mean. Let's say I have a page backed by a request-scoped bean #{myBean} which displays a dataTable. a user can click on a row to perform some operation on row data.
    I always thought the following to be true about lifecycle of JSF request-scoped bean:
    1.User makes initial page request
    -HTTP Request 1 (R1) comes in
         1. RestoreView encounters #{myBean} in page and constructs MyBean
         2. RenderResponse renders the page
    -R1 is terminated, page is displayed, myBean is evicted from memory
    2.User looks at the dataTable and clicks on a specific row (via commandLink). Now MyBean.action() is supposed to be
    executed and perform some operation on row data:
    -HTTP R2 comes in
         1.MyBean is constructed again (e.g. not using same instance as in R1). (THIS IS KEY!)
         2.myBean.action() is executed
    -R2 is terminated, myBean is again evicted from memory
    Is the above understanding correct?
    Or does myBean instance (and its' properties) remain in appserver memory between R1 and R2 and R2 actually uses the
    same instance of myBean?
    If scenario above is correct, then I have a strange problem:
    -when performing myBean.action() during R2 on rowData (which is instance of MyHibernateBean) I get a
    HibernateException stating that bean isn't associated with a Hibernate Session. This can only happen if the lifecycle of the object and its' parent myBean exceeded that of R1. That is because I have a Hibernate Servlet
    Filter that a) start a Hibernate Transaction on incoming request and b) commits it on the way out.
    Here's pseudo-code for myBean:
    public class MyBean {
        public static String HANDLE = "#{myBean}";
        //getters setters omitted
        //used as 'value' in dataTable
        private List<MyHibernateBean> dataBeans;
        //dataTable binding
        private UIData tableData;
        public MyBean() {
        public String action() {
            //read children & modify state of a hibernate bean
            MyHibernateBean dataBean = (MyHibernateBean) this.tableData.getRowData();
            HibernateUtil.getCurrentSession().refresh(dataBean); //seems necessary as dataBean instance deemed 'stale'
            dataBean.getChildCollection(); //will fail without line above
            return "toSomewhereElse";
    }

    By the way, I have an hypothesis why this does not work...
    The datatable values MUST be specified using a value binding expression. When the restoreState method for the component is called, JSF attempts to use the VB expression to get the table values. When the managed bean is not found, it creates a new (empty) one and the world ends (actually it just returns back to the original page because it cannot figure out what to do)

  • JSP/classloader memory leak?

    We have a site that includes about 600 JSPs.
              JSP re-compilation is turned on in production, to support content updates
              (JSPs are considered to be content, in this case). However, this is causing
              problems, as the JVM running weblogic grows significantly each time JSPs
              are updated. There has been suggestion that the JSP class-loaders are not
              being garbage-collected properly.
              The environment is WebLogic 5.1 SP6, running on Sun's JDK 1.2.2, on Solaris
              2.7.
              Has anyone else seen this problem before? Is there a fix, or a work-around?
              cheers,
              Mike Williams
              

    Yup - Solaris doc says that this error actually means that there is
              not enough swap space for the new process (javac) - that's why I
              thought that this is not a JVM but a Solaris problem somehow.
              When this happens there are no any additional processes running (except
              jvm which runs WebLogic - no shells, no strays, etc). What is puzzling is that
              simply restarting the jvm doesn't help - only reboot does. That led me
              to think that probably something leaks in Solaris itself whith each new process
              creation (and obviously lots and lots of JSP compilations have something
              to do with it). Any ideas on this?
              Mike Reiche <[email protected]> wrote:
              > The 'not enough space' message refers to swap space. Your system
              > had processes using up more swap space than your system had.
              > The JSP compile was the last straw. So when you rebooted the
              > box, it (1) restarted the JVM and (2) killed every other process
              > running on the system - probably a couple dozen shells, telnets,
              > maybe some other JVMs. That's why rebooting fixed it.
              > But - how big was your JVM when this happened - way too big, I
              > would guess.
              > Mike
              > Dimitri Rakitine <[email protected]> wrote:
              >>I have a question - we had this happening several times
              >>on Solaris
              >>boxes (JSPs do not compile with 'not enough space' error)
              >>and simply
              >>killing the JVM and restarting the WebLogic doesn't solve
              >>the problem -
              >>only rebooting the box does. If this is a JVM problem
              >>then restarting it
              >>should help, right?
              >>
              >>Mike Reiche <[email protected]> wrote:
              >>
              >>
              >>> Sun's JVMs have problems...
              >>
              >>> 1) The JVM does not GC memory from the 'Method Area'
              >>(not the Java
              >>> Heap) of the JVM until it does a Full GC on the Java
              >>Heap.
              >>> The method area is used for things like java method
              >>executable
              >>> code. When a JSP is modified and reloaded, the old
              >>class is left
              >>> in the Method Area.
              >>
              >>> This means if you have something like -ms512m -mx512m,
              >>and your
              >>> heap never reaches 512MB, then the 'Method Area' will
              >>never get
              >>> GC'ed - no matter how many JSPs are loaded and reloaded
              >>- eventually
              >>> your JVM will use up all available memory and swap,
              >>and you will
              >>> get IOException.
              >>
              >>> Sun claims that this is not a bug.
              >>
              >>> 2) I have also noticed that if WLS does many, many concurrent
              >>JSP
              >>> compiles, the number of threads in the JVM goes way
              >>up (over 1,000)
              >>> and so does memory. The number of threads comes back
              >>down eventually,
              >>> but the memory doesn't. We have avoided this by pre-compiling
              >>> the JSPs.
              >>
              >>> Mike
              >>
              >>
              >>
              >>
              >>> Mike Williams <[email protected]> wrote:
              >>>>We have a site that includes about 600 JSPs.
              >>>>
              >>>>JSP re-compilation is turned on in production, to support
              >>>>content updates
              >>>>(JSPs are considered to be content, in this case). However,
              >>>>this is causing
              >>>>problems, as the JVM running weblogic grows significantly
              >>>>each time JSPs
              >>>>are updated. There has been suggestion that the JSP
              >>class-loaders
              >>>>are not
              >>>>being garbage-collected properly.
              >>>>
              >>>>The environment is WebLogic 5.1 SP6, running on Sun's
              >>>>JDK 1.2.2, on Solaris
              >>>>2.7.
              >>>>
              >>>>Has anyone else seen this problem before? Is there a
              >>fix,
              >>>>or a work-around?
              >>>>
              >>>>cheers,
              >>>>Mike Williams
              >>>>
              >>>>
              >>
              >>
              >>--
              >>Dimitri
              Dimitri
              

  • Maintaining data of view objects in cache memory for repeated usage

    Hi,
         We are developing an application which is having around 800 viewobjects that will be used as LOV in different screens. Therefore, it is decided to create a separate project for all such LOV view objects and keep the same in shared scope so that the data can be made availabe across the application.
         The application also communicates with different database schemas based on the logged-in county. For a particular user, LOV view object LovView1 should get the data fetched from Schema1 whereas for user2, the same LovView1 should get the data from Schema2.
         For this, we have created n number of ApplicationModules like AM1, AM2 etc in the project each one being connected to different database. A base application module also has been created and all the county specific AMs extend this base AM. Also all the LOV view object instances are included in this base AM so that they will be available in the county specific AMs also.The entire project is made as an ADF Library jar and this base AM is utilized by other projects for mapping the LOV by attaching the library.
         At runtime, whenever a particular viewobject is accessed, the findViewObject() method of the baseAM has been overridden and the logic is built in such a way to get the logged in user's county code from a session variable and based on the county, the corresponding AM is communicated with and the view object is returned.
         The view objects of the LOV project is used as LOV as well as for doing some other backend processes. In such cases, the view object is obtained and necessary filter conditions are appended to the view criteria and is executed to get the filtered rowset.
    Now, my questions are,
    1. Is it enough to create the jar for the LOVProject and access the view objects from the same baseAM across the application?
    2. I wish to keep all the data in cache memory to avoid repeated DB hits for all the LOV view objects. How it can be achieved? To be more precise, consider two users user1 and user2 logging into the application with different county. When user1 access a LOV viewobject for the first time, data needs to be fetched from the DB, kept in application scoped cache memory and return the rowset. On subsequent calls to the viewobject, the data needs to be retreived from the cache and not from the DB. When user2 also access the same LOV viewobject, the same logic as explained for user1 should happen. How can I achieve this? Actually my doubt is when user2 access, will the data pertaining to user1 remains available in cache? If not, how to make it retain the data in cache?
    3. I also wish to append a particular where condition to a viewobject irrespective of other considerations like logged in county, existing view criteria etc.. How can I do this? A separate thread for this requirement has been posted in the forum Including additional where clause conditions to view criteria dynamically
    Kindly give me your suggessions.
    Thanks in advance.
    Regards.

    Hi Vijay,
    regarding your questions:
    1. What is the difference between "TimesTen In-Memory Database" and
    "In-Memory Database Cache" in terms of features and licensing model?
    ==> Product has just been renamed and integrated better with the Oracle database - Times-Ten == In-Memory-Cache-Database
    2. Is "In-Memory Database Cache" option integrated with Oracle 10g
    installable or a separate installable (i.e. TimesTen installable with only
    cache feature)?
    ==> Seperate Installation
    3. Is "In-Memory Database Cache" option same as that of "TimesTen Cache
    Connect to Oracle" option in TimesTen In-Memory Database?
    ==> Please have a look here: http://www.oracle.com/technology/products/timesten/quickstart/cc_qs_index.html
    This explains the differences.
    4. After integrating "In-Memory Database Cache" option with Oracle 10g, data
    access will happen only through Oracle sqlplus or OCI calls. Am I right here
    in making this statement?
    ==> Please see above mentioned papers
    5. Is it possible to cache the result set of a join query in "In-Memory
    Database Cache"?
    ==> Again ... ;-)
    Kind regards
    Mike

  • JVM crashes with illegal Memory Access ..

    [JRockit] ERROR: The JVM has crashed. Writing crash information to C:\bea10.3\wlserver_10.3\samples\domains\wl_server\jrockit.3712.dump.
    ===== BEGIN DUMP =============================================================
    JRockit dump produced after 0 days, 00:13:27 on Mon Dec 07 20:06:05 2009
    * If you see this dump, please go to *
    * http://edocs.bea.com/jrockit/go2troubleshooting.html *
    * for troubleshooting information. *
    Additional information is available in:
    C:\bea10.3\wlserver_10.3\samples\domains\wl_server\jrockit.3712.dump
    C:\bea10.3\wlserver_10.3\samples\domains\wl_server\jrockit.3712.mdmp
    Error Message: Illegal memory access. [54]
    Exception Rec: EXCEPTION_ACCESS_VIOLATION (c0000005) at 0x00466F21 - memory at 0x00000000 could not be read.
    Minidump : Wrote mdmp. Size is 472MB
    SafeDllMode : -1
    Version : BEA JRockit(R) R27.6.0-50_o-100423-1.6.0_05-20080626-2105-windows-ia32
    GC Strategy : Mode: throughput. Currently using strategy: genparpar
    GC Status : OC is not running. Last finished OC was OC#2.
    : YC is not running. Last finished YC was YC#24.
    OC History : Strategy genparpar was used for OC#1 to OC#2.
    YC History : Ran 3 YCs before OC#1.
    : Ran 3 YCs before OC#2.
    : Ran 18 YCs since last OC.
    YC Promotion : Last YC successfully promoted all objects
    Heap : 0x00C00000 - 0x10C00000 (Size: 256 MB)
    Compaction : 0x00C00000 - 0x01C00000 (Current compaction type: internal)
    NurseryList : 0x00E57CF0 - 0x08132978
    KeepArea : 0x04693C88 - 0x06320918
    NurseryMarker: [ 0x04693C88,  0x06320918 ]
    CompRefs : References are 32-bit.
    CPU : Intel Core 2 SSE SSE2 SSE3 SSSE3 SSE4.1 EM64T
    Number CPUs : 2
    Tot Phys Mem : 2096984064 (1999 MB)
    OS version : Microsoft Windows XP version 5.1 Service Pack 3 (Build 2600) (32-bit)
    Thread System: Windows Threads
    Java locking : Lazy unlocking enabled (class banning) (transfer banning)
    State : JVM is running
    Command Line : -Xverify:all -Xms256m -Xmx512m -Xverify:none -da -Dplatform.home=C:\bea10.3\WLSERV~1.3 -Dwls.home=C:\bea10.3\WLSERV~1.3\server -Dweblogic.home=C:\bea10.3\WLSERV~1.3\server -Dweblogic.management.discover=true -Dwlw.iterativeDev= -Dwlw.testConsole= -Dwlw.logErrorsToConsole= -Dweblogic.ext.dirs=C:\bea10.3\patch_wlw1030\profiles\default\sysext_manifest_classpath;C:\bea10.3\patch_wls1030\profiles\default\sysext_manifest_classpath;C:\bea10.3\patch_cie660\profiles\default\sysext_manifest_classpath -Dweblogic.Name=examplesServer -Djava.security.policy=C:\bea10.3\WLSERV~1.3\server\lib\weblogic.policy -Dsun.java.launcher=SUN_STANDARD weblogic.Server
    java.home : C:\bea10.3\JROCKI~1\jre
    j.class.path : C:\bea10.3\wlserver_10.3\samples\server\examples\build\serverclasses;C:\bea10.3\patch_wlw1030\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\bea10.3\patch_wls1030\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\bea10.3\patch_cie660\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\bea10.3\JROCKI~1\lib\tools.jar;C:\bea10.3\WLSERV~1.3\server\lib\weblogic_sp.jar;C:\bea10.3\WLSERV~1.3\server\lib\weblogic.jar;C:\bea10.3\modules\features\weblogic.server.modules_10.3.0.0.jar;C:\bea10.3\WLSERV~1.3\server\lib\webservices.jar;C:\bea10.3\modules\ORGAPA~1.5/lib/ant-all.jar;C:\bea10.3\modules\NETSFA~1.0_1/lib/ant-contrib.jar;;C:\bea10.3\WLSERV~1.3\common\eval\pointbase\lib\pbembedded57.jar;C:\bea10.3\WLSERV~1.3\common\eval\pointbase\lib\pbclient57.jar;C:\bea10.3\WLSERV~1.3\server\lib\xqrl.jar;;C:\bea10.3\wlserver_10.3\server\lib\wlspy.jar;;
    j.lib.path : C:\bea10.3\JROCKI~1\bin;.;C:\WINDOWS\system32;C:\WINDOWS;C:\bea10.3\patch_wlw1030\profiles\default\native;C:\bea10.3\patch_wls1030\profiles\default\native;C:\bea10.3\patch_cie660\profiles\default\native;C:\bea10.3\WLSERV~1.3\server\native\win\32;C:\bea10.3\WLSERV~1.3\server\bin;C:\bea10.3\modules\ORGAPA~1.5\bin;C:\bea10.3\JROCKI~1\jre\bin;C:\bea10.3\JROCKI~1\bin;C:/Program Files/Java/jre1.6.0_02/bin/client;C:/Program Files/Java/jre1.6.0_02/bin;C:\Program Files\IBM\WebSphere MQ\Java\lib;C:\oracle\product\10.2.0\bin;C:\Program Files\Documentum\Shared;c:\windows\system32;c:\windows;c:\windows\system32\wbem;c:\program files\ntru cryptosystems\ntru tcg software stack\bin\;c:\program files\wave systems corp\gemalto\access client\v5\;c:\program files\intel\dmix;c:\program files\intel\wifi\bin\;c:\program files\common files\roxio shared\dllshared\;c:\program files\common files\roxio shared\9.0\dllshared\;c:\program files\utimaco\safeguard easy\;C:\Program Files\Windows Imaging\;c:\program files\java\jdk1.6.0_05\bin;;C:\bea10.3\wlserver_10.3\server\lib\wlspy.jar;C:\Program Files\IBM\WebSphere MQ\bin;C:\Program Files\IBM\WebSphere MQ\tools\c\samples\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Subversion\bin;C:\bea10.3\WLSERV~1.3\server\native\win\32\oci920_8
    JAVA_HOME : C:\bea10.3\JROCKI~1
    JAVAOPTIONS: <not set>
    PATH : C:\bea10.3\JROCKI~1\jre\bin;C:\bea10.3\patch_wlw1030\profiles\default\native;C:\bea10.3\patch_wls1030\profiles\default\native;C:\bea10.3\patch_cie660\profiles\default\native;C:\bea10.3\WLSERV~1.3\server\native\win\32;C:\bea10.3\WLSERV~1.3\server\bin;C:\bea10.3\modules\ORGAPA~1.5\bin;C:\bea10.3\JROCKI~1\jre\bin;C:\bea10.3\JROCKI~1\bin;C:/Program Files/Java/jre1.6.0_02/bin/client;C:/Program Files/Java/jre1.6.0_02/bin;C:\Program Files\IBM\WebSphere MQ\Java\lib;C:\oracle\product\10.2.0\bin;C:\Program Files\Documentum\Shared;c:\windows\system32;c:\windows;c:\windows\system32\wbem;c:\program files\ntru cryptosystems\ntru tcg software stack\bin\;c:\program files\wave systems corp\gemalto\access client\v5\;c:\program files\intel\dmix;c:\program files\intel\wifi\bin\;c:\program files\common files\roxio shared\dllshared\;c:\program files\common files\roxio shared\9.0\dllshared\;c:\program files\utimaco\safeguard easy\;C:\Program Files\Windows Imaging\;c:\program files\java\jdk1.6.0_05\bin;;C:\bea10.3\wlserver_10.3\server\lib\wlspy.jar;C:\Program Files\IBM\WebSphere MQ\bin;C:\Program Files\IBM\WebSphere MQ\tools\c\samples\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files\Subversion\bin;C:\bea10.3\WLSERV~1.3\server\native\win\32\oci920_8
    C Heap : Good; no memory allocations have failed
    StackOverFlow: 0 StackOverFlowErrors have occured
    OutOfMemory : 0 OutOfMemoryErrors have occured
    Registers (from ThreadContext: 0x319BD1FC / OS context: 0x319BD5F8):
    eax = 2b1cdf58 ecx = 31b647a8 edx = 00000000 ebx = 0000002d
    esp = 319bd8c4 ebp = 31b66400 esi = 00000000 edi = 00000001
    es = 00000023 cs = 0000001b ss = 00000023 ds = 00000023
    fs = 0000003b gs = 00000000
    eip = 00466f21 eflags = 00010202
    Stack:
    (* marks the word pointed to by the stack pointer)
    319bd8c4: 319bda40* 28ac5bdc 2d61e1c4 31b636f8 0000002c 31b66590
    319bd8dc: 00000000 00000001 00000001 00000001 31b66588 00000000
    319bd8f4: 0000002c 00000000 00000005 31b647a8 2d61e1c4 2d630700
    319bd90c: 00001df5 00462f77 28ac5bdc 31b636f8 319bdec8 319bdf04
    Code:
    (* marks the word pointed to by the instruction pointer)
    00466ef0: 08c8448d 28244489 89f8048d 8b142444 431c2444 c085f633
    00466f08: 00f9860f ff8b0000 54244c8b 8b34518b 4c8bb204 518b3c24
    00466f20: f20c8b2c* 1824548b 8bca0c8d 89142454 8b38244c 8928244c
    00466f38: 5489f11c b70f04f1 00014e88 b8b70f00 0000014a 44c7f92b
    Loaded modules:
    (* denotes the module causing the exception)
    00400000-00410fff C:\bea10.3\JROCKI~1\bin\java.exe
    7c900000-7c9b1fff C:\WINDOWS\system32\ntdll.dll
    7c800000-7c8f5fff C:\WINDOWS\system32\kernel32.dll
    77dd0000-77e6afff C:\WINDOWS\system32\ADVAPI32.dll
    77e70000-77f01fff C:\WINDOWS\system32\RPCRT4.dll
    77fe0000-77ff0fff C:\WINDOWS\system32\Secur32.dll
    77c10000-77c67fff C:\WINDOWS\system32\MSVCRT.dll
    7c340000-7c395fff C:\bea10.3\JROCKI~1\jre\bin\msvcr71.dll
    00420000-006c3fff *C:\bea10.3\JROCKI~1\jre\bin\jrockit\jvm.dll
    76b40000-76b6cfff C:\WINDOWS\system32\WINMM.dll
    77f10000-77f58fff C:\WINDOWS\system32\GDI32.dll
    7e410000-7e4a0fff C:\WINDOWS\system32\USER32.dll
    71ab0000-71ac6fff C:\WINDOWS\system32\WS2_32.dll
    71aa0000-71aa7fff C:\WINDOWS\system32\WS2HELP.dll
    76390000-763acfff C:\WINDOWS\system32\IMM32.DLL
    6d820000-6d82bfff C:\bea10.3\JROCKI~1\jre\bin\verify.dll
    6d3c0000-6d3defff C:\bea10.3\JROCKI~1\jre\bin\java.dll
    6d320000-6d327fff C:\bea10.3\JROCKI~1\jre\bin\hpi.dll
    6d860000-6d86efff C:\bea10.3\jrockit_160_05\jre\bin\zip.dll
    6d570000-6d578fff C:\bea10.3\jrockit_160_05\jre\bin\management.dll
    6d620000-6d632fff C:\bea10.3\jrockit_160_05\jre\bin\net.dll
    237a0000-237cffff C:\Program Files\F-Secure\FSPS\program\FSLSP.DLL
    237d0000-237e6fff c:\program files\f-secure\scanner-interface\fsgkiapi.dll
    71a50000-71a8efff C:\WINDOWS\system32\mswsock.dll
    662b0000-66307fff C:\WINDOWS\system32\hnetcfg.dll
    71a90000-71a97fff C:\WINDOWS\System32\wshtcpip.dll
    23ca0000-23cc6fff C:\WINDOWS\system32\DNSAPI.dll
    23cd0000-23cd7fff C:\WINDOWS\System32\winrnr.dll
    23ce0000-23d0bfff C:\WINDOWS\system32\WLDAP32.dll
    23d60000-23d65fff C:\WINDOWS\system32\rasadhlp.dll
    6d640000-6d648fff C:\bea10.3\jrockit_160_05\jre\bin\nio.dll
    68000000-68035fff C:\WINDOWS\system32\rsaenh.dll
    769c0000-76a73fff C:\WINDOWS\system32\USERENV.dll
    5b860000-5b8b4fff C:\WINDOWS\system32\netapi32.dll
    25c20000-25c2afff C:\bea10.3\jrockit_160_05\jre\bin\jmapi.dll
    25e30000-25e3dfff C:\bea10.3\wlserver_10.3\server\native\win\32\wlfileio2.dll
    26120000-26138fff C:\WINDOWS\system32\iphlpapi.dll
    26150000-26167fff C:\WINDOWS\system32\MPRAPI.dll
    77cc0000-77cf1fff C:\WINDOWS\system32\ACTIVEDS.dll
    26170000-26194fff C:\WINDOWS\system32\adsldpc.dll
    76b20000-76b30fff C:\WINDOWS\system32\ATL.DLL
    774e0000-7761cfff C:\WINDOWS\system32\ole32.dll
    261a0000-2622afff C:\WINDOWS\system32\OLEAUT32.dll
    26230000-2623dfff C:\WINDOWS\system32\rtutils.dll
    71bf0000-71c02fff C:\WINDOWS\system32\SAMLIB.dll
    77920000-77a12fff C:\WINDOWS\system32\SETUPAPI.dll
    26280000-26284fff C:\bea10.3\wlserver_10.3\server\native\win\32\wlntio.dll
    6d800000-6d807fff C:\bea10.3\jrockit_160_05\jre\bin\sunmscapi.dll
    77a80000-77b14fff C:\WINDOWS\system32\CRYPT32.dll
    77b20000-77b31fff C:\WINDOWS\system32\MSASN1.dll
    76bf0000-76bfafff C:\WINDOWS\system32\psapi.dll
    6d7c0000-6d7c5fff C:\bea10.3\jrockit_160_05\jre\bin\rmi.dll
    31c20000-31d32fff C:\bea10.3\JROCKI~1\jre\bin\dbghelp.dll
    "[ACTIVE] ExecuteThread: '18' fo" id=54 idx=0xc8 tid=5456 lastJavaFrame=0x319BDEF4
    Stack 0: start=0x31980000, end=0x319C0000, guards=0x31983000 (ok), forbidden=0x31981000
    Thread Stack Trace:
    at dtCreateDTable+1025(dispatchtables.c:298+7)@0x00466F21
    at defineClass+167(defineclass.c:110+7)@0x00462F77
    at lib_define_class+34(library.c:516+16)@0x005164C2
    at libDefineClass+39(library.c:576+38)@0x00516707
    at libDefineClass2+58(library.c:597+34)@0x0051685A
    at JVM_DefineClassWithSource+43(jvmclass.c:59+43)@0x004E609B
    at Javajava_lang_ClassLoader_defineClass1@32+235()@0x6D3C15DA
    -- Java stack --
    at java/lang/ClassLoader.defineClass1(Ljava/lang/String;[BIILjava/security/ProtectionDomain;Ljava/lang/String;)Ljava/lang/Class;(Native Method)
        at java/lang/ClassLoader.defineClass(ClassLoader.java:620)
        at java/security/SecureClassLoader.defineClass(SecureClassLoader.java:124)
        at weblogic/utils/classloaders/GenericClassLoader.defineClass(GenericClassLoader.java:335)
        at weblogic/utils/classloaders/GenericClassLoader.findLocalClass(GenericClassLoader.java:288)
        ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E7FCE78[recursive]
    at weblogic/utils/classloaders/GenericClassLoader.findClass(GenericClassLoader.java:256)
    at java/lang/ClassLoader.loadClass(ClassLoader.java:306)
    ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E7FCE78[recursive]
    at java/lang/ClassLoader.loadClass(ClassLoader.java:251)
    at weblogic/utils/classloaders/GenericClassLoader.loadClass(GenericClassLoader.java:176)
    at jrockit/vm/Classes.loadClassInternal(Classes.java:75)
    ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E7FCE78[recursive]
    at jrockit/vm/RNI.c2java(IIIII)V(Native Method)
    at java/lang/ClassLoader.defineClass1(Ljava/lang/String;[BIILjava/security/ProtectionDomain;Ljava/lang/String;)Ljava/lang/Class;(Native Method)
        at java/lang/ClassLoader.defineClass(ClassLoader.java:620)
        at java/security/SecureClassLoader.defineClass(SecureClassLoader.java:124)
        at weblogic/utils/classloaders/GenericClassLoader.defineClass(GenericClassLoader.java:335)
        at weblogic/utils/classloaders/GenericClassLoader.findLocalClass(GenericClassLoader.java:288)
        ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E7FCE78[recursive]
    at weblogic/utils/classloaders/GenericClassLoader.findClass(GenericClassLoader.java:256)
    at java/lang/ClassLoader.loadClass(ClassLoader.java:306)
    ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E7FCE78[recursive]
    at java/lang/ClassLoader.loadClass(ClassLoader.java:251)
    at weblogic/utils/classloaders/GenericClassLoader.loadClass(GenericClassLoader.java:176)
    at jrockit/vm/Classes.loadClassInternal(Classes.java:75)
    ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E7FCE78[biased lock]
    at jrockit/vm/RNI.c2java(IIIII)V(Native Method)
    at jrockit/vm/Classes.forName0(Ljava/lang/String;ZLjava/lang/ClassLoader;)Ljava/lang/Class;(Native Method)
    at java/lang/Class.forName0(Ljava/lang/String;ZLjava/lang/ClassLoader;)Ljava/lang/Class;(Native Method)
    at java/lang/Class.forName(Class.java:247)
    at sun/reflect/generics/factory/CoreReflectionFactory.makeNamedType(CoreReflectionFactory.java:95)
    at sun/reflect/generics/visitor/Reifier.visitClassTypeSignature(Reifier.java:107)
    at sun/reflect/generics/tree/ClassTypeSignature.accept(ClassTypeSignature.java:31)
    at sun/reflect/annotation/AnnotationParser.parseSig(AnnotationParser.java:370)
    at sun/reflect/annotation/AnnotationParser.parseClassValue(AnnotationParser.java:351)
    at sun/reflect/annotation/AnnotationParser.parseMemberValue(AnnotationParser.java:280)
    at sun/reflect/annotation/AnnotationParser.parseAnnotation(AnnotationParser.java:222)
    at sun/reflect/annotation/AnnotationParser.parseAnnotations2(AnnotationParser.java:69)
    at sun/reflect/annotation/AnnotationParser.parseAnnotations(AnnotationParser.java:52)
    at java/lang/reflect/Field.declaredAnnotations(Field.java:1016)
    ^-- Holding lock: java/lang/reflect/Field@0x032BFE90[biased lock]
    at java/lang/reflect/Field.getDeclaredAnnotations(Field.java:1009)
    at java/lang/reflect/AccessibleObject.getAnnotations(AccessibleObject.java:175)
    at org/apache/openjpa/lib/util/J2DoPriv5Helper$1.run(J2DoPriv5Helper.java:51)
    at jrockit/vm/AccessController.doPrivileged(AccessController.java:233)
    at jrockit/vm/AccessController.doPrivileged(AccessController.java:241)
    at org/apache/openjpa/persistence/PersistenceMetaDataDefaults.annotated(PersistenceMetaDataDefaults.java:293)
    at org/apache/openjpa/persistence/PersistenceMetaDataDefaults.getAccessType(PersistenceMetaDataDefaults.java:262)
    at org/apache/openjpa/persistence/PersistenceMetaDataDefaults.getAccessType(PersistenceMetaDataDefaults.java:269)
    at org/apache/openjpa/persistence/PersistenceMetaDataDefaults.getAccessType(PersistenceMetaDataDefaults.java:250)
    at org/apache/openjpa/meta/AbstractMetaDataDefaults.populate(AbstractMetaDataDefaults.java:155)
    at org/apache/openjpa/persistence/PersistenceMetaDataDefaults.populate(PersistenceMetaDataDefaults.java:227)
    at org/apache/openjpa/meta/MetaDataRepository.addMetaData(MetaDataRepository.java:794)
    at org/apache/openjpa/meta/MetaDataRepository.addMetaData(MetaDataRepository.java:780)
    at org/apache/openjpa/persistence/AnnotationPersistenceMetaDataParser.getMetaData(AnnotationPersistenceMetaDataParser.java:657)
    at org/apache/openjpa/persistence/AnnotationPersistenceMetaDataParser.parseClassAnnotations(AnnotationPersistenceMetaDataParser.java:480)
    at org/apache/openjpa/persistence/AnnotationPersistenceMetaDataParser.parse(AnnotationPersistenceMetaDataParser.java:352)
    at org/apache/openjpa/persistence/PersistenceMetaDataFactory.load(PersistenceMetaDataFactory.java:229)
    at org/apache/openjpa/meta/MetaDataRepository.getMetaDataInternal(MetaDataRepository.java:474)
    at org/apache/openjpa/meta/MetaDataRepository.getMetaData(MetaDataRepository.java:294)
    ^-- Holding lock: org/apache/openjpa/meta/MetaDataRepository@0x0E7FCDF0[biased lock]
    at org/apache/openjpa/enhance/PCEnhancer.<init>(PCEnhancer.java:248)
    at org/apache/openjpa/enhance/PCEnhancer.<init>(PCEnhancer.java:219)
    at org/apache/openjpa/enhance/PCClassFileTransformer.transform0(PCClassFileTransformer.java:139)
    at org/apache/openjpa/enhance/PCClassFileTransformer.transform(PCClassFileTransformer.java:120)
    at org/apache/openjpa/persistence/PersistenceProviderImpl$ClassTransformerImpl.transform(PersistenceProviderImpl.java:210)
    at weblogic/deployment/PersistenceUnitInfoImpl$ClassPreProcessorImpl.preProcess(PersistenceUnitInfoImpl.java:497)
    at weblogic/utils/classloaders/ClassPreProcessor$ClassPreProcessorSupport.preProcess(ClassPreProcessor.java:95)
    at weblogic/utils/classloaders/GenericClassLoader.doPreProcess(GenericClassLoader.java:348)
    at weblogic/utils/classloaders/GenericClassLoader.defineClass(GenericClassLoader.java:329)
    at weblogic/utils/classloaders/GenericClassLoader.findLocalClass(GenericClassLoader.java:288)
    ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E093168[recursive]
    at weblogic/utils/classloaders/GenericClassLoader.findClass(GenericClassLoader.java:256)
    at java/lang/ClassLoader.loadClass(ClassLoader.java:306)
    ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E093168[recursive]
    at java/lang/ClassLoader.loadClass(ClassLoader.java:251)
    at weblogic/utils/classloaders/GenericClassLoader.loadClass(GenericClassLoader.java:176)
    at jrockit/vm/Classes.loadClassInternal(Classes.java:75)
    ^-- Holding lock: weblogic/utils/classloaders/GenericClassLoader@0x0E093168[biased lock]
    at jrockit/vm/RNI.c2java(IIIII)V(Native Method)
    at jrockit/vm/Classes.forName0(Ljava/lang/String;ZLjava/lang/ClassLoader;)Ljava/lang/Class;(Native Method)
    at java/lang/Class.forName0(Ljava/lang/String;ZLjava/lang/ClassLoader;)Ljava/lang/Class;(Native Method)
    at java/lang/Class.forName(Class.java:247)
    at sun/reflect/generics/factory/CoreReflectionFactory.makeNamedType(CoreReflectionFactory.java:95)
    at sun/reflect/generics/visitor/Reifier.visitClassTypeSignature(Reifier.java:107)
    at sun/reflect/generics/tree/ClassTypeSignature.accept(ClassTypeSignature.java:31)
    at sun/reflect/generics/visitor/Reifier.reifyTypeArguments(Reifier.java:50)
    at sun/reflect/generics/visitor/Reifier.visitClassTypeSignature(Reifier.java:120)
    at sun/reflect/generics/tree/ClassTypeSignature.accept(ClassTypeSignature.java:31)
    at sun/reflect/generics/repository/MethodRepository.getReturnType(MethodRepository.java:50)
    at java/lang/reflect/Method.getGenericReturnType(Method.java:236)
    at java/lang/reflect/Method.toGenericString(Method.java:482)
    at weblogic/ejb/container/ejbc/EjbCodeGenerator.setMethod(EjbCodeGenerator.java:3511)
    at weblogic/ejb/container/ejbc/EjbCodeGenerator.remote_interface_methods(EjbCodeGenerator.java:2698)
    at weblogic/ejb/container/ejbc/EjbCodeGenerator.remote_business_interface_methods(EjbCodeGenerator.java:2685)
    at jrockit/vm/RNI.c2java(IIIII)V(Native Method)
    at jrockit/vm/Reflect.invokeMethod(Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;(Native Method)
        at sun/reflect/NativeMethodAccessorImpl.invoke0(Ljava/lang/reflect/Method;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;(Native Method)
        at sun/reflect/NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun/reflect/DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java/lang/reflect/Method.invoke(Method.java:597)
        at weblogic/utils/compiler/CodeGenerator.processAt(CodeGenerator.java:688)
        at weblogic/utils/compiler/CodeGenerator.parse(CodeGenerator.java:582)
        at weblogic/utils/compiler/CodeGenerator.parse(CodeGenerator.java:539)
        at weblogic/utils/compiler/CodeGenerator.generateCode(CodeGenerator.java:341)
        at weblogic/utils/compiler/CodeGenerator.generate(CodeGenerator.java:242)
        at weblogic/utils/compiler/CodeGenerator.generate(CodeGenerator.java:197)
        at weblogic/ejb/container/ejbc/EJBCompiler.generateSourcesFromBeanInfo(EJBCompiler.java:1019)
        at weblogic/ejb/container/ejbc/EJBCompiler.doCompile(EJBCompiler.java:299)
        at weblogic/ejb/container/ejbc/EJBCompiler.compileEJB(EJBCompiler.java:552)
        at weblogic/ejb/container/ejbc/EJBCompiler.compileEJB(EJBCompiler.java:519)
        at weblogic/ejb/container/deployer/EJBDeployer.runEJBC(EJBDeployer.java:393)
        at weblogic/ejb/container/deployer/EJBDeployer.compileJar(EJBDeployer.java:715)
        at weblogic/ejb/container/deployer/EJBDeployer.compileIfNecessary(EJBDeployer.java:618)
        at weblogic/ejb/container/deployer/EJBDeployer.prepare(EJBDeployer.java:1154)
        at weblogic/ejb/container/deployer/EJBModule.prepare(EJBModule.java:425)
    Stopping PointBase server...
    PointBase server stopped.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                &n

    Looks like a JVM crash during classloading. Have no idea what might cause it. I suggest you try upgrading to a more recent JRockit version (google for "download jrockit" and get the latest JRMC version you can find, it includes JRockit R27.6.5). If that doesn't help, open a ticket with Oracle Support and provide the text dump and the minidump for analysis.
    Henrik

  • Access jar file from in-memory classes...

    I have some classes that I compile to memory and everything works fine until one class that must access some external jar files. I have been unable to access those jar files from disk after trying every suggestion using URLClassLoader. I even tried someone's example to hack the SystemClassLoader which properly adds the jar file paths, but still they can't be seen. The only way it works is if I put the files in the jdk/jre/lib/ext directory. Then everything works fine. There must be a way to load the jar files in memory as well as the class files so they can be accessible. Has anyone done anything like this? Is it possible? Even though the class files are in memory, why would the jar files not be seen even when they are added to the same URLClassLoader's URL's. Thanks.

    Sorry that wasn't clear. What I mean is that the classes are compiled to byte code directly to memory and no physical .class file is created. Yes, I'm using my own ClassLoader that extends URLClassLoader and I'm setting the parent to ClassLoader.getSystemClassLoader(). I also should mention that I'm doing this inside a Netbeans module that is part of a Netbeans Platform application. I don't know why that should matter though, since I'm trying to do everything in memory without creating the physical files. Thanks.

  • Writting a ClassLoader

    I'm trying to write a ClassLoader that, when trying to load a class, looks for it in a special directory if the normal way doesn't find it.
    I've overriden the findClass method to do the job. It is supposed that the findClass method will call it if the parent classloaders could not load the class.
    The I have write a wrapper to instantiate my ClassLoader and ask it to load the main class of any application, using reflection to get the main method.
    My problem is this: If the main class of the application is not found in the classpath, the findClass method is called and everything seems to work fine. But if the main class is in the classpath, and other classes are not, my findClass method is never called and I get a NoClassDefFound error.
    Does anyone know why the findClass method is not called? Why do I receive a NoClassDefFound error instead of a ClassNotFound exception?
    Any clue welcome!

    I wrote this somewhere once... some people seemed to find it helpful....
    Back to the original question. You want to "unload" a class or set of classes from the VM. Alright, first we have to understand how classes are identified in the VM. A classes "Primary Key" if you will, is its fully qualified name, here it come.... AND a reference to the class loader that loaded it.
    So how do we use this information to unload and load some "plugin". Well we know we need to make our own classloader. You can either make your own custom extension, or you can use something like the URL classloader. Next we need to construct this classloader with the current classloader as it's parent. The current classloader might be the bootstrap, or it might be something else (Java Web Start)... This makes using not yet loaded classes in the "normal" classpath possible because the parent will find them. Looking closely we see a problem... If the "plugin" is in the classpath then the parent will just load it. Yeah, it will, so don't put it in the classpath. That's what the URL part of the URLClassloader is for. After all this, we can reflectively load our "plugin" which is located off of the classpath, with our custom classloader.
    Now, on to reloading. When a classloader, or class gets GCed has no impact at all on these methods. There could be a gig of classes in memory. If they didn't get loaded by classloader reference I'm holding, I don't care. Here's the idea of the reload. You create a new classloader, and then reflectively invoke the methods and classes you needed all over again. This causes them to be read into the VM again, because their "Primary Key" is different. You need to remember this though, and make sure your using the right classloader to get these classes.
    This does work. I have implemented it. I have a piece of software which generates java source code, compiles it, then runs it by a reflective invokation so I can control it. When the user changes something, I re-generate, re-compile, and reload the classes and run the new ones.
    enjoy

  • Application scoped objects in a cluster

    Hi -
              Will weblogic clustering provide failover for Application scoped
              objects (in the ServletContext)? I've read through most of the
              documentation, and it doesn't mention anything. Also, the servlet 2.3
              spec says
              "Context attributes are local to the VM in which they were created.
              This prevents
              ServletContext attributes from being a shared memory store in a
              distributed
              container. When information needs to be shared between servlets
              running in a
              distributed environment, the information should be placed into a
              session (See
              Chapter SRV.7, &#8220;Sessions&#8221;), stored in a database, or set
              in an Enterprise
              JavaBeans TM component." (Section 3.4)
              However, it doesn't mention anything about failover.
              We have lots of application scoped objects that will need to failover
              somehow - anyone have experience with this?
              Thanks,
              Scott
              

    Hi Scott,
              The application scoped objects (ServletContext) are per Web Container as
              explained in the spec. When the server hosting that Web Container dies, so
              too do the objects in the ServletContext.
              If you are looking something like ServletContext that is replicated across
              the cluster and supports failover, you should check out our Coherence
              product at http://www.tangosol.com/ -- that is exactly what it does.
              Peace,
              Cameron Purdy
              Tangosol Inc.
              Tangosol Coherence: Clustered Coherent Cache for J2EE
              Information at http://www.tangosol.com/
              "Scott Gilpin" <[email protected]> wrote in message
              news:[email protected]...
              > Hi -
              >
              > Will weblogic clustering provide failover for Application scoped
              > objects (in the ServletContext)? I've read through most of the
              > documentation, and it doesn't mention anything. Also, the servlet 2.3
              > spec says
              >
              > "Context attributes are local to the VM in which they were created.
              > This prevents
              > ServletContext attributes from being a shared memory store in a
              > distributed
              > container. When information needs to be shared between servlets
              > running in a
              > distributed environment, the information should be placed into a
              > session (See
              > Chapter SRV.7, &#8220;Sessions&#8221;), stored in a database, or set
              > in an Enterprise
              > JavaBeans TM component." (Section 3.4)
              >
              > However, it doesn't mention anything about failover.
              >
              > We have lots of application scoped objects that will need to failover
              > somehow - anyone have experience with this?
              >
              > Thanks,
              > Scott
              

  • Release memory for nested top-level classes

    Hello experts.
    I have a top-level class which consists of several static methods. Inside such a method I create several new instances of a nested top-level class inside my original class. Later I want to release one of these instances i.e. destroy instance and free memory. How can I do that?
    Thanks.

    sure, but I do not see any references to this nested top-level class. With "Releasing" I mean something like directly assigning a NULL value to the nested top-level clas in order to enable GC.
    But as I said there are no references and while monitoring the memory I see that the GC does not collect some memory. (I know that GC is not reliable, but after ten attempts of this scenario the memory allocation is equal the whole time).
    I guess the GC does not work with classes, but the classloader. But how can I control releasing memory in this scenario?
    Any further hints?

  • Please help with Classloader

    BufferedWriter write = new BufferedWriter(new FileWriter("file100.txt"));
    write.write("testttttttttttttttt");
    write.close();
    File f1 = new File("file100.txt");
    System.out.println(f1.exists()); --- this returns true
    System.out.println(ClassLoader.getSystemResource("file100.txt").toString()); -- this returns NullPointerException, why??
    also
    File f = new File("file1.txt");
    System.out.println(f.exists()); -- returns false, but file1.txt is in the same directory as file100.txt, the only difference is it wasn't created in the program, it's already there
    Please help! thank you!

    System.out.println(ClassLoader.getSystemResource("file1
    0.txt").toString()); -- this returns
    NullPointerException, why??The ClassLoader should be used to load java classes to memory, since file100.txt isn't a java class getSystemResource . To read a File use FileReader or FileInputStream.
    >
    also
    File f = new File("file1.txt");
    System.out.println(f.exists()); -- returns false,
    se, but file1.txt is in the same directory as
    file100.txt, the only difference is it wasn't created
    in the program, it's already thereIs that the directory the program was started from? That wil most likely be the current directory is you don't specify a path.

Maybe you are looking for

  • Displaying text in local web browser

    Hi, Been looking at a web forwarding program that accepts a GET request from a browser and goes off and gets the page from the remote server and then needs to feed that page back to the browser. I've got as far as getting the page back from the remot

  • Temp files greater than 2GB

    While running an OBIEE report, I receive the following error: State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 46073] Operation 'stat()' on file '/u02/OracleBIData/tmp/nQS_28056_15671_7

  • Cleaning spool requests - report RSPO1041

    Hi experts, We're using SRM 5.5 and we've scheduled the reports - BBP_GET_STATUS_2 ( every 2 minutes) - CLEAN_REQREQ_UP As a consequence, in the SPOOL we are having many requests. In order to delete the spool requests, we have one job for the report

  • Shadow slider banding artifacts in PV2012

    I've been pixel peeping the same images I have uploaded in this post (it is still available for download) and found some artiafcts. Note the banding in the shadow under the ski tip:                         Click the image to view at 100%. I've been d

  • How to use adobe 5.0 on windows 7 to install 2 upgrades.

    how to use adobe 5.0 on windows 7 to install 2 upgrades.