jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • Archiva
  • MRM-657

'ORA-00910: specified length too long for its datatype' Error when clicking on searched artifact.

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Won't Fix
  • Affects Version/s: 1.0
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None
  • Environment:
    Oracle 10g 10.2.0.3.0 on Sun Solaris Sparc 64

Description

When I do a search for an artifact, then I get the results, I then get this error:

javax.jdo.JDODataStoreException: An exception was thrown while adding/validating class(es) : ORA-00910: specified length too long for its datatype

java.sql.SQLException: ORA-00910: specified length too long for its datatype

at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:158)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:316)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:282)
at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:639)
at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:113)
at oracle.jdbc.driver.T4CStatement.execute_for_rows(T4CStatement.java:703)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1196)
at oracle.jdbc.driver.OracleStatement.execute(OracleStatement.java:1804)
at org.apache.tomcat.dbcp.dbcp.DelegatingStatement.execute(DelegatingStatement.java:264)
at org.jpox.store.rdbms.table.AbstractTable.executeDdlStatement(AbstractTable.java:614)
at org.jpox.store.rdbms.table.AbstractTable.executeDdlStatementList(AbstractTable.java:570)
at org.jpox.store.rdbms.table.AbstractTable.create(AbstractTable.java:297)
at org.jpox.store.rdbms.table.AbstractTable.exists(AbstractTable.java:341)
at org.jpox.store.rdbms.RDBMSManager$ClassAdder.performTablesValidation(RDBMSManager.java:3052)
at org.jpox.store.rdbms.RDBMSManager$ClassAdder.addClassTablesAndValidate(RDBMSManager.java:3313)
at org.jpox.store.rdbms.RDBMSManager$ClassAdder.run(RDBMSManager.java:2554)
at org.jpox.store.rdbms.RDBMSManager$MgmtTransaction.execute(RDBMSManager.java:2406)
at org.jpox.store.rdbms.RDBMSManager.addClasses(RDBMSManager.java:821)
at org.jpox.store.rdbms.RDBMSManager.addClass(RDBMSManager.java:835)
at org.jpox.AbstractPersistenceManager.newObjectIdInstance(AbstractPersistenceManager.java:2377)
at org.apache.maven.archiva.database.jdo.JdoAccess.getObjectById(JdoAccess.java:429)
at org.apache.maven.archiva.database.jdo.JdoProjectModelDAO.getProjectModel(JdoProjectModelDAO.java:74)
at org.apache.maven.archiva.database.browsing.DefaultRepositoryBrowsing.getProjectModel(DefaultRepositoryBrowsing.java:281)
at org.apache.maven.archiva.database.browsing.DefaultRepositoryBrowsing.selectVersion(DefaultRepositoryBrowsing.java:127)
at org.apache.maven.archiva.web.action.ShowArtifactAction.artifact(ShowArtifactAction.java:105)

Now this does not come up like with continuum (at start up):
http://jira.codehaus.org/browse/CONTINUUM-1622

So Archiva runs, but not when I try to search.

  • Options
    • Sort By Name
    • Sort By Date
    • Ascending
    • Descending
    • Download All

Attachments

  1. File
    archiva-base.xml-patched
    17/Mar/08 6:14 AM
    78 kB
    Olivier Dassaud
  2. File
    package-oracle.orm
    05/Mar/08 7:03 AM
    0.7 kB
    Gunther Van den Bosch

Issue Links

is superceded by

Task - A task that needs to be done. MRM-1025 remove the archiva database

  • Major - Major loss of function.
  • Closed - The issue is considered finished, the resolution is correct. Issues which are not closed can be reopened.

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
Gunther Van den Bosch added a comment - 05/Mar/08 7:02 AM

This could be solved by adapting the JDO mapping for Oracle. Oracle supports only VARCHAR types with a maximum length of 4000. The standard implementation of archiva sometimes uses fields which are longer.
I have attached the package-oracle.orm file which should be included in the archiva-model-1.0.1.jar next to the package.jdo

Using the Oracle mapping can be activated by setting the mapping property in the application.xml for the Jdofactory component
<property>
<name>javax.jdo.option.Mapping</name>
<value>oracle</value>
</property>

I hope this helps

Show
Gunther Van den Bosch added a comment - 05/Mar/08 7:02 AM This could be solved by adapting the JDO mapping for Oracle. Oracle supports only VARCHAR types with a maximum length of 4000. The standard implementation of archiva sometimes uses fields which are longer. I have attached the package-oracle.orm file which should be included in the archiva-model-1.0.1.jar next to the package.jdo Using the Oracle mapping can be activated by setting the mapping property in the application.xml for the Jdofactory component <property> <name>javax.jdo.option.Mapping</name> <value>oracle</value> </property> I hope this helps
Hide
Permalink
Olivier Dassaud added a comment - 17/Mar/08 6:14 AM

Hello,

We used to experience the same problem.

We solved it changing some sizes in :
archiva-base/archiva/model/src/main/mdo/archiva-base.xml (stash.maxSize="4000")

FYI the new file is attached to that ticket.

But it looks that Gunther proposal is smarter.

Olivier.

Show
Olivier Dassaud added a comment - 17/Mar/08 6:14 AM Hello, We used to experience the same problem. We solved it changing some sizes in : archiva-base/archiva/model/src/main/mdo/archiva-base.xml (stash.maxSize="4000") FYI the new file is attached to that ticket. But it looks that Gunther proposal is smarter. Olivier.
Hide
Permalink
arno koehler added a comment - 05/May/08 7:09 AM - edited

I see the same error in my log files.

The setup I am using is Archiva.WAR on JBoss in combination with Oracle.
The solution Gunther presents is a bit difficult for me, because in the WAR there is (off course) no application.xml and I would not know what to do with this now.

I tried to add

<property>
<name>javax.jdo.option.Mapping</name>
<value>oracle</value>
</property>

to my web.xml but it doens't fix the problem.
What can I do to fix my problem?

Show
arno koehler added a comment - 05/May/08 7:09 AM - edited I see the same error in my log files. The setup I am using is Archiva.WAR on JBoss in combination with Oracle. The solution Gunther presents is a bit difficult for me, because in the WAR there is (off course) no application.xml and I would not know what to do with this now. I tried to add <property> <name>javax.jdo.option.Mapping</name> <value>oracle</value> </property> to my web.xml but it doens't fix the problem. What can I do to fix my problem?
Hide
Permalink
Aaron Hamid added a comment - 18/Sep/08 3:53 PM

This error occurs for me if I hit the Reports button. Any update on this issue? I'm not sure where to find the original files to modify (other than application.xml, where I added the javax.jdo.option.Mapping, but it didn't appear to help...maybe I need to start fresh with this option?). I'd rather not limit the column size, but instead set them to CLOB so they can support the requirements.

Show
Aaron Hamid added a comment - 18/Sep/08 3:53 PM This error occurs for me if I hit the Reports button. Any update on this issue? I'm not sure where to find the original files to modify (other than application.xml, where I added the javax.jdo.option.Mapping, but it didn't appear to help...maybe I need to start fresh with this option?). I'd rather not limit the column size, but instead set them to CLOB so they can support the requirements.
Hide
Permalink
Aaron Hamid added a comment - 18/Sep/08 4:21 PM

Attempting a partial db-dependent override via package-oracle.orm and package-oracle.jdo did not work for me. I had to edit and replace the main package.jdo (by placing the override in classes/).

Show
Aaron Hamid added a comment - 18/Sep/08 4:21 PM Attempting a partial db-dependent override via package-oracle.orm and package-oracle.jdo did not work for me. I had to edit and replace the main package.jdo (by placing the override in classes/).
Hide
Permalink
Brett Porter added a comment - 23/Feb/10 2:44 AM

superceded

Show
Brett Porter added a comment - 23/Feb/10 2:44 AM superceded

People

  • Assignee:
    Unassigned
    Reporter:
    Mick Knutson
Vote (2)
Watch (4)

Dates

  • Created:
    16/Jan/08 9:57 AM
    Updated:
    23/Feb/10 2:45 AM
    Resolved:
    23/Feb/10 2:45 AM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.