[JBoss AS7 Development] - stopping jboss7
by ian diddams
ian diddams [http://community.jboss.org/people/didds] created the document:
"stopping jboss7"
To view the document, visit: http://community.jboss.org/docs/DOC-17175
--------------------------------------------------------------
apolgies if this is the wrong forum for this query - if you steer me to a more apropriate place then that's fine.
starting a jboss7 instance is easy enough - cd bin; ./standalone.sh and away you go.
Stopping the instance is somewhat less obvious though - googling elicited this - bin/jboss-admin.sh --connect command=:shutdown
However, I then had to make alterations to JBOSS_HOME/configuration/standalone.xml so the instance can be accessed outside the local system - and that "breaks" the stopping command above with a compliant
Communication error: Could not connect to remote://localhost:9999 in 5000ms. Make sure the server is running and/or consider setting a longer timeout by setting -Dorg.jboss.as.client.connect.timeout=<timeout in ms>.
Closed connection to localhost:9999
presumably this is because of the chnages made in standalone.xml - so what else must I change to allow this shutdown command to now work as a result?
cheers
ian
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-17175]
Create a new document in JBoss AS7 Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 6 months
[jBPM Development] - get objects from task cast conversion error
by Luis Tamayo
Luis Tamayo [http://community.jboss.org/people/luis.tamayo] created the discussion
"get objects from task cast conversion error"
To view the discussion, visit: http://community.jboss.org/message/625133#625133
--------------------------------------------------------------
Always the object returned is String, do you have any ideas how can I get the object modified in previus task.
public String imprimirTareasConsola() {
HumanTaskClientMina htk = new HumanTaskClientMina();
User u = new User("operator");
System.out.println("======>Operador");
List<TaskSummary> t = htk.getAssignedTasks(u);
if (t != null && t.size() > 0) {
Object xx = htk.getTaskContentInput(t.get(0));
if (xx != null) {
if (xx != null) {
System.out.println("===> Class name en content: "
+ xx.getClass().getName());
if (xx instanceof Persona) {
System.out.println("==00> Id en content type "
+ ((Persona) xx).getId());
} else if (xx instanceof String) {
System.out.println("==00> name type " + (String) xx);
}
System.out
.println("===> cerrando Class name en content: ");
} else {
System.out.println("==> El content es null ");
}
}
return null;
}
}
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/625133#625133]
Start a new discussion in jBPM Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months
[JBoss AS7 Development] - possible jboss as7 bug
by andrea bisaro
andrea bisaro [http://community.jboss.org/people/abisaro] created the discussion
"possible jboss as7 bug"
To view the discussion, visit: http://community.jboss.org/message/625065#625065
--------------------------------------------------------------
Hi all,
i ported a webapp (.war) running on JBoss 4.2.2 to JBoss 5.1.0 without big problems, then I was asked to try to port it to JBoss AS 7.
After two or three days of frustrating temptatives, always getting an obscure error at deployment time, trying to modify, add, remove xml conf files in the app's WEB-INF, I cleaned up my mind and started from beginning, that is the error printed by the server.
The error is the following:
14:36:26,605 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-7) MSC00001: Failed to start service jboss.deployment.unit."XXXX.war".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.unit."XXXX.war".PARSE: Failed to process phase PARSE of deployment "XXXX.war"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:121)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1765)
at org.jboss.msc.service.ServiceControllerImpl$ClearTCCLTask.run(ServiceControllerImpl.java:2291)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [:1.6.0_20]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [:1.6.0_20]
at java.lang.Thread.run(Thread.java:619) [:1.6.0_20]
Caused by: java.lang.IllegalArgumentException: No enum const class org.jboss.metadata.web.spec.BodyContentType.emtpy
at java.lang.Enum.valueOf(Enum.java:196) [:1.6.0_20]
at org.jboss.metadata.web.spec.BodyContentType.valueOf(BodyContentType.java:30)
at org.jboss.metadata.parser.jsp.TagMetaDataParser.parse(TagMetaDataParser.java:117)
at org.jboss.metadata.parser.jsp.TldMetaDataParser.parse(TldMetaDataParser.java:226)
at org.jboss.as.web.deployment.TldParsingDeploymentProcessor.parseTLD(TldParsingDeploymentProcessor.java:124)
at org.jboss.as.web.deployment.TldParsingDeploymentProcessor.deploy(TldParsingDeploymentProcessor.java:89)
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:115)
... 5 more
and I noticed what looks like a typo error somewhere in the code that parse the TLDs.
I put it in bold for your convenience
Caused by: java.lang.IllegalArgumentException: No enum const class org.jboss.metadata.web.spec.BodyContentType.em*tp*y
The BodyContentType enum declaration is:
public enum BodyContentType {
tagdependent, JSP, em*pt*y, scriptless
}
the valueOf method throwing the exception is:
public static <T extends http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-... Enum<T>> T valueOf( http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-... Class<T> enumType, http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-... String name) {
T result = enumType. http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-... enumConstantDirectory(). http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-... get(name);
if (result != null)
return result;
if (name == null)
throw new http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-... NullPointerException("Name is null");
throw new http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-... IllegalArgumentException("No enum const " + enumType +"." + name);
}
I think that the wrong em*tp*y name is passed instead of the right em*pt*y
I got it using jboss-as-7.0.1.Final but I think it affects also previous versions
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/625065#625065]
Start a new discussion in JBoss AS7 Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months
[JBoss AS7 Development] - Multiple Persistence Units & DataSources for one App
by Subhra Roy
Subhra Roy [http://community.jboss.org/people/subhraroy] created the discussion
"Multiple Persistence Units & DataSources for one App"
To view the discussion, visit: http://community.jboss.org/message/624720#624720
--------------------------------------------------------------
This is a continuation from http://community.jboss.org/message/623828#623828 http://community.jboss.org/message/623828#623828
As suggested by Scott I am starting a new discussion.
Our requirement is to be able to dynamically create persistence managers and attach datasources on the fly to the managers further depending on context we can have more than one providers for our app. So we want full control on the persistence manager configuration and initialization etc. Currently AS7 is trying to instanciate the persistence provider on the startup of the app. We would like to avoid that.
Problem 1
AS7 tries to initialize the persistence.xml on app startup and I could not find a way from stopping it from doing that. Even after renaming the file to x-persistence.xml AS7 is still trying to configure the persistence manager.
Observations
1) If the file name is kept as persistence.xml it tries to use the inbuilt provider and then tries to process the one specified in the xml and throws error saying one app can have only one provider.
2) When the xml is renamed it does load the specified provider from the xml. But it still does not allow more than one provider per app and still manages to find the config and tries to load the persistence provider.
Problem 2
AS7 mandates that the persitence.xml have the datasource fixed during deploy time and throws error if the <jta (non-jta) - data source> tags are missing in the xml. What we have is a platform which alows multiple different apps to startup and collaborate and thus we can only know this in runtime.
What we require
1) AS7 to allow more than one persistance provider per app.
2) Way to configure AS7 so that it does not try to automatically instanciate the providers.
3) AS7 should not mandate that the datasouce be bound statically to the provider.
Insight on our requirement:
What we have is a platform where web applications can be built, deployed, managed, executed. Building an application is more like configuring and based on the configuration the platform gives a feel of virtual applications. (Technically speaking only one app is running on the server). The customer base can be managed through this platform. Data sources configured. Thus one "virtual app" can have more than one data source (per customer) in some cases. As well as virtual apps will have different providers / entity managers / data sources. All this is dynamic based on the platform (our app) configuration. We have multiple ways of deploying. We have achieved this functionality in Embedded Tomcat/Jetty, Osgi-Equinox-embedded tomcat, Tomcat,Jetty, so far. We were trying out AS7 as our next possible deployment when we got stuck on these problems.
I hope I could make sense and thanks to all for taking time to help us resolve these problems.
Regards,
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/624720#624720]
Start a new discussion in JBoss AS7 Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months