3 Star 2 Fork 3

Gitee 极速下载 / yavijava

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
此仓库是为了提升国内下载速度的镜像仓库,每日同步一次。 原始仓库: https://github.com/yavijava/yavijava
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
BSD-3-Clause

Build Status Join the chat at https://gitter.im/yavijava/yavijava

Welcome to the YAVI Java API

WHAT IS YAVI JAVA API?

It is a fork of the VI Java API which is a set of Java libraries that aim to ease the usage of VI SDK Web Services interfaces. It's now open-sourced under a mixed BSD license and Apache-2.0 license.

It provides the following benefits to the Java developers:

  • Enables OO programming with a well defined managed object model
  • Reduces the need to use ManagedObjectReference and makes possible compile time type checking
  • Hides the complexity of the PropertyCollector
  • Provides necessary utility classes to simplify VI SDK web interfaces
  • High performance with 4+ times faster than AXIS engine
  • Adds the ability to provide your own HTTP Client
  • Adds logging using log4j
  • Adds gradle support for the build system

As a result, the application code using this API is much shorter (70% less) and much more readable than the equivalent using web service interfaces directly. The API itself is straight-forward and easy to learn and use.

WHO CREATED THE API?

To find out more about the original VI Java API see http://vijava.sf.net

As for who created this fork called YAVI Java that is Michael Rice.

Whats with the name?

The name YAVI means simply Yet Another VI Java. I forked this project and moved it to github because the project seemd stale and I felt it needed new life. I wanted things like GitHub, custom http clients, and logging, and tests as well as other stuff so I decided to fork the project and do it.

Do I have to change my code to use this?

No!! This is a drop in replacement and requires no code modification, but does introduce some new dependencies (Always check the build.gradle for the latest requirements):

dependencies {
    compile 'org.apache.directory.studio:org.dom4j.dom4j:1.6.1'
    compile 'log4j:log4j:1.2.17'
    compile 'org.apache.httpcomponents:httpclient:4.3.5'
    testCompile 'org.mockito:mockito-all:1.9.5'
    testCompile group: 'junit', name: 'junit', version: '4.+'
}

WHERE CAN I GET HELP?

File a bug: https://github.com/yavijava/yavijava/issues

IRC: Freenode IRC #vijava

COPYRIGHT & LICENSE: BSD. See the License.txt file for details

What happened to the samples?!?!

Never fear. I removed them from the core of the project and made them their own project. They can be found here: https://github.com/yavijava/yavijava-samples

Testing

Testing is broken into two main packages which are discussed below. It is very important that pull requests you send include a test. Many very large enterprise customers depend on this library so extensive work is being put into trying to cover as much of the codebase as possible with tests.

Integration

The first package is integration tests which are stored in src/intTest There is a properties file included that contains the URL, username and password for use in connecting to a vCenter or HostSystem. It has a default value of https://vcsa/sdk for its URL, and 'administrator@vsphere.local' for the user name, and 'password' is used for the default password. The reason these defaults are included is because I use the vCenter Server Appliance in SIM mode to do as many of the tests as possible and I create an alias in my /etc/hosts file so vcsa always points at my local vCenter. Next I use a very basic shell script to configure the VCSA SIM and use 'password' for my default password. To run these tests make sure the properties file contains valid information for your environment. Next from the project root where the build.gradle is execute gradle intTest or use the gradlew script and execute: ./gradlew intTest

Unit

The Second package is the unit tests. These tests are stored in src/test These are basic unit tests and should be created using either junit or spock. Tests can be written in pure Java or Groovy. Please use the appropriate folder for the language you create your test with. The unit tests are run automatically by travis-ci when a pull request is opened, and they should always be run before you open a pull request where you are introducing changes that either fix bugs, or add functionality to ensure they continue to pass with your changes. To run these tests execute gradle test or use the gradlew script and execute ./gradlew test

Copyright (c) 2012 2013 Steve Jin. All Rights Reserved. Copyright (c) 2008 VMware, Inc. All Rights Reserved. Copyright (c) 2009 Altor Networks. All Rights Reserved. Copyright (c) 2009 NetApp. All Rights Reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of VMware, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

简介

YAVIJAVA is an OpenSource JAVA SDK for VMWare vSphere 展开 收起
Java 等 2 种语言
BSD-3-Clause
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
Java
1
https://gitee.com/mirrors/yavijava.git
git@gitee.com:mirrors/yavijava.git
mirrors
yavijava
yavijava
gradle

搜索帮助

53164aa7 5694891 3bd8fe86 5694891