以文本方式查看主题

-  中文XML论坛 - 专业的XML技术讨论区  (http://bbs.xml.org.cn/index.asp)
--  『 EAI/SOA基础与技术 』  (http://bbs.xml.org.cn/list.asp?boardid=73)
----  我是一个uddi4j和juddi的新手,麻烦大家帮帮我。  (http://bbs.xml.org.cn/dispbbs.asp?boardid=73&rootid=&id=48678)


--  作者:BCW0928
--  发布时间:6/19/2007 9:45:00 AM

--  我是一个uddi4j和juddi的新手,麻烦大家帮帮我。
我最近刚装了,uddi4j 和 juddi, 然后我测试了里面的 sample examples.
FindBusinessExample 可以跑,而且也没什么问题,
但是当我测试 FindBusinessExample 的时候就不行了,有谁可以帮帮我。
一下是出错的信息:

C:\apache-tomcat-6.0.13\webapps\uddi4j\samples>java SaveBusinessExample
*********** Running SaveBusinessExample ***********
Configuration properties set: {org.uddi4j.TransportClassName=org.uddi4j.transpor
t.ApacheAxisTransport, org.uddi4j.logEnabled=true}

Get authtoken
log4j:WARN No appenders could be found for logger (org.apache.axis.i18n.ProjectR
esourceBundle).
log4j:WARN Please initialize the log4j system properly.

Request message:
<uddiv2:get_authToken cred="juddi" generic="2.0" userID="juddi" xmlns:uddiv2="ur
n:uddi-org:api_v2"/>

Response message:
<authToken generic="2.0" operator="jUDDI.org" xmlns=""><authInfo>authToken:8A11C
DB0-1E03-11DC-8DB0-87A7351B6906</authInfo></authToken>
java.lang.NullPointerException
        at org.uddi4j.UDDIException.isValidElement(UDDIException.java:111)
        at org.uddi4j.UDDIElement.<init>(UDDIElement.java:38)
        at org.uddi4j.response.AuthToken.<init>(AuthToken.java:85)
        at org.uddi4j.client.UDDIProxy.get_authToken(UDDIProxy.java:1626)
        at SaveBusinessExample.run(SaveBusinessExample.java:72)
        at SaveBusinessExample.main(SaveBusinessExample.java:50)

一下是我的 sample.prop 文件:
# Property file used to set parameters for UDDI4J samples.

# -----------------------------------------------------------------------
# inquiryURL: The URL for the inquiry API of the target UDDI registry
# publishURL: URL for the publish API of the target UDDI registry
# A list of UDDI URLs is on the UDDI4J website http://www.uddi4j.org/
#
# A typical entry would be of the form
# inquiryURL=http://company.com/uddi_node
# publishURL=https://company.com/uddi_publish_node
# -----------------------------------------------------------------------
# IBM UDDI test site
#inquiryURL=http://test.uddi.microsoft.com/inquire   
inquiryURL=http://localhost:8080/juddi/inquiry
#publishURL=https://test.uddi.microsoft.com/publish
publishURL=http://localhost:8080/juddi/publish

# -----------------------------------------------------------------------
# Userid to use when running the publish samples. Userid/passwords should
# not generally be stored in clear text
# -----------------------------------------------------------------------
userid = juddi
password = juddi

# -----------------------------------------------------------------------
# Transport classname. Typically defined on commandline as
# -Dorg.uddi4j.TransportClassName=xxx.
# -----------------------------------------------------------------------
TransportClassName=org.uddi4j.transport.ApacheSOAPTransport
#TransportClassName=org.uddi4j.transport.ApacheAxisTransport
# TransportClassName=org.uddi4j.transport.HPSOAPTransport

# -----------------------------------------------------------------------
# Debug log enabled or not. Typically defined on command line as
# -Dorg.uddi4j.logEnabled=true
# -----------------------------------------------------------------------
# logEnabled=false
logEnabled=true

# -----------------------------------------------------------------------
# Values used to determine the implementation of JSSE to use. Provided
# for convenience, this is typically configured within the jdk
# in JAVA_HOME\jre\lib\security
# -----------------------------------------------------------------------
# Sun JSSE implementation
handlerPackageName=com.sun.net.ssl.internal.www.protocol
securityClassName=com.sun.net.ssl.internal.ssl.Provider

# IBM JSSE implementation
# handlerPackageName=com.ibm.net.ssl.internal.www.protocol
# securityClassName=com.ibm.jsse.JSSEProvider

# -----------------------------------------------------------------------
# UDDI names to use within samples. Samples may or maynot use these values,
# Check the source for the sample
# -----------------------------------------------------------------------
businessName=Sample Business
serviceName=Sample Service
tmodelName=Sample TModel
sampleEntityName=S
assertionRelationship=peer-peer

# -----------------------------------------------------------------------
# Additional values can be added as needed as a convenient repository
# for data relevant to the UDDI4J samples
# -----------------------------------------------------------------------

一下是我的 juddi.properties 文件:
# jUDDI Registry Properties (used by RegistryServer)
# see http://www.juddi.org for more information

# The UDDI Operator Name
juddi.operatorName = jUDDI.org

# The i18n locale default codes
juddi.i18n.languageCode = en
juddi.i18n.countryCode = US

# The UDDI DiscoveryURL Prefix
juddi.discoveryURL = http://localhost:8080/juddi/uddiget.jsp?

# The UDDI Operator Contact Email Address
juddi.operatorEmailAddress = bow5003@psu.edu

# The maximum name size and maximum number
# of name elements allows in several of the
# FindXxxx and SaveXxxx UDDI functions.
juddi.maxNameLength=255
juddi.maxNameElementsAllowed=5
juddi.maxBusinessEntitiesPerUser=25
juddi.maxBusinessServicesPerBusiness=20
juddi.maxBindingTemplatesPerService=10
juddi.maxTModelsPerUser=100
juddi.maxRowsLimit=10

# jUDDI Authentication module to use
juddi.auth = org.apache.juddi.auth.DefaultAuthenticator

# jUDDI DataStore module currently to use
juddi.dataStore = org.apache.juddi.datastore.jdbc.JDBCDataStore

# jUDDI DataSource to use
juddi.dataSource=java:comp/env/jdbc/juddiDB

# jUDDI UUIDGen implementation to use
juddi.uuidgen = org.apache.juddi.uuidgen.DefaultUUIDGen

# jUDDI Cryptor implementation to use
juddi.cryptor = org.apache.juddi.cryptor.DefaultCryptor

# jUDDI Validator to use
juddi.validator=org.apache.juddi.validator.DefaultValidator

# jUDDI Proxy Properties (used by RegistryProxy)
juddi.proxy.adminURL = http://localhost:8080/juddi/admin
juddi.proxy.inquiryURL = http://localhost:8080/juddi/inquiry
juddi.proxy.publishURL = http://localhost:8080/juddi/publish
juddi.proxy.transportClass = org.apache.juddi.proxy.AxisTransport
juddi.proxy.securityProvider = com.sun.net.ssl.internal.ssl.Provider
juddi.proxy.protocolHandler = com.sun.net.ssl.internal.www.protocol


一下是我在C:\apache-tomcat-6.0.13\webapps\juddi\WEB-INF 里面的 juddi-users.xml 文件
<?xml version="1.0" encoding="UTF-8"?>
<juddi-users>
  <user userid="sviens" password="password" />
  <user userid="juddi" password="juddi" />
</juddi-users>

一下是我的CLASSPATH:
C:\Program Files\Java\jdk1.6.0_01\bin;
C:\Program Files\Java\jdk1.6.0_01\src;
C:\apache-tomcat-6.0.13\lib\servlet-api.jar;
C:\apache-tomcat-6.0.13\lib\jsp-api.jar;
C:\apache-tomcat-6.0.13\lib\el-api.jar;
C:\Servlets+JSP;
C:\axis-1_4\lib\axis.jar;
C:\axis-1_4\lib\commons-discovery-0.2.jar;
C:\axis-1_4\lib\commons-logging-1.0.4.jar;
C:\axis-1_4\lib\jaxrpc.jar;C:\axis-1_4\lib\saaj.jar;
C:\axis-1_4\lib\log4j-1.2.8.jar;
C:\axis-1_4\lib\endorsed\xml-apis-2.6.2.jar;
C:\axis-1_4\lib\endorsed\xercesImpl-2.6.2.jar;
C:\axis-1_4\lib\wsdl4j-1.5.1.jar;
C:\axis-1_4\lib\activation.jar;
C:\axis-1_4\lib\mailapi_1_3_1.jar;
C:\Program Files\Java\jdk1.6.0_01\lib\tools.jar;
C:\uddi4j\lib\uddi4j.jar;
C:\apache-tomcat-6.0.13\webapps\juddi\WEB-INF\lib\juddi.jar;
C:\apache-tomcat-6.0.13\lib\soap.jar;
C:\axis-1_4\lib\mail.jar;.

麻烦哪位高手可以帮个忙,我已经试了3天了。


--  作者:yuzhouhenan
--  发布时间:9/16/2007 10:50:00 AM

--  
你的问题解决没,我也有同样的问题
--  作者:kele515
--  发布时间:9/22/2007 2:50:00 PM

--  
我曾经也遇到到你说的问题,但是我将环境换成了tomcat5.5,jdk1.5之后,问题就解决了,你可以试试将你的环境也换成tomcat5.5+jdk1.5再试试,应该可以正常运行FindBusinessExample.java
--  作者:taleljp
--  发布时间:4/14/2008 2:52:00 PM

--  
如何测试udd4j/samples里的例子呢?哪里能不能告知我一下怎么样才能测试它们。我已经安装好了juddi.诚挚感谢
--  作者:bandaotiehe
--  发布时间:8/26/2008 8:12:00 PM

--  
顶啊 我也遇见这样的问题  有谁知道啊  说说怎么解决啊  先谢谢了啊
--  作者:lendlicelaw
--  发布时间:10/6/2008 5:07:00 PM

--  
貌似是你log4j的问题,你把sample.prop里的logenable=true换成false试试呢?
W 3 C h i n a ( since 2003 ) 旗 下 站 点
苏ICP备05006046号《全国人大常委会关于维护互联网安全的决定》《计算机信息网络国际联网安全保护管理办法》
78.125ms