6 Replies Latest reply on Dec 31, 2005 1:18 AM by roy.russo

    portal 2.2 / sqlserver

    trannt

      Hi,
      The versions are Jboss 4.0.3SP1, portal 2.2 (binary download), sqlserver 2000SP3. I created the database from scratch. Datasource is setup properly. Portal 2.0 has been successfully installed.

      The error is when startup portal2.2 it fails to load default-object.xml file. You may see the error below.
      ================================

      15:49:46,471 INFO [STDOUT] Hibernate: insert into JBP_OBJECT_NODE (PATH, NAME,
      PARENT_KEY) values (?, ?, ?)
      15:49:46,487 INFO [STDOUT] Hibernate: insert into JBP_PORTAL_OBJECT (LISTENER,
      PK) values (?, ?)
      15:49:46,487 INFO [STDOUT] Hibernate: insert into JBP_PORTAL (PK) values (?)
      15:49:46,503 INFO [STDOUT] Hibernate: insert into JBP_OBJECT_NODE (PATH, NAME,
      PARENT_KEY) values (?, ?, ?)
      15:49:46,518 WARN [JDBCExceptionReporter] SQL Error: 2627, SQLState: 23000
      15:49:46,518 ERROR [JDBCExceptionReporter] Violation of UNIQUE KEY constraint 'U
      Q__JBP_OBJECT_NODE__02084FDA'. Cannot insert duplicate key in object 'JBP_OBJECT
      _NODE'.
      15:49:46,518 ERROR [MainDeployer] Could not start deployment: file:/C:/jboss-4.0
      .3SP1/server/default/deploy/jboss-portal.sar/conf/data/default-object.xml
      org.jboss.deployment.DeploymentException: could not insert: [org.jboss.portal.co
      re.impl.model.portal.ObjectNode]; - nested throwable: (org.hibernate.exception.C
      onstraintViolationException: could not insert: [org.jboss.portal.core.impl.model
      .portal.ObjectNode])
      at org.jboss.portal.core.deployment.jboss.ObjectDeployment.start(ObjectD
      eployment.java:292)
      at org.jboss.portal.server.deployment.jboss.ServerDeployer.start(ServerD
      eployer.java:222)
      at org.jboss.deployment.MainDeployer.start(MainDeployer.java:989)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:790)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      =============================

      I wonder if anyone has a similar experience.

      Thanks,
      T



        • 1. Re: portal 2.2 / sqlserver
          parfenov

          Hi;

          I ran into the same problem with the same configuration. I used jtds driver (version 1.2).

          If anybody known the solution, please post it here.

          Thanks,
          V

          • 2. Re: portal 2.2 / sqlserver
            cbreeves

            I had the same problem with:

            4.0.3SP1, portal 2.2

            RDBMS: Microsoft SQL Server, version: 9.0.1399
            JDBC driver: Microsoft SQL Server 2005 JDBC Driver - Beta 1, version: 1.0.107.104

            • 3. Re: portal 2.2 / sqlserver

              I'm using the jtds driver 1.2. an one of you post your datasource descriptor, so I can have a look.

              • 4. Re: portal 2.2 / sqlserver
                parfenov

                Hi Roy;

                I used the destriptor which comes with the portal bundle named "portal-sqlserver-ds.xml". I used "out of box" destriptor without any changes (even login name and password was the same).

                Thank you,

                Vadim


                Here is the context of the descriptor:

                <?xml version="1.0" encoding="UTF-8"?>

                <local-tx-datasource>
                <jndi-name>PortalDS</jndi-name>
                <connection-url>jdbc:jtds:sqlserver://localhost:1433;tds=8.0;lastupdatecount=true</connection-url>
                <driver-class>net.sourceforge.jtds.jdbc.Driver</driver-class>
                <user-name>portal</user-name>
                portalpassword
                </local-tx-datasource>

                • 5. Re: portal 2.2 / sqlserver

                  ok. I'm looking at it now, but it may be a while. I'm on SQLExpress, which had TCP/IP disabled by default.

                  I'm able to connect now and reproduce the errors.

                  • 6. Re: portal 2.2 / sqlserver

                    There is a temporary fix here: http://jira.jboss.com/jira/browse/JBPORTAL-540

                    I cannot commit the code until I verify it works on other DB vendors, and removing the constraint does not affect data integrity.