About the last_call_et column in v$session
Hello,
Can someone help me about a behaviour that is very strange ...
We have connection about SAS on a database which manipulate Oracle table and others SAS Structure.
The query is a "join" about that table and a "SAS Table" between million of lines in the Oracle table one ....
It last a long time ....
During the query, we have time to see at the v$session table...
At any time (it lasts 3h), we saw that the column 'last_call_et' of the v$session never change : it continuesly stay at 0.
What does it mean ? it means that SAS send a query every second ? Or this column shows the last "internal call"?
If this is the right reason, i would'nt understand why, when i take the same query( launched by SAS) in TOAD, there is no the same behaviour and this behaviuor is in that case the right behaviour : the session is ACTIVE but the last_call_et respresents really the time since i launched the query... So why when SAS do it, the last_call_et stay at 0 ? it works like SAS launch every second this query !!!!
Can someone help me ?
Thanks ...
Jonathan Lewis wrote:
user12046632 wrote:
When you say :
A FETCH is a database call :
That means that it must affect the value of 'last_call_et' or not ?"A Fetch is a database call"
"last_call_et" -- certainly sounds like that could be something to do with database calls, perhaps End Time of LAST database CALL.
A parse is also a database call, as is an execute ... I feel that perhaps I was a little too concise with my description. You asked why SAS could be doing lots of calls (although that wasn't exactly how you put the question) and I replied that calls could include fetches. And yes, the last_call_et is reset on every fetch (amongst other things - and ignoring the special behaviour of background processes).Ok
>
(accordint to me, only to user's activity do so and not to "database internal callsl") ! isn't it ?You don't want to believe everything you read on the internet - even if it did come from the online manuals. But a "fetch" is not a "database internal call" anyway, it's a call from a client to the server.Be sure that i don't do so.
But the explanation of Oracle of the term 'cal' is not so precise at all ...
>
Your follonwing explanations seems to answers contrarily ....
But the question is there : what sort of call affetcs the value of "last_call_et"All database calls - which you should read as "all calls from the client to the server".Ok
>
>>
>>
When you say
all_rows plan => parse call, execute call ..... with very long call time, lots of fetch calls
first_rows_n plan => parse call, execute call ... with very short call time, lots of fetch calls
In the first case you would see last_call_et constantly growing until the fetches started
In the second case last_call_et would keep resetting to zero so fast you probably wouldn't see it as a non-zero value.
I don't understand : ok for the conséquences on the timing ... but if there are a lot of fetch call in both cases : the behaviour on the 'last_call_et' has to be equal ?True - but in one case I've included an execute call that is active for a very long time, and in the other I've proposed an execute call that is active for a very short time. (And execute calls are calls, and I did ask you about the exact details of your observations.)Ok
If we consider that every call reset to 0 the value of 'last_call_et',
why, in the case of launching the same request by TOAD, shouldn't i see the reset to 0 when the fetches works (because in TOAD during the whole query, which means since the click on "launching query" to the retrieving of data, the value did not reset to 0) ?
>
>>
When you say
Having said that, I've just run a quick test in SQL*Plus on 11.1.0.6 and 10.2.0.3 to demonstrate this point, and 11g is behaving differently from 10g - in the case where the last_call_et should be growing it stays at zero.
"in the case" : in the case of the v11 or the v10 ?11g
In my case : i'am on a v10.2.0.3 ::: Is there a bug ?Not that I know of.ok. So it is in V11 that you have an incorrect behaviour ....
>>
>
Regards
Jonathan LewisLAST NEWS : we have relaunched the query in SAS and observed that we have the same context of plan in both cases (by SAS en y TOAD) : ALL_ROWS.
Very strange ...
Last question :
Just to be sure : When you talk about "First Rows plan" : it means that the retrieve data are restricted to the first rows encountered
or
it is just the plan of the query which is in "that context" which means that the engine works so although the whole data are retrieved ....
thanks for your return
Similar Messages
-
A question about the IE management of session id
Hi, guys! I have a question about the IE browser management of session id.
As we know, firefox browser will use cookie to record session id, so if we delete the cookie files then the client can't find target session.
But it's not the same as IE browser.I found I already can find target session after I delete the cookies.
Then I think maybe IE browser use URL rewrite mechanism(GET request) and hidden text mechanism(POST request), but I'm not sure!
Or maybe IE browser use current IE window process's cache to record the session id?
Please help me, thank you very much in advance!
I'm Chinese, my English is so bad, please understand, thanks.Thank you for your answer, but I still have a question.
Can you tell me how your deleting cookies works? I just use IE browser tools->Internet Options->Delete Cookies to delete my cookie, but the session still can be retrieved! Just like you said, the session id is kept in the memory.
But if I use firefox to do the same operations, the session will can't be retrieved.Does that mean firefox not only delete cookies' files but also delete them in the memory.
Can I use IE browser to do the same effect as firefox browser? And how to do? Thank you. -
What other V$ view than V$SESSION can provide the "program" column ?
Hi all,
We get a blank value , no value then, given by the "program" column of the V£SESSION view when our after logon database trigger fires. This is perhaps because we use a forms R6i application which uses a 8.0.6 version of oracle client.
So I want to know which other V$ view can be joined with the V$SESSION view to get the program column.
Thank you very much indeedModifying the sqlnet.ora has 0 to do with the issue at hand.
Face it:
if the client executable doesn't have provisions to expose the program name,
you will never see it in v$session.
Your problem is you want to remain in the Stone Age, where the CD rom didn't exist and records where played by birds.
Sybrand Bakker
Senior Oracle DBA -
great Problemes after installing Yosemite (10.10.2 ) with Photoshop CS6....The program crashes --last time 10 times during my work session..wacomtable doesnt work..it is slow...and get error messages about the graphic card....It s a Terror to work with my beloved Photoshop!
The Yosemite upgrade very often damages existing Photoshop installations. Thank Apple for that.
You need to uninstall and re-install Photoshop, then apply all the Photoshop upgrades from scratch.
But first, give us details about your setup:
BOILERPLATE TEXT:
Note that this is boilerplate text.
If you give complete and detailed information about your setup and the issue at hand,
such as your platform (Mac or Win),
exact versions of your OS, of Photoshop (not just "CS6", but something like CS6v.13.0.6) and of Bridge,
your settings in Photoshop > Preference > Performance
the type of file you were working on,
machine specs, such as total installed RAM, scratch file HDs, total available HD space, video card specs, including total VRAM installed,
what troubleshooting steps you have taken so far,
what error message(s) you receive,
if having issues opening raw files also the exact camera make and model that generated them,
if you're having printing issues, indicate the exact make and model of your printer, paper size, image dimensions in pixels (so many pixels wide by so many pixels high). if going through a RIP, specify that too.
A screen shot of your settings or of the image could be very helpful too,
etc.,
someone may be able to help you (not necessarily this poster, who is not a Windows user).
Please read this FAQ for advice on how to ask your questions correctly for quicker and better answers:
http://forums.adobe.com/thread/419981?tstart=0
Thanks! -
How configure the auditory columns for the user in Session?
I want to have my page of login to enter the application.
After validating to the login/password according to user table
create table usuario(
id number not null,
login varchar2(15) not null,
pasword varchar2(15) not null,
);..., set to user in HttpSession
I wish to configure in mys entities(bc4j) the audit columns (userCreation/userModification) similar to dateCreation and dateModification...For example for the following table
crate table Cliente(
id not null,
name varchar2(20),
userCreation varchar(15) not null,
userModification varchar(15),
dateCreation date not null,
dateModification date
...For the date columns I configure as history columns in the edition of the entity objects and works correctly...
thanksRigoberto
Take a look at this topic and see if it helps:
Re: User Authentication: prepareSession() vs. jbo.sessioncookie.JHS_USER
Kind regards,
Peter Ebell
JHeadstart Team -
About the column display index of datagrid
i need do a customize datagrid, but seems hard to save the
display index of the grid column after the user drag and drop one
column to another postion. What i need is catch the event after
column drag and record that into database, and when reload based on
the record , resort that column display index as saved before, how
to get thatthat was i already did before, now even the all columns and
match datafied are dynamic, my question is
when after render all columns , dray a column a from right to
left , after that i can not catch that column display index
in the grid view, the real index in columns of grid is still
remain same , i want catch the dray column event and
get the display index(not the index of columns, but the order
which that column display in the view) and after reload
, i can show those colomns in right order as saved
before -
A question about the impact of SQL*PLUS SERVEROUTPUT option on v$sql
Hello everybody,
SQL> SELECT * FROM v$version;
BANNER
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
TNS for Linux: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
SQL>
OS : Fedora Core 17 (X86_64) Kernel 3.6.6-1.fc17.x86_64I would like to ask a question about the SQL*Plus SET SERVEROUTPUT ON/OFF option and its impact on queries on views such as v$sql and v$session. Here is the problem
Actually I define three variables in SQL*Plus in order to store sid, serial# and prev_sql_id columns from v$session in order to be able to use them later, several times in different other queries, while I'm still working in the current session.
So, here is how I proceed
SET SERVEROUTPUT ON; -- I often activate this option as the first line of almost all of my SQL-PL/SQL script files
SET SQLBLANKLINES ON;
VARIABLE mysid NUMBER
VARIABLE myserial# NUMBER;
VARIABLE saved_sql_id VARCHAR2(13);
-- So first I store sid and serial# for the current session
BEGIN
SELECT sid, serial# INTO :mysid, :myserial#
FROM v$session
WHERE audsid = SYS_CONTEXT('UserEnv', 'SessionId');
END;
PL/SQL procedure successfully completed.
-- Just check to see the result
SQL> SELECT :mysid, :myserial# FROM DUAL;
:MYSID :MYSERIAL#
129 1067
SQL> Now, let's say that I want to run the following query as the last SQL statement run within my current session
SELECT * FROM employees WHERE salary >= 2800 AND ROWNUM <= 10;According to Oracle® Database Reference 11g Release 2 (11.2) description for v$session
http://docs.oracle.com/cd/E11882_01/server.112/e25513/dynviews_3016.htm#REFRN30223]
the column prev_sql_id includes the sql_id of the last sql statement executed for the given sid and serial# which in the case of my example, it will be the above mentioned SELECT query on the employees table. As a result, right after the SELECT statement on the employees table I run the following
BEGIN
SELECT prev_sql_id INTO :saved_sql_id
FROM v$session
WHERE sid = :mysid AND serial# = :myserial#;
END;
PL/SQL procedure successfully completed.
SQL> SELECT :saved_sql_id FROM DUAL;
:SAVED_SQL_ID
9babjv8yq8ru3
SQL> Having the value of sql_id, I'm supposed to find all information about cursor(s) for my SELECT statement and also its sql_text value in v$sql. Yet here is what I get when I query v$sql upon the stored sql_id
SELECT child_number, sql_id, sql_text
FROM v$sql
WHERE sql_id = :saved_sql_id;
CHILD_NUMBER SQL_ID SQL_TEXT
0 9babjv8yq8ru3 BEGIN DBMS_OUTPUT.GET_LINES(:LINES, :NUMLINES); END;Therefore instead of
SELECT * FROM employees WHERE salary >= 2800 AND ROWNUM <= 10;for the value of sql_text I get the following value
BEGIN DBMS_OUTPUT.GET_LINES(:LINES, :NUMLINES);Which is not of course what I was expecting to find in v$sql for the given sql_id.
After a bit googling I found the following thread on the OTN forum where it had been suggested (well I think maybe not exactly for the same problem) to turn off SERVEROUTPUT.
Problem with dbms_xplan.display_cursor
This was precisely what I did
SET SERVEROUTPUT OFFafter that I repeated the whole procedure and this time everything worked pretty well as expected. I checked SQL*Plus documentation for SERVEROUTPUT
and also v$session page, yet I didn't find anything indicating that SERVEROUTPUT should be switched off whenever views such as v$sql, v$session
are queired. I don't really understand the link in terms of impact that one can have on the other or better to say rather, why there is an impact
Could anyone kindly make some clarification?
thanks in advance,
Regards,
Dariyoosh>
and also v$session page, yet I didn't find anything indicating that SERVEROUTPUT should be switched off whenever views such as v$sql, v$session
are queired. I don't really understand the link in terms of impact that one can have on the other or better to say rather, why there is an impact
Hi Dariyoosh,
SET SERVEROUTPUT ON has the effect of executing dbms_output.get_lines after each and every statement. Not only related to system view.
Here below what Tom Kyte is explaining in this page:
Now, sqlplus sees this functionality and says "hey, would not it be nice for me to dump this buffer to screen for the user?". So, they added the SQLPlus command "set serveroutput on" which does two things
1) it tells SQLPLUS you would like it <b>to execute dbms_output.get_lines after each and every statement</b>. You would like it to do this network rounding after each call. You would like this extra overhead to take place (think of an install script with hundreds/thousands of statements to be executed -- perhaps, just perhaps you don't want this extra call after every call)
2) SQLPLUS automatically calls the dbms_output API "enable" to turn on the buffering that happens in the package.Regards.
Al -
Get more info about the last errors in Oracle
Hi all,
There is a log in a live system where it is possible to see every minute the following error:
Sweep Incident[48073]: failed, err=[1858]
I know that error can happen mainly when:
1. Trying to insert caracter field in a numeric column
2. Using in the wrong way the function to_date()
I need more information about that error, what can be causing the error in the system and why. Is it possible to see more information about the last errors in Oracle? For example, if a query produces an error... is it possible to see in Oracle the error and the query that caused the error?
Hope you can help me.
Thanks in advance.Thanks Niall.
I'm not sure if I got you...
What I found is that MMON makes snapshots of the database 'health' and stores this information in the AWR. So, it seems like in the database there could be a numeric column that is storing character fields, and when MMON works, it finds that error... is that right?
I found the following information:
SQL> select substr(s.username,1,18) username,
2 substr(s.program,1,22) program,
3 decode(s.command,
4 0,'No Command',
5 1,'Create Table',
6 2,'Insert',
7 3,'Select',
8 6,'Update',
9 7,'Delete',
10 9,'Create Index',
11 15,'Alter Table',
12 21,'Create View',
13 23,'Validate Index',
14 35,'Alter Database',
15 39,'Create Tablespace',
16 41,'Drop Tablespace',
17 40,'Alter Tablespace',
18 53,'Drop User',
19 62,'Analyze Table',
20 63,'Analyze Index',
21 s.command||': Other') command
22 from
23 v$session s,
24 v$process p,
25 v$transaction t,
26 v$rollstat r,
27 v$rollname n
28 where s.paddr = p.addr
29 and s.taddr = t.addr (+)
30 and t.xidusn = r.usn (+)
31 and r.usn = n.usn (+)
32 order by 1;
USERNAME PROGRAM COMMAND
oracle@airvs1b (MMON) No Command
SQL> select addr, pid, spid, username, serial#, program,traceid, background, latchwait, latchspin from v$process where program='oracle@airvs1b (MMON)';
ADDR PID SPID USERNAME SERIAL# PROGRAM
000000044A4E48A8 24 15372 oracle 1 oracle@airvs1b (MMON)
TRACEID B LATCHWAIT LATCHSPIN
---------------- ---------- ------------------------ --------------- 1
SQL> select
2 substr(a.spid,1,9) pid,
3 substr(b.sid,1,5) sid,
4 substr(b.serial#,1,5) ser#,
5 substr(b.machine,1,6) box,
6 substr(b.username,1,10) username,
7 b.server,
8 substr(b.osuser,1,8) os_user,
9 substr(b.program,1,40) program
10 from v$session b, v$process a
11 where
12 b.paddr = a.addr
13 and a.spid=15372
14 order by spid;
PID SID SER# BOX USERNAME SERVER OS_USER PROGRAM
15372 1082 1 airvs1 DEDICATED oracle oracle@airvs1b (MMON)
Is there any way I can see what MMON is doing and when is failing?
Thank you very much.
Edited by: user11281526 on 19-jun-2009 5:18 -
Re: [iPlanet-JATO] Finding the database column length
This is the technique I would recommend. If you'd like to wrap this
mechanism up in the model class itself, create a subclass of QueryModelBase
that provides such a method and use that as the base class for all your
QueryModels.
Todd
----- Original Message -----
From: "Craig V. Conover" <craig.conover@S...>
Sent: Friday, October 19, 2001 12:15 PM
Subject: Re: [iPlanet-JATO] Finding the database column length
Chidu,
The result set that you get back is a JDBC ResultSet, not a "JATO" resultset. In ND, everything was wrapped in a "spider" data
structure, and therefore, difficult to get to the underlying datastructure, in many cases. In some case ND made it easier to do
certain things, and in other ways, made it more difficult or impossible(like seeing the SQL for an insert, update, delete).
>
Anyway, looking at the java.sql package, you can do this.
java.sql.ResultSet rs = <jata-model>.getResultSet();
java.sql.ResultSetMetaData rsMeta = rs.getMetaData();
// not sure if this is what you need, but it was the closest thing I couldfind
int colSize = rsMeta.getColumnDisplaySize(int column);
There are numerous other methods in the ResultSetMetaData interface thatmay be of use as well.
>
c
chidusv@y... wrote:
Hi,
How do I find out the length of a database column in a data model? In
NetDynamics, we can do dataobject.getDataField(<field
name>).getColumnLength(). Is it possible to achieve this in JATO
without using a resultset?
Thanks,
Chidu.
For more information about JATO, please visit
http://developer.iplanet.com/tech/appserver/framework/index.jsp
>>
>>
>>
>>
>
>
>
For more information about JATO, please visit
http://developer.iplanet.com/tech/appserver/framework/index.jsp
>
>
>
>
>
>
>This is the technique I would recommend. If you'd like to wrap this
mechanism up in the model class itself, create a subclass of QueryModelBase
that provides such a method and use that as the base class for all your
QueryModels.
Todd
----- Original Message -----
From: "Craig V. Conover" <craig.conover@S...>
Sent: Friday, October 19, 2001 12:15 PM
Subject: Re: [iPlanet-JATO] Finding the database column length
Chidu,
The result set that you get back is a JDBC ResultSet, not a "JATO" resultset. In ND, everything was wrapped in a "spider" data
structure, and therefore, difficult to get to the underlying datastructure, in many cases. In some case ND made it easier to do
certain things, and in other ways, made it more difficult or impossible(like seeing the SQL for an insert, update, delete).
>
Anyway, looking at the java.sql package, you can do this.
java.sql.ResultSet rs = <jata-model>.getResultSet();
java.sql.ResultSetMetaData rsMeta = rs.getMetaData();
// not sure if this is what you need, but it was the closest thing I couldfind
int colSize = rsMeta.getColumnDisplaySize(int column);
There are numerous other methods in the ResultSetMetaData interface thatmay be of use as well.
>
c
chidusv@y... wrote:
Hi,
How do I find out the length of a database column in a data model? In
NetDynamics, we can do dataobject.getDataField(<field
name>).getColumnLength(). Is it possible to achieve this in JATO
without using a resultset?
Thanks,
Chidu.
For more information about JATO, please visit
http://developer.iplanet.com/tech/appserver/framework/index.jsp
>>
>>
>>
>>
>
>
>
For more information about JATO, please visit
http://developer.iplanet.com/tech/appserver/framework/index.jsp
>
>
>
>
>
>
> -
How to Print the Report Column headers on each page of any report
Can someone offer assistance on how I can go about achieving the ability to show and print the Report Column headers on each page of any report using the Print Attributes of APEX 3.0? These reports will be printed using Excel and Word.
I read a thread with a similar request but the answer seems vague for my level of understanding.
I am connected to a print server and using BI Publisher.
Thanks,
RicHello Ric,
>> These reports will be printed using Excel and Word.
I'm not sure I understand what you are trying to do. You are using a very powerful tool – BI Publisher – why do you need Excel or Word for printing? Is there a special need only Excel or Word can provide?
One of the major advantages of using BI Publisher is that it's taking care of all these tedious tasks like reasonable page breaking, headers and footers, and also table headers.
Regards,
Arie. -
How to write the expression when create the calculated column?
Dear,
I want to create some calculated column in my attribute view, but I don't know how to write the code in the expression, is there any introduction about this part, how to use those function and how about the grammar in this expression code ? or is there any example about this calculated column?
Thanks for your sincerely answer.Hi Zongjie,
you can find some information about the creation of calculated columns in the HANA Modeling Guide (http://help.sap.com/hana/SAP_HANA_Modeling_Guide_for_SAP_HANA_Studio_en.pdf).
Within chapter 6.2.1 (Create Analytic Views) you can see under point 7 some basics and also a simple example. The same is also valid for Calculation Views.
Chapter 8.9 (Using Functions in Expressions) describes the different available functions.
You also can use the integrated search in the HANA Studio by clicking the "?" button in the button left corner. Then you get some links in the side panel with related information.
In general you can write your expression manually or you can just drag and drop the functions, elements, operators into the editor window. For example if you drag and drop the "if" function into the editor window you get "if(intarg,arg2,arg3)" inserted. The arguments can be replaced manually or also by drag and drop.
It is also worse to use the "Validate Syntax" button on top of the editor window. It gives you directly a feedback if your expression syntax is correct. If not you get some helpful information about the problem (ok, sometimes it is a little bit confusing because of the cryptic error message format ).
Best Regards,
Florian -
About the template FSCM9.1 FP2 Peopletools 8.52.03 (v4 - July 2012)
Hello,
Just tested quickly this new template delivered 2 months ago (July 2012).
As far as I undestand, it is just a recut of the one delivered in April 2012. At least it solves the main issue I reported in that other About the template FSCM9.1 FP2 Peopletools 8.52.03 (v3) about the network prompt missing.
But I still have remarks/issues on the template FSCM9.1 FP2 Peopletools 8.52.03 (v4) released earlier in July 2012.
_1. First of all, there a lot of errors reported in /var/log/messages_
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526918.883:3): avc: denied { read } for pid=92 comm="restorecon" name="libc.so.6" dev=xvda2 ino=21 scontext=system_u:sys
tem_r:restorecon_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=lnk_file
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526918.910:4): avc: denied { execute } for pid=92 comm="restorecon" path="/lib64/libc-2.5.so" dev=xvda2 ino=20 scontext=
system_u:system_r:restorecon_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=file
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526921.489:5): avc: denied { read } for pid=296 comm="pam_console_app" name="ld.so.cache" dev=xvda2 ino=94143 scontext=s
ystem_u:system_r:pam_console_t:s0-s0:c0.c1023 tcontext=system_u:object_r:file_t:s0 tclass=file
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526921.489:6): avc: denied { getattr } for pid=290 comm="pam_console_app" path="/etc/ld.so.cache" dev=xvda2 ino=94143 sc
ontext=system_u:system_r:pam_console_t:s0-s0:c0.c1023 tcontext=system_u:object_r:file_t:s0 tclass=file
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526921.530:7): avc: denied { read } for pid=293 comm="pam_console_app" name="libc.so.6" dev=xvda2 ino=21 scontext=system
_u:system_r:pam_console_t:s0-s0:c0.c1023 tcontext=system_u:object_r:file_t:s0 tclass=lnk_file
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526921.530:8): avc: denied { execute } for pid=293 comm="pam_console_app" path="/lib64/libc-2.5.so" dev=xvda2 ino=20 sco
ntext=system_u:system_r:pam_console_t:s0-s0:c0.c1023 tcontext=system_u:object_r:file_t:s0 tclass=file
Sep 13 05:02:55 localhost kernel: input: PC Speaker as /class/input/input3
Sep 13 05:02:55 localhost kernel: Initialising Xen virtual ethernet driver.
Sep 13 05:02:55 localhost kernel: Error: Driver 'pcspkr' is already registered, aborting...
Sep 13 05:02:55 localhost kernel: Floppy drive(s): fd0 is unknown type 15 (usb?), fd1 is unknown type 15 (usb?)
Sep 13 05:02:55 localhost kernel: floppy0: Unable to grab IRQ6 for the floppy driver
Sep 13 05:02:55 localhost kernel: lp: driver loaded but no devices found
Sep 13 05:02:55 localhost kernel: md: Autodetecting RAID arrays.
Sep 13 05:02:55 localhost kernel: md: Scanned 0 and added 0 devices.
Sep 13 05:02:55 localhost kernel: md: autorun ...
Sep 13 05:02:55 localhost kernel: md: ... autorun DONE.
Sep 13 05:02:55 localhost kernel: EXT3 FS on xvda2, internal journal
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526929.896:9): avc: denied { execute } for pid=965 comm="restorecon" path="/lib64/libc-2.5.so" dev=xvda2 ino=20 scontext
=system_u:system_r:restorecon_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=file
Sep 13 05:02:55 localhost kernel: kjournald starting. Commit interval 5 seconds
Sep 13 05:02:55 localhost kernel: EXT3 FS on xvda1, internal journal
Sep 13 05:02:55 localhost kernel: EXT3-fs: mounted filesystem with ordered data mode.
Sep 13 05:02:55 localhost kernel: kjournald starting. Commit interval 5 seconds
Sep 13 05:02:55 localhost kernel: EXT3 FS on xvdb1, internal journal
Sep 13 05:02:55 localhost kernel: EXT3-fs: mounted filesystem with ordered data mode.
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526930.647:10): avc: denied { execute } for pid=989 comm="setfiles" path="/lib64/libc-2.5.so" dev=xvda2 ino=20 scontext=
system_u:system_r:setfiles_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=file
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526942.398:11): avc: denied { net_admin } for pid=990 comm="setfiles" capability=12 scontext=system_u:system_r:setfiles
_t:s0 tcontext=system_u:system_r:setfiles_t:s0 tclass=capability
Sep 13 05:02:55 localhost kernel: hrtimer: interrupt took 35229469 ns
Sep 13 05:02:55 localhost kernel: Adding 2104504k swap on /dev/xvda3. Priority:-1 extents:1 across:2104504k SS
Sep 13 05:02:55 localhost kernel: warning: process `kudzu' used the deprecated sysctl system call with 1.23.
Sep 13 05:02:55 localhost kernel: Loading iSCSI transport class v2.0-870.
Sep 13 05:02:55 localhost kernel: libcxgbi:libcxgbi_init_module: tag itt 0x1fff, 13 bits, age 0xf, 4 bits.
Sep 13 05:02:55 localhost kernel: libcxgbi:ddp_setup_host_page_size: system PAGE 4096, ddp idx 0.
Sep 13 05:02:55 localhost kernel: Chelsio T3 iSCSI Driver cxgb3i v2.0.0 (Jun. 2010)
Sep 13 05:02:55 localhost kernel: iscsi: registered transport (cxgb3i)
Sep 13 05:02:55 localhost kernel: NET: Registered protocol family 10
Sep 13 05:02:55 localhost kernel: cnic: Broadcom NetXtreme II CNIC Driver cnic v2.2.14 (Mar 30, 2011)
Sep 13 05:02:55 localhost kernel: Broadcom NetXtreme II iSCSI Driver bnx2i v2.6.2.3 (Jan 06, 2010)
Sep 13 05:02:55 localhost kernel: iscsi: registered transport (bnx2i)
Sep 13 05:02:55 localhost kernel: iscsi: registered transport (tcp)
Sep 13 05:02:55 localhost kernel: iscsi: registered transport (iser)
Sep 13 05:02:55 localhost kernel: iscsi: registered transport (be2iscsi)
Sep 13 05:02:55 localhost kernel: ip6_tables: (C) 2000-2006 Netfilter Core Team
Sep 13 05:02:55 localhost kernel: warning: `mcstransd' uses 32-bit capabilities (legacy support in use)
Sep 13 05:02:55 localhost kernel: type=1400 audit(1347526970.336:12): avc: denied { sys_tty_config } for pid=1374 comm="consoletype" capability=26 scontext=system_u:system_r
:consoletype_t:s0 tcontext=system_u:system_r:consoletype_t:s0 tclass=capability
Sep 13 05:02:55 localhost kernel: RPC: Registered udp transport module.
Sep 13 05:02:55 localhost kernel: RPC: Registered tcp transport module.
Sep 13 05:02:55 localhost kernel: RPC: Registered tcp NFSv4.1 backchannel transport module.
Sep 13 05:03:00 localhost automount[1769]: lookup_read_master: lookup(nisplus): couldn't locate nis+ table auto.master
Sep 13 05:03:59 localhost kernel: type=1400 audit(1347527039.771:13): avc: denied { sys_tty_config } for pid=2029 comm="consoletype" capability=26 scontext=system_u:system_r
:consoletype_t:s0 tcontext=system_u:system_r:consoletype_t:s0 tclass=capability
Sep 13 05:04:00 localhost NET[2061]: /sbin/dhclient-script : updated /etc/resolv.conf
Sep 13 05:04:01 localhost kernel: IPv6 over IPv4 tunneling driver
Sep 13 05:04:01 localhost NET[2219]: /opt/oracle/psft/vm/oraclevm-template.sh : updated /etc/resolv.conf
Sep 13 05:04:08 localhost NET[2472]: /etc/sysconfig/network-scripts/ifup-post : updated /etc/resolv.conf
Sep 13 05:06:08 localhost restorecond: Reset file context /etc/resolv.conf: system_u:object_r:etc_runtime_t:s0->system_u:object_r:net_conf_t:s0
Sep 13 05:08:19 localhost kernel: Slow work thread pool: Starting up
Sep 13 05:08:19 localhost kernel: Slow work thread pool: Ready
Sep 13 05:08:19 localhost kernel: FS-Cache: Loaded
Sep 13 05:08:19 localhost kernel: FS-Cache: Netfs 'nfs' registered for caching
Sep 13 05:08:19 localhost kernel: svc: failed to register lockdv1 RPC service (errno 97).
...Well, I don't know if it triggers others problems yet, but the last line could reveale an error within the /etc/hosts file which has not been properly modified during deployment (especially IPV6, it probably should be removed) :
[root@psovmfscmfp2 /]# more /etc/hosts
127.0.0.1 localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6
192.168.1.150 psovmfscmfp2.phoenix.nga psovmfscmfp2
[root@psovmfscmfp2 /]#_2. Now about the COBOL_
Despite I choosed to install Microfocus, COBOL does not work. Sample COBOL processes such as PTPDBTST and PTPDTTST finished in error.
The log is empty, here below the output from the file $PS_CFG_HOME/psft/pt/8.52/appserv/prcs/PRCSDOM/LOGS/stdout (psadm2) :
=================================Error===============================
Message: Process 10899 is marked 'Initiated' or 'Processing' but can not detect status of PID
Process Name: PTPDBTST
Process Type: COBOL SQL
Session Id: 9313
=====================================================================
OprId = VP1Note that I successfully tested AEs and SQRs.
Here is the command line fired that I can see from the process monitor > parameter (nga is being my run control id) :
PSRUN PTPDBTST ORACLE/F91TMPLT/VP1/OPRPSWD/nga/10899//0 I used the following trace setting on the PTPDBTST's process parameter (override) to see what happens :
%%DBTYPE%%/%%DBNAME%%/%%OPRID%%/%%OPRPSWD%%/%%RUNCNTLID%%/%%INSTANCE%%//%%DBFLAG%%But it does not generate more logs...
I also use "RCCBL Redirect =1" in psappsrv.cfg (reconfigure and restart appdom), then start the COBOL through menu PeopleTools > Utilities > Debug > PeopleTools Test Utilities, and run a "Remote Call Test".
I received "COBOL Program PTPNTEST aborted (2,-1) FUNCLIB_UTIL.RC_TEST_PB.FieldChange PCPC:2143 Statement:26", but it generated two empty files (PTPNTEST_VP1_0913064910.out and PTPNTEST_VP1_0913064910.err).
Next step, checking the folder $PS_HOME/cblbin, it is...er... empty... does this mean COBOL have not been compiled ? Hmmm, I'm pretty sure I replied 'yes' when it was prompted though (still have the screenshots)...
And we can see several folders dated from today and license seems ok from Microfocus directories :
[psadm1@psovmfscmfp2 tools]$ cd /opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit
[psadm1@psovmfscmfp2 svrexp-51_wp4-64bit]$ ls -lrt
total 264
-r--r--r-- 1 root root 10455 Nov 19 2009 ADISCTRL
dr-xr-xr-x 10 root root 4096 Nov 19 2009 terminfo
dr-xr-xr-x 2 root root 4096 Nov 19 2009 xdb
-r--r--r-- 1 root root 11949 Nov 19 2009 eslmf-mess
dr-xr-xr-x 2 root root 4096 Nov 19 2009 include
dr-xr-xr-x 17 root root 4096 Nov 19 2009 lang
dr-xr-xr-x 4 root root 4096 Nov 19 2009 es
dr-xr-xr-x 2 root root 4096 Nov 19 2009 dynload
drwxrwxrwx 2 root root 4096 Nov 19 2009 deploy
dr-xr-xr-x 2 root root 4096 Nov 19 2009 dynload64
dr-xr-xr-x 2 root root 4096 Nov 19 2009 dialog
dr-xr-xr-x 2 root root 4096 Nov 19 2009 cpylib
dr-xr-xr-x 8 root root 28672 Nov 19 2009 lib
dr-xr-xr-x 3 root root 4096 Nov 19 2009 snmp
dr-xr-xr-x 8 root root 4096 Nov 19 2009 src
dr-xr-xr-x 28 root root 4096 Nov 19 2009 demo
dr-xr-xr-x 6 root root 4096 Nov 19 2009 docs
-rw-r--r-- 1 root root 49 Sep 13 05:13 license.txt
-r-xr-xr-x 1 root root 12719 Sep 13 05:13 install.orig
-r-xr-xr-x 1 root root 13006 Sep 13 05:13 install
dr-xr-xr-x 6 root root 4096 Sep 13 05:13 lmf
dr-xr-xr-x 2 root root 4096 Sep 13 05:13 aslmf
dr-xr-xr-x 6 root root 4096 Sep 13 05:15 etc
dr-xr-xr-x 4 root root 12288 Sep 13 05:15 bin
[psadm1@psovmfscmfp2 svrexp-51_wp4-64bit]$ more license.txt
I
ORACLE-30DAYDEV64
01030 A0780 014A6 7980B A17CSo let's assume it has been properly installed and let's compile the COBOLs. Here we go :
[psadm1@psovmfscmfp2 svrexp-51_wp4-64bit]$ cd $PS_HOME/setup
[psadm1@psovmfscmfp2 setup]$ ./pscbl.mak
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Convert all files for Unicode ....
Conversion Summary for Source Codes in :
Source: /opt/oracle/psft/pt/tools/src/cbl/
Target: /opt/oracle/psft/pt/tools/src/cblunicode/
Number of Copy Libraries Read: 71
Modified: 71
Not Modified: 0
Number of Programs Read: 44
Modified: 44
Not Modified: 0
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : All COBOL files were converted for Unicode successfully
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Compiling PTPCBLAE.cbl ...
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak: line 249: cob: command not found
cp: cannot stat `PTPCBLAE.gnt': No such file or directory
cp: cannot stat `PTPCBLAE.int': No such file or directory
cp: cannot stat `PTPCBLAE.lst': No such file or directory
...What about env. variables ? COBDIR, COBPATH and COBOL do not appears anywhere in PATH...
[psadm1@psovmfscmfp2 setup]$ env|grep -i cobol
[psadm1@psovmfscmfp2 setup]$Let's set the env variables as we could expect to be (page 27, step 17 of the given doc), and retry to compile the COBOL :
[psadm1@psovmfscmfp2 setup]$ export COBDIR=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit
[psadm1@psovmfscmfp2 setup]$ export LD_LIBRARY_PATH=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit/lib:$LD_LIBRARY_PATH
[psadm1@psovmfscmfp2 setup]$ export PATH=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit/bin:$PATH
[psadm1@psovmfscmfp2 setup]$ ./pscbl.mak
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Convert all files for Unicode ....
Conversion Summary for Source Codes in :
Source: /opt/oracle/psft/pt/tools/src/cbl/
Target: /opt/oracle/psft/pt/tools/src/cblunicode/
Number of Copy Libraries Read: 71
Modified: 71
Not Modified: 0
Number of Programs Read: 44
Modified: 44
Not Modified: 0
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : All COBOL files were converted for Unicode successfully
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Compiling PTPCBLAE.cbl ...
Micro Focus LMF - 010: Unable to contact license manager. This product has been unable to contact the License Manager. Execution of this product has been terminated. This product cannot execute without the License Manager. Contact your license administrator or refer to the 'Information Messages' chapter of the License Management Facility Administrator's Guide.
cob64: error(s) in compilation: PTPCBLAE.cbl
cp: cannot stat `PTPCBLAE.gnt': No such file or directory
cp: cannot stat `PTPCBLAE.int': No such file or directory
cp: cannot stat `PTPCBLAE.lst': No such file or directory
...Ok, maybe a bit better, at least it is trying to contact LMF. Probably the LMF is not started. Let's try to start it :
[root@psovmfscmfp2 microfocus]# ./mflmman
MF-LMF:Thu Sep 13 07:19:37 2012: LMF Starting
[root@psovmfscmfp2 microfocus]#Good, it is starting, it means it wasn't (sic). Now retry to compile :
[psadm1@psovmfscmfp2 setup]$ export COBDIR=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit
[psadm1@psovmfscmfp2 setup]$ export LD_LIBRARY_PATH=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit/lib:$LD_LIBRARY_PATH
[psadm1@psovmfscmfp2 setup]$ export PATH=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit/bin:$PATH
[psadm1@psovmfscmfp2 setup]$ ./pscbl.mak
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Convert all files for Unicode ....
Conversion Summary for Source Codes in :
Source: /opt/oracle/psft/pt/tools/src/cbl/
Target: /opt/oracle/psft/pt/tools/src/cblunicode/
Number of Copy Libraries Read: 71
Modified: 71
Not Modified: 0
Number of Programs Read: 44
Modified: 44
Not Modified: 0
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : All COBOL files were converted for Unicode successfully
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Compiling PTPCBLAE.cbl ...
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Compiling PTPCURND.cbl ...
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Compiling PTPDBTST.cbl ...
<snipped>
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : Compiling PTPWLGEN.cbl ...
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : All COBOL programs have been successfully compiled.
/opt/oracle/psft/pt/tools/setup/pscbl_mf.mak : The COBOL executables were copied to /opt/oracle/psft/pt/tools/cblbin
rm: cannot remove `/opt/oracle/psft/pt/apptools/src/cblunicode/CECCRLP1.cbl': Permission denied
rm: cannot remove `/opt/oracle/psft/pt/apptools/src/cblunicode/CECCRLUP.cbl': Permission deniedIt looks better, I think the last lines marked with "Permission denied" can be safely be ignored.
Those files are owned by psadm3 with a read only for other users (sic). But more concern, I'm wondering why it looks into apptools (???) whereas I'm using psadm1 (tools only, COBPATH=/opt/oracle/psft/pt/tools/cblbin).
Anyway, seems the *.gnt files required to run the COBOLs programs are now in bin :
[psadm1@psovmfscmfp2 setup]$ ls /opt/oracle/psft/pt/tools/cblbin
PTPCBLAE.gnt PTPDTTST.gnt PTPECOBL.gnt PTPLOGMS.gnt PTPRATES.gnt PTPSQLGS.gnt PTPTESTU.gnt PTPTSCNT.gnt PTPTSLOG.gnt PTPTSTBL.gnt PTPTSWHR.gnt
PTPCURND.gnt PTPDTWRK.gnt PTPEFCNV.gnt PTPMETAS.gnt PTPRUNID.gnt PTPSQLRT.gnt PTPTESTV.gnt PTPTSEDS.gnt PTPTSREQ.gnt PTPTSUPD.gnt PTPUPPER.gnt
PTPDBTST.gnt PTPDYSQL.gnt PTPERCUR.gnt PTPNETRT.gnt PTPSETAD.gnt PTPSTRFN.gnt PTPTFLDW.gnt PTPTSEDT.gnt PTPTSSET.gnt PTPTSUSE.gnt PTPUSTAT.gnt
PTPDEC31.gnt PTPECACH.gnt PTPESLCT.gnt PTPNTEST.gnt PTPSHARE.gnt PTPTEDIT.gnt PTPTLREC.gnt PTPTSFLD.gnt PTPTSTAE.gnt PTPTSWHE.gnt PTPWLGEN.gnt
[psadm1@psovmfscmfp2 setup]$Have a try to link COBOLs :
[psadm1@psovmfscmfp2 setup]$ ./psrun.mak
./psrun.mak - linking PSRUN for oel-5-x86_64, Version 2.6.32-200.13.1.el5uek ...
./psrun.mak - Successfully created PSRUN in directory: /opt/oracle/psft/pt/tools/bin
./psrun.mak - linking PSRUNRMT for oel-5-x86_64, Version 2.6.32-200.13.1.el5uek ...
./psrun.mak - Successfully created PSRUNRMT in directory: /opt/oracle/psft/pt/tools/bin
[psadm1@psovmfscmfp2 setup]$The err files are empty :
-rw-r--r-- 1 psadm1 oracle 0 Sep 13 07:26 psrun.err
-rw-r--r-- 1 psadm1 oracle 0 Sep 13 07:26 psrunrmt.errSo far, so good now. We are able to test again the sample COBOL... until next failure.
Yes, unfortunately, it fails again. But good thing, the log is not empty now :
PSRUN: error while loading shared libraries: libcobrts64.so: cannot open shared object file: No such file or directoryThat's probably coming from some missing libraries during the psprcs.cfg configuration. Let's use the same env. variables settings as for psadm1 when compiling COBOLs.
[psadm2@psovmfscmfp2 appserv]$ export COBDIR=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit
[psadm2@psovmfscmfp2 appserv]$ export LD_LIBRARY_PATH=$COBDIR/lib:$LD_LIBRARY_PATH
[psadm2@psovmfscmfp2 appserv]$ export PATH=$COBDIR/bin:$PATH
[psadm2@psovmfscmfp2 appserv]$ ./psadminReconfigure, restart prcs and re-test... SUCCESSFULLY !!!!!!!!!!!!!!!!!!!!!!!!!
Log from PTPDBTST process shows :
SUCCESSFUL DATABASE CONNECTION
SUCCESSFUL DATABASE DISCONNECTWhat a pain !
I did not go further, but we could expect the same issue within the Application COBOLs, since the cblbin directory is also empty out there.
According to psprcs.env, there're two values for COBDIR and the one for the applications cobol is empty :
[psadm2@psovmfscmfp2 PRCSDOM]$ more psprcsrv.env
INFORMIXSERVER=192.168.1.149
COBPATH=/opt/oracle/psft/pt/apptools/cblbin:/opt/oracle/psft/pt/tools/cblbin
PATH=/opt/oracle/psft/pt/apptools/bin:/opt/oracle/psft/pt/apptools/bin/interfacedrivers::/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit/bin:/opt/oracle/psft/pt/tools/appserv:/opt
/oracle/psft/pt/tools/setup:/opt/oracle/psft/pt/tools/jre/bin:/opt/oracle/psft/pt/bea/tuxedo/bin:.:/opt/oracle/psft/pt/oracle-client/11.2.0.x/bin:/opt/oracle/psft/pt/oracle-clie
nt/11.2.0.x/perl/bin:/usr/local/bin:/bin:/usr/bin:/opt/oracle/psft/pt/tools/bin:/opt/oracle/psft/pt/tools/bin/sqr/ORA/bin:/opt/oracle/psft/pt/tools/verity/linux/_ilnx21/bin:/hom
e/psadm2/bin:.
[psadm2@psovmfscmfp2 PRCSDOM]$ ls /opt/oracle/psft/pt/apptools/cblbin
[psadm2@psovmfscmfp2 PRCSDOM]$ ls /opt/oracle/psft/pt/tools/cblbin
PTPCBLAE.gnt PTPDTTST.gnt PTPECOBL.gnt PTPLOGMS.gnt PTPRATES.gnt PTPSQLGS.gnt PTPTESTU.gnt PTPTSCNT.gnt PTPTSLOG.gnt PTPTSTBL.gnt PTPTSWHR.gnt
PTPCURND.gnt PTPDTWRK.gnt PTPEFCNV.gnt PTPMETAS.gnt PTPRUNID.gnt PTPSQLRT.gnt PTPTESTV.gnt PTPTSEDS.gnt PTPTSREQ.gnt PTPTSUPD.gnt PTPUPPER.gnt
PTPDBTST.gnt PTPDYSQL.gnt PTPERCUR.gnt PTPNETRT.gnt PTPSETAD.gnt PTPSTRFN.gnt PTPTFLDW.gnt PTPTSEDT.gnt PTPTSSET.gnt PTPTSUSE.gnt PTPUSTAT.gnt
PTPDEC31.gnt PTPECACH.gnt PTPESLCT.gnt PTPNTEST.gnt PTPSHARE.gnt PTPTEDIT.gnt PTPTLREC.gnt PTPTSFLD.gnt PTPTSTAE.gnt PTPTSWHE.gnt PTPWLGEN.gnt
[psadm2@psovmfscmfp2 PRCSDOM]$The directory "/opt/oracle/psft/pt/apptools/cblbin" is owned by psadm3 and hosted on the database server (nfs mounted), so I assume we also need to set proper values for env variables, and compile the COBOLs before being able to use them.
To resume what I did to make the COBOLs working on this PSOVM :
1. As root, start LMF (this has to be done only once)
cd /opt/oracle/psft/pt/cobol/microfocus
./mflmman
2. As psadm1, set proper env. variable and compile (setting env variable has to be done each time you want to compile COBOLs)
export COBDIR=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit
export LD_LIBRARY_PATH=$COBDIR/lib:$LD_LIBRARY_PATH
export PATH=$COBDIR/bin:$PATH
cd $PS_HOME/setup
./pscbl.mak
./psrun.mak
3. As psadm2, set proper env. variable and reconfigure psprcs.cfg, restart, restart (setting env variable has to be done each time you want to start the process scheduler, so probably better to append these in the .bash_profile)
export COBDIR=/opt/oracle/psft/pt/cobol/svrexp-51_wp4-64bit
export LD_LIBRARY_PATH=$COBDIR/lib:$LD_LIBRARY_PATH
export PATH=$COBDIR/bin:$PATH
cd $PS_HOME/appserv
./psadmin
4. Same as step 2, but with user psadm3.
HTH,
Nicolas.
PS: will it be the same issue on the HCM template delivered at the same time ? To be tested as well.
PS2: and yes, I tested it twice before posting, result is same.
Edited by: N Gasparotto on Sep 13, 2012 5:17 PMFortunately, the COBOL issue does not exist on PSOVM HCM9.1 FP2 PT8.52.06 delivered in July 2012 (v3). COBOL are properly compiled (tools and app COBOLs), cblbin is not empty and they run successfully on the first shot.
Nicolas. -
Multiple instances of the same bean class in session?
I�m trying to think of a way to have multiple instances of the same bean class in session scope using JSF. For example, let�s say that I have two <h:dataTable>s on the same page. They both use the backing bean called genericBean. Now, the content for genericBean will be different for each <h:dataTable>. In fact, the data source that backs genericBean is not known until runtime. It could be a database, web service, etc.
What I would like is for when JSF needs access genericBean instead of looking for the value with key �genericBean� in the session map it looks for �genericBean_[some runtime ID]�. I could specify this id in EL on a custom component, as a request parameter or whatever.
I think that I need the bean to be in session scope because the tables are complex and I want them to be editable.
I have some ideas about how I can do this but I was wondering if someone has already solved this problem or if there is a standard way to do this using tools like Shale, etc.
Thanks,
RandyWell, I came up with an interesting solution to this so I thought that I would post it here.
I have a page that looks like this.
<html>
<head>
<title>My Page</title>
</head>
<body>
<f:view>
<f:subview id="component1">
<jsp:include page="component.jsp">
<jsp:param name="id" value="a" />
</jsp:include>
</f:subview>
<hr>
<f:subview id="component2">
<jsp:include page="component.jsp">
<jsp:param name="id" value="b" />
</jsp:include>
</f:subview>
</f:view>
</body>
</html>
And component.jsp looke like this.
<f:verbatim>
<p>
<h1>Component
</f:verbatim>
<h:outputText value=" #{param.id}" />
<f:verbatim>
</h1>
</p>
</f:verbatim>
<h:form>
<h:outputText value="#{component.id}" />
<h:outputText value="#{component.value}" />
<h:commandButton value="increment" action="#{component.increment}" />
<h:commandButton value="decrement" action="#{component.decrement}" />
<f:verbatim>
<input type="hidden" name="id"
value="</f:verbatim><h:outputText value="#{param.id}"/><f:verbatim>" />
</f:verbatim>
</h:form>
The idea is that I want component.jsp to be initialized differently based on the id param. The component managed bean is configured to be in session scope but I want the component instance for id a and id b to be different instances in session scope. Therefore, I added a custom variable resolver to handle this.
public Object resolveVariable(FacesContext context, String name) {
// This id will be different for the different subviews.
HttpServletRequest request = (HttpServletRequest) context.getExternalContext() .getRequest();
String id = request.getParameter("id");
// If there is an id in the request then check if this is a bean that can have multiple
// instances in session scope.
if ((id != null) && (id.length() > 0)) {
ExternalContext ec = context.getExternalContext();
// Build the new name for the key of this bean
String newName = name + "_" + id;
Object value = null;
// See if the bean instance already esists.
if ((null == (value = ec.getRequestMap().get(newName))) &&
(null == (value = ec.getSessionMap().get(newName))) &&
(null == (value = ec.getApplicationMap().get(newName)))) {
// We could not find the bean instance in scope so create the bean
// using the standard variable resolver.
value = original.resolveVariable(context, name);
// Now check if the bean implements that page component interface. If it is
// a page component then we want to rename the key to access this bean so
// that the instance is only used when the id is provided in the request.
// For example, if there are two components (a and b) we will have in session scope
// component_a and component_b. The will each point to a unique instance of the
// Component bean class.
if (value instanceof PageComponent) {
// Try to get the value again
if (null != (value = ec.getRequestMap().get(name))) {
// Initialize the bean using the id
((PageComponent) value).initInstance(id);
ec.getRequestMap().remove(name);
ec.getRequestMap().put(newName, value);
} else if (null != (value = ec.getSessionMap().get(name))) {
((PageComponent) value).initInstance(id);
ec.getSessionMap().remove(name);
ec.getSessionMap().put(newName, value);
} else if (null != (value = ec.getApplicationMap().get(name))) {
((PageComponent) value).initInstance(id);
ec.getApplicationMap().remove(name);
ec.getApplicationMap().put(newName, value);
return value;
return original.resolveVariable(context, name);
} -
Where can I learn more about the Logic Environment?
I've been using LogicPro for a while now - since version 7 came out - and I'm ready to learn more about the mysterious Logic Environment. Anyone know of a good tutorial or website on this topic? I don't have a specific question - what I need is a general overview.
My sessions are primarily audio recording and mixing with a virtual instrument from time to time. I rarely use MIDI except to play the synths and instruments.
My environmental experience so far has been limited to creating and naming audio objects, accessing "hidden" faders and as an alternate to the mix views provided in the global and track mixers.
I'd prefer free advice but I'm not against paying if it's worth it. I have read the manual but I have a feeling that it will be more helpful once I have a better grasp on the big picture. It's a reference manual more than a how-to.
My MIDI devices are an Axiom-61 and PreSonus FaderPort.
Thanks,
John
Message was edited by: John CurleyApple has what they call "online seminars" available on the main Logic page
http://www.apple.com/logicpro/
If you look on the bottom right hand side of the page, you see a link for online seminars. You'll have to go through a regstration process, then you can watch 3 or 4 streaming Quicktime videos of people using different functions in Logic. There's nothing really in depth there, but it does show you a few useful shortcuts and methods. -
Creating a Folder Within Form or Document Library & Display the name not in the name column.
I have created a form library that will used to create folders within that. The folder creation is done using an InfoPath Form that has been uploaded to the Form Library. When the new folder was created the name will be displayed at the Name column within
the Form Library. I want to change that to another column like documents or suchlike.
Can it be done using InfoPath 2010 VSTA C# or not? If their are other options available please could you try to inform me!
Thank You,
ChiranthakaHi,
If you want to show the name of folder in another column, a workaround is that you can create an extra column, then create a SharePoint Designer workflow to set the value of
this column with the name of folder.
Here is a link about Create Workflow using SharePoint Designer and set field value for your reference:
http://www.codeproject.com/Tips/419037/Create-Workflow-using-SharePoint-Designer
I have seen a similar post from you in the link below:
http://social.technet.microsoft.com/Forums/en-US/c3ff3f17-dbe2-40f9-86c5-ff7d4b663f09/creating-a-folder-within-form-or-document-library-display-the-name-not-in-the-name-column?forum=sharepointcustomizationprevious
It's recommended that you post a single question in a single thread which will make it easier to be discussed by others.
Best regards
Patrick Liang
TechNet Community Support
Maybe you are looking for
-
I installed Premiere Pro CS 6.0 on a brand new system. Win 8.1, i7 3.4 GHz on an Asus Sabertooth 16 Gig memory AMD Radeon R9 290 Graphics Board with the latest drivers and Bios. On starting Premiere I get the (as I noticed quite frequent appearing) e
-
If two people share the same computer, but have separate itunes account, Apple ID, and icloud and one of them downloads an app will it also go into the other persons account since y'all use the same computer
-
Can't Install iOS4 onto iTouch! And How to Backup?
I have iTouch 3G(8GB). I synced my iTouch yesterday. Took it off the computer then I updated iTunes to iTune9. Then I replugged iPod in and hit the "Check for Updates" and the computer started to download the iOS4 software. Then it "Prepared iPod for
-
How to keep photo files in order upon export?
My wife has imported two sets of files from two different cameras into iPhoto. Due to date/time stamping errors in the cameras these files did not import in the order she hoped. Consequently she created an Album and renamed and reordered the .jpg f
-
Remove message from AQ after reading?
I have created a java message driven bean that it equaling an AQ. The AQ has been created with multiple_subcriber=>true. How can I manage that the message is been removed after it has been distributed to the MDB?