You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This project welcomes contributions and suggestions. Most contributions require you to agree to a
4
+
Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us
5
+
the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.
6
+
7
+
When you submit a pull request, a CLA bot will automatically determine whether you need to provide
8
+
a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions
9
+
provided by the bot. You will only need to do this once across all repos using our CLA.
10
+
11
+
This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
12
+
For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or
13
+
contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
14
+
15
+
## How to contribute
16
+
17
+
### Reporting bugs
18
+
19
+
If you find a bug, please report it by [opening an issue](https://github.com/Azure-Samples/java-ai/issues/new). Please include:
20
+
21
+
- A clear and descriptive title
22
+
- A detailed description of the issue
23
+
- Steps to reproduce the problem
24
+
- Expected vs actual behavior
25
+
- Screenshots if applicable
26
+
- Environment details (OS, Java version, etc.)
27
+
28
+
### Suggesting enhancements
29
+
30
+
Enhancement suggestions are tracked as [GitHub issues](https://github.com/Azure-Samples/java-ai/issues). When creating an enhancement suggestion, please include:
31
+
32
+
- A clear and descriptive title
33
+
- A detailed description of the proposed enhancement
34
+
- An explanation of why this enhancement would be useful
35
+
- If possible, a draft implementation approach
36
+
37
+
### Pull requests
38
+
39
+
1. Fork the repository
40
+
2. Create a feature branch from `main`
41
+
3. Make your changes
42
+
4. Add or update tests as needed
43
+
5. Ensure all tests pass
44
+
6. Update documentation if needed
45
+
7. Submit a pull request
46
+
47
+
### Development setup
48
+
49
+
To set up the development environment:
50
+
51
+
1. Clone the repository
52
+
2. Ensure you have Java 17+ installed
53
+
3. Install Azure CLI and Azure Developer CLI (azd)
54
+
4. Install Docker or Podman
55
+
5. Follow the instructions in the [README.md](README.md) to build and run locally
56
+
57
+
### Code style
58
+
59
+
- Follow existing code style and formatting
60
+
- Use meaningful variable and method names
61
+
- Add comments for complex logic
62
+
- Ensure all public methods have appropriate documentation
63
+
64
+
### Testing
65
+
66
+
- Add unit tests for new functionality
67
+
- Ensure all existing tests pass
68
+
- Test your changes locally before submitting
69
+
70
+
### Documentation
71
+
72
+
- Update README.md if needed
73
+
- Add inline documentation for new public APIs
74
+
- Update any relevant markdown files in the documentation
75
+
76
+
## Resources
77
+
78
+
-[Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
This AI Shop application demonstrates several key features:
19
+
20
+
-**Multi-modal AI Integration**: Uses Azure OpenAI's vision capabilities to analyze product images and generate comprehensive product information automatically
21
+
-**Microservices Architecture**: Built with Spring Boot microservices including API Gateway, Eureka service discovery, and specialized services for different functions
22
+
-**Cloud-Native Deployment**: Fully containerized application deployable to Azure Container Apps with Azure Developer CLI (azd)
23
+
-**AI-Powered Categorization**: Intelligent product categorization using LangChain4j for enhanced product organization
24
+
-**Secure Blob Storage**: Azure Blob Storage integration with SAS token generation for secure image handling
25
+
-**Modern React UI**: Clean, responsive user interface for easy product upload and management
26
+
-**Enterprise Security**: Entra ID authentication and role-based access control for production readiness
27
+
28
+
## Getting Started
29
+
30
+
### Quick Start with Azure
31
+
32
+
The fastest way to get started is to deploy directly to Azure:
33
+
34
+
1.**Fork this repository** to your GitHub account
35
+
2.**Open in GitHub Codespace** (recommended) or clone locally
36
+
3.**Login to Azure** and run deployment:
37
+
```bash
38
+
azd auth login
39
+
azd up
40
+
```
41
+
4.**Access your application** at the provided endpoint after deployment completes
42
+
43
+
### Local Development
44
+
45
+
For local development and testing:
46
+
47
+
1.**Prerequisites**: Ensure you have Java 17+, Azure CLI, azd, and Docker installed
48
+
2.**Build the common module**: Follow instructions in [src/java-ai-common/common/README.md](src/java-ai-common/common/README.md)
49
+
3.**Start services in order**: Follow the detailed steps in the "Run locally" section below
50
+
4.**Access the application** at http://localhost:3000
51
+
52
+
## Guidance
53
+
54
+
### Architecture Decisions
55
+
56
+
This application follows several architectural patterns:
57
+
58
+
-**Microservices Pattern**: Each service has a single responsibility and can be deployed independently
59
+
-**API Gateway Pattern**: Centralized entry point for all client requests with service orchestration
60
+
-**Service Discovery**: Uses Eureka for dynamic service registration and discovery in local development
61
+
-**Event-Driven Architecture**: Services communicate through well-defined APIs and events
62
+
-**Cloud-First Design**: Built specifically for Azure Container Apps with proper scaling and monitoring
63
+
64
+
### Best Practices Implemented
65
+
66
+
-**Security**: Entra ID authentication, managed identities, and secure secret management
67
+
-**Monitoring**: Azure Log Analytics integration for comprehensive observability
68
+
-**Scalability**: Container Apps auto-scaling based on demand
69
+
-**Reliability**: Health checks, graceful degradation, and proper error handling
70
+
-**Performance**: Optimized container images and efficient resource utilization
71
+
72
+
### Customization Guidelines
73
+
74
+
To adapt this application for your use case:
75
+
76
+
1.**Model Configuration**: Update AI model deployments in `infra/bicep/deploy.bicep`
77
+
2.**Service Logic**: Modify business logic in individual service modules
78
+
3.**UI Customization**: Update React components in `src/ai-shop-ui`
79
+
4.**Data Models**: Extend DTOs in `src/java-ai-common` for additional fields
80
+
5.**Infrastructure**: Adjust Azure resources in bicep templates as needed
-[GitHub Issues](https://github.com/Azure-Samples/java-ai/issues) for project-specific questions
111
+
-[Microsoft Q&A for Azure](https://learn.microsoft.com/en-us/answers/products/azure)
112
+
16
113
## Prerequisites
17
114
18
115
Easiest way to start is to Fork and [open the repository in a GitHub Codespace](https://github.com/codespaces/new/Azure-Samples/java-ai) as it contains all the prerequisites.
| 9.0-10.0 | Releases within the previous three months |
10
+
| 4.0-8.9 | Most recent release |
11
+
12
+
## Reporting a Vulnerability
13
+
14
+
Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/).
15
+
16
+
If you believe you have found a security vulnerability in any Microsoft-owned repository that meets [Microsoft's definition of a security vulnerability](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10)), please report it to us as described below.
17
+
18
+
## Reporting Security Issues
19
+
20
+
**Please do not report security vulnerabilities through public GitHub issues.**
21
+
22
+
Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report).
23
+
24
+
If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc).
25
+
26
+
You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc).
27
+
28
+
Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:
29
+
30
+
* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
31
+
* Full paths of source file(s) related to the manifestation of the issue
32
+
* The location of the affected source code (tag/branch/commit or direct URL)
33
+
* Any special configuration required to reproduce the issue
34
+
* Step-by-step instructions to reproduce the issue
35
+
* Proof-of-concept or exploit code (if possible)
36
+
* Impact of the issue, including how an attacker might exploit the issue
37
+
38
+
This information will help us triage your report more quickly.
39
+
40
+
If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs.
41
+
42
+
## Preferred Languages
43
+
44
+
We prefer all communications to be in English.
45
+
46
+
## Policy
47
+
48
+
Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd).
0 commit comments