0

I'm strugling a bit with adding users to my weblogic 12.2.1 server. To start the server I use cargo 1.6.2

    [INFO] [talledLocalContainer] Adding users and groups to WebLogic domain.
[WARNING] [talledLocalContainer] ERROR: transport error 202: bind failed: Address already in use
[WARNING] [talledLocalContainer] ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
[WARNING] [talledLocalContainer] JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debugInit.c:750]
[WARNING] [talledLocalContainer] org.codehaus.cargo.util.CargoException: Cannot execute WLST script.
[ERROR] Starting container [org.codehaus.cargo.container.weblogic.WebLogic121xInstalledLocalContainer@985696] failed
org.codehaus.cargo.util.CargoException: Cannot execute WLST script.
        at org.codehaus.cargo.container.weblogic.WebLogic121xInstalledLocalContainer.executeScript(WebLogic121xInstalledLocalContainer.java:205)
        at org.codehaus.cargo.container.weblogic.WebLogic121xInstalledLocalContainer.executePostStartTasks(WebLogic121xInstalledLocalContainer.java:147)
        at org.codehaus.cargo.container.spi.AbstractLocalContainer.start(AbstractLocalContainer.java:233)
        at org.codehaus.cargo.maven2.ContainerStartMojo.executeLocalContainerAction(ContainerStartMojo.java:84)
        at org.codehaus.cargo.maven2.ContainerRunMojo.doExecute(ContainerRunMojo.java:96)
        at org.codehaus.cargo.maven2.AbstractCargoMojo.execute(AbstractCargoMojo.java:462)
        at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

The interesting part of my cargo is the property section

<properties>
                                <cargo.servlet.port>7001</cargo.servlet.port>
                                <cargo.port.offset>1</cargo.port.offset>

                                <cargo.jvmargs>
                                    -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=6000 -Xnoagent
                                    -Djava.compiler=NONE
                                </cargo.jvmargs>
                                <cargo.servlet.users>
                                    test-clientid:passw0rd:advisor|customer1:passw0rd:
                                </cargo.servlet.users>
                                <cargo.logging>high</cargo.logging>
                                <deployable.location>${project.basedir}/lanc-application/target/land-register-connector.ear
                                </deployable.location>
                                <deployable.plan.env>${env}</deployable.plan.env>
                            </properties>

The profiles works fine when I leave out cargo.servlet.users. I have tried another debug port without luck.

Any ideas?

stuf99
  • 95
  • 6

1 Answers1

0

If you tried to change debug port and this did not help and concating it with the fact that without users entry in config all works fine then i strongly recommend to create issue in their jira here: https://codehaus-cargo.atlassian.net. Here is issue with adding weblogic support: https://codehaus-cargo.atlassian.net/browse/CARGO-1319. I looked through their tests and did not find any tests for your case. I found only user verification but nothing else. For me it seems like a possible bug. If not at least you will get your question answered.

It seems that root cause is exception which is telling you that address already in use. Seems that port 6000 is already used. First ill try just to change port to something else cause it seems that through jdwp cargo is only communicating with containers and there is no other dependencies from previous jobs or configs which will be affected by port change. If this wont work then you will have to detect who uses the port. Here is root cause exception:

   [WARNING] [talledLocalContainer] ERROR: transport error 202: bind failed: 
   Address already in use
   [WARNING] [talledLocalContainer] ERROR: JDWP Transport dt_socket failed 
   to initialize, TRANSPORT_INIT(510)
   [WARNING] [talledLocalContainer] JDWP exit error 
   AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debugInit.c:750]

Actually it should be marked as error, not warning.

It seems that script execution fails during creating jvmlauncher to connect with your container: https://github.com/codehaus-cargo/cargo/blob/master/core/containers/weblogic/src/main/java/org/codehaus/cargo/container/weblogic/WebLogic121xInstalledLocalContainer.java#L225

Script execution is triggered by cargo itself during addind users: https://github.com/codehaus-cargo/cargo/blob/master/core/containers/weblogic/src/main/java/org/codehaus/cargo/container/weblogic/WebLogic121xInstalledLocalContainer.java#L145

Stepan Pogosyan
  • 562
  • 1
  • 7
  • 15