Karaf 4.3.6

The documentation, https://karaf.apache.org/manual/latest/#_datasources_jdbc,  
for the "name" argument in the command "jdbc:ds-create" states "to create the 
datasource definition file (deploy/datasource-[name].xml)."  I do not see a 
file created in the deploy directory, but I do see a file in the cache 
directory for the "Apache Felix Configuration Admin Service" bundle with a 
generated name.
  
1) Is this phase inaccurate and should be removed from the documentation?

2) If the phrase is correct, how does one create the file in the deploy 
directory?

***
* Example of creating JDBC Datasource and looking of the created data 
definition file in the deploy directory
**
karaf@root()> jdbc:ds-create -dn hsqldb -url "dbc:hsqldb:mem:." -u sa myDb
karaf@root()> ds-list
Name              │ Service Id │ Product              │ Version                 
 │ URL                                                 │ Status
──────────────────┼────────────┼──────────────────────┼──────────────────────────┼─────────────────────────────────────────────────────┼───────
myDb              │ 177        │ HSQL Database Engine │ 2.5.1                   
 │ jdbc:hsqldb:dbc:hsqldb:mem:.                        │ OK
karaf@root()> config:list '(service.factoryPid=org.ops4j.datasource)'
----------------------------------------------------------------
Pid:            org.ops4j.datasource.ad014501-2db1-4455-abb9-ced214fee015
FactoryPid:     org.ops4j.datasource
BundleLocation: mvn:org.ops4j.pax.jdbc/pax-jdbc-config/1.5.0
Properties:
   dataSourceName = myDb
   osgi.jdbc.driver.name = hsqldb
   service.factoryPid = org.ops4j.datasource
   service.pid = org.ops4j.datasource.ad014501-2db1-4455-abb9-ced214fee015
   url = dbc:hsqldb:mem:.
   user = sa
karaf@root()> shell:ls deploy
.      ..     README
karaf@root()> 
karaf@root()> list -t 0 12                                                      
                                                                                
                                                                                
         
START LEVEL 100 , List Threshold: 0
ID │ State  │ Lvl │ Version │ Name
───┼────────┼─────┼─────────┼────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────12
 │ Active │  10 │ 1.9.22  │ Apache Felix Configuration Admin Service
karaf@root()> 
karaf@root()> shell:ls -l  
data/cache/bundle12/data/config/org/ops4j/datasource/ad014501-2db1-4455-abb9-ced214fee015.config
                                                                                
                                                
-rw-r--r--   1 paul     staff         252 Apr 29 11:30 
data/cache/bundle12/data/config/org/ops4j/datasource/ad014501-2db1-4455-abb9-ced214fee015.config
karaf@root()> 
karaf@root()> shell:cat  
data/cache/bundle12/data/config/org/ops4j/datasource/ad014501-2db1-4455-abb9-ced214fee015.config
                                                                                
                                
:org.apache.felix.configadmin.revision:=L"1"
dataSourceName="myDb"
osgi.jdbc.driver.name="hsqldb"
service.factoryPid="org.ops4j.datasource"
service.pid="org.ops4j.datasource.ad014501-2db1-4455-abb9-ced214fee015"
url="dbc:hsqldb:mem:."
user="sa"
karaf@root()>    karaf@root()>                                                  
                                                                                
                                                                                
                            


Paul Spencer 

Reply via email to