Does return value of Local EJB need to be serializable?

Hi,
I know It's a bit lazy of me not looking this up in the specs, but I'll give it a go anyway. Does the return value of a Local EJB need to be a serializable object? For my app it would be very convenient to return a org.w3c.dom.Document.
Kind Regards,
Rune Bj�rnstad.

If you use LocalEJB, all params addresses are referencies, so you needn't use serializable interface.

Similar Messages

  • Dynamic popup does return value from popup window

    have to create a page , with dynamic Popup using query. I am using APEX_ITEM.POPUP_FROM_QUERY(). Dynamic popup is generated, i can able to open the popup, when i click the link of the generated records. It does not return the value.
    I feel that , it's like your error.
    could you please help me ou.t

    I also have similar kind of problem.
    1. How can I open new window to a particluar URL on a button click event? I know in line, we have target attribute.
    2. How can I pass the child window values to the parent
    3. How can I refresh the parent window or parent page to to show the changed values in the child window and ofcourse close the child.
    Any help on this will be appreciated.
    Thanks
    Rsaj

  • Query to table in Database Link returns value from local table

    Hi
    I made a databaselink (Create database link db_a.world connect to db_a identified by <user> using 'db_a.world')
    Then I query a table, connected as a user in db_b.world (this is our developer database - identical to db_a): Select count(*) from table@db_a.world.
    When I get the result - it comes from the database I am logged in to (db_b)! - This is easy to check, because when I run select count(*) from table - it shows the same number. When I connect to the remote database, the same query shows another (correct) number.
    When I created the database link, Oracle demanded a loopback clause. Why is that, and can this be the reason for the strange behaviour?
    Thanx
    Anders
    Narvik, Norway

    Hi Anders,
    A loopback database link is when you want to test connecting to the same database as say a different user. It can be used for testing purposes. Creating a database link doesn't require a loopback clause. The reason why you are getting the same row count as db_b.world because db_a.world has been created as a loopback link.
    In the example you have Create database link db_a.world connect to db_a identified by <user> using 'db_a.world' , the clause after 'connect to' is meant to be the username and the clause after 'identified by' is meant to be the password.
    So, create a regular database link like this:
    create database link db_a_link connect to <user> identified by <passwd> using <service name>
    You shouldn't get an error message that the loopback clause has to be specified. Then try querying and hopefully it will work.
    -Raj

  • Oralce Store Procedure not returning values in out parameters

    I am goig to execute an oracle store procedure using C# through through ODP.NET. The store procedure executes succsfully but it does not return any value in the out parameter.
    When I execute the same store procedure with the same input parameteres from within SQL*Plus. It does return values.
    This is to be clearify here that in the oracle store procedure the data type for the out parameter is number and in the c# the variavle that will hold its value is Integer. I also tried using Long on the C# side but it is still not working. After the successfull execution of the store procedure the C# variable contains nulll value.

    I am goig to execute an oracle store procedure using C# through through ODP.NET. The store procedure executes succsfully but it does not return any value in the out parameter.
    When I execute the same store procedure with the same input parameteres from within SQL*Plus. It does return values.
    This is to be clearify here that in the oracle store procedure the data type for the out parameter is number and in the c# the variavle that will hold its value is Integer. I also tried using Long on the C# side but it is still not working. After the successfull execution of the store procedure the C# variable contains nulll value.

  • LOV does not return value to the base page sometimes

    Hi,
    I have created messageLOV type items. These LOVs do return value to the base page usually. We have a user in Uruguay who is trying to use the page which has the LOVs. He says the LOV takes a long time to return to the main page after he clicks on quick select and also the value does not get populated in the main page.
    We have not been facing any such problem here in India. The LOV has been tested rigorously with no issues as such.
    Can you please suggest a reason why such a problem is occuring? Expecting your replies soon
    Thanks,
    Priya

    Thiyaga, did you read the devguide or the tutorial ?
    Can you please give me the inputs about the creation of LOV and it requires how many lov mappings as mandatory?
    This is there in the devguideHow to identify the mapping fields of an LOV which is already existing in the base page to reproduce in a similar way and need to do a customization on top of it ?
    Open the page XML and you can find the LOV mappings.Tapash

  • Why does EJB needs two interface???

    Hi All,
    This has been asked by many ppl and many of you might be having
    the correct answer for it. Please tell me....
    Why does EJB needs two interface (Home and Remote Interface)?. Why not one?
    Thanx to all...
    Regards
    GoodieGuy

    Hi Goodie ,
    Its good question and its a very valid one , one has to have doubt
    why two , why not one ..
    Here the answer goes ..
    First of all you need to understand that its a distributed computing technique ie I mean lot of people will be accessing the bean at the same time , right ? OK , you cann't access the bean directly.
    and lastly the stateless and entity beans do instance pooling.
    The very purpose of having two interfaces is
    1) To differnentiate the bussiness logic and life cycle methods .
    2) The home interface inititates life cycle methods like creation , destruction etc .
    3) There are lot of beans in the container , and through home you are
    creating the instance or accessing one of them .
    4) Once you have home object using it we get the remote object ie the instance of the bean that you want to access if stateless any bean can be called , if statefull depending upon the parameter in create method that respective bean is created and invoked .
    In ejb 1.0 and 1.1 even though the bean and the client are in same jvm its assumed that they are remote and in 2.0 Ver we have local this is to avoid network traffic .
    Hope you have got the answer , but if u still need clarification
    read EBRoman book first and second chapters thoroughly and then proceed
    a head.
    Bye
    Mahesh L.
    ============

  • Received ipad2 synced to itunes and uploaded my backup, now I find out it does not have WiFi 3G and need to return it, is there a way of getting all of my data off the ipad2?

    Received ipad2, synced to itunes and uploaded my backup from my Ipad, now I find out that it does not have Wi-Fi+3G, need to return it, is there a way to get my data off the ipad2 so I can return it?

    if you mean restore it to factory default then you can choose that while having it connected to the computer and using itunes

  • Returning cloned objects from EJB Local Interfaces

    We'd like to let our WAS 5/J2EE container manage our transactions/unit of work. However, we don't want to have our objects serialized, so we intend to use LocalInterfaces. Additionally, we want to return value objects that support Toplink indirection such that we are not returning the actual cache object but instead a clone.Our question is, how do we return a cloned object that supports indirection from Toplink that we can later do a deepMergeClone on in an explicit update method?

    Additional Information on the first post:
    The pattern we've been testing is as follows:
    1. We set up LocalInterfaces on our EJB's
    2. The EJB Getters are using acquireNonSynchronizedUnitOfWork() to get a NON-JTS transaction to perform a readQuery. This results in a Cloned Bis object being generated. We then release the UOW and return the object.
    3. The Returned Biz object Getters are using Indirection (probably using the released non-synchronized UOW).
    4. The pattern for UPDATE is that we allow the Web Container code (servlet) to change the Cloned Biz Object, they then submit the CLONED and changed object to an EJB update() method where we use getClientSession().getActiveUnitOfWork() to link to the JTS transaction and perform a uow.deepMergeClone(bizObjectClone);
    We are trying to use the pattern for the following reasons:
    1. Isolation of the Cache to upper layers
    2. Transaction Boundry is the EJB Container
    3. We understand that there is a performance overhead with CLoned Biz Objects but this more mirrors the ValueObject Pattern then anything else we've tried.
    BIG Question:
    1. Is this a supported TopLink Pattern?
    2. If its not supported, can it be?
    3. Do you have any other suggested patterns?

  • WB_RT_GET_JOB_METRICS does not return values

    DB v 10.2.0.2
    OWB repository/client v 10.2.0.3
    A DB function has a call to the Control Center transformation WB_RT_GET_JOB_METRICS to extract and preserve the metadata of number of records inserted/updated/deleted in a DB table.
    ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    1.
    The control center transformation WB_RT_GET_JOB_METRICS does not return any values when used under the Post-Mapping Process(mapped to the DB function describe above) in a Map.
    The input parameter ;Audit Id' to the Map is passed from a calling Process Flow. The following query is used to retrieve the Audit Id of the Map.,
    SELECT execution_audit_id
    INTO l_audit_id
    FROM ALL_RT_AUDIT_EXECUTIONS
    WHERE parent_execution_audit_id = P_AUDIT_ID;
    And the retrieve l_audit_id is passed to the WB_RT_GET_JOB_METRICS transformation to extract the number of records inserted/deleted/updated with the execution of the map.
    Gurus, please advice if the approach is appropriate to retrieve the number of records inserted/deleted/updated by the execution of the map. If not, any alternate method.
    +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    2. The control center transformation WB_RT_GET_JOB_METRICS returns values when used in a standalone pl/sql block with the appropriate audit_id.
    Is this because the metadata for the Map execution is complete, whereas in the earlier attempt, the transformation is called within the map using the Post-Mapping process.
    +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    3. Since the option 1 did not return any value, tried other option of calling/executing a transformation(call the the DB function mentioned earlier) after the Map activity is successful in a ProcessFlow. Here, the transformation does not seem to be executing, any tips of correcting this issue.
    Request the forum for some helpful tips to resolve the problem. TiA (Thanks in Advance) for the response.
    Message was edited by:
    user599655

    In a process flow, passed the pseudo variable to a transformation to run the WB_RT_GET_JOB_METRICS after the map execution. I am not sure if this is the best solution, but it worked for me.
    Still trying to figure how to use the pre-defined transformation when working on expression.
    Thanks.

  • LOV query is invalid, a display and a return value are needed

    hello - i am having this issue and can't get around this when creating a popup LOV based on sql.
    below is LOV query. as you see the view has only two columns. I tried various ways by giving alias to columns in query but nothing works. What did I miss here?
    select description,inventory_item_id from xx_apex_inv_v
    1 error has occurred
    LOV query is invalid, a display and a return value are needed, the column names need to be different. If your query contains an in-line query, the first FROM clause in the SQL statement must not belong to the in-line query.

    Did you try it like this?
    select description d, inventory_item_id v from xx_apex_inv_v

  • Select List with Submit : a display and a return value are needed...error

    Hi,
    Why the next SELECT returns error in Select list with submit ?
    List of values definition:
    SELECT b.nom nom_bannniere,
    b.no_banniere no_bann
    FROM banniere@my_source b
    WHERE b.statut = 0
    ORDER BY nom_bannniere;
    1 error has occurred
    * LOV query is invalid, a display and a return value are needed, the column names need to be different. If your query contains an in-line query, the first FROM clause in the SQL statement must not belong to the in-line query.

    gfrancoeur,
    Try this SQL:
    SELECT b.nom d,
    b.no_banniere r
    FROM banniere@my_source b
    WHERE b.statut = 0
    ORDER BY 1Thanks,
    - Scott -

  • Multiple return values (Bug-ID 4222792)

    I had exactly the same request for the same 3 reasons: strong type safety and code correctness verification at compile-time, code readability and ease of mantenance, performance.
    Here is what Sun replied to me:
    Autoboxing and varargs are provided as part of
    JSRs 14 and 201
    http://jcp.org/en/jsr/detail?id=14
    http://jcp.org/en/jsr/detail?id=201
    See also:
    http://forum.java.sun.com/forum.jsp?forum=316
    http://developer.java.sun.com/developer/earlyAccess/adding_generics/index.html
    Multiple return values is covered by Bug-ID 4222792
    Typically this is done by returning an array.
    http://developer.java.sun.com/developer/bugParade/bugs/4222792.html
    That's exactly the problem: we dynamically create instances of array objects that would better fit well within the operand stack without stressing the garbage collector with temporary Array object instances (and with their backing store: 2 separate allocations that need to be recycled when it is clearly a pollution that the operand stack would clean up more efficiently)
    If you would like to engage in a discussion with the Java Language developers, the Generics forum would be a better place:
    http://forum.java.sun.com/forum.jsp?forum=316
    I know that (my report was already refering to the JSR for language extension) Generics is not what I was refering to (even if a generic could handle multiple return values, it would still be an allocated Object
    instance to pack them, i.e. just less convenient than using a static class for type safety.
    The most common case of multiple return values involve values that have known static datatypes and that should be checked with strong typesafety.
    The simple case that involves returning two ints then will require at least two object instances and will not solve the garbage collection overhead.
    Using a array of variable objects is exactly similar, except that it requires two instances for the components and one instance for the generic array container. Using extra method parameters with Integer, Byte, ... boxing objects is more efficient, but for now the only practical solution (which causes the least pollution in the VM allocator and garbage collector) is to use a custom class to store the return values in a single instance.
    This is not natural, and needlessly complexifies many interfaces.
    So to avoid this pollution, some solutions are used such as packing two ints into a long and returning a long, depacking the long after return (not quite clean but still much faster at run-time for methods that need to be used with high frequencies within the application. In some case, the only way to cut down the overhead is to inline methods within the caller code, and this does not help code maintenance by splitting the implementation into small methods (something that C++ can do very easily, both because it supports native types parameters by reference, and because it also supports inline methods).
    Finally, suppose we don't want to use tricky code, difficult to maintain, then we'll have to use boxing Object types to allow passing arguments by reference. Shamely boxed native types cannot be allocated on the operand stack as local variables, so we need to instanciate these local variables before call, and we loose the capacity to track the cases where these local variables are not really initialized by an effective call to the method that will assign them. This does not help debugging, and is against the concept of a strongly typed language like Java should be:
    Java makes lots of efforts to track uninitialized variables, but has no way to determine if an already instanciated Object instance refered in a local variable has effectively received an effective assignment because only the instanciation is kept. A typical code will then need to be written like this:
    Integer a = null;
    Integer b = null;
    if (some condition) {
    //call.method(a, b, 0, 1, "dummy input arg");
    // the method is supposed to have assigned a value to a and b,
    // but can't if a and b have not been instanciated, so we perform:
    call.method(a = new Integer(), b = new Integer(), 0, 1, "dummy input
    arg");
    // we must suppose that the method has modified (not initialized!)
    the value
    // of a and b instances.
    now.use(a.value(), b.value())
    // are we sure here that a and b have received a value????
    // the code may be detected at run-time (a null exception)
    // or completely undetected (the method() above was called but it
    // forgot to assign a value to its referenced objects a and b, in which
    // case we are calling in fact: now.use(0, 0); with the default values
    // or a and b, assigned when they were instanciated)
    Very tricky... Hard to debug. It would be much simpler if we just used:
    int a;
    int b;
    if (some condition) {
    (a, b) = call.method(0, 1, "dummy input arg");
    now.use(a, b);
    The compiler would immediately detect the case where a and b are in fact not always initialized (possible use bere initialization), and the first invoked call.method() would not have to check if its arguments are not null, it would not compile if it forgets to return two values in some code path...
    There's no need to provide extra boxing objects in the source as well as at run-time, and there's no stress added to the VM allocator or garbage collector simply because return values are only allocated on the perand stack by the caller, directly instanciated within the callee which MUST (checked at compile-time) create such instances by using the return statement to instanciate them, and the caller now just needs to use directly the variables which were referenced before call (here a and b). Clean and mean. And it allows strong typechecking as well (so this is a real help for programmers.
    Note that the signature of the method() above is:
    class call {
    (int, int) method(int, int, String) { ... }
    id est:
    class "call", member name "method", member type "(IILjava.lang.string;)II"
    This last signature means that the method can only be called by returning the value into a pair of variables of type int, or using the return value as a pair of actual arguments for another method call such as:
    call.method(call.method("dummy input arg"), "other dummy input arg")
    This is strongly typed and convenient to write and debug and very efficient at run-time...

    Can anyone give me some real-world examples where
    multiple return values aren't better captured in a
    class that logically groups those values? I can of
    course give hundreds of examples for why it's better
    to capture method arguments as multiple values instead
    of as one "logical object", but whenever I've hankered
    for multiple return values, I end up rethinking my
    strategy and rewriting my code to be better Object
    Oriented.I'd personally say you're usually right. There's almost always a O-O way of avoiding the situation.
    Sometimes though, you really do just want to return "two ints" from a function. There's no logical object you can think of to put them in. So you end up polluting the namespace:
    public class MyUsefulClass {
    public TwoInts calculateSomething(int a, int b, int c) {
    public static class TwoInts {
        //now, do I use two public int fields here, making it
        //in essence a struct?
       //or do I make my two ints private & final, which
       //requires a constructor & two getters?
      //and while I'm at it, is it worth implementing
      //equals(), how about hashCode()? clone()?
      //readResolve() ?
    }The answer to most of the questions for something as simple as "TwoInts" is usually "no: its not worth implementing those methods", but I still have to think about them.
    More to the point, the TwoInts class looks so ugly polluting the top level namespace like that, MyUsefulClass.TwoInts is public, that I don't think I've ever actually created that class. I always find some way to avoid it, even if the workaround is just as ugly.
    For myself, I'd like to see some simple pass-by-value "Tuple" type. My fear is it'd be abused as a way for lazy programmers to avoid creating objects when they should have a logical type for readability & maintainability.
    Anyone who has maintained code where someone has passed in all their arguments as (mutable!) Maps, Collections and/or Arrays and "returned" values by mutating those structures knows what a nightmare it can be. Which I suppose is an argument that cuts both ways: on the one hand you can say: "why add Tuples which would be another easy thing to abuse", on the other: "why not add Tuples, given Arrays and the Collections framework already allow bad programmers to produce unmainable mush. One more feature isn't going to make a difference either way".
    Ho hum.

  • How to trap null return values from getters when using Method.invoke()?

    Hi,
    I am using Method.invoke() to access getters in an Object. I need to know which getters return a value and which return null. However, irrespective of the actual return value, I am always getting non-null return value when using Method.invoke().
    Unfortunately, the API documentation of Method.invoke() does not specify how it treats null return values.
    Can someone help?
    Thanks

    What do you get as a result?I think I know what the problem is.
    I tested this using following and it worked fine:
    public class TestMethodInvoke {
    public String getName() {
    return null;
    public static void main(String args[]) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException {
    Object o = new TestMethodInvoke();
    Class cls = o.getClass();
    Method m = cls.getMethod("getName", (Class[]) null);
    Object result = m.invoke(o, (Object[])null);
    if (result == null) {
    System.err.println("OK: Return value was null as expected");
    else {
    System.err.println("FAILED: Return value was NOT null as expected");
    However, when I use the same technique with an EJB 3.0 Entity class, the null return value is not returned. Instead, I get a String() object. Clearly, the problem is the the EJB 3.0 implementation (Glassfish/Toplink) which is manipulating the getters.
    Regards
    Dibyendu

  • Named return value optimization

    Hello,
    can anybody tell me wheather sun's CC does named return value
    optimization for local variables of classes without copyconstructors?
    Objects of classes with copy-constructor don't get optimized as you
    can see in the attached example... (function return_indirect)
    Is it possible to enable named return value optimization for classes with
    copy-constructors?
    Note: side effects in copy constructors may be ignored for returning values
    says the standard...
    Please take a look at the following code, which executes differently
    with CC and gcc. (gcc does named return value optimization)
    Thanks in advance for your feedback.
    Cheers,
    Tom
    ========== file nrvo.cc
    #include <iostream>
    using namespace std;
    struct Int
         Int(void)
         : d(0)
         { cout << "Int::Int(void)" << endl; }
         Int(int i)
         : d(i)
         { cout << "Int::Int(void)" << endl; }
         Int(const Int &i)
         : d(i.d)
         { cout << "Int::Int(const Int &)" << endl; }
         ~Int(void)
         { cout << "Int::~Int(void)" << endl; }
         private:
         int d;
    Int return_indirect(void)
         Int i;
         return i;
    Int return_direct(void)
         return Int();
    int main(void)
         Int i0(return_direct());
         Int i1(return_indirect());
         return 0;
    ====
    gcc output:
    Int::Int(void)
    Int::Int(void)
    Int::~Int(void)
    Int::~Int(void)
    ====
    CC output:
    Int::Int(void)
    Int::Int(void)
    Int::Int(const Int &)
    Int::~Int(void)
    Int::~Int(void)
    Int::~Int(void)

    Sorry, but I couldn't find bug report/enhance request page for Sun Studio, so I'll write an enhancement request here.
    Now I use Sun Studio 11. The C++ compile in it still doesn't have "named return value optimization".
    Unfortunately, most of my co-workers don't pay attension how many times (implicit-) copy constructors and destructor are called. So they use temporary object very often to return values.
    The optimization might improve our program's performance and memory use(to avoid fragmentation) drastically.
    I really need it! I hope that Sun's developer find this topic and improve the C++ compiler in future.

  • Get method return value

    Hi. We're using bytecode instrumentation in a native jvmti agent to monitor method entry/exit. I'd like to capture method return values and report them upon method exit. I see how to obtain local variables, and am indeed doing this when a method is entered; however, I'm not sure how to get a method's return value.
    Thanks for any advice.
    -- david

    You will need to do two things to make this work:
    1) Change the method that your return instrumentation calls to accept a parameter (the return value).
    2) Modify your bytecode instrumentation to call your new function with the return value.

Maybe you are looking for

  • Unable to install FlashPlayer 11.6 on Mac OS 10.7.5

    Hi, I have also been having problems installing Flash Player 11.6.602.167 on my Mac (OS 10.7.5).  I decided to try uninstalling, then re-installing after an online tutorial stopped working to see if it was related to Flash Player.  I am able to downl

  • Enhancement request: modifiable style for report highlighting

    Dear Apex Developers, I have investigated the way highlighting is done in reports. What I found is, that a span container is put around the text to be highlighted with the style attributes colr:red; font-weight:bold;. The red characters do not fit wi

  • Invoicing getting Delayed

    Hi All, There  is a  delay in creation of invoice after delivery has been created. Usually the process is for Creation of invoice will depend on the route(no. of days in transit) after the actual GI date. For Example: If Tuesday is the actual GI date

  • Accessing third party jars - please help

    I have an application that I developed and put in a jar file. The application will run from the jar file and will run after it has been signed with a certificate from the signed jar file. I think I followed all the necessary steps according to the de

  • Pagination with rownum!

    i've the following query....... for getting first 10 records SELECT A.leave_trans_id,A.leave_category_id,A.emp_id, B.leave_description,C.first_name,C.last_name, to_char(A.from_date,'DD-Mon-YYYY') from_date, to_char(A.to_date,'DD-Mon-YYYY') to_date, C