You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@juddi.apache.org by Behrad <be...@yahoo.com> on 2004/10/14 10:24:54 UTC

Juddi TModel Problem

Howdy All,

I'm working with Juddi Server ( with UDDI4J API on Top ), but i have
some problems:

1) I can't update a Tmodel with save_tmodel function with tmodel_key
[UUID] passed. "it says Duplicate Entry Found for key 1 ..." this is
..."\
\
2) I delete a tmodel with delete_tmodel. after that when i try to call\
find_tmodel and get_tmodel_detail to list tmodels, it throws a\
NullPointerException and says: " [A DispositionReport was not\
present]".\
i waana know if i should do something to returned DispositionReport\
from delete_tmodel function!\
\
Here is some snippet of my code in UDDI4J:\
\
1) TO DELETE A TMODEL:\
                String key = "uuid:35272D40-1C58-11D9-A333\-C151C1240987";\
                proxy.delete_tModel( token.getAuthInfoString(), key );\
\
2) TO LIST TMODELS:\
        // proxy is a UDDIProxy object ...\
        proxy = getProxy();\
        Vector wsdls = new Vector();\
        CategoryBag categories = new CategoryBag();\
        Vector keys = new Vector();\
        KeyedReference keyRef = new KeyedReference();\
        keyRef.setTModelKey( "EHEALTH_TMODEL" );\
        keys.add( keyRef );\
        categories.setKeyedReferenceVe\ctor( keys );\
        Vector list = proxy.find_tModel( categories, null, MAX_ROWS\
).getTModelInfos().getTModelIn\foVector();\
\
3) To Update a TMODEL:\
                 TModel model = new TModel();\
                 model.setTModelKey(\
"uuid:38012FA0-1C55-11D9-A266\-E751391200B2" );\
                model.setDefaultDescriptionStr\ing( "sample tmodel" );\
                model.setName( "category tmodel" );\
                OverviewDoc wsdl = new OverviewDoc();\
",1]);//-->as where i pass an invalid tmodel_key it says: "Invalid. Key not found
..."

2) I delete a tmodel with delete_tmodel. after that when i try to call
find_tmodel and get_tmodel_detail to list tmodels, it throws a
NullPointerException and says: " [A DispositionReport was not
present]".
i waana know if i should do something to returned DispositionReport
from delete_tmodel function!

Here is some snippet of my code in UDDI4J:

1) TO DELETE A TMODEL:
               String key = "uuid:35272D40-1C58-11D9-A333-C151C1240987";
               proxy.delete_tModel( token.getAuthInfoString(), key );

2) TO LIST TMODELS:
       // proxy is a UDDIProxy object ...
       proxy = getProxy();
       Vector wsdls = new Vector();
       CategoryBag categories = new CategoryBag();
       Vector keys = new Vector();
       KeyedReference keyRef = new KeyedReference();
       keyRef.setTModelKey( "EHEALTH_TMODEL" );
       keys.add( keyRef );
       categories.setKeyedReferenceVector( keys );
       Vector list = proxy.find_tModel( categories, null, MAX_ROWS
).getTModelInfos().getTModelInfoVector();

3) To Update a TMODEL:
                TModel model = new TModel();
                model.setTModelKey(
"uuid:38012FA0-1C55-11D9-A266-E751391200B2" );
               model.setDefaultDescriptionString( "sample tmodel" );
               model.setName( "category tmodel" );
               OverviewDoc wsdl = new OverviewDoc();
                model.setOverviewDoc( wsdl );\
                CategoryBag categories = new CategoryBag();\
                Vector keys = new Vector();\
                KeyedReference keyRef = new KeyedReference();\
                keyRef.setTModelKey( "EHEALTH_TMODEL" );\
                keys.add( keyRef );\
                categories.setKeyedReferenceVe\ctor( keys );\
                model.setCategoryBag( categories );\
                Vector modelvec = new Vector();\
                modelvec.add( model );\
                out.print( ((TModel)proxy.save_tModel(\
token.getAuthInfoString(), modelvec ).getTModelVector().get( 0\
)).getTModelKey() );\
\
Your help is really needed. Thanks in advance.\
\
--Behrad\
",1]);D(["mb","",0]);D(["ce"]);//-->               wsdl.setOverviewURL( "tmodel url" );
               model.setOverviewDoc( wsdl );
               CategoryBag categories = new CategoryBag();
               Vector keys = new Vector();
               KeyedReference keyRef = new KeyedReference();
               keyRef.setTModelKey( "EHEALTH_TMODEL" );
               keys.add( keyRef );
               categories.setKeyedReferenceVector( keys );
               model.setCategoryBag( categories );
               Vector modelvec = new Vector();
               modelvec.add( model );
               out.print( ((TModel)proxy.save_tModel(
token.getAuthInfoString(), modelvec ).getTModelVector().get( 0
)).getTModelKey() );

Your help is really needed. Thanks in advance.

--Behrad

p.s. I founded out that when Deleteing an UDDI datatype Juddi first deletes it then inserts new information. it works for BusinessEntity, Service, ... but not for TModel, 'cause it phisically wont be out from DB, so it's PK would be duplicated during the insert. i didnt realy spect such a silly thing from juddi.apache !!!


--Behrad  
Give joy, Not request it.


		
---------------------------------
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.