This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 63538

Summary: j2eeserver API extension for Profiler
Product: serverplugins Reporter: Jiri Sedlacek <jis>
Component: InfrastructureAssignee: Sherold Dev <sherold>
Status: RESOLVED FIXED    
Severity: blocker CC: apireviews, iformanek, pjiricka
Priority: P2 Keywords: API_REVIEW_FAST
Version: 5.x   
Hardware: All   
OS: All   
Issue Type: ENHANCEMENT Exception Reporter:
Attachments: Summary of new API
Sources of new classes and diff of modified files
JavaDoc of new API
Diagrams showing usecases

Description Jiri Sedlacek 2005-09-01 17:01:17 UTC
An API extension is needed in the j2eeserver module for the Profiler to be able 
to profile Web projects (and all other J2EE-related project types in future) in 
a comfortable way.

Currently the Profiler declares implementation dependency on plugins for 
supported servers to be able to use isRunning/start/stop and other 
functionalities. This approach turned out to be unacceptable.

The new API introduces following parts:

1/ Profiler SPI, which will be registered into Lookup and allow the j2eeserver 
code to obtain information about current profiling session status, settings 
required for starting a server in profiling mode and to stop profiled server

2/ Profiler API, which defines class encapsulating settings required for 
starting a server in profiling mode and provides support for reading current 
state of Profiler registered in Lookup

3/ Ant task 'nbstartprofiledserver' that may stop other server being profiled 
and prepare the target server for profiling - this means (re)starting the 
server using provided settings or no action if the server is already running 
with correct configuration

4/ Extension of J2eePlatform that allows the Profiler to check if the Java 
platform specified for the server is acceptable for profiling. If not, the 
Profiler is able to check if other platform which can be used for profiling is 
acceptable for running the server

The designed API is supposed to be a FRIEND API for the Profiler only, not for 
general use.
Comment 1 Jiri Sedlacek 2005-09-01 17:04:01 UTC
Created attachment 24466 [details]
Summary of new API
Comment 2 Jiri Sedlacek 2005-09-01 17:05:05 UTC
Created attachment 24467 [details]
Sources of new classes and diff of modified files
Comment 3 Jiri Sedlacek 2005-09-01 17:05:56 UTC
Created attachment 24468 [details]
JavaDoc of new API
Comment 4 Jiri Sedlacek 2005-09-01 17:06:48 UTC
Created attachment 24469 [details]
Diagrams showing usecases
Comment 5 Pavel Buzek 2005-09-07 03:37:33 UTC
I assume that when you mention in javadoc that "Profiler has to implement this
interface and register it into Lookup." and "Allows to determine current state
of a Profiler registered into Lookup." then you mean the default (global)
lookup. You should clarify that.
Otherwise I am OK with this change.
Comment 6 Sherold Dev 2005-09-15 14:53:32 UTC
The javadoc has been updated according to Pavel's comment.

The suggested api had to be extended of the Profiler.attachProfiler(Map
projectProperties) method, which will allow to connect the Profiler to a server
ready for profiling from the nbstartprofiledserver ant task.
Comment 7 Sherold Dev 2005-09-15 17:01:46 UTC
Fixed in trunk (profiler_support branch merged to trunk)

commit log:

Checking in apichanges.xml;
/cvs/j2eeserver/apichanges.xml,v  <--  apichanges.xml
new revision: 1.19; previous revision: 1.18
done
Checking in manifest.mf;
/cvs/j2eeserver/manifest.mf,v  <--  manifest.mf
new revision: 1.46; previous revision: 1.45
done
Checking in ant/antsrc/org/netbeans/modules/j2ee/ant/StartProfiledServer.java;
/cvs/j2eeserver/ant/antsrc/org/netbeans/modules/j2ee/ant/StartProfiledServer.java,v
 <--  StartProfiledServer.java
new revision: 1.2; previous revision: 1.1
done
Checking in ant/antsrc/org/netbeans/modules/j2ee/ant/antlib.xml;
/cvs/j2eeserver/ant/antsrc/org/netbeans/modules/j2ee/ant/antlib.xml,v  <-- 
antlib.xml
new revision: 1.4; previous revision: 1.3
done
Checking in ant/nbproject/project.xml;
/cvs/j2eeserver/ant/nbproject/project.xml,v  <--  project.xml
new revision: 1.8; previous revision: 1.7
done
Checking in nbproject/project.xml;
/cvs/j2eeserver/nbproject/project.xml,v  <--  project.xml
new revision: 1.13; previous revision: 1.12
done
Checking in
src/org/netbeans/modules/j2ee/deployment/devmodules/api/J2eePlatform.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/devmodules/api/J2eePlatform.java,v
 <--  J2eePlatform.java
new revision: 1.8; previous revision: 1.7
done
Checking in src/org/netbeans/modules/j2ee/deployment/impl/Bundle.properties;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/Bundle.properties,v
 <--  Bundle.properties
new revision: 1.33; previous revision: 1.32
done
Checking in src/org/netbeans/modules/j2ee/deployment/impl/ServerInstance.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ServerInstance.java,v
 <--  ServerInstance.java
new revision: 1.62; previous revision: 1.61
done
Checking in src/org/netbeans/modules/j2ee/deployment/impl/ServerRegistry.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ServerRegistry.java,v
 <--  ServerRegistry.java
new revision: 1.48; previous revision: 1.47
done
Checking in
src/org/netbeans/modules/j2ee/deployment/impl/ui/InstanceNodeDecorator.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ui/InstanceNodeDecorator.java,v
 <--  InstanceNodeDecorator.java
new revision: 1.3; previous revision: 1.2
done
Checking in
src/org/netbeans/modules/j2ee/deployment/impl/ui/actions/Bundle.properties;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ui/actions/Bundle.properties,v
 <--  Bundle.properties
new revision: 1.22; previous revision: 1.21
done
Checking in
src/org/netbeans/modules/j2ee/deployment/impl/ui/actions/ProfileAction.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ui/actions/ProfileAction.java,v
 <--  ProfileAction.java
new revision: 1.2; previous revision: 1.1
done
Checking in
src/org/netbeans/modules/j2ee/deployment/impl/ui/actions/RestartAction.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ui/actions/RestartAction.java,v
 <--  RestartAction.java
new revision: 1.3; previous revision: 1.2
done
Checking in
src/org/netbeans/modules/j2ee/deployment/impl/ui/actions/StopAction.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ui/actions/StopAction.java,v
 <--  StopAction.java
new revision: 1.3; previous revision: 1.2
done
Checking in
src/org/netbeans/modules/j2ee/deployment/impl/ui/resources/profilerblocking.png;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ui/resources/profilerblocking.png,v
 <--  profilerblocking.png
new revision: 1.2; previous revision: 1.1
done
Checking in
src/org/netbeans/modules/j2ee/deployment/impl/ui/resources/profiling.png;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/impl/ui/resources/profiling.png,v
 <--  profiling.png
new revision: 1.2; previous revision: 1.1
done
Checking in
src/org/netbeans/modules/j2ee/deployment/plugins/api/J2eePlatformImpl.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/plugins/api/J2eePlatformImpl.java,v
 <--  J2eePlatformImpl.java
new revision: 1.4; previous revision: 1.3
done
Checking in src/org/netbeans/modules/j2ee/deployment/plugins/api/StartServer.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/plugins/api/StartServer.java,v
 <--  StartServer.java
new revision: 1.9; previous revision: 1.8
done
Checking in
src/org/netbeans/modules/j2ee/deployment/profiler/api/ProfilerServerSettings.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/profiler/api/ProfilerServerSettings.java,v
 <--  ProfilerServerSettings.java
new revision: 1.2; previous revision: 1.1
done
Checking in
src/org/netbeans/modules/j2ee/deployment/profiler/api/ProfilerSupport.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/profiler/api/ProfilerSupport.java,v
 <--  ProfilerSupport.java
new revision: 1.2; previous revision: 1.1
done
Checking in src/org/netbeans/modules/j2ee/deployment/profiler/spi/Profiler.java;
/cvs/j2eeserver/src/org/netbeans/modules/j2ee/deployment/profiler/spi/Profiler.java,v
 <--  Profiler.java
new revision: 1.2; previous revision: 1.1
done
Checking in www/j2ee-server-ui-spec-promof.html;
/cvs/j2eeserver/www/j2ee-server-ui-spec-promof.html,v  <-- 
j2ee-server-ui-spec-promof.html
new revision: 1.6; previous revision: 1.5
done
Comment 8 Sherold Dev 2005-09-15 17:02:40 UTC
F.
Comment 9 Jaroslav Tulach 2005-09-16 07:03:30 UTC
Keep the keyword there so we can query for list of closed reviews: 
http://openide.netbeans.org/tutorial/reviews/ 
Comment 10 Sherold Dev 2005-09-23 16:46:38 UTC
Module release and specification version numbers were incremented to 4 and 1.10
respectively.

Modules that will use these new API should update their j2eeserver dependency to
these version numbers. Modules that support both, the old/3 and new/4 j2eeserver
release versions, can specify it by using the value "3-4".