WLST Scope
If anybody reading , knw answer to my question ..MAY REPLY
1)thru WLST can i deploy my ejb bean ,war .ear file to runing server ? how ? bcs
we ahve distrbutes teams those all wld be wrkign on diff location and later need
to confugre aplction at 1 location ..any more clrfction needed
Anil,
Yes you can deploy to a running server.
deploy("myApp","c:/myApplications/foo.war","myserver,managed1")
thanks,
-satya
Anil wrote:
If anybody reading , knw answer to my question ..MAY REPLY
1)thru WLST can i deploy my ejb bean ,war .ear file to runing server ? how ? bcs
we ahve distrbutes teams those all wld be wrkign on diff location and later need
to confugre aplction at 1 location ..any more clrfction needed
Similar Messages
-
Creation of Customisation file from WLST Script in OSB
Hi,
Please help in creating Customisation file in OSB from WLST ScriptsHi,
Please refer -
Create Customization File in OSB 10g with WLST script
http://download.oracle.com/docs/cd/E13159_01/osb/docs10gr3/deploy/config_appx.html
http://download.oracle.com/docs/cd/E13159_01/osb/docs10gr3/javadoc/com/bea/wli/config/customization/Customization.html
Regards,
Anuj -
What deterimes the amount of data in a waveform from a TDS 1012 scope
Hello,
What determines the amount of data that is in a waveform that comes out of a TDS 1012 scope? I am assuming that I will have to look at the driver vi to determine the commands sent to the scope to figure it out. I am in a situation that I need to have the y axis to have a high resolution, that results in very little data being collected from the scope.
Regards,
Kaspar
Regards,
KasparHello,
The amount of data that comes out of the TDS 1012 scope is determined by the data start (DATaTARt) and data stop (DATaTOP) commands that are defined on page 58 (2-38) in the 346 page programming manual for the scope. I found of that the data start was not set to 1, which is the beginning of the data.
I also had a very low level signal on channel that was all most unreadable by the scope that caused me to think that I was not getting all of the data.
Regards,
Kaspar
Regards,
Kaspar -
Accessing message out of scope
Hi all,
I have a message "Message_A" constructed inside the scope shape and being sent to the send port. Now when any exception occurs i need to log the details to the database. I have an exception handler with the expression in the construct message as
below
Excep_message(FILE.ReceivedFileName)=Message_A(FILE.ReceivedFileName);
I received the error "use of unconstructed message 'Message_A'" when compiling the project. For this error i constructed the message "Message_A" before the scope shape as below.
Message_A=null;
Message_A(BTS.Operation)="Operation";
Then i was able to compile the project without any error. When i deployed and the application exectued i got the below error.
xlang/s engine event log entry: Uncaught exception (see the 'inner exception' below) has suspended an instance of service 'Ibox.UNEDIFACT.COPARN.Orchestration.CoparnOrchestration_AEJEA(3f2f8342-08cd-6b69-c647-d13dc48b24ad)'.
The service instance will remain suspended until administratively resumed or terminated.
If resumed the instance will continue from its last persisted state and may re-throw the same unexpected exception.
InstanceId: 5bbb4a82-19ae-48bc-8bc0-b8c992088c68
Shape name: ConstructMessage_1
ShapeId: a849f763-3f7f-4bc3-bea2-9887fc3c7415
Exception thrown from: segment 1, progress 10
Inner exception: The part 'part' of message 'Message_A' contained a null value at the end of the construct block.
Exception type: NullPartException
Source: Microsoft.XLANGs.Engine
Target Site: Void ConstructionCompleteEvent(Boolean)
The following is a stack trace that identifies the location where the exception occured
at Microsoft.XLANGs.Core.Part.ConstructionCompleteEvent(Boolean fKillUnderlyingPart)
at Microsoft.XLANGs.Core.XMessage.ConstructionCompleteEvent(Boolean killUnderlyingPartWhenDirty)
at Ibox.UNEDIFACT.COPARN.Orchestration.CoparnOrchestration_AEJEA.segment1(StopConditions stopOn)
at Microsoft.XLANGs.Core.SegmentScheduler.RunASegment(Segment s, StopConditions stopCond, Exception& exp)
Kindly assist why the null error is being raised even when i have assigned the Message_A with a value.
Regards, Vivin.You assigned Message_A with a null value, that's where the null error is raised!
To assign Message_A with a value you will need to execute a mapping or assign it with a variable that contains a xmlDocument if your Message_A is a generic message.
Another question: why do you want a null Message_A on your messagebox? Is that the required behavior?
Be sure to also check following blog by Paole, it contains everything you need to know about processing and creating xlangmessages:
http://blogs.msdn.com/b/appfabriccat/archive/2010/06/23/4-different-ways-to-process-an-xlangmessage-within-an-helper-component-invoked-by-an-orchestration.aspx
Glenn Colpaert - Microsoft Integration MVP - Blog : http://blog.codit.eu -
What is the scope of implicit loop variables?
Hi,
I'm facing some strange error from the ABSL editor (syntax checker).
In ABSL the loop variables are implicit and don't have to be declared in the head section of the script.
My question now is simple: How is the scope/visibility of such loop variables specified ?
There's a complete code snippet below.
In line no.9, there's the first time use of implicit loop variable 'task_inst'.
Because of type inference, it will be typed as MasterDataWanneBe/Tasks (which is my own BO type).
In line no.20, I want to use the same variable name in a different loop, outside the parenthesis/scope of the first first use.
Now the ABSL syntax checker complains about incompatible types (see code snippet)
Thus the type inference should result in the, (lets say 'local') type Project/Task, which is the one I was querying for.
To me it looks like, that loop variables implicitly get a global scope (hopefully bound to this ABSL file only).
I would like to see the scope/visibility of loop variables restricted to the parenthesis.
In other words only inside the loop.
Hint
I heard (from little sparrows), that local variable scoping is not possible because of underlying
generated ABAP code. If so, than it would be helpful to print warnings, in case of types are compatible
but used in different scopes. Think about the unintended side effects.
import ABSL;
import AP.ProjectManagement.Global;
var query_tasks;
var query_tasks_param;
var query_tasks_result;
foreach (empl_inst in this.Employees) {
foreach (task_inst in empl_inst.Tasks) {
// ^^^^^^^^^ first time use
task_inst.Delete();
// ===========================================================================
query_tasks = Project.Task.QueryByResponsibleEmployee;
query_tasks_param = query_tasks.CreateSelectionParams();
query_tasks_result = query_tasks.Execute(query_tasks_param);
foreach (task_inst in query_tasks_result) {
// ^^^^^^^^^ Error: 4
// The foreach loop variable is already inferred to an incompatible type:
// Node(MasterDataWanneBe/Tasks). Expected Node(Project/Task)Yes, variable declarations in ByD Scripting Language indeed have (snippet) global visibility. In the FP 3.0 release the variables can be declared anywhere in the snippet (not only in the beginning, as with FP 2.6), however still not within code blocks, i.e. within curly braces ({}). Therefore variable name shadowing is still not supported and because of the global visibility of variables they cannot be reused for a different type, later in the same snippet. This is because of the statically typed nature of ByD Script, despite the type inference convenience.
Kind regards,
Andreas Mueller -
Weblogic 10.3.2/3 AdminServer startup failure using WLST
Hi,
I'm migrating our Weblogic environments onto a Linux platform(Centos 5.5). I'm running 64bit Java and I've installed Weblogic using the Generic Jar. However I expierence an error when attempting to Start the AdminServer using a WLST script. If I then execute ./startWeblogic.sh the server starts without any problems.
I create the domain fine, I then start the AdminServer within WLST to make some configuration changes username/password etc. Starting the AdminServer generates an error error see below.
This happens on both versions of Weblogic 10.3.2 & 10.3.3. I've just tried starting the server directly via WLST and I get the same issue.
Starting weblogic server ...
WLST-WLS-1289993140407: <Nov 17, 2010 11:25:41 AM GMT> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with Java HotSpot(TM) 64-Bit Server VM Version 17.1-b03 from Sun Microsystems Inc.>
WLST-WLS-1289993140407: <Nov 17, 2010 11:25:41 AM GMT> <Info> <Management> <BEA-141107> <Version: WebLogic Server 10.3.2.0 Tue Oct 20 12:16:15 PDT 2009 1267925 >
WLST-WLS-1289993140407: <Nov 17, 2010 11:25:42 AM GMT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
WLST-WLS-1289993140407: <Nov 17, 2010 11:25:42 AM GMT> <Info> <WorkManager> <BEA-002900> <Initializing self-tuning thread pool>
WLST-WLS-1289993140407: <Nov 17, 2010 11:25:42 AM GMT> <Notice> <Log Management> <BEA-170019> <The server log file /strata/clients/inc39/Stream5/CDL/Logs/AdminServer_%yyyy%%MM%%dd%.log is opened. All server side log events will be written to this file.>
.WLST-WLS-1289993140407: <Nov 17, 2010 11:25:44 AM GMT> <Notice> <Security> <BEA-090082> <Security initializing using security realm myrealm.>
.WLST-WLS-1289993140407: <Nov 17, 2010 11:25:47 AM GMT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STANDBY>
WLST-WLS-1289993140407: <Nov 17, 2010 11:25:47 AM GMT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
.WLST-WLS-1289993140407: <Nov 17, 2010 11:25:49 AM GMT> <Notice> <StdErr> <BEA-000000> <Nov 17, 2010 11:25:49 AM com.sun.faces.config.ConfigureListener contextInitialized
WLST-WLS-1289993140407: INFO: Initializing Sun's JavaServer Faces implementation (1.2_03-b04-FCS) for context '/console'>
WLST-WLS-1289993140407: <Nov 17, 2010 11:25:49 AM GMT> <Notice> <StdErr> <BEA-000000> <Nov 17, 2010 11:25:49 AM com.sun.faces.config.ConfigureListener contextInitialized
WLST-WLS-1289993140407: INFO: Completed initializing Sun's JavaServer Faces implementation (1.2_03-b04-FCS) for context '/console'>
...WLST-WLS-1289993140407: Stopped draining WLST-WLS-1289993140407
WLST-WLS-1289993140407: Stopped draining WLST-WLS-1289993140407
java -version
java version "1.6.0_22"
Java(TM) SE Runtime Environment (build 1.6.0_22-b04)
Java HotSpot(TM) 64-Bit Server VM (build 17.1-b03, mixed mode)How is your script constructed?
The following shows an example of a startscript:
beahome = '<middleware-home>';
linux = true;
adminusername = 'username';
adminpassword = 'password';
domainname = 'DomainName';
pathseparator = '/';
if not linux:
pathseparator = '\\';
domainlocation = beahome + pathseparator + 'user_projects' + pathseparator + 'domains' + pathseparator + domainname;
nodemanagerhomelocation = beahome + pathseparator + 'wlserver_10.3' + pathseparator + 'common' + pathseparator + 'nodemanager';
print 'START NODE MANAGER';
startNodeManager(verbose='true', NodeManagerHome=nodemanagerhomelocation, ListenPort='5556', ListenAddress='localhost');
print 'CONNECT TO NODE MANAGER';
nmConnect(adminusername, adminpassword, 'localhost', '5556', domainname, domainlocation, 'ssl');
print 'START ADMIN SERVER';
nmStart('AdminServer');
nmServerStatus('AdminServer');
print 'CONNECT TO ADMIN SERVER';
connect(adminusername, adminpassword); -
How to get a parameter from each request in a session scope BackingBean
While calling my JSF page, I pass an id as parameter in the URL, and in the Backing bean I retrieve it from the request.
On each request I need to get the id and populate the page accordingly.
But I am forced to create my Backing Bean in session scope b'cos otherwise ValueChangeListener method does not work properly.
So where and how do I get the id on each request?
Pls. helpWhat you can do is create it in the request scope like this:
<managed-bean>
<managed-bean-name>personBean</managed-bean-name>
<managed-bean-class>
com.PersonBean
</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
<managed-property>
<property-name>id</property-name>
<property-class>java.lang.Long</property-class>
<value>#{param.id}</value>
</managed-property>
</managed-bean>And then in the page use a hidden field to set the id in case of a postback (validation error):
<h:inputHidden id="id" value="#{personBean.id}"/>Does that help you?
Thomas -
Getting bean from request scope
Hi,
I am new to JSF and unfortunately I am running into a problem that I am not entirely sure about. I look in other forums and what I am doing looks right but I am not getting the desired result.
In my faces-config.xml file I have a managed bean defined as follows:
<managed-bean>
<managed-bean-name>LogIn</managed-bean-name>
<managed-bean-class>lex.cac.tables.RefUsers</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
</managed-bean>I then have a log on page with a form which contains a user name and password field. The tags are defined as
<h:inputText immediate="false" value="#{LogIn.username}" /> (for username) and
<h:inputSecret immediate="false" required="true"
value="#{LogIn.password}" /> (for password)
When I submit the form the web app navigates to a jsp page which attempts to do validation against a database.
The first step though is retrieving the object which is suppose to be in request scope.
I attempt the following but I get back null which causes a NullPointerException. Why can't if find the bean?
ExternalContext ec = FacesContext.getCurrentInstance().getExternalContext();
Map params = ec.getRequestParameterMap();
params.get("LogIn"); //null is returned hereWhat am i doing wrong? Can someone please help.
Thanks in advance,
Alex.Something like that:
FacesContext fc = FacesContext.getCurrentInstance();
RefUsers LogIn = (RefUsers)fc.getApplication().createValueBinding("#{LogIn}").getValue(fc);
String username = LogIn.getUsername();
String password = LogIn.getPassword(); -
Session scope managed bean is not instantiating?
We have the need to use a session bean (rather than pageFlowScope) in our application. But it looks like the session beans are not being instantiated at run time like other beans are. I created a simple test case to verify. One bean, named "MySessionBean", defined in the task flow as Session scope, then referenced in a view with an input text box, value: #{sessionScope.MySessionBean.value1}. When I run the application, I just get PropertyNotFoundException, Target Unreachable, 'MySessionBean' returned null.
If I simply change the bean to use pageFlowScope, everything works fine. I have debug code in the bean constructor, and it never gets called. Is there some other step I am missing to have ADF instantiate the session bean?No luck, I tried it in both adfc-config.xml, and faces-config.xml. I also tried moving the call to my view, from my bounded taskflow, into the adfc-config unbounded task flow, and then I ran that instead. Still got the same error. Here is my code from the the last round of tests with the view called in the main adfc-config.xml unbounded taskflow:
adfc-config.xml:
<?xml version="1.0" encoding="windows-1252" ?>
<adfc-config xmlns="http://xmlns.oracle.com/adf/controller" version="1.2">
<view id="testView">
<page>/testView.jspx</page>
</view>
<managed-bean id="__2">
<managed-bean-name id="__5">MySessionBean</managed-bean-name>
<managed-bean-class id="__4">test.MySessionBean</managed-bean-class>
<managed-bean-scope id="__3">session</managed-bean-scope>
</managed-bean>
</adfc-config>
testView.jspx:
<?xml version='1.0' encoding='UTF-8'?>
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:af="http://xmlns.oracle.com/adf/faces/rich">
<jsp:directive.page contentType="text/html;charset=UTF-8"/>
<f:view>
<af:document id="d1">
<af:form id="f1">
<af:inputText label="Label 1" id="it1"
value="#{sessionScope.MySessionBean.value1}"/>
</af:form>
</af:document>
</f:view>
</jsp:root>
MySessionBean.java:
package test;
public class MySessionBean {
private String value1="Hello World";
public MySessionBean() {
super();
public void setValue1(String value1) {
this.value1 = value1;
public String getValue1() {
return value1; -
ASA Migration of DHCP Scope to a Server
Hello All,
We migrated the DHCP scope from the ASA to a MS DHCP server with this configuration:
group-policy BV-SSL1 internal
group-policy BV-SSL1 attributes
no address-pools value remotepool4 remotepool2 remotepool3
no intercept-dhcp enable
dhcp-network-scope 10.180.49.0
exit
tunnel-group BVVPN10 general-attributes
no address-pool remotepool2
no address-pool remotepool3
no address-pool remotepool4
dhcp-server 10.182.14.55
exit
tunnel-group BV-SSL general-attributes
no address-pool remotepool2
no address-pool remotepool3
no address-pool remotepool4
dhcp-server 10.182.14.55
exit
no vpn-addr-assign aaa
no vpn-addr-assign local
vpn-addr-assign dhcp
This is running good, until we used all 254 addresses that was specified in the dhcp-network-scope.
My question is should i have specified dhcp-network-scope none to allow for all 3 scopes can be used to hand out IP addresses for the remote users?
Thanks,
KimberlyOkay, that's at least a good start. Can you monitor the ULS logs while you attempt to browse to the site to see what form of error(s) you're getting?
Trevor Seward
Follow or contact me at...
  
This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs. -
WLST Exception while Creating JMS Resources
Hi,
I am using Weblogic version 10 MP!, Below is the WLST online script, You willl see a lot of variables in the script, the value which i am calling from another file, This is beacuse everytime instead of modifying the script i will modify the template. There is a lot of p.MS1, p.MS2, the information is called from a different file.
Please provide some kind of suggestion to fix this issue.
Thanks in Advance..
********************************************************************************************SCRIPT********************************************************************************
from weblogic.descriptor import BeanAlreadyExistsException
from java.lang.reflect import UndeclaredThrowableException
from java.lang import System
import javax
from java.util import *
from javax.management import *
import javax.management.Attribute
from javax import management
from javax.management import MBeanException
from javax.management import RuntimeMBeanException
import javax.management.MBeanException
from java.lang import UnsupportedOperationException
import Domain_info as p
import Cluster_info as q
domName = p.Domain_Name
adminServerName = p.Admin_Name
adminServerListenPort = p.AdminPort
adminServerListenAddress = p.AdminListen
userName = p.username
passWord = p.password
domainDir = p.domainDir
URL = "t3://143.192.44.41:7301"
ManagedServer1 = q.MS1
ManagedServer2 = q.MS2
ManagedServer3 = q.MS3
ManagedServer4 = q.MS4
JMSServer1 = q.JMS1
JMSServer2 = q.JMS2
JMSServer3 = q.JMS3
JMSServer4 = q.JMS4
Queue1 = q.Q1
Queue2 = q.Q2
Queue3 = q.Q3
Queue4 = q.Q4
Queue5 = q.Q5
JMS_resource = q.JMS_resource
connect(userName, passWord, URL)
clustHM = HashMap()
edit()
startEdit()
cd('/')
print JMS_resource
print JmsSystemResource
#create(JMS_resource,'JMSSystemResource')
cd('JMSSystemResource/'+JMS_resource+'JmsResource/')
#cd('/')
#create(Queue1,'Queue')
#setJNDIName('jms/'+Queue1)
#setSubDeploymentName(JMSServer1,JMSServer2)
#cd('/')
#cd('JMSSystemResource/'+JMS_resource)
#create(JMSServer1,JMSServer2, 'SubDeployment')
save()
activate(block="true")
disconnect()
print 'End of script ...'
exit()
****************************************************END OF SCRIPT ***********************************************************************************************************
Exception:
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
This Exception occurred at Sat Oct 18 18:13:50 GMT 2008.
javax.management.AttributeNotFoundException: com.bea:Name=Sample_1,Type=Domain:JMSSystemResource
at weblogic.rjvm.ResponseImpl.unmarshalReturn(ResponseImpl.java:221)
at weblogic.rmi.internal.BasicRemoteRef.invoke(BasicRemoteRef.java:224)
at javax.management.remote.rmi.RMIConnectionImpl_1001_WLStub.getAttribute(Unknown Source)
at weblogic.management.remote.common.RMIConnectionWrapper$11.run(ClientProviderBase.java:531)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.security.service.SecurityManager.runAs(Unknown Source)
at weblogic.security.Security.runAs(Security.java:61)
at weblogic.management.remote.common.RMIConnectionWrapper.getAttribute(ClientProviderBase.java:529)
at javax.management.remote.rmi.RMIConnector$RemoteMBeanServerConnection.getAttribute(RMIConnector.java:857)
at weblogic.management.scripting.BrowseHandler.regularPush(BrowseHandler.java:420)
at weblogic.management.scripting.BrowseHandler.splitPush(BrowseHandler.java:145)
at weblogic.management.scripting.BrowseHandler.cd(BrowseHandler.java:640)
at weblogic.management.scripting.WLScriptContext.cd(WLScriptContext.java:195)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.python.core.PyReflectedFunction.__call__(PyReflectedFunction.java:160)
at org.python.core.PyMethod.__call__(PyMethod.java:96)
at org.python.core.PyObject.__call__(PyObject.java:270)
at org.python.core.PyObject.invoke(PyObject.java:2041)
at org.python.pycode._pyx19.cd$5(<iostream>:161)
at org.python.pycode._pyx19.call_function(<iostream>)
at org.python.core.PyTableCode.call(PyTableCode.java:208)
at org.python.core.PyTableCode.call(PyTableCode.java:267)
at org.python.core.PyFunction.__call__(PyFunction.java:172)
at org.python.pycode._pyx18.f$0(/opt/SCRIPTS/Domain_Creation/Create_JMS.py:52)
at org.python.pycode._pyx18.call_function(/opt/SCRIPTS/Domain_Creation/Create_JMS.py)
at org.python.core.PyTableCode.call(PyTableCode.java:208)
at org.python.core.PyCode.call(PyCode.java:14)
at org.python.core.Py.runCode(Py.java:1135)
at org.python.util.PythonInterpreter.execfile(PythonInterpreter.java:167)
at weblogic.management.scripting.WLST.main(WLST.java:106)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at weblogic.WLST.main(WLST.java:29)
Caused by: javax.management.AttributeNotFoundException: com.bea:Name=Sample_1,Type=Domain:JMSSystemResource
at weblogic.management.jmx.modelmbean.WLSModelMBean.getPropertyDescriptorForAttribute(WLSModelMBean.java:1419)
at weblogic.management.mbeanservers.internal.SecurityInterceptor.getPropertyDescriptor(SecurityInterceptor.java:842)
at weblogic.management.mbeanservers.internal.SecurityInterceptor.checkGetSecurity(SecurityInterceptor.java:580)
at weblogic.management.mbeanservers.internal.SecurityInterceptor.getAttribute(SecurityInterceptor.java:297)
at weblogic.management.mbeanservers.internal.AuthenticatedSubjectInterceptor$5.run(AuthenticatedSubjectInterceptor.java:192)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.management.mbeanservers.internal.AuthenticatedSubjectInterceptor.getAttribute(AuthenticatedSubjectInterceptor.java:190)
at weblogic.management.jmx.mbeanserver.WLSMBeanServer.getAttribute(WLSMBeanServer.java:269)
at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1385)
at javax.management.remote.rmi.RMIConnectionImpl.access$100(RMIConnectionImpl.java:81)
at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1245)
at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1348)
at javax.management.remote.rmi.RMIConnectionImpl.getAttribute(RMIConnectionImpl.java:597)
at javax.management.remote.rmi.RMIConnectionImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:589)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:479)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.security.service.SecurityManager.runAs(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:475)
at weblogic.rmi.internal.BasicServerRef.access$300(BasicServerRef.java:59)
at weblogic.rmi.internal.BasicServerRef$BasicExecuteRequest.run(BasicServerRef.java:1016)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:200)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:172)
Problem invoking WLST - Traceback (innermost last):
File "/opt/SCRIPTS/Domain_Creation/Create_JMS.py", line 52, in ?
File "<iostream>", line 170, in cd
WLSTException: 'Error cding to the MBean'Hi David,
Thanks for replying...
Here i am trying to create connection Factory
i made some small changes to script and run ls() command...
****************************************************SCRIPT******************************************************************************
from weblogic.descriptor import BeanAlreadyExistsException
from java.lang.reflect import UndeclaredThrowableException
from java.lang import System
import javax
from java.util import *
from javax.management import *
import javax.management.Attribute
from javax import management
from javax.management import MBeanException
from javax.management import RuntimeMBeanException
import javax.management.MBeanException
from java.lang import UnsupportedOperationException
import Domain_info as p
import Cluster_info as q
import sys
from java.lang import System
domName = p.Domain_Name
adminServerName = p.Admin_Name
adminServerListenPort = p.AdminPort
adminServerListenAddress = p.AdminListen
userName = p.username
passWord = p.password
domainDir = p.domainDir
URL = "t3://143.192.44.41:7301"
ManagedServer1 = q.MS1
ManagedServer2 = q.MS2
ManagedServer3 = q.MS3
ManagedServer4 = q.MS4
JMSServer1 = q.JMS1
JMSServer2 = q.JMS2
JMSServer3 = q.JMS3
JMSServer4 = q.JMS4
Queue1 = q.Q1
Queue2 = q.Q2
Queue3 = q.Q3
Queue4 = q.Q4
Queue5 = q.Q5
JMS_resource = q.JMS_resource
Connection_Factory1 = q.CF1
connect(userName, passWord, URL)
clustHM = HashMap()
edit()
startEdit()
# Creating a JMS Connection
ls()
create(Connection_Factory1,"JMSConnectionFactory")
ls()
cd("JMSConnectionFactory/"+Connection_Factory1)
print("Created the JMS Connection Factory ...."+Connection_Factory1)
cmo.setJNDIName(jms/Connection_Factory1)
#cd('/')
#create(Queue1,'Queue')
#setJNDIName('jms/'+Queue1)
#setSubDeploymentName(JMSServer1,JMSServer2)
#cd('/')
#cd('JMSSystemResource/'+JMS_resource)
#create(JMSServer1,JMSServer2, 'SubDeployment')
save()
activate(block="true")
disconnect()
print 'End of script ...'
exit()
****************************************************************END********************************************************************************
ls() OUTPUT
dr-- AppDeployments
dr-- BridgeDestinations
dr-- Clusters
dr-- CustomResources
dr-- DeploymentConfiguration
dr-- Deployments
dr-- EmbeddedLDAP
dr-- ErrorHandlings
dr-- FileStores
dr-- InternalAppDeployments
dr-- InternalLibraries
dr-- JDBCDataSourceFactories
dr-- JDBCStores
dr-- JDBCSystemResources
dr-- JMSBridgeDestinations
dr-- JMSInteropModules
dr-- JMSServers
dr-- JMSSystemResources
dr-- JMX
dr-- JTA
dr-- JoltConnectionPools
dr-- Libraries
dr-- Log
dr-- LogFilters
dr-- Machines
dr-- MailSessions
dr-- MessagingBridges
dr-- MigratableTargets
dr-- RemoteSAFContexts
dr-- SAFAgents
dr-- SNMPAgent
dr-- SNMPAgentDeployments
dr-- Security
dr-- SecurityConfiguration
dr-- SelfTuning
dr-- Servers
dr-- ShutdownClasses
dr-- SingletonServices
dr-- StartupClasses
dr-- SystemResources
dr-- Targets
dr-- VirtualHosts
dr-- WLDFSystemResources
dr-- WLECConnectionPools
dr-- WSReliableDeliveryPolicies
dr-- WTCServers
dr-- WebAppContainer
dr-- WebserviceSecurities
dr-- XMLEntityCaches
dr-- XMLRegistries
-rw- AdminServerName Sample_AdminServer
-rw- AdministrationMBeanAuditingEnabled false
-rw- AdministrationPort 9002
-rw- AdministrationPortEnabled false
-rw- AdministrationProtocol t3s
-rw- ArchiveConfigurationCount 0
-rw- ClusterConstraintsEnabled false
-rw- ConfigBackupEnabled false
-rw- ConfigurationAuditType none
-rw- ConfigurationVersion 10.0.1.0
-rw- ConsoleContextPath console
-rw- ConsoleEnabled true
-rw- ConsoleExtensionDirectory console-ext
-rw- DomainVersion 10.0.1.0
-r-- LastModificationTime 0
-rw- Name Sample_1
-rw- Notes null
-rw- Parent null
-rw- ProductionModeEnabled false
-r-- RootDirectory /opt/Dev/Sample_1
-r-- Type Domain
-r-x freezeCurrentValue Void : String(attributeName)
-r-x isSet Boolean : String(propertyName)
-r-x restoreDefaultValue Void : String(attributeName)
-r-x unSet Void : String(propertyName)
No stack trace available.
Problem invoking WLST - Traceback (innermost last):
File "/opt/SCRIPTS/Domain_Creation/Create_JMS.py", line 60, in ?
File "<iostream>", line 511, in create
WLSTException: 'Error occured while performing create : Cannot create MBean of type JMSConnectionFactory. You can only create MBeans children to the current cmo. \nTo view the children types that you can create, use listChildTypes().' -
Problem with WLST in weblogic application server 10.3 on solaris 10 x86
Hi Friends, I installed Sun Solaris 10 on my desktop x86. I am able to install oracle weblogic application server 10.3.
I created one domain and I am trying to start AdminServer on that using WLST command.
Before that , I started the admin server from command as normal start ( nohup ./startWebLogic.sh &) and the server started perfectly alright. After that I was trying to open admin console in firefox browser. It was opening perfectly alright.
Now I stopped the server and checked no processes which are related to weblogic were running , and then initialized the WLST environment using the script "wlst.sh" , which is at (in my system) /usr/bea/wlserver_10.3/common/bin/wlst.sh. Now the environment had been set and the WLST offline prompt came up.
Now I used the below WLST scirpt command
startServer('AdminServer','mydomain','t3://localhost:7001','weblogic','weblogic1');
and the server started perfectly alright, now what I did was , I started admin console at FireFox browser , it prompted me to enter user name and password , I gave them , and once the login is done, then in my shell window , I am seeing error as
**wls:/offline> WLST-WLS-1263965848154: <Jan 19, 2010 11:39:24 PM CST> <Error> <HTTP> <BEA-101017> <[ServletContext@28481438[app:consoleapp module:console path:/console spec-version:2.5]] Root cause of ServletException.**
**WLST-WLS-1263965848154: java.lang.OutOfMemoryError: PermGen space**
**WLST-WLS-1263965848154: at java.lang.ClassLoader.defineClass1(Native Method)**
**WLST-WLS-1263965848154: at java.lang.ClassLoader.defineClass(ClassLoader.java:616)**
**WLST-WLS-1263965848154: at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)**
**WLST-WLS-1263965848154: at weblogic.utils.classloaders.GenericClassLoader.defineClass(GenericClassLoader.java:344)**
**WLST-WLS-1263965848154: at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:301)**
**WLST-WLS-1263965848154: Truncated. see log file for complete stacktrace**
**WLST-WLS-1263965848154: >**
**WLST-WLS-1263965848154: <Jan 19, 2010 11:39:24 PM CST> <Error> <JMX> <BEA-149500> <An exception occurred while registering the MBean com.bea:Name=mydomain,Type=SNMPAgentRuntime.**
**WLST-WLS-1263965848154: java.lang.OutOfMemoryError: PermGen space**
**WLST-WLS-1263965848154: at java.lang.ClassLoader.defineClass1(Native Method)**
**WLST-WLS-1263965848154: at java.lang.ClassLoader.defineClass(ClassLoader.java:616)**
**WLST-WLS-1263965848154: at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)**
**WLST-WLS-1263965848154: at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)**
**WLST-WLS-1263965848154: at java.net.URLClassLoader.access$000(URLClassLoader.java:56)**
**WLST-WLS-1263965848154: Truncated. see log file for complete stacktrace**
**WLST-WLS-1263965848154: >**
**WLST-WLS-1263965848154: Exception in thread "[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'" java.lang.OutOfMemoryError: PermGen space**
So I thought I have less memory consuming for this weblogic admin server and opened up ,
_/usr/bea/wlserver_10.3/common/bin/commEnv.sh_
and changed the memory arguments as
Sun)
JAVA_VM=-server
MEM_ARGS="-Xms1024m -Xmx1024m -XX:MaxPermSize=1024m" <---- previously these were 32m and 200m and MaxPermSize
and also in /usr/bea/wlserver10.3/common/bin/bin/setDomainEnv.sh_
and in this file also I changed the memory arguments as
*if [ "${JAVA_VENDOR}" = "Sun" ] ; then*
*WLS_MEM_ARGS_64BIT="-Xms256m -Xmx512m"*
*export WLS_MEM_ARGS_64BIT*
*WLS_MEM_ARGS_32BIT="-Xms1024m -Xmx1024m"*
*export WLS_MEM_ARGS_32BIT*
and restarted the server using the WLST command and again tried to open the admin console on a browser, same error is showing.
(1) Environment : Sun Solaris x86
(2) JDK : sun jdk 1.6._17
Please help me what I am doing wrong here and please let me know the solution.
I was trying to install jrockit 1.6 on this since my OS is sun solaris X86 , there is no compatible jrockit version is not there.
Thanks a lot
PeterHi Peter,
As you have mentioned in your Post that
MEM_ARGS="-Xms1024m -Xmx1024m -XX:MaxPermSize=1024m" <---- previously these were 32m and 200m and MaxPermSize
The Setting you have provided is wrong ...that is the reason you are gettingjava.lang.OutOfMemoryError: PermGen space. There is a RRation between PermSize and the maximum Heap Size...
Just a Bit Explaination:
Formula:
(OS Level)Process Size = Java Heap (+) Native Space (+) (2-3% OS related Memory)
PermSize : It's a Netive Memory Area Outside of the Heap, Where ClassLoading kind of things happens. In an operating System like Windows Default Process Size is 2GB (2048MB) default (It doesnt matter How much RAM do u have 2GB or 4GB or more)...until we dont change it by setting OS level parameter to increase the process size..Usually in OS like Solaris/Linux we get 4GB process size as well.
Now Lets take the default Process Size=2GB (Windows), Now As you have set the -Xmx512M, we can assume that rest of the memory 1536 Mb is available for Native codes.
(ProcessSize - HeapSize) = Native (+) (2-3% OS related Memory)
2048 MB - 512 MB = 1536 MB
THUMB RULES:
<h3><font color=red>
MaxPermSize = (MaxHeapSize/3) ----Very Special Cases
MaxPermSize = (MaxHeapSize/4) ----Recommended
</font></h3>
In your Case -Xmx (Max Heap Size) and -XX:MaxPermSize both were same ....That is the reason you are getting unexpected results. These should be in proper ration.
What should be the exact setting of these parameters depends on the Environment /Applications etc...
But Just try -Xmx1024m -Xms1024m -XX:MaxPermSize256m
Another recommendation for fine tuning always keep (Xmx MaxHeapSize & Xms InitialHeapSize same).
Thanks
Jay SenSharma
http://jaysensharma.wordpress.com (WebLogic Wonders Are Here)
Edited by: Jay SenSharma on Jan 20, 2010 5:33 PM -
Problem with scope in DESTINATION_APP
Experts --
I am using a Default logic file to move data from FINANCEDETAIL cube to FINANCE.
*DESTINATION_APP=FINANCE
*SKIP_DIM=LINEITEMDETAIL
*WHEN Entity
*IS *
*REC(EXPRESSION=%Value%)
*ENDWHEN
*COMMIT
My problem is with the logic's scope. When I post to FINANCEDETAIL for JAN it posts to FINANCE only for JAN. That is normally correct, but in this case I want it to post from detail to ALL months within the year--even if FINANCEDETAIL has not changed.
I have added XDIM_MEMBERSET TIME=%MyTime% (i.e. all months).
I added a line to the logic *DESTINATION TIME=%MyTime%
I can tell from DebugLogic.log that all of the months are part of my original query. Records to be posted, however, are only months that have actually changed.
Documentation suggests that I need to put this logic within a *RUNLOGIC? Is that the right track?
Thanks...MarvHi Halomoan--
Thanks for responding. I am using BPC version 5.1.
Here is my logic in all it's gory detail.
BPC is actually working as it is supposed to. It is sending back data from DETAIL that has changed.
I want it to send back ALL the time series monthly data for selected Account/Entity--even though it appears it has not changed in DETAIL (I have a problem in that FINANCE may be out of synch with FINANCEDETAIL).
*CALCULATE_DIFFERENCE 0
*MEMBERSET(%MyDetail%,"Descendants([DETAIL].[AllLineItems],999,leaves)")
*XDIM_MEMBERSET DETAIL=AllLineItems,%MyDetail%
*MEMBERSET(%MyTime%,"Descendants([TIME].[2009.Total],999,leaves)")
*XDIM_MEMBERSET TIME=%MyTime%
*DESTINATION_APP=FINANCE
*DESTINATION TIME=%MyTime%
*SKIPDIM=DETAIL
*RENAME_DIM DATASOURCE=DATASRC
*ADD_DIM DATATYPE=AVG
*ADD_DIM INTCO=NON_INTERCO
*WHEN DEPARTMENT
*IS *
*REC(EXPRESSION=%VALUE%)
*ENDWHEN
*COMMIT -
Problem with beans in session scope
Hello,
I developped a website using JSP/Tomcat and I can't figure out how to fix this problem.
I am using beans in session scope to know when a user is actualy logged in or not and to make some basic informations about him avaible to the pages. I then add those beans to an application scope bean that manages the users, letting me know how many are logged in, etc... I store the user beans in a Vector list.
The problem is that the session beans never seem to be destroyed. I made a logout page which use <jsp:remove/> but all it does is to remove the bean from the scope and not actualy destroying it. I have to notify the application bean that the session is terminated so I manualy remove it from its vector list.
But when a user just leave the site without using the logout option, it becomes a problem. Is there a way to actualy tell when a session bean is being destroyed ? I tried to check with my application bean if there are null beans in the list but it never happens, the user bean always stays in memory.
Is there actualy a way for me to notify the application bean when the user quits the website without using the logout link ? Or is the whole design flawed ?
Thanks in advance.
Nicolas JaccardI understand I could create a listener even with my current setup Correct, you configure listeners in web.xml and they are applicable to a whole web application irrespective of whether you use jsp or servlets or both. SessionListeners would fire when a session was created or when a session is about to be dropped.
but I do not know how I could get a reference of the application bean in >question. Any hint ?From your earlier post, I understand that you add a UserBean to a session and then the UserBean to a vector stoed in application scope.
Something like below,
UserBean user = new UserBean();
//set bean in session scope.
session.setAttribute("user", user);
//add bean to a Vector stored in application scope.
Vector v = (Vector)(getServletContext().getAttribute("userList"));
v.add(user);If you have done it in the above fashion, you realize, dont you, that its the same object that's added to both the session and to the vector stored in application scope.
So in your sessionDestroyed() method of your HttpSessionListener implementation,
void sessionDestroyed(HttpSessionEvent event){
//get a handle to the session
HttpSession session = event.getSession();
//get a handle to the user object
UserBean user = (UserBean)session.getAttribute("user");
//get a handle to the application object
ServletContext ctx = session.getServletContext();
//get a handle to the Vector storing the user objs in application scope
Vector v = (Vector)ctx.getAttribute("userList");
//now remove the object from the Vector passing in the reference to the object retrieved from the Session.
v.removeElement(user);
}That's it.
Another approach would be to remove the User based on a unique identifier. Let's assume each User has a unique id (If your User has no such feature, you could still add one and set the user id to the session id that the user is associated with)
void sessionDestroyed(HttpSessionEvent event){
//get a handle to the session
HttpSession session = event.getSession();
//get a handle to the user object
UserBean user = (UserBean)session.getAttribute("user");
//get the unique id of the user object
String id = user.getId();
//get a handle to the application object
ServletContext ctx = session.getServletContext();
//get a handle to the Vector storing the user objs in application scope
Vector v = (Vector)ctx.getAttribute("userList");
//now iterate all user objects in the Vector
for(Iterator itr = v.iterator(); itr.hasNext()) {
User user = (User)itr.next();
if(user.getId().equals(id)) {
//if user's id is same as id of user retrieved from session
//remove the object
itr.remove();
}Hope that helps,
ram. -
Built-in wlst ant task does not work in weblogic 10.3.1
Hi,
We have an installer script that deploys an ear file to a weblogic managed server. The script also invokes the build-tin wlst ant task to bounce the managed server. However, in version 10.3.1 the wlst task seems to be broken. I get this error:
[echo] [wlst] sys-package-mgr: can't create package cache dir, '/u00/webadmin/product/10.3.1/WLS/wlserver_10.3/server/lib/weblogic.jar/./java
tmp/wlstTemp/packages'
[echo] [wlst] java.io.IOException: No such file or directory
[echo] [wlst] at java.io.UnixFileSystem.createFileExclusively(Native Method)
[echo] [wlst] at java.io.File.checkAndCreate(File.java:1704)
[echo] [wlst] at java.io.File.createTempFile(File.java:1792)
[echo] [wlst] at java.io.File.createTempFile(File.java:1828)
[echo] [wlst] at com.bea.plateng.domain.script.jython.WLST_offline.getWLSTOfflineInitFilePath(WLST_offline.java:240)
[echo] [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[echo] [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[echo] [wlst] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[echo] [wlst] at java.lang.reflect.Method.invoke(Method.java:597)
[echo] [wlst] at weblogic.management.scripting.utils.WLSTUtil.getOfflineWLSTScriptPath(WLSTUtil.java:63)
[echo] [wlst] at weblogic.management.scripting.utils.WLSTUtil.setupOffline(WLSTUtil.java:214)
[echo] [wlst] at weblogic.management.scripting.utils.WLSTInterpreter.<init>(WLSTInterpreter.java:133)
[echo] [wlst] at weblogic.management.scripting.utils.WLSTInterpreter.<init>(WLSTInterpreter.java:75)
[echo] [wlst] at weblogic.ant.taskdefs.management.WLSTTask.execute(WLSTTask.java:103)
[echo] [wlst] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
Obviously that is not a valid directory...so I am wondering what it is trying to do, and why. The wlst task worked perfectly in 10.3.0. No changes were made when attempting to run the script against 10.3.0 and 10.3.1, which tells me that something is different with the 10.3.1 setup. Here is the ant code I am running:
<target name="init-taskdefs">
<taskdef resource="net/sf/antcontrib/antcontrib.properties">
<classpath>
<pathelement location="ant-ext/ant-contrib.jar" />
</classpath>
</taskdef>
<taskdef name="wldeploy" classname="weblogic.ant.taskdefs.management.WLDeploy" />
<taskdef name="wlst" classname="weblogic.ant.taskdefs.management.WLSTTask" />
</target>
<macrodef name="wlShutdownServer">
<attribute name="adminUser" default="${deploy.admin.username}" />
<attribute name="adminPassword" default="${deploy.admin.password}" />
<attribute name="adminUrl" default="${deploy.admin.url}" />
<attribute name="serverTarget" />
<sequential>
<trycatch property="server.error">
<try>
<wlst failonerror="true"
arguments="@{adminUser} @{adminPassword} @{adminUrl} @{serverTarget}">
<script>
adminUser=sys.argv[0]
adminPassword=sys.argv[1]
adminUrl=sys.argv[2]
serverTarget=sys.argv[3]
connect(adminUser,adminPassword,adminUrl)
target=getMBean("/Servers/"+serverTarget)
if target == None:
target=getMBean("/Clusters/"+serverTarget)
type="Cluster"
else:
type="Server"
print 'Shutting down '+serverTarget+'...'
shutdown(serverTarget,type,'true',15,force='true')
print serverTarget+' was shut down successfully.'
</script>
</wlst>
<!-- setDomainEnv.sh must have been called to set DOMAIN_HOME. Remove all leftover .lok files to allow server
to start back up again. -->
<echo message="Deleting any lok files that have not been removed..." />
<delete failonerror="false">
<fileset dir="${env.DOMAIN_HOME}/servers/@{serverTarget}" includes="**/*.lok"/>
</delete>
</try>
<catch>
<fail message="@{serverTarget} shutdown failed. ${server.error}" />
</catch>
<finally/>
</trycatch>
</sequential>
</macrodef>
Any help would be appreciated. Thanks!Well, it looks like passing something like "-Djava.io.tmpdir=/var/tmp/javatmp/`date +%Y%m%d`" to ant did the trick. I had to make sure that directory existed first, otherwise it threw a java ioexception.
I still don't understand what changes between 10.3.0 and 10.3.1 to necessitate this change.
Maybe you are looking for
-
How can I transfer my old dragonvale island into my new game center account?
I restored my ipod, but now I had to make a new game center account. Since Dragonvale used my old GC account, it forgot my island and generated a new one. I dont wanna have to start over again. Help me! (dont say to start over)
-
Subcontracting - How to plan the components in MRP
Hi Experts, We have the following requirement to map the subcontracting scenario in SAP MM. 1) Subcontracting PR has to be generated during MRP run for all the FERT materials ( Done ) 2) Auto convertion of PR into PO by scheduling the batch job ( Do
-
Is there any sample that shows how to use mapping file with TopLink JPA? Thanks.
-
Diffrence between cpu and elapse time in tkprof
Hi All i found huge diffrence between cpu and elapsed time in tkprof. can you please advice me on this issue. >call count cpu elapsed disk query current rows ================================================== Parse 1 0.12 1.36 2 11 0 0 Execute 1 14.3
-
Having problem while activating my product please help
having problem while activating the product