Showing posts with label weblogic. Show all posts
Showing posts with label weblogic. Show all posts

Wednesday, August 29, 2012

Slides from DOAG SIG FMW 'WebLogic Administration and Deployment with WLST' (ger)

Today I had the pleasure to present about Oracle WebLogic Scripting Tool at the DOAG SIG Middleware, Cologne, Germany. First time for http://www.enpit-consulting.com. Slides are in german, but WLST scripts are still Jython, so also worth for the english Oracle Fusion Middleware Community ;)


Tuesday, December 13, 2011

RESTful Management Services in Oracle WebLogic Server 12c

Version: 12.1.1 (developer edition, ZIP, no installer)

Installation

unzip wls1211_dev as follows

0000@2713_0-41266a23103b2a19

In order to be able to work with this edition we have to call configure.cmd. This basically unpacks all jars, create the registry.xml and wlserver\.product.properties

To have some reusable snippets I have created additional scripts in the new MW_HOME

env_wls12c_dev.cmd

@echo off
@rem ***************************************************************************
@rem This script is used to set the environment for
@rem Oracle WebLogic Server 12.1.1 dev ZIP edition
@rem ***************************************************************************

set MW_HOME=C:\oracle\product\12.1.1\middleware
set JAVA_HOME=C:\oracle\product\11.1.2.1\middleware\jdk160_24
set JAVA_VENDOR=Sun


install_wls12c_dev.cmd



@echo off
@rem ***************************************************************************
@rem This script is used to install Oracle WebLogic Server 12.1.1 dev ZIP edition
@rem ***************************************************************************

call env_wls1211_dev.cmd

title Installing WLS 12.1.1.0...

call %MW_HOME%\configure.cmd

pause


Now execute install_wls12c_dev.cmd



In order to create a domain by configuration wizard



a) call env_wls12c_dev.cmd



b) %MW_HOME%\wlserver\common\bin\config.cmd



RESTful Management Service API



Sounds cool...lets try



Activate by Domain > Configuration > Advanced Configuation > Enable RESTful Management Services



=> (restart required)



After restart you will notice the following in the output



INFO: Scanning for root resource and provider classes in the packages:
weblogic.management.rest.resources
weblogic.management.rest.provider
13.12.2011 00:03:13 com.sun.jersey.api.core.ScanningResourceConfig logClasses
INFO: Root resource classes found:
class weblogic.management.rest.resources.ApplicationResource
class weblogic.management.rest.resources.TestResource
class weblogic.management.rest.resources.ClusterResource
class weblogic.management.rest.resources.DataSourceResource
class weblogic.management.rest.resources.ServerResource
13.12.2011 00:03:13 com.sun.jersey.api.core.ScanningResourceConfig logClasses
INFO: Provider classes found:
class weblogic.management.rest.provider.CollectionResponseXmlProvider
class weblogic.management.rest.provider.ItemResponseJsonProvider
class weblogic.management.rest.provider.CollectionResponseJsonProvider
class weblogic.management.rest.provider.CollectionResponseHtmlProvider
class weblogic.management.rest.provider.ItemResponseHtmlProvider
class weblogic.management.rest.provider.ItemResponseXmlProvider
13.12.2011 00:03:14 com.sun.jersey.server.impl.application.WebApplicationImpl _i
nitiate
INFO: Initiating Jersey application, version 'Jersey: 1.9 09/02/2011 11:17 AM'


(=> This is good news! It states that some RESTful service will be available.)



After Restart open http://localhost:7001/management/tenant-monitoring/servers



(the authorized users must be in the group Administrators or Monitors)



0001@2713_2713-41266a27ed555555



Login in as weblogic user and see the default HTML output



0002@2713_2713-41266a27efb11d34



If you e.g. need better proccessable formats, JSON and XML are of course also supported. Let's see how it is done and what it looks.



Add Accept Header with application/json



0004@2713_2713-41266a27f2c474d0



Add Accept Header with application/xml



0005@2713_2713-41266a27f36b5493



Currently there is REST support for Servers (all in a domain or specific one), Clusters ( all in a domain or specific incl server members), applications (all in a domain or specific app), data sources (all in a domain or specific).



With these capabilities it' possible to implement a custom monitoring solution. A slim mobile wls monitoring app (and more)! => Hands on;)



See doc for details of all available RESTful-Services in WLS12.1.1 http://docs.oracle.com/cd/E24329_01/web.1211/e26722/toc.htm



Collected Documentation links



Overview OTN: http://www.oracle.com/technetwork/middleware/weblogic/documentation/index.html



WLS 12c  Data sheet: http://www.oracle.com/us/products/middleware/application-server/oracle-weblogic-server-ds-1391360.pdf



WLS 12c online Documentation Library: http://docs.oracle.com/cd/E24329_01/index.htm



Usind RESTful Services  With WLS 12c: http://docs.oracle.com/cd/E24329_01/web.1211/e26722/toc.htm



Dislikes



- Still many BEA* stuff in diffrent scripts. It would be nice to have a clean and straight product without any historical garbage.



- configure.xml : ProgramGroupName=BEA WebLogic Platform 10.3 (Integrated Build)....


Why there is still the need to have a programm group called "BEA WebLogic Platform 10.3"?


My suggestions: Oracle WebLogic Platform 12.1.1 or Oracle Fusion Middleware Platform 12.1.1, everythin else, but not 10.3!



Like



- Java EE 6 Support. (It took a long time..)


- Better Maven Support


- RESTful Management Service


- ZIP distribution. Although the file is called wls1211_dev.zip it is possible to create a domain in production mode by the configuration wizard. At least in a simple testdrive it worked for me.


-Startup time feels better than wls11g


- more to test...(-Dservertype=wlx  to avoid loading EJB, JMS, JCA )

Monday, November 21, 2011

My DOAG 2011 Slides – Upgrade Guide for Oracle ADF on WebLogic Server

Just translated my german slides from DOAG 2011 and uploaded those to slideshare.
Hopefully someone will find it useful. At the conference there were just too few attendees…
http://www.slideshare.net/multikoop/doag-2011-upgrade-guide-for-oracle-adf-on-weblogic-server

Wednesday, September 7, 2011

JDeveloper 11.1.2/WLS 10.3.5 hot deployment issue [solved]

Status: Solved

Applies to: JDeveloper 11.1.2 / WLS 10.3.5, Windows XP

Problem Description

Having activated the WebLogic Fast Swap Option

0000@2510_2510-412669670fedcbaa

a strange Exception comes up in the Log-Window for the integrated WebLogic Server output.

java.net.URISyntaxException: Illegal character in opaque part at index 16: zip:C:/Dokumente und Einstellungen/ak/Anwendungsdaten/JDeveloper/system11.1.2.0.38.60.17/DefaultDomain/servers/DefaultServer/tmp/_WL_user/adf.oracle.domain.webapp/q433f9/WEB-INF/lib/adf-richclient-impl-11.jar!/oracle/adfinternal/view/faces/renderkit/rich/PageTemplateRenderer.class
at java.net.URI$Parser.fail(URI.java:2809)
at java.net.URI$Parser.checkChars(URI.java:2982)
at java.net.URI$Parser.parse(URI.java:3019)
at java.net.URI.<init>(URI.java:578)
at java.net.URL.toURI(URL.Java:918)
at com.bea.wls.redef.io.ClassChangeNotifier.toURI(ClassChangeNotifier.java:251)
at com.bea.wls.redef.io.ClassChangeNotifier.isRelative(ClassChangeNotifier.java:211)
at com.bea.wls.redef.io.ClassChangeNotifier.updateCache(ClassChangeNotifier.java:80)
at com.bea.wls.redef.RedefiningClassLoader.findClass(RedefiningClassLoader.java:115)
at java.lang.ClassLoader.loadClass(ClassLoader.java:305)
at java.lang.ClassLoader.loadClass(ClassLoader.java:246)

Issue Analysis

It turns out that the Exception occures because the (by default) created WebLogic domain is located at a directory which contains spaces, e.g. C:/Dokumente und Einstellungen/<user>/Anwendungsdaten/JDeveloper/system11.1.2.0.38.60.17/

Solution

Move your JDev User Dir to a location without space in directory names! This can be done as follows

1. systemwide (for all your JDev installations)

0001@2510_0000@2507_0-412669653f2a1908

2. or finegrained (for specific JDev installation)

$MW_HOME\jdeveloper\jdeveloper.exe -J-Dide.user.dir=c:\ak\JDeveloper

(this will not effect other jdeveloper installations on your machine.)

If you now start Jdeveloper a new jdev user dir will be created.

0002@2510_0001@2507_2507-41266965401845c9

Note: If you want to keep your prefs, etc. copy the system11.1.2.0.38.60.17 from old location to the new one and delete the wls default domain

system11.1.2.0.38.60.17\DefaultDomain directory. (This is needed, because many scripts in DefaultDomain are generated at time of domain creation and so may contain absolute paths! So in order not to get stuck with those issues just delete the DefaultDomain directory. it will be created next time you start wls from jdeveloper)

Conclusion

After moving the jdev user dir you will see in the wls log window

[05:26:06 PM] Updated /C:/ak/JDeveloper/system11.1.2.0.38.60.17/o.j2ee/drs/<app>/<app>WebApp.war/WEB-INF/classes

(after Rebuild of your ViewController project).

Happy fast swapping! It is a real timesaver now!

Further reading

Section 36.4, "Reloading Oracle ADF Metadata in Integrated WebLogic Server." of fusion developmen guide 11.1.2.0.

Sunday, May 9, 2010

Type error in Installation Guide for Oracle Team Productivity Center Server 11.1.1.3?!

Short post, but quite interesting to mention I think.

While going through the current installation guide of Oracle TPC Server 11.1.1.3 the following line catched my eyes:

“If you are using WebLogic Server as the installation server, make sure you are using version 10.3.4.”

That’s really up to date information;) IMHO WLS 10.3.3 is the “most current” WLS version.

Further information

Friday, April 30, 2010

Monitoring Dashboard in WLS Administration Console introduced

Type: Info
Applies to: Oracle WebLogic Server: 10.3.3

Just after JDeveloper 11.1.1.3 was released of course I had to give it a try;-) Somehow I am always curious about changes the Admin Console of the WLS. Since WLS is integrated it is really easy and quick to do. Just start a simple ADF Fusion Web app and open http://localhost:7101/console

The following things catched my eyes:

a) The Admin Console  is internationalized. On my laptop the login form appears in german by default now:
image 
To change the language you just have to change the preferred language in the browser settings and reload the page.

b) On the Homepage I recognized a new entry:
image 
This opens the so called “Monitoring Dashboard” which obviously is developed by ADF Faces RC. Cool! No activation of the diagnostic console needed! No slowly loading Applet;) Thanks!

image

c) the diagnostic-console can still be activated in the preferences but just in order to inform that it has been replaced by the new monitoring dashboard….and the Request Performance

d) Request performance
image At the first look the view is a bit disappointing because you will not see anything here until you “…first configure WLDF instrumentation to use the ElapsedTimeAction diagnostic action attached to "Around" diagnostic monitors. Only data from the ElapsedTimeAction action is shown on this page.” See the context help for more information. (Maybe I will blog about it in more detail in a separate post)

It would be nice if this information (to first configure a WLDF inst) would be visible as INFO or WARNING directly on the Request Performance Tab.

Sunday, November 22, 2009

TELDE - What's that?

If you are wondering what telde is all about then I would like to give a hint on a presentation my collegue Ulrich gave at DOAG 2009 : ADF 11g rich client development best practices . We are using TELDE for development, testing and so on...while developing Apps on the oracle stack (currently ADF11g/JDeveleloper/WebLogic/Oracle Enterprise Linux). So TELDE stands for

TEam Linux Development Environment

It consists of the following components right now:

Oracle Enterprise Linux 5.3

Oracle Database 11.1.0.7

Oracle WebLogic Server 11g

Oracle JDeveloper 11.1.1.x

Oracle Team Productivity Center

Hudson Continuous Integration Server 

OpenLDAP

SVN Server


running on VMWare.




So if you are interested in setting up such an environment, look at http://padora.blogspot.com


Monday, November 16, 2009

WLS: Monitoring Oracle JRockit JVM with JRockit Mission Control remotely

Status: resolved
JRockit Mission Control: 3.1.2
WebLogic: 10.3.2

Use case

You have the need to remotely monitor and profile the JRockit JVM(s) of Oracle WebLogic Server.


Solution

  1. Install JRockit Mission Control on the client
  2. Configure WebLogic Server Domain with JRockit JVM
  3. Configure JRockit Management Server

Components/Products

 Product
Download
 Oracle® WebLogic Server
Download from OTN
 Oracle® JRockit Mission Control 
Download from OTN 

How to

Bereich
Beschreibung
  
Putty 
Login as oracle
on telde.local
[oracle@telde ~]$ cd middleware/user_projects/domains/base_domain/ [oracle@telde base_domain]$ vi startWebLogic.sh
Putty/viAdd the following java Options before starting the WLS instance:

JAVA_OPTIONS="-Xmanagement:ssl=false,authenticate=false,port=7091"
export JAVA_OPTIONS

${DOMAIN_HOME}/bin/startWebLogic.sh $*

Save file and Close vi.
PuttyStart WLS

[oracle@telde base_domain]$ ./startWebLogic.sh
….
Notice the starting of the management server

[JRockit] Management server started on port 7091, ssl=false, authenticate=false.

ClientStart JRockit Mission Control
JRMCCreate a new connection
image
Enter Host
Enter Port
image
Click: Test connection
=> Status keeps “Unable to connect”
Click: Finish

Starting the console on the newly created connection you might receive the following exception:

Could not open Management Console for telde.local.
  com.jrockit.mc.rjmx.ConnectionException: Connection refused to host: 127.0.0.1; nested exception is:
    java.net.ConnectException: Connection refused: connect
    com.jrockit.mc.rjmx.ConnectionException: Connection refused to host: 127.0.0.1; nested exception is:
        java.net.ConnectException: Connection refused: connect
        at com.jrockit.mc.rjmx.ConnectionManager.connect(ConnectionManager.java:63)
        at com.jrockit.mc.console.ui.actions.StartConsole$1.preConnect…

So how to fix?
 

PuttyStop WLS
 Edit startWebLogic.sh
Add -Djava.rmi.server.hostname=<remotehost> to the java options so that it looks like
Putty/vi

..

JAVA_OPTIONS="-Djava.rmi.server.hostname=telde.local -Xmanagement:ssl=false,authenticate=false,port=7091"
export JAVA_OPTIONS

${DOMAIN_HOME}/bin/startWebLogic.sh $*

Save file and exit vi.

PuttyStart WLS once again

[oracle@telde base_domain]$ ./startWebLogic.sh
JRMCNow try to test connection again.
Result should be
image
JRMCStart the console and monitor CPU, Mem, seak for memory leaks, etc.
image

Resources

java.rmi.server.hostname (1.1 and later)

The value of this property represents the host name string that should be associated with remote stubs for locally created remote objects, in order to allow clients to invoke methods on the remote object. In 1.1.7 and later, the default value of this property is the IP address of the local host, in "dotted-quad" format.