Skip to main content

DRB Java Driver

Project description

JavaNode driver

The drb-driver-java python module aims to wrap Java version of DRB model. It is able to navigates among java nodes content.

See documentation for details.

Library usage

Java (JDK) must be present in the system and the JAVA_HOME environment variable must be set.

Installation

Installing this library with execute the following in a terminal

pip install drb-driver-java

Configuration

Automatic

The classpath is initialized retrieving Java libraries using a specific entry point drb.driver.java where:

  • name: represent the Java library package extension (e.g. jar)
  • value: represent the package where Java libraries are stocked

The following example will retrieve all jar files resources from the Python package my.package.classpath:

from setuptools import setup

setup(
    entry_points={
        'drb.driver.java': 'jar = my.package.classpath'
    },
    # Other setuptools.setup parameters
)

Manual

To add custom Java libraries to the JVM classpath, please configure CLASSPATH_ADDON environment variable. It contains absolute path of additional Java libraries

export CLASSPATH_ADDON=$CLASSPATH_ADDON:/path/to/my/custom/java/lib

Java Factory and Java Node

The module implements the basic factory model defined in DRB in its node resolver. Based on the python entry point mechanism, this module can be dynamically imported into applications.

The entry point group reference is drb.driver.
The driver name is java.
The factory class DrbJavaFactory is encoded into drb.drivers.factory

The java factory creates a JavaNode from an existing java content. It uses a base node to access the content data using a streamed implementation from the base node.

The base node can be a DrbFileNode, DrbHttpNode, DrbTarNode or any other nodes able to provide streamed (BufferedIOBase, RawIOBase, IO) java content.

limitations

The current version does not manage child modification and insertion. JavaNode is currently read only.

Using this module

To include this module into your project, the drb-driver-java module shall be referenced into requirements.txt file, or the following pip line can be run:

pip install drb-driver-java

Set eventually environment variable CLASSPATH_ADDON and JAVA_HOME

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

drb-driver-java-1.4.0.tar.gz (27.7 MB view details)

Uploaded Source

Built Distribution

drb_driver_java-1.4.0-py3-none-any.whl (27.7 MB view details)

Uploaded Python 3

File details

Details for the file drb-driver-java-1.4.0.tar.gz.

File metadata

  • Download URL: drb-driver-java-1.4.0.tar.gz
  • Upload date:
  • Size: 27.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.18

File hashes

Hashes for drb-driver-java-1.4.0.tar.gz
Algorithm Hash digest
SHA256 d0116e12d18467f48f5e439aae90b69fb918b7516b1959896f8c00b43ee224d5
MD5 01bbbd27bef31dd146f472c8b8238fd5
BLAKE2b-256 d564a54264ef3a229500f3d246a82edbefcd08606c950d9afcff6b9c1dd7e139

See more details on using hashes here.

File details

Details for the file drb_driver_java-1.4.0-py3-none-any.whl.

File metadata

File hashes

Hashes for drb_driver_java-1.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 37c56852d354793cf7e292a3460bcde36f1834548500d5553c2631435caee3f4
MD5 f43736bc98df31dcef7dba39a533ab66
BLAKE2b-256 b3cbcca35b58009701fe9470a0f3971b0ca4afd7db1d2de7d1e00036ca97aa02

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page