Failover callback not called when listener dies

I need to create a RAC-aware Pro*C application.
I got the preconfigured VirtualBox images with OL 5 and RAC nodes.
The listener is installed on both machines too. They share a single IP address for the listener, which I added to the hosts file:
192.168.56.201   rac-scan.localdomain    rac-scanActually, the cluster decides to create a virtual network adapter on one of the nodes and this address is assigned to it and then the listener becomes awailable. When this node dies, the cluster starts the listener on another node.
I don't know, whether it's a proper way. I heard that the listener should be on a separate machine.
But the problem is: when I turn off the node my client program is connected to, the failover callback function is not called. The next oracle operation fails with "ORA-03114: not connected to ORACLE".
I followed http://docs.oracle.com/cd/A91202_01/901_doc/appdev.901/a89857/oci09adv.htm#428924 and https://support.oracle.com/CSP/main/article?cmd=show&type=NOT&id=415245.1 to create the sample program that registers the callback.
Could it be that the failover only works when the DB service fails, but not the listener?

The problem was bad connection string

Similar Messages

  • OCCI AQ Subscription: callback not called

    When data changed in table, I want my application to know immediately. So I use the Subsription class. The implements as follows. When I insert row to table set_tab_info, the triggers acts, but the callback not called. What's wrong?
    --create multi consumer queue table
    BEGIN
    dbms_aqadm.create_queue_table (
                                       queue_table => 'hr.table06',
                                       queue_payload_type => 'RAW',
                                       comment => 'multi-consumer',
                                       multiple_consumers => TRUE,
                                       compatible => '8.1.0'
    END;
    --create multi consumer queue
    BEGIN
    dbms_aqadm.create_queue (
                                  queue_name => 'queue06',
                                  queue_table=> 'hr.table06'
    END;
    BEGIN
    dbms_aqadm.start_queue(queue_name => 'queue06');
    END;
    --create table
    CREATE TABLE set_tab_info(
         flag NUMBER
    --create trigger, as a test, the payload is a byte
    CREATE OR REPLACE TRIGGER tablechangeNew
         AFTER UPDATE OR INSERT OR DELETE
         ON set_tab_info
         FOR EACH ROW
    DECLARE
         enqopt dbms_aq.enqueue_options_t;
         mprop dbms_aq.message_properties_t;
         enq_msgid RAW(16);
         rcpt_list dbms_aq.aq$_recipient_list_t;
    BEGIN
         rcpt_list(0) := sys.aq$_agent('RECEIVER06', null, null);
         mprop.recipient_list := rcpt_list;
         dbms_aq.enqueue(
                        queue_name => 'hr.queue06',
                        enqueue_options => enqopt,
                        message_properties => mprop,
                        payload => HEXTORAW('61'),
                        msgid => enq_msgid);
    END;
    #include <iostream>
    #include <iomanip>
    #include <string>
    #include <cstdlib>
    #include <vector>
    using namespace std;
    #include "occi.h"
    using namespace oracle::occi;
    #include "occiAQ.h"
    using namespace oracle::occi::aq;
    string username("HR");
    string password("HR");
    string connstr("192.168.8.22:1521/study");
    Environment* p_env = NULL;
    Subscription* p_sub = NULL;
    Connection* p_conn = NULL;
    vector<Subscription> sub_vec;
    class NotifyRegister
    public:
         static unsigned int callback(Subscription& sub, NotifyResult* nr)
              //nr->getPayload();
              //Message msg = nr->getMessage();
              //Bytes bt =nr->getMessageId();
              cout << "callback was called!" << endl;
              return 0;
         void notifyTest()
              p_env = Environment::createEnvironment(Environment::EVENTS);
              p_sub = new Subscription(p_env);
              p_sub->setSubscriptionNamespace(Subscription::NS_AQ);
              //SCHEMA.QUEUE:CONSUMER_NAME
              p_sub->setSubscriptionName("HR.QUEUE06:RECEIVER06");
              p_sub->setPresentation(Subscription::PRES_DEFAULT);
              p_sub->setProtocol(Subscription::PROTO_CBK);
              p_sub->setNotifyCallback(&NotifyRegister::callback);
              //what's the context mean, how to set?
              p_sub->setCallbackContext((void*)this);
              p_env->enableSubscription(*p_sub);
              p_conn = p_env->createConnection(username, password, connstr);
              sub_vec.push_back(*p_sub);
              p_conn->registerSubscriptions(sub_vec);
    int main()
         NotifyRegister nr;
         nr.notifyTest();
         pause();
         return EXIT_SUCCESS;
    I don't know how to set the callback context. so just use this statement:
    p_sub->setCallbackContext((void*)this);

    Thanks, once again. Sorry for my naive questions, but I'm unable to find a good example for this...
    After registering the Subscriber, and creating the environment in EVENT mode, it seems like it is picking up the message. Once I send a AQ message, I get an error from visual studio, telling me the variable ESP was not properly saved across a function call. At least it reacts now :)
    Could it be that I'm doing something wrong when defining or hooking my callback function? The breakpoint in the callback function is never called....
    my registering routine now looks like this:
    void aq_connection::create_callback() {
    payload = new Bytes(env); //is this the correct way?
    Subscription sub(env);
    sub.setSubscriptionNamespace(oracle::occi::aq::Subscription::NS_AQ);
    sub.setProtocol(oracle::occi::aq::Subscription::PROTO_CBK);
    sub.setPayload(*payload);
    sub.setCallbackContext((void *)this);
    sub.setSubscriptionName(quename + ":" + config->subscribername);
    sub.setPresentation(oracle::occi::aq::Subscription::PRES_DEFAULT);
    sub.setNotifyCallback(&aq_connection::event_message);
    subs.push_back(sub);
    conn->registerSubscriptions(subs);
    I thought it was ok to create a local Subscription instance, as I put it into the global subs-vector.
    Thanks in advance,
    Sverre

  • Failover callback NOT registered. - What it's mean?

    Hi
    In the logs we receives information’s " ... Failover callback NOT registered." What it's exactly mean?
    We use TT RO Cache groups to RAC.
    The OracleDB and Oracle client the same version 10.2
    10:54:50.91 Info: ORA: 9391: ora-9391-0013-raStuff08713: refresh.c:4051 (srvH ctx func) = (0x00000000009b1358 0x0000000000000000(0x0000000000000000 0x0000000000000000) 0x0000000000000000) Failover callback NOT registered.
    BR
    Andrzej

    root@tbaltJSLEE1# ttVersion
    TimesTen Release 7.0.5.0.0 (64 bit Solaris/x86) (tt70:17001) 2008-04-04T00:06:18Z
    Instance admin: jnetx
    Instance home directory: /opt/TimesTen/tt70
    Daemon home directory: /var/TimesTen/tt70
    Access control enabled.
    root@tbaltJSLEE1#
    Command> call ttConfiguration;
    < CkptFrequency, 600 >
    < CkptLogVolume, 0 >
    < CkptRate, 0 >
    < ConnectionCharacterSet, UTF8 >
    < ConnectionName, ccompldsn >
    < Connections, 64 >
    < DataBaseCharacterSet, UTF8 >
    < DataStore, /data/DataStore/CCOMPL/ccomplds >
    < DurableCommits, 0 >
    < GroupRestrict, <NULL> >
    < LockLevel, 0 >
    < LockWait, 10 >
    < LogBuffSize, 65536 >
    < LogDir, /data/DataStore/CCOMPL/log >
    < LogFileSize, 64 >
    < LogFlushMethod, 1 >
    < LogPurge, 1 >
    < Logging, 1 >
    < MemoryLock, 0 >
    < NLS_LENGTH_SEMANTICS, BYTE >
    < NLS_NCHAR_CONV_EXCP, 0 >
    < NLS_SORT, BINARY >
    < OracleID, SUNSEED >
    < PassThrough, 0 >
    < PermSize, 1000 >
    < PermWarnThreshold, 90 >
    < PrivateCommands, 0 >
    < Preallocate, 0 >
    < QueryThreshold, 0 >
    < RACCallback, 1 >
    < SQLQueryTimeout, 0 >
    < TempSize, 64 >
    < TempWarnThreshold, 90 >
    < Temporary, 0 >
    < TransparentLoad, 0 >
    < TypeMode, 0 >
    < UID, CCOMPL >
    37 rows found.
    Command>

  • Region Monitoring iOS 7 : didEnterRegion method is not calling when app is killed by user or by OS in iOS 7 only. It is working fine when it is in background. and the same code is working fine with iOS 6 for both app in suspended mode and background mode.

    Region Monitoring iOS 7 : didEnterRegion method is not calling when app is killed by user or by OS in iOS 7 only. It is working fine when it is in background. and the same code is working fine with iOS 6 for both app in suspended mode and background mode. What changes I have to made to work great in iOS 7 also.

    I rewrote code for debugging purpose and tried to catch error using GetLastError();  method,
    but it only printed 0. Below is code snippet; I think Create() throw an exception
    and code goes to catch block. 
    LONG ConnectTS(CString strIP, UINT n_Port)
    try{
              ErrorLog(0,0,"ConnectTS is calling Create [is going to call]","");
              if(!Create())
    // Exception Line
    n_Err = GetLastError();
    return NET_INIT;
    catch(...)
                       DWORD errorCode = GetLastError();
                       CString errorMessage
                       errorMessage.Format("%lu",errorCode);
                       ErrorLog (0, 0, "Image
    System", (LPTSTR)(LPCTSTR)errorMessage);
                       return  IS_ERR_WINDOWS;
    Output: -
    ConnectTS is calling Create [is going to call]
    Image System
    0

  • Occi AQ callback not called

    I have written code for dequeing messages with blocking calls (Consumer::recieve), which works fine. Now I try to register a callback function, which should be called when a message is in the queue.
    Some code:
    void aq_connection::create_callback() {
    payload = new Bytes(env); //?
    Subscription newSubscription(env);
    newSubscription.setSubscriptionNamespace(oracle::occi::aq::Subscription::NS_AQ);
    newSubscription.setProtocol(oracle::occi::aq::Subscription::PROTO_CBK);
    newSubscription.setPayload(*payload);
    newSubscription.setCallbackContext((void *)this);
    newSubscription.setSubscriptionName(quename + ":" + config->subscribername);
    newSubscription.setPresentation(oracle::occi::aq::Subscription::PRES_DEFAULT);
    newSubscription.setNotifyCallback(&aq_connection::event_message);
    mye callback method is defined like this:
    static unsigned int event_message(oracle::occi::aq::Subscription &sub ,oracle::occi::aq::NotifyResult *not) {
    std::cout << "got message\n";
    return 0;
    The problem is, the event_message function is never called... I send in messages into the queue with this stored procedure:
    message := OURMSG_TYP(p_id, p_msg_type_id, p_msg, p_operation, p_data);
    enqueue_options.visibility := DBMS_AQ.ON_COMMIT;
         enqueue_options.relative_msgid := NULL;
         enqueue_options.sequence_deviation := NULL;
         enqueue_options.transformation := NULL;
         message_properties.priority := 1;
         message_properties.delay :=     DBMS_AQ.NO_DELAY;
         message_properties.expiration := p_expiration;
         message_properties.correlation := NULL;
         --message_properties.recipient_list :=
         message_properties.exception_queue := vcp_exception_queue_name;
         --message_properties.sender_id :=
         message_properties.original_msgid := NULL;
         message_properties.transaction_group := NULL;
         message_properties.user_property :=     NULL;
         DBMS_AQ.ENQUEUE(
         queue_name => our_queue_name,
    enqueue_options => enqueue_options,
    message_properties => message_properties,
    payload => message,
    msgid => message_handle
    Any obvious reason why my callback is never called?
    regards,
    Sverre

    Thanks, once again. Sorry for my naive questions, but I'm unable to find a good example for this...
    After registering the Subscriber, and creating the environment in EVENT mode, it seems like it is picking up the message. Once I send a AQ message, I get an error from visual studio, telling me the variable ESP was not properly saved across a function call. At least it reacts now :)
    Could it be that I'm doing something wrong when defining or hooking my callback function? The breakpoint in the callback function is never called....
    my registering routine now looks like this:
    void aq_connection::create_callback() {
    payload = new Bytes(env); //is this the correct way?
    Subscription sub(env);
    sub.setSubscriptionNamespace(oracle::occi::aq::Subscription::NS_AQ);
    sub.setProtocol(oracle::occi::aq::Subscription::PROTO_CBK);
    sub.setPayload(*payload);
    sub.setCallbackContext((void *)this);
    sub.setSubscriptionName(quename + ":" + config->subscribername);
    sub.setPresentation(oracle::occi::aq::Subscription::PRES_DEFAULT);
    sub.setNotifyCallback(&aq_connection::event_message);
    subs.push_back(sub);
    conn->registerSubscriptions(subs);
    I thought it was ok to create a local Subscription instance, as I put it into the global subs-vector.
    Thanks in advance,
    Sverre

  • Failover did not happen when network switch went down!!! PLEASE HELP

    Hi gurus,
    Yesterday one disaster struck my RAC database. We have two node cluster and it is 10.2.0.2, both of them located in different sites, yesterday suddenly power went down and the one of the network switch went down and got destructed, node one of RAC database was connected to that switch, but the failover did not happen to the node two as this should be the case when one node goes down the other should be available for all the node one sessions/connections.
    when I tried to ping/telnet the node 1, it was not happening because the switch was down, the network guyz connected the cables to other switch available. When I connected to the node 1, it was showing "Oracle is not available" message.
    And when I tried the other node, it was the same case but I did not see any error in alert log file. Then my TL restarted both the nodes and then the database was available.
    I am very confused that how the failover did not happen and how the database went down, PLEASE suggest something to how to identifiy what was happened. Thanks & Regards
    Edited by: user1221 on Mar 18, 2009 1:09 AM

    About Oracle RAC ... you have 2 nodes ... You have to connect 4 IPs.
    I mean
    - IP public node1
    - IP public node2
    - IP Virtual node1
    - IP Virtual node2
    When node1 down
    You can not ping "IP public node1", but you should ping "- IP Virtual node1", because it should up on node2.
    But not bind 1521 port.
    Idea about failover
    you have to create new difference Service...on RAC Database!
    and on your client have to set TNS to on failover and balance (if you used OCI), you can use TAF feature
    Example:
    DB =
    (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = db01-vip)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = db02-vip)(PORT = 1521)) (FAILOVER=ON)(LOAD_BALANCE = yes) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = NEW_SERVICE_DB) (FAILOVER_MODE = (TYPE = SELECT) (METHOD = BASIC) (RETRIES = 180) (DELAY = 5))))
    If you use JDBC, can not use TAF.
    Anyway, I suggest you read more about RAC on http://otn.oracle.com/rac and http://oracleracsig.org
    Good Luck

  • Failover did not happen when one node went down!!! PLEASE HELP

    Hi gurus,
    Yesterday one disaster struck my RAC database. We have two node cluster and it is 10.2.0.2, both of them located in different sites, yesterday suddenly power went down and the one of the network switch went down and got destructed, node one of RAC database was connected to that switch, but the failover did not happen to the node two as this should be the case when one node goes down the other should be available for all the node one sessions/connections.
    when I tried to ping/telnet the node 1, it was not happening because the switch was down, the network guyz connected the cables to other switch available. When I connected to the node 1, it was showing "Oracle is not available" message.
    And when I tried the other node, it was the same case but I did not see any error in alert log file. Then my TL restarted both the nodes and then the database was available.
    I am very confused that how the failover did not happen and how the database went down, PLEASE suggest something to how to identifiy what was happened. Thanks & Regards

    Thanks for your reply,
    after the network switch was replaced we connected to both the nodes and found that the instances are down with no reason given in the Alertlog file. We just restarted both the instances and then the database was up and the clients connected to both the instances with equal sessions on both the instances. I want to know that whether the failover can be done at the application side or it should be done on the database side i,e; in tnsnames.ora file with the required parameters? as in our scenario there is no failover configuration in the tnsnames.ora file.
    Thanks & Regards

  • Command button action not calling when in subview

    i have a page that is fine when it's in it's own view...
    the command button calls a managed bean's method..
    <af:commandButton text="Call Method"
    action="#{backing_myPage.CallMethod}"
    binding="#{backing_myPage.commandButton1}"
    id="commandButton1"/>
    but when i remove the view tags and include it in a main index.jspx page
    that has a main view and a tabbed panel with showdetailitems and
    for each showdetaileditem i have a subview
    and then an include
    <f:subview id="discovered_subview" rendered="true"
    binding="#{backing_index.mypage_subview}">
    <jsp:include page="/mypage.jspx" />
    </f:subview>
    Mypage renders but the commandbutton's action is not called..
    but is called when run as a standalone page
    tia

    I also have the same problem as above. Changing the dropDown values to String does not fix it.
    I am using Netbeans Visual Web Pack.
    I drag a drop down box onto a brand new page.
    I double click the drop down box and in the processValueChange action i put System.out.println("Hello World");
    In the init() method i add 2 options to the drop down box:
    "option 1", "1"
    "option 2", "2"
    values are Strings
    I press F6 to run
    I notice that the drop down box is correctly populated.
    I change the drop down box selection
    Nothing is printed.

  • NW2004s SP12, action not called when Save button pressed

    Hi Experts,
    I have a strange behaviour in my Interactive form SAVE functionality. If its a large form, the SAVE button does not call corresponding action method in the implementation.
    However it does when the form size is small eg 1.5Mb or so.
    Please advise. This is quite urgent.
    Thanks in advance
    Mona

    Hi!
    If you commit the form and insert data after that,
    that data will not being commited to the database and got lost until you use
    something like forms_ddl ( 'commit' ); after the insert.
    :system.last_query, which is the very last query of a block in your form,
    will never show an insert in any trigger.
    May a commit-trigger is not a good place for an insert.
    But anyway, hope this help you.
    Regard
    Stauder

  • Substitution not called when posting from a different system through ALE

    Hi
    When I post an FI document using FB01 in FI system,the posting calls a  substitution to fill the cost center if the cost centre is empty.We have a custom function module which substitute the cost center
    The HR system is linked to FI system through an interface.
    So when HR system post a document through FI,it post successfully if the cost center is filled.
    But it fails to call the substitution when posting a document without cost center.
    There is a statement in our custom fm
    ASSIGN ('(SAPF110S)XBSEG[]') TO <lfs_bseg_tab>.
    ASSIGN ('(SAPMF05A)XBSEG[]') TO <lfs_bseg_tab>.
    These statements fails to work when calling remotely from HR system and so it doesnt fill <lfs_bseg_tab>.
    So the HR guys telling tat because of this reason,the substitution is not called.
    Could anyone please help?

    Hello ,
    are you use BTE or GGB1 ?
    regards
    Prabhu

  • Strange behavior: action method not called when button submitted

    Hello,
    My JSF app is diplaying a strange behavior: when the submit button is pressed the action method of my managed bean is not called.
    Here is my managed bean:
    package arcoiris;
    import java.util.ArrayList;
    import java.util.List;
    import javax.faces.model.SelectItem;
    public class SearchManagedBean {
        //Collected from search form
        private String keyword;
        private String country;
        private int[] postcode;
        private boolean commentExists;
        private int rating;
        private boolean websiteExists;
        //Used to populate form
        private List<SelectItem> availableCountries;
        private List<SelectItem> availablePostcodes;
        private List<SelectItem> availableRatings;
        //Retrieved from ejb tier
        private List<EstablishmentLocal> retrievedEstablishments;
        //Service locator
        private arcoiris.ServiceLocator serviceLocator;
        //Constructor
        public SearchManagedBean() {
            System.out.println("within constructor SearchManagedBean");
            System.out.println("rating "+this.rating);
        //Getters and setters
        public String getKeyword() {
            return keyword;
        public void setKeyword(String keyword) {
            this.keyword = keyword;
        public String getCountry() {
            return country;
        public void setCountry(String country) {
            this.country = country;
        public boolean isCommentExists() {
            return commentExists;
        public void setCommentExists(boolean commentExists) {
            this.commentExists = commentExists;
        public int getRating() {
            return rating;
        public void setRating(int rating) {
            this.rating = rating;
        public boolean isWebsiteExists() {
            return websiteExists;
        public void setWebsiteExists(boolean websiteExists) {
            this.websiteExists = websiteExists;
        public List<SelectItem> getAvailableCountries() {
            List<SelectItem> countries = new ArrayList<SelectItem>();
            SelectItem si_1 = new SelectItem();
            SelectItem si_2 = new SelectItem();
            SelectItem si_3 = new SelectItem();
            si_1.setValue("2");
            si_1.setLabel("ecuador");
            si_2.setValue("1");
            si_2.setLabel("colombia");
            si_3.setValue("3");
            si_3.setLabel("peru");
            countries.add(si_1);
            countries.add(si_2);
            countries.add(si_3);
            return countries;
        public void setAvailableCountries(List<SelectItem> countries) {
            this.availableCountries = availableCountries;
        public List<SelectItem> getAvailablePostcodes() {
            List<SelectItem> postcodes = new ArrayList<SelectItem>();
            SelectItem si_1 = new SelectItem();
            SelectItem si_2 = new SelectItem();
            SelectItem si_3 = new SelectItem();
            si_1.setValue(75001);
            si_1.setLabel("75001");
            si_2.setValue(75002);
            si_2.setLabel("75002");
            si_3.setValue(75003);
            si_3.setLabel("75003");
            postcodes.add(si_1);
            postcodes.add(si_2);
            postcodes.add(si_3);
            return postcodes;
        public void setAvailablePostcodes(List<SelectItem> availablePostcodes) {
            this.availablePostcodes = availablePostcodes;
        public List<SelectItem> getAvailableRatings() {
            List<SelectItem> ratings = new ArrayList<SelectItem>();
            SelectItem si_1 = new SelectItem();
            SelectItem si_2 = new SelectItem();
            SelectItem si_3 = new SelectItem();
            si_1.setValue(1);
            si_1.setLabel("1");
            si_2.setValue(2);
            si_2.setLabel("2");
            si_3.setValue(3);
            si_3.setLabel("3");
            ratings.add(si_1);
            ratings.add(si_2);
            ratings.add(si_3);
            return ratings;
        public void setAvailableRatings(List<SelectItem> availableRatings) {
            this.availableRatings = availableRatings;
        public int[] getPostcode() {
            return postcode;
        public void setPostcode(int[] postcode) {
            this.postcode = postcode;
        public List<EstablishmentLocal> getRetrievedEstablishments() {
            return retrievedEstablishments;
        public void setRetrievedEstablishments(List<EstablishmentLocal> retrievedEstablishments) {
            this.retrievedEstablishments = retrievedEstablishments;
        //Business methods
        public String performSearch(){
            System.out.println("performSearchManagedBean begin");
            SearchRequestDTO searchRequestDto = new SearchRequestDTO(this.keyword,this.country,this.postcode,this.commentExists,this.rating, this.websiteExists);
            SearchSessionLocal searchSession = lookupSearchSessionBean();
            List<EstablishmentLocal> retrievedEstablishments = searchSession.performSearch(searchRequestDto);
            this.setRetrievedEstablishments(retrievedEstablishments);
            System.out.println("performSearchManagedBean end");
            return "success";
        private arcoiris.ServiceLocator getServiceLocator() {
            if (serviceLocator == null) {
                serviceLocator = new arcoiris.ServiceLocator();
            return serviceLocator;
        private arcoiris.SearchSessionLocal lookupSearchSessionBean() {
            try {
                return ((arcoiris.SearchSessionLocalHome) getServiceLocator().getLocalHome("java:comp/env/ejb/SearchSessionBean")).create();
            } catch(javax.naming.NamingException ne) {
                java.util.logging.Logger.getLogger(getClass().getName()).log(java.util.logging.Level.SEVERE,"exception caught" ,ne);
                throw new RuntimeException(ne);
            } catch(javax.ejb.CreateException ce) {
                java.util.logging.Logger.getLogger(getClass().getName()).log(java.util.logging.Level.SEVERE,"exception caught" ,ce);
                throw new RuntimeException(ce);
    }Here is my jsp page:
    <%@page contentType="text/html"%>
    <%@page pageEncoding="UTF-8"%>
    <%@taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
    <%@taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
       "http://www.w3.org/TR/html4/loose.dtd">
             <html>
                 <head>
                     <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
                     <META HTTP-EQUIV="pragma" CONTENT="no-cache">
                     <title>JSP Page</title>
                 </head>
                 <body>
                     <f:view>
                         <h:panelGroup id="body">
                             <h:form id="searchForm">
                                 <h:panelGrid columns="2">
                                     <h:outputText id="keywordLabel" value="enter keyword"/>   
                                     <h:inputText id="keywordField" value="#{SearchManagedBean.keyword}"/>
                                     <h:outputText id="countryLabel" value="choose country"/>   
                                     <h:selectOneListbox id="countryField" value="#{SearchManagedBean.country}">
                                         <f:selectItems id="availableCountries" value="#{SearchManagedBean.availableCountries}"/>
                                     </h:selectOneListbox>
                                     <h:outputText id="postcodeLabel" value="choose postcode(s)"/>   
                                     <h:selectManyListbox id="postcodeField" value="#{SearchManagedBean.postcode}">
                                         <f:selectItems id="availablePostcodes" value="#{SearchManagedBean.availablePostcodes}"/>
                                     </h:selectManyListbox>
                                     <h:outputText id="commentExistsLabel" value="with comment"/>
                                     <h:selectBooleanCheckbox id="commentExistsField" value="#{SearchManagedBean.commentExists}" />
                                     <h:outputText id="ratingLabel" value="rating"/>
                                     <h:selectOneListbox id="ratingField" value="#{SearchManagedBean.rating}">
                                         <f:selectItems id="availableRatings" value="#{SearchManagedBean.availableRatings}"/>
                                     </h:selectOneListbox>
                                     <h:outputText id="websiteExistsLabel" value="with website"/>
                                     <h:selectBooleanCheckbox id="websiteExistsField" value="#{SearchManagedBean.websiteExists}" />
                                     <h:commandButton value="search" action="#{SearchManagedBean.performSearch}"/>
                                 </h:panelGrid>
                             </h:form>
                         </h:panelGroup>
                     </f:view>
                 </body>
             </html>
         here is my faces config file:
    <?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE faces-config PUBLIC
      "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
      "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
    <faces-config>
        <managed-bean>
            <managed-bean-name>SearchManagedBean</managed-bean-name>
            <managed-bean-class>arcoiris.SearchManagedBean</managed-bean-class>
            <managed-bean-scope>request</managed-bean-scope>
        </managed-bean>
        <navigation-rule>
           <description></description>
            <from-view-id>/welcomeJSF.jsp</from-view-id>
            <navigation-case>
            <from-outcome>success</from-outcome>
            <to-view-id>index.jsp</to-view-id>
            </navigation-case>
        </navigation-rule>
    </faces-config>The problem occurs when the field ratingField is left blank (which amounts to it being set at 0 since it is an int).
    Can anyone help please?
    Thanks in advance,
    Julien.

    Hello,
    Thanks for the suggestion. I added the tag and it now says:
    java.lang.IllegalArgumentException
    I got that from the log:
    2006-08-17 15:29:16,859 DEBUG [com.sun.faces.el.ValueBindingImpl] setValue Evaluation threw exception:
    java.lang.IllegalArgumentException
         at sun.reflect.GeneratedMethodAccessor118.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.sun.faces.el.PropertyResolverImpl.setValue(PropertyResolverImpl.java:178)
         at com.sun.faces.el.impl.ArraySuffix.setValue(ArraySuffix.java:192)
         at com.sun.faces.el.impl.ComplexValue.setValue(ComplexValue.java:171)
         at com.sun.faces.el.ValueBindingImpl.setValue(ValueBindingImpl.java:234)
         at javax.faces.component.UIInput.updateModel(UIInput.java:544)
         at javax.faces.component.UIInput.processUpdates(UIInput.java:442)
         at javax.faces.component.UIComponentBase.processUpdates(UIComponentBase.java:935)
         at javax.faces.component.UIForm.processUpdates(UIForm.java:196)
         at javax.faces.component.UIComponentBase.processUpdates(UIComponentBase.java:935)
         at javax.faces.component.UIComponentBase.processUpdates(UIComponentBase.java:935)
         at javax.faces.component.UIViewRoot.processUpdates(UIViewRoot.java:363)
         at com.sun.faces.lifecycle.UpdateModelValuesPhase.execute(UpdateModelValuesPhase.java:81)
         at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:90)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
         at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
         at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
         at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:159)
         at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
         at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
         at java.lang.Thread.run(Thread.java:595)
    2006-08-17 15:29:16,875 DEBUG [com.sun.faces.context.FacesContextImpl] Adding Message[sourceId=searchForm:ratingField,summary=java.lang.IllegalArgumentException)Do you see where the problem comes from??
    Julien.

  • Initializer block not called when static method called

    public class Initializer {
         Initializer(){
              System.out.println("Constructor called");
                   System.out.println("CLASS INITIALIZED");
         static void method(){
              System.out.println("Static method called");
         public static void main(String[] args) {
              Initializer.method();
    From the JLS
    A class or interface type T will be initialized immediately before the first occurrence of any one of the following:
    T is a class and an instance of T is created.
    T is a class and a static method declared by T is invoked.
    [b]
    But when i call the static method , if the class is initialized shouldnt the initializer block be called, it is not called, why.

    Perhaps running something like this will add a little more colour?:
    public class Initializer {
        static {
            System.out.println("First static initializer");
            System.out.println("First instance initializer");
        Initializer() {
            System.out.println("Constructor");
        static {
            System.out.println("Second static initializer");
            System.out.println("Second instance initializer");
        static void staticMethod() {
            System.out.println("staticMethod");
        void instanceMethod() {
            System.out.println("instanceMethod");
        public static void main(String[] args) {
            System.out.println("main");
            staticMethod();
            new Initializer().instanceMethod();
    }

  • Position not saved when battery dies

    I got an old 2nd gen nano, that is permanently connected in my car.
    I use it to listen to audiobook.
    Problem is:
    an hour after turning off the engine, ipod nano loses power (battery not holding charge), and next time I power the engine, nano comes back up, but has no recollection as to what was playing, or even if I choose manually the track - position is lost
    any way to 'bookmark' or 'save' last position?

    Youve got to be kidding me.
    Are you being serious?
    The problem is not that the battery sometimes runs out.
    The problem is that the SIM is not recognized when it does.
    Its not "bad" or "wrong" or "improper" for your phone to die.
    Why am i having this absurd conversation?
    Twilight zone...

  • Callback Methods called when a UI Componet is displayed

    Hi ,
    There are 3 callback methods called as preInitialize , initialize and creationComplete that will come into picture when a UI Component is initialized .
    Can anybody clarify my confusion here , what does a UI Component Mean here ??
    Is it a Container like a Application or a control like Button ??
    Please share your ideas . Thanks for reading .

    Here is a link that explains the lifecycle of Flex components.  It is an oldie ( Flex 2 ) but a goodie !
    http://www.adobe.com/livedocs/flex/201/html/wwhelp/wwhimpl/common/html/wwhelp.htm?context= LiveDocs_Book_Parts&file=containers_intro_063_12.html

  • Air.swf GetApplicationVersion callback not called

    I am trying to use air.swf from
    http://airdownload.adobe.com/air/browserapi
    per the Adobe documentation to detect if an air application is
    already installed. I'm using getApplicationVersion but the callback
    function is never called. launchApplication() and
    installApplication() work fine.
    The code looks like this:
    _air.getApplicationVersion(appID, pubID,
    versionDetectCallback);
    VersionDetectCallback() is never called. I de-compiled the
    air.swf and ran the code directly to try and figure out what's
    failing. But I get the same result. I can see the timer on the
    LocalConnection endpoint timing out after 5 seconds. I just can't
    figure out why the appinstaller is not calling back. The actual
    call (taken from the decompiled swf) looks like this:
    airappinstaller = new ProductManager("airappinstaller");
    var launchArgs:Array;
    launchArgs = ["-isinstalled", appID, pubID, "adobe.com" + ":"
    + lcName, "onApplicationVersion"];
    airappinstaller.launch(launchArgs.join(" "));
    where onApplicationVersion is the endpoint callback function
    and lcName is the LocalConnection name.
    Anyone know why GetApplicationVersion() doesn't work?

    I am trying to use air.swf from
    http://airdownload.adobe.com/air/browserapi
    per the Adobe documentation to detect if an air application is
    already installed. I'm using getApplicationVersion but the callback
    function is never called. launchApplication() and
    installApplication() work fine.
    The code looks like this:
    _air.getApplicationVersion(appID, pubID,
    versionDetectCallback);
    VersionDetectCallback() is never called. I de-compiled the
    air.swf and ran the code directly to try and figure out what's
    failing. But I get the same result. I can see the timer on the
    LocalConnection endpoint timing out after 5 seconds. I just can't
    figure out why the appinstaller is not calling back. The actual
    call (taken from the decompiled swf) looks like this:
    airappinstaller = new ProductManager("airappinstaller");
    var launchArgs:Array;
    launchArgs = ["-isinstalled", appID, pubID, "adobe.com" + ":"
    + lcName, "onApplicationVersion"];
    airappinstaller.launch(launchArgs.join(" "));
    where onApplicationVersion is the endpoint callback function
    and lcName is the LocalConnection name.
    Anyone know why GetApplicationVersion() doesn't work?

Maybe you are looking for

  • How to change currency sign in report

    How can I change the currency sign in report like from dollar to pound sign. Any help and advice will be highly appreciated.

  • How do i scan multiple pages into one pdf file

    How do I scan multiple pages into one pdf file?

  • Can I change target for Itunes music library?

    I have 2 hard drives on my laptop and will actually need to buy an external hard drive as my laptop has less space than my iPod. I can't import all my CD's yet. Also, the C drive hold iTunes but I have a D drive that has about 12gigs to hold more spa

  • Fonts being deleted in windows 8.1! Is an update the cause?

    Hi, After a reboot nearly all fonts are missing in the fonts folder. It has much influence to the running programs, they sometimes don't work at all! When I reinstall the fonts, they seem to still be there, but the same time they are missing. And aft

  • Delete the database records

    Hi All I  want to delete the records that are older than 40 days in my custom table ZTABLE. How can I use table maintenence generator to achieve the same? Will this be done by archiving the records.. Thanks.. Prabhas