Using OSB for Public API (REST)

Hi there,
Is it a good practice to use Oracle Service Bus to expose a PUBLIC REST API?
The idea is to have a separeted OSB instance which will be in the WEB so that other partners and applications (Native Mobile, for instance) can access some of our services. The application layer will have many different applications, like SAP, JEE systems, Cobol and others. But the public API will be design in a more RESTful fashion.
What about security?
What about performance? (Parsing JMS, XML and others into JSON will probably create extra load into the OSB).
What are be the advantages of using OSB instead of a more traditional Service Layer?
P.S.: We are being careful with the design of our API, sometimes the underlying system doesn't help, so some transformation has to happen (more load!) in order to make the API elegant and meaningful.
Cheers

Personally, I'd prefer Collections as they are nice to work with. Their only annoying issue is certainly the constant casting as soon as you retrieve Objects from them.
I do not consider the documentation of what those Collection include too big a problem. Just include a line for each Collection parameter stating "Set of Strings" or the like. I wouldn't even check the type through instanceof, I'd just cast. If a ClassCastException is thrown, I think that's the proper thing to do.
As you might have noticed, there is a proposal of "Generics" for Java, which would adopt something like those template classes known in C++. There is even a beta implementation available, so you can go ahead and code your Set<String>. Time will tell if this proposal finds its way into the official Java standard, the drawback being a more complex syntax. If you want to know more about it, check out those links:
http://forum.java.sun.com/forum.jsp?forum=316
http://www.jcp.org/jsr/detail/14.jsp
http://developer.java.sun.com/developer/earlyAccess/adding_generics

Similar Messages

  • [svn] 4662: Refactoring to reflect new FXG utils package names to com.adobe .fxg.* for public APIs and com.adobe.internal.fxg. * for internal APIs not guaranteed to remain constant.

    Revision: 4662
    Author: [email protected]
    Date: 2009-01-25 16:05:12 -0800 (Sun, 25 Jan 2009)
    Log Message:
    Refactoring to reflect new FXG utils package names to com.adobe.fxg.* for public APIs and com.adobe.internal.fxg.* for internal APIs not guaranteed to remain constant.
    QA: No
    Doc: No
    Checkintests Pass
    Modified Paths:
    flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/fxg/TextFXGGraphics.java
    flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/fxg/TextHelper.java
    flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/media/FXGTranscoder.java
    Added Paths:
    flex/sdk/trunk/modules/fxgutils/src/java/com/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/fxg/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/fxg/FXGConstants.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/fxg/FXGException.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/AbstractFXGNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/AbstractShapeNode.jav a
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/BitmapGraphicNode.jav a
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/DefinitionNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/DelegateNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/EllipseNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/FXGNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/FillNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/FilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/GradientEntryNode.jav a
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/GraphicContentNode.ja va
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/GraphicContext.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/GraphicNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/GroupDefinitionNode.j ava
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/GroupNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/LibraryNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/LineNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/MaskPropertyNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/MaskableNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/MaskingNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/PathNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/PlaceObjectNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/RectNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/ScalableGradientNode. java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/StrokeNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/TextGraphicNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/TextNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/TransformNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/fills/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/fills/AbstractFillNod e.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/fills/BitmapFillNode. java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/fills/LinearGradientF illNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/fills/RadialGradientF illNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/fills/SolidColorFillN ode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/AbstractFilte rNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/BevelFilterNo de.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/BlurFilterNod e.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/ColorMatrixFi lterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/DropShadowFil terNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/GlowFilterNod e.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/GradientBevel FilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/filters/GradientGlowF ilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/strokes/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/strokes/AbstractStrok eNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/strokes/LinearGradien tStrokeNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/strokes/RadialGradien tStrokeNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/strokes/SolidColorStr okeNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/text/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/text/AbstractCharacte rTextNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/text/AbstractTextNode .java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/text/BRNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/text/CDATANode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/text/ParagraphNode.ja va
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/text/SpanNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/transforms/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/transforms/AbstractTr ansformNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/transforms/ColorTrans formNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/transforms/MatrixNode .java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/BevelType.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/BlendMode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/Caps.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/InterpolationMe thod.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/Joints.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/Kerning.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/LineBreak.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/MaskType.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/ScaleMode.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/ScalingGrid.jav a
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/SpreadMethod.ja va
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/WhiteSpaceColla pse.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/dom/types/Winding.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/sax/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/sax/FXGSAXScanner.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/AbstractFXGGraphics.j ava
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/FXGGraphics.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/ImageHelper.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/ShapeHelper.java
    flex/sdk/trunk/modules/fxgutils/src/java/com/adobe/internal/fxg/swf/TypeHelper.java
    Removed Paths:
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/FXGConstants.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/FXGException.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/AbstractFXGNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/AbstractShapeNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/BitmapGraphicNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/DefinitionNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/DelegateNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/EllipseNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/FXGNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/FillNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/FilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/GradientEntryNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/GraphicContentNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/GraphicContext.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/GraphicNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/GroupDefinitionNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/GroupNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/LibraryNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/LineNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/MaskPropertyNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/MaskableNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/MaskingNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/PathNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/PlaceObjectNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/RectNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/ScalableGradientNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/StrokeNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/TextGraphicNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/TextNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/TransformNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/fills/AbstractFillNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/fills/BitmapFillNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/fills/LinearGradientFillNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/fills/RadialGradientFillNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/fills/SolidColorFillNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/filters/AbstractFilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/filters/BevelFilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/filters/BlurFilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/filters/ColorMatrixFilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/filters/DropShadowFilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/filters/GlowFilterNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/filters/GradientBevelFilterNode.ja va
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/filters/GradientGlowFilterNode.jav a
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/strokes/AbstractStrokeNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/strokes/LinearGradientStrokeNode.j ava
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/strokes/RadialGradientStrokeNode.j ava
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/strokes/SolidColorStrokeNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/text/AbstractCharacterTextNode.jav a
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/text/AbstractTextNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/text/BRNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/text/CDATANode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/text/ParagraphNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/text/SpanNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/transforms/AbstractTransformNode.j ava
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/transforms/ColorTransformNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/transforms/MatrixNode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/BevelType.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/BlendMode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/Caps.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/InterpolationMethod.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/Joints.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/Kerning.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/LineBreak.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/MaskType.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/ScaleMode.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/ScalingGrid.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/SpreadMethod.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/WhiteSpaceCollapse.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/dom/types/Winding.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/sax/FXGSAXScanner.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/swf/AbstractFXGGraphics.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/swf/FXGGraphics.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/swf/ImageHelper.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/swf/ShapeHelper.java
    flex/sdk/trunk/modules/fxgutils/src/java/flash/fxg/swf/TypeHelper.java

    The problem with submitting a bug report is I don't know how to replicate it.
    The java file showed up on the "Referenced Libraries". I removed it from there and it fixed the problem.
    If I return it to the classpath via Eclipse it doesn't demonstrate the problem.
    I don't know how it got into the classpath to cause this problem. I even tried editing the classpath (which I'm fairly certain was not how the problem was caused) but that didn't replicate the problem.
    I didn't check the .classpath to see what the entry was before I removed it via eclipse so I don't know what the entry looked like. The problem wasn't in the version is SVN so I don't know how to find what changes were made.
    If you sill want a bug report I can enter one but with out any instructions on how to replicate it.

  • Experience using Oracle for public sector budgetting?

    I am looking to know if anyone has experience using Planning for public sector budgetting, not necessarily the PubSect app itself.
    I am looking for some highlevel feedback regarding the biggest challenges in using Hyperion Planning for developing a government/state budget, where the typical cycle involves a parliament or another elected organ, etc.
    I am aware of the Scottish government using one and Abu Dhabi also has it implemented but if you know others I would be delighted to hear of them.
    Thanks All :) .
    Agnete

    We did think about using the device as a "Shared Device" but we thought this would get over complicated, as the library has requested that the users can just pick it up and use it without any hassle. Which in an ideal world would be easy but alas, it is not!
    We also thought about using Single App Mode and locking it into the AirWatch Secure Browser, where we could disable things like caching and saving usernames and passwords etc!
    Thanks for your reply!
    Vish

  • Untyped Collections vs. Typed Arrays for public API

    hi,
    I'm just courious about hearing any tips or advice from you ragarding how to design a public API of a program that uses collections (like collections of Date-objects for example). In a first thought I'd go and implement it using the Collection-Framework by defining public accessor methods that take in a Collection of the desired objects, as well as (for the getters) return some Collection (for example here a concrete TreeSet when data is returned sorted). So far so good, but then I always end up using downcasts to the object I expected (checked using "instanceof" to avoid ClassCastException's). As I'd like to make the public part of the API as robust as possible I don't like to force the users to read the methods' javadocs in full detail in order to know what dsired objects to put in the collection they pass in, or to what interface-types they can downcast when fetching objects from such a collection from an accessor method.
    The other idea might be - to overcome this untyped API - to use arrays here (as they're typed and bound during compile-time), but in the Java Tutorial I read that array-based interfaces are mostly legacy things and should be avoided (by using collections) in new systems. Personally I like the Collection-Framework very much, since it offers a lot of things like sorting, easy iteration, etc. Generally speaking I like them as they feel more like objects than arrays do. But it also always feels like they're untyped by using downcasts everywhere, which are only checked at runtime (of course) so that it is a potentially hard to detect risk of error for the API users. Even when subclassing the Collections (i.e. implementing java.util.Collection in an own collection-like class) we gain no compile-type checks here, since we have to implement the methods accepting and returning java.lang.Object's. I understand that the idea of the Collection-Framework is to keep things very general, but when using this generality we loose type-checks at compile-time yielding towards loosing robustness.
    There are several good books out there with general recommendations and tips about how to write good, nice, and robust code, including ideoms and coding-styles, but none of them (at least none of mine) has covered this. The essence of what I could get out of them is that code (especially a public API) should be robust and we should re-use the wheel (like the Collections-Framework in java.util), but what about the thing of "Untyped Collections vs. Typed Arrays" when comparing code-reuse and interoperability with other collecion-based APIs against the robustness of compile-time checks of data-types in arrays.
    Suppose you were about to use some API, what kind of interface (and for what reason) would you like? Typed Arrays which are not so nice to handle/use, or Untyped Collections where you've always got to read the API's docs about what to put in and what to downcast to... I know that it's easy (using the static convenience methods of java.util.Collections and java.util.Arrays) to convert between both, but what would you natively prefer?
    Thank you very much for your answers, and I really look forward to any thoughts on this, as I personally have not decided on this...
    X-Post from "Java Collections Framework" forum since I think it does not only belong to Collection Framework details, as it is more a general API-design topic...

    Typically speaking, I prefer the Collections API to using arrays as well, although the specific needs often dictate the best choice. When developing type safe collections, I would suggest one of two design options:
    1) extend SDK Collection classes to become type safe. For example, extend ArrayList with DateList and then over-ride all the add methods so that a ClassCastException is thrown when the argument is not assignable to java.util.Date. This design has less development over-head, since you inherit the collection management logic from the super class, but the type checks are obviously completed at run time, not compile time
    2) make your own class that implement the Collections API. Basically, I would create one abstract class that manages the collection logic, holding an array of Objects that can be resized and then have your subclasses provide type-specific add methods to that array. Here you gain compile-time type checks, but have a higher development over-head.

  • Facebook auth for web api REST implementation

    Is it possible to use the OOB experience when creating a web REST API project like a website? It was easy enough to incorporate the FB redirect for a generated site, but I'd like to use same authentication for a REST API too?  Is it possible to use
    the components provided by VS project but not do a redirect to FB but rather return a error to calling client?  What would the calling client need to include to the REST API in order for the authentication to work? Is this possible to do?

    Hi sir,
    Yes, you can use FaceBook as an ACS Identity Provider in your project. I suggest you can refer to this document.
    https://msdn.microsoft.com/en-us/library/azure/gg185967.aspx?f=255&MSPPError=-2147217396
    Also, there is a code sample about REST service Authentication with ACS, you could download it and refer to it:
    https://code.msdn.microsoft.com/vstudio/AAL-Native-App-to-REST-de57f2cc
    Regards,
    Will
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • About using OSB JMX Monitoring API

    hi Experts,
    My customer is using OSB11.1.1.7, they are trying to use JMX Monitoring API to get the statistic info, but have the following issues:
    1. For the non-soap service, the serviceDomainMbean.getBusinessServiceStatistics method always return error when typeFlag was set with ResourceType.WEBSERVICE_OPERATION.value(), reason is there is no ws operation for this service, customer wants to know how to know if a service has no ws operation ,therefore they can avoid to get ws-operation statistic info for those kind of services.
    2. Is there a way to get statistic info for the current aggregation interval? the api seems works with period from last reset.
    3. Further more, How to get statistic info for special period, for example, customer want to query statistic info from 05/01 to 05/03, or from 05/03 12:00 to 05/03 13:00
    Thanks for the help.
    Best regards

    Davinder Singh wrote:
    Hi ,
    I have an application deployed on weblogic server 8.1 . This has some MBeans exposed
    for management purposes. This needs to be accessed from another web application
    running on another weblogic instance on different machine. For this the managed
    application has a Connector server and the management application is trying to
    connect it through Connector client.
    At the managed application side , i am getting NoSuchMethodError: javax.management.MBeanServer.getClassLoaderRepository()
    I am not using weblogic implementation of JMX (MBean Server).
    My guess about the error :the weblogic implements JMX version 1.0 and i am using
    JMX remoting API (RI from Sun) which requires JMX 1.2
    Is there a way i can make weblogic use JMX 1.2 ?I dont think there is a way to do this. But I might be wrong.
    >
    Thanx,
    Davinder

  • Use LoginToken for Server API Session

    I get an Invalid pointererror when I try the code below. I'm trying to use the Login Token passed from the portlet as the token for the Server API Session I create.
    portletContext = PortletContextFactory.CreatePortletContext(Request, Response);
    //Get Remote Session
    IRemoteSession prcSession = portletContext.GetRemotePortalSession();
    //Get UserLogin token from Portlet
    stringsUserLoginToken = prcSession.GetLoginToken();
    //Reconnect to portal session with token
    IPTSession oPTSession = PortalObjectsFactory.CreateSession();
    oPTSession.Reconnect(sUserLoginToken);

    We are using 5.0.3. I found I could use the Login Token passed from the portlet in a Server API Session by doing the following:
    IPTSession pSession = PortalObjectsFactory.CreateSession();
    pSession.Reconnect(sLoginToken);

  • BEA public API (WLS6.1)for programatically updating default security realm?

    Hi,
    Does anyone know how to use BEA's public API to programmatically add/update WLS
    6.1 user credentials in the default security realm? The API would of course
    automatically persist the updates to $WLS/config/mydomain/fileRealm.properties.
    Is there a way to do such updates by programmatically engaging the WLS security
    realm related Mbeans? I basically need to do (from a deployed application component)
    what is easily done from the WLS Console's [security->User->Add User/Change
    Password] screen. Ideally, I could use the same API that the weblogic.security.acl.internal.FileRealm
    command line utility (or wlshell also) uses to make updates. But I doubt that
    the classes used by these tools are in BEA's public API for WLS 6.1. Especially
    important to me would be the BEA API mechanism that takes a clear-text password
    and hashes it to the encrypted format written in fileRealm.properties (and synchronized
    w/ SerializedSystemIni.dat). Ultimately, I am trying to replicate a large
    Oracle table of (*user, clear-text -password, group) records into the default
    WLS security realm. Thanks for any insights.
    Ben

    Thanks to another's post, I have found the answer to my problem in the Girdley/Woollen/Emerson
    book "J2EE Applications and BEA WebLogic Server" pp. 496-498:
    Note: this code segment is for WLS 6.1 and this API is said to be deprecated
    in WLS 7+
    //Roughly outlined, assuming session w/ userName, groupName, password Strings
    in HTTP Post request
    weblogic.security.acl.CachingRealm realm = (weblogic.security.acl.CachingRealm)
    weblogic.security.acl.Security.getRealm();
    weblogic.security.acl.User u;
    weblogic.security.acl.Group g;
    u = realm.newUser(userName, password, null);
    g = realm.getGroup(groupName); // use g = realm.newGroup(groupName) if groupName
    does not exist in realm
    g.addMember(u);
    //log in the new user
    int rc = weblogic..servlet.security.ServletAuthentication.weak(userName, password,
    httpSession);
    // use realm.deleteUser(u), realm.deleteGroup(g) as appropriate, etc.
    "Ben Cotton" <[email protected]> wrote:
    >
    >
    Hi,
    Does anyone know how to use BEA's public API to programmatically add/update
    WLS
    6.1 user credentials in the default security realm? The API would of
    course
    automatically persist the updates to $WLS/config/mydomain/fileRealm.properties.
    Is there a way to do such updates by programmatically engaging the
    WLS security
    realm related Mbeans? I basically need to do (from a deployed application
    component)
    what is easily done from the WLS Console's [security->User->Add User/Change
    Password] screen. Ideally, I could use the same API that the weblogic.security.acl.internal.FileRealm
    command line utility (or wlshell also) uses to make updates. But I
    doubt that
    the classes used by these tools are in BEA's public API for WLS 6.1.
    Especially
    important to me would be the BEA API mechanism that takes a clear-text
    password
    and hashes it to the encrypted format written in fileRealm.properties
    (and synchronized
    w/ SerializedSystemIni.dat). Ultimately, I am trying to replicate
    a large
    Oracle table of (*user, clear-text -password, group) records into the
    default
    WLS security realm. Thanks for any insights.
    Ben

  • App rejected due to non-public api's

    Hi,
              My App rejected due to non-public api's.
    Apple's Comments: 
    2.5: Apps that use non-public
                                      "We found that your app uses one or more non-public APIs, which is not in compliance with the App Store Review Guidelines. The use of non-public APIs is not permissible because it can lead to a poor user experience should these APIs change.
    We found the following non-public API/s in your app:
    _updateView (I have the method name like "_updateView" in my source, can I change the name of the method. Is it works ? )
    If you have defined methods in your source code with the same names as the above-mentioned APIs, we suggest altering your method names so that they no longer collide with Apple's private APIs to avoid your application being flagged in future submissions.
    Additionally, one or more of the above-mentioned APIs may reside in a static library included with your application. If you do not have access to the library's source, you may be able to search the compiled binary using "strings" or "otool" command line tools. The "strings" tool can output a list of the methods that the library calls and "otool -ov" will output the Objective-C class structures and their defined methods. These techniques can help you narrow down where the problematic code resides."
                                    And in my application, I am using the FBConnect, SDWebImage library,  and Twitter+oAuth api's. These are non-public api's ? Now, can I integrate Jira (Crash Reporter) to my application? Can anybody solve my issue......
    Thanks & Regards,
    Rajesh Kumar Yandamuri

    I have the same problem what to do with below points from the apple.
    Requires help plz help me my app rejected two times with this points.
    We found that your app uses one or more non-public APIs, which is not in compliance with the App Store Review Guidelines. The use of non-public APIs is not permissible because it can lead to a poor user experience should these APIs change.
    We found the following non-public API/s in your app:
    _tearDown
    If you have defined methods in your source code with the same names as the above-mentioned APIs, we suggest altering your method names so that they no longer collide with Apple's private APIs to avoid your application being flagged in future submissions.
    Additionally, one or more of the above-mentioned APIs may reside in a static library included with your application. If you do not have access to the library's source, you may be able to search the compiled binary using "strings" or "otool" command line tools. The "strings" tool can output a list of the methods that the library calls and "otool -ov" will output the Objective-C class structures and their defined methods. These techniques can help you narrow down where the problematic code resides.
    We appreciate that you may have made the precautions in your code for using non-public APIs, however, there is no way to accurately or completely predict how an API may be modified and what effects those modifications may have. For this reason, we do not permit the use of non-public APIs in App Store apps.
    If there are no alternatives for providing the functionality your app requires, we encourage you to file an enhancement request. Or, try working with the Apple Developer Technical Support team to explore alternative solutions. 
    On occasion, there may be apps on the App Store that don't appear to be in compliance with the App Store Review Guidelines. We work hard to ensure that the apps on the App Store are in compliance and we try to identify any apps currently on the App Store that may not be. It takes time to identify these occurrences but another app being out of compliance is not a reason for your app to be.
    For discrete code-level questions, you may wish to consult with Apple Developer Technical Support. Please be sure to:
    - include the complete details of your rejection issues
    - prepare any symbolicated crash logs, screenshots, and steps to reproduce the issues for when the DTS engineer follows up.
    For information on how to symbolicate and read a crash log, please see Tech Note TN2151 Understanding and Analyzing iPhone OS Application Crash Reports.
    If you have difficulty reproducing this issue, please try testing the workflow as described in  <https://developer.apple.com/library/ios/qa/qa1764/>Testing Workflow with Xcode's Archive feature".

  • Why is there no WSDL type support for Web Api?

    So I am just getting started with .Net WebApi and one thing that I am noticing straight away is that there is no Contract defining how the Api looks and should be consumed (Request/Responses from each Action), this is usually in the form of a WSDL for WCF/Soap.
    It seems to me like this is something that would be very valuable and make life a lot easier for consumers of your Api.
    Is there a reason there isn't one? Is there a programming paradime or principle that I am unaware of? Is there a way I could create one?

    SOAP, REST AND PEOPLE'S CREATIVITY
    SOAP needs a description document like WSDL because each resource can be consumed with different messages, there are no definition on the protocol about constraints to the possible names/messages that you can manipulate a resource.
    For example, in SOAP your web service that allow clients manipulate an user can expose the operation that create an user in many different messages, like:
    addUser
    createUser
    insertUser
    Of course, these are just few sample messages, because I've see a lot of funny web services method names. There are really creative people out there.
    In other hand, if you are exposing your underlying system using web api that really respect the REST principles, the client just need to know that you have a resource named Users, because there is 99% of chance that you can create an user in this way
    POST /Users
    And this occurs for each operation you want to expose using SOAP or a web api REST.
    Despite being SOAP a protocol, which restricts what you can or can not do, and be REST a style architecture, which leaves many open points of how to do things. There are efforts to define conventions of how to expose and consume REST web apis.
    DESCRIBING A WEB API REST
    In the field of how to describe a web api REST I can cite
    Swagger. It is not a attempt to create a WSDL like to web api REST, but it is a good attempt to create an open standard for describing web apis REST.
    Swagger is a specification and complete framework implementation for describing, producing, consuming, and visualizing RESTful web services.
    I use Swagger a lot and really love it, mainly because
    Swagger UI that allow you generate a nice live console and documentation for your web api.
    There are many implementations of Swagger for most of languages: C#, Java, Python, Ruby, etc.
    If you are using ASP .NET Web API, there a some projects to auto generate the Swagger specification, like
    Swagger.NET
    GENERATING CLIENTS TO A WEB API REST
    Because the constraints of REST, like the limited set of verbs (GET, POST, PUT, DELETE, etc) is not so difficuty to generate a client library to a web api REST.
    Projects like
    WebApiProxy can easily generate clients do C# and Javascript.
    CONVENTIONS FOR WEB API REST
    To keep our lifes as developers easier is good define some conventions of how our web api REST will behave, the best effort I know in this field is the very good
    Apigee - Web Api Design ebook. The e-book is not an attempt to create a bible or a mantra about how to design your api, but rather a collection of conventions observed in large web REST apis, like Twitter, Facebook, Linkedin, Google, etc.

  • Map ***** for public transportation! What app can help me get the same results as the map before the ios6 upgrade?!!

    I remember using maps for public transportation before i start driving and it was pretty godd. Telling me when the next bus is departing giving me all the option necerssary to get to where i want to go all in the map app...now when i touch on the public transportation option it just take me to a bunch of apps that i try and try and none of them work as the map...so now i want to know if there is any app that can replace the efficience of maps before      ios6     upgrade...
    Please help

    There are lots of public transit information apps in the App Store. A search for "public transit" or "public transportation" should turn them up. What you might find useful would depend on where you'd be using it. I've used HopStop.

  • Any Public API's used for Punch Machine in OTL

    Hi,
    Could you let me know if there are any Public API's used for Punch Machine in OTL
    Thanks.

    Could you let me know if there are any Public API's used for Punch Machine in OTLPlease see these docs.
    Would like Punch In or Out Time to be Used to Worked Day Determination. [ID 1350155.1]
    Oracle Time and Labor (OTL) Implementation and User Guide, Release 12 [ID 1070930.1]
    Thanks,
    Hussein

  • How to configure proxy services in OSB for Rest based services?

    how to configure proxy services in OSB for Rest based services implemented using Jersey (Rest).
    The Client need to contact OSB proxy servies by posting application/xml using jersey client and OSB proxy service will call the OSB business service.
    i would like to know how to get this request in OSB proxy service and send it to the business service and get the response back.

    I would suggest you refer to the below links:
    https://blogs.oracle.com/jeffdavies/entry/restful_services_with_oracle_s_1
    https://blogs.oracle.com/jamesbayer/entry/using_rest_with_oracle_service
    Hope this helps.
    Thanks,
    Patrick

  • Which Objects should I target for integrating Eloqua REST API 2.0?

    Which Objects should I target for integration? and What are the possible use cases for the additional objects other than core objects?

    I am still trying to find a good REST API 2,0 document like the Bulk 2.0 document.  Book List: Oracle Marketing Cloud
    I did find this but is also not in depth:
    REST API - Documentation for Core Objects

  • Public API's to create delivery for each delivery line

    I've requirement to create unique delivery for each delivery line using API. Can any body use public API to meet this requirement. Please ! any idea and thought !
    R12.
    Thanks in Advance,
    Ramana

    Try the WSH_DELIVERIES_PUB.Create_Update_Delivery API. The API creates a new delivery record or updates an existing delivery record in WSH_NEW_DELIVERIES table. The DELIVERY_ID, NAME and return status of a new delivery are passed as OUT parameters, while the DELIVERY_ID or NAME of an existing delivery for update is passed as an IN parameter.
    Pass IN parameter p_action_code value UPDATE ---> incase you want to update existing delivery.
    Pass IN parameter p_action_code value CREATE --> incase you want to create a new dleivery.
    Parameter Usage Type Required
    p_api_version_number IN Number x
    p_init_msg_list IN Varchar2 -
    x_return_status OUT Varchar2 -
    x_msg_count OUT Number -
    x_msg_data OUT Varchar2 -
    p_action_code IN Varchar2 x
    p_delivery_info IN OUT Record x
    p_delivery_name IN Varchar2 -
    x_delivery_id OUT Number -
    x_name OUT Varchar2 -
    I hope all this infor. comes handy.
    -Dhawang

Maybe you are looking for

  • YouTube videos no longer play on Macbook Pro

    I don't remember the exact time that this started but I keep getting "An error Occurred Please try again later".   W\hen I try to watch a  Youtube Video.  This happens on Safari and Firefox with Mavericks. I can watch some YouTube videos from other w

  • New ipod shuffle remote doesn't work correctly

    I've bought a player today, plugged in to USB port. iTunes proposed me to update to the latest version - I agreed. So I had the lates updates. When I try to increase volume using remote - it doesn't work. When I stop playing by using middle button th

  • Which application uses that file and prevents emptying the Trash?

    Hi, This has been with the OS for quite some time. Every once in a while, when trying to empty the trash, I get the error message: "The operation can't be completed because the item 'filename.estension' is in use." How useless is that? Now, if OS X t

  • Lightroom 4.3 & Flickr Authorization Issue

    When I try to authorize Flickr in the publish services, nothing happens. I click authorize and then click authorize again on the permission window and then it just returns to the beginning as not authorized. No internet explorer window even opens? I

  • Synchronization in light grey

    I am trying to synchronize my iPhone and iPad with my main computer. But the synchronize button on the lower right hand corner is in light grey and therefore cannot be selected. Does somebody know why? thanks.